Difference between revisions of "FALSE/pt"
< FALSE
Jump to navigation
Jump to search
Line 3: | Line 3: | ||
|type=integer | |type=integer | ||
|value=0 | |value=0 | ||
|desc=Constante de tipo integer (número inteiro) que armazena o valor ZERO.<br> '''FALSE=0'''.<br><br>''Usada em | |desc=Constante de tipo integer (número inteiro) que armazena o valor ZERO.<br> '''FALSE=0'''.<br><br>''Usada em variáveis que representam valores booleanos.'' | ||
|examples=<lsl>integer bool; | |examples=<lsl>integer bool; | ||
string boolStr; | string boolStr; |
Revision as of 13:41, 31 December 2009
LSL Portal | Functions | Events | Types | Operadores | Constants | Flow Control | Biblioteca de Script | Tutorials |
Exemplos<lsl>integer bool; string boolStr; string BOOL_STR_FALSE = "FALSE (FALSO)"; string BOOL_STR_TRUE = "TRUE (VERDADEIRO)"; default{ state_entry(){ bool= TRUE; llSetText("Clique aqui para mudar o valor da varíavel booleana.",<1,1,1>,1); } touch_start(integer total_number) { if (bool){ // se bool é TRUE recebe FALSE bool = FALSE; boolStr = BOOL_STR_FALSE; }else{//senão recebe TRUE, pois é FALSE bool=TRUE; boolStr = BOOL_STR_TRUE; } string txt = "Você mudou o valor da variável booleana para "+ boolStr+"\nClique para mudar novamente."; llSay(0,txt); llSetText(txt,<1,1,1>,1); } } </lsl> |