OsGetNumberOfNotecardLines

From OpenSimulator

(Difference between revisions)
Jump to: navigation, search
m (XEngine to OSSL)
 
(6 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{osslfunc|
+
{{osslfunc
threat_level = VeryHigh
+
|threat_level=VeryHigh
|
+
|permissions=${OSSL|osslParcelO}ESTATE_MANAGER,ESTATE_OWNER
function_syntax = <source lang="lsl">
+
|delay=0
osGetNumberOfNotecardLines(string name)  
+
|function_syntax=integer osGetNumberOfNotecardLines(string name)  
</source>
+
|ossl_example=<source lang="lsl">
|
+
// osGetNumberOfNotecardLines example
ossl_example = <source lang="lsl">//Example usage:
+
 
default {
+
default  
     state_entry() {
+
{
        integer i;
+
     state_entry()
 +
    {
 
         string notecard = llGetInventoryName(INVENTORY_NOTECARD, 0);
 
         string notecard = llGetInventoryName(INVENTORY_NOTECARD, 0);
         for(i=1; i&lt;=osGetNumberOfNotecardLines(notecard); i++) {
+
         integer length=osGetNumberOfNotecardLines(notecard);
            llSay(0, osGetNotecardLine(notecard, i));
+
        llSay(0, "NumberOfNotecardLines is: " + (string) length);
        }
+
 
 
     }
 
     }
 
}
 
}
 
</source>
 
</source>
|  
+
|description=This function directly reads how many lines a notecard has if the specified notecard exists within the task inventory, bypassing the dataserver event to reduce code complexity.
additional_info = This function directly reads how many lines a notecard has if the specified notecard exists within the task inventory, bypassing the dataserver event to reduce code complexity.
+
 
|
 
|
 
}}
 
}}

Latest revision as of 06:36, 7 November 2019

integer osGetNumberOfNotecardLines(string name)
This function directly reads how many lines a notecard has if the specified notecard exists within the task inventory, bypassing the dataserver event to reduce code complexity.
Threat Level VeryHigh
Permissions ${OSSL|osslParcelO}ESTATE_MANAGER,ESTATE_OWNER
Delay 0 seconds
Example(s)
// osGetNumberOfNotecardLines example
 
default 
{
    state_entry()
    {
        string notecard = llGetInventoryName(INVENTORY_NOTECARD, 0);
        integer length=osGetNumberOfNotecardLines(notecard);
        llSay(0, "NumberOfNotecardLines is: " + (string) length);
 
    }
}
Personal tools
General
About This Wiki