Jump to content
  • 0

Doubt about var


Dynasty

Question


  • Group:  Members
  • Topic Count:  24
  • Topics Per Day:  0.01
  • Content Count:  151
  • Reputation:   5
  • Joined:  11/09/12
  • Last Seen:  

Hi

 

i have a doubt about Account variable,  if i not set it a var it means that the var that i put in a conditional it = to 0?

 

ex:

if(var == 0)
mes "dfasdf";
close;

without setting before?

Link to comment
Share on other sites

6 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  50
  • Topics Per Day:  0.01
  • Content Count:  1702
  • Reputation:   238
  • Joined:  09/05/12
  • Last Seen:  

Yea. You can also set var = 0 in the first place. :P 

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  24
  • Topics Per Day:  0.01
  • Content Count:  151
  • Reputation:   5
  • Joined:  11/09/12
  • Last Seen:  

Set it like it was a C languague?

Ex:
Oninit:
Var = 0
End;

If(var = 0)
Mes "fdsafds";
Close;

?

Edited by Dynasty
Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2350
  • Joined:  10/28/11
  • Last Seen:  

recently just explained that variable cant be remove by using the way you shown above..

it cant be done ...with your way..

the script is required to attach to a player when try to clear the variable since the variable is player based.

 

althought you can try clear it from the SQL  table, but this required all players to logoff before you can do so..

 
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  24
  • Topics Per Day:  0.01
  • Content Count:  151
  • Reputation:   5
  • Joined:  11/09/12
  • Last Seen:  

recently just explained that variable cant be remove by using the way you shown above..

it cant be done ...with your way..

the script is required to attach to a player when try to clear the variable since the variable is player based.

 

althought you can try clear it from the SQL  table, but this required all players to logoff before you can do so..

 

 

sorry but i dont get it D;!

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  81
  • Topics Per Day:  0.02
  • Content Count:  1654
  • Reputation:   583
  • Joined:  08/09/12
  • Last Seen:  

if(!xyz)

mes "Variable xyz is empty or never been used before.";

else

mes "Variable xyz contains "+xyz;

close;

/ok
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  24
  • Topics Per Day:  0.01
  • Content Count:  151
  • Reputation:   5
  • Joined:  11/09/12
  • Last Seen:  

if(!xyz)
mes "Variable xyz is empty or never been used before.";
else
mes "Variable xyz contains "+xyz;
close;
/ok

 

 

Ok... now i get it :D thk  

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...