Closed zauberparacelsus closed 6 years ago
It may not be obvious and could use some documentation but the values like "Cornerstone" etc are from a text column in the users database named customType
. This field is already available via DATA_ACCOUNT_TYPE
. Payment info is DATA_PAYINFO
, but I believe that's always 0 in InWorldz/Halcyon. Are there any fields remaining that aren't already available?
Well, the main thing this function intends to address are custom flags that a grid owner might define. The handling for cornerstone and others with existing LSL access is just for completeness.
I realized after posting my previous message that you said grid owner not land owner, so my previous response doesn't apply. I'm going to give a proper reply instead now. ;)
The examples above (that already exist) aren't flags, they are bits of data stored in fields in the users
database. At least for the ones normally in customType
, you can't have more than one value (e.g. in the sense of "Cornerstone" being one of the possible string values, and anything else wouldn't match).
It's possible to do but there would need to be more detail: a specific list of fields desired. As I mentioned above, most of the ones mentioned are already accessible to scripts. This could be a "low-hanging fruit" feature if you're only referring to the fields that already exist, but I think most of those are already available. So any proposal here should provide a very specific list of data items requested, at least the initial set to provide.
"So is this a suggestion to allow a script to set a flag on a user?"
No, this is reading, not writing. Specifically, reading stuff like this...
Yeah I realized I had misread your previous reply. Have you seen my edit?
As I said earlier, that text is already available via DATA_ACCOUNT_TYPE
.
Is there anything still missing?
Closing at Z's out-of-band request for now.
The following is a proposal for a pair of LSL functions, which is similar in scope to iwIsPlusUser, or llRequestAgentData with DATA_PAYINFO. These functions would be potentially useful for land/region management scripts, as well as any LSL-based grid management scripts.
I have chosen to propose this on the halcyon github rather than the InWorldz mantis, due to applications for non-InWorldz grids based on Halcyon.
integer iwCheckProfileFlag(key avatar, string flag);
The function checks to see if the specified avatar's profile flags contains the specified flag, and then returns TRUE if it does, or FALSE if not. In this context, a "profile flag" includes things such as "Resident", "Cornerstone", "InWorldz Employee", "Payment Info On File" etc. If a grid is using any custom flags such as "Grid Monkey", "Mentor", or such, the function would be able to check for those as well.integer iwCheckProfileFlagList(key avatar, list flags, integer option);
This function is an alternative version that checks multiple flags at once, provided as a list of strings. If the integer option is 0, then it will return TRUE if at least one of the specified flags is present. If option is 1, then it will return TRUE only if all of the specified flags are present. If option is 2, it will return the total number of flags that are present.