Jump to content
  • 0

checking value to script to atcommand?


hakuren

Question


  • Group:  Members
  • Topic Count:  120
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   6
  • Joined:  12/02/11
  • Last Seen:  

hello is this possible when an npc set a value example:

-------------------------------------------------

( On The Script )

set hehe,1; and the atcommand will check

-------------------------------------------------

( On The Atcommand Source )

if (hehe == 1) {

end;

}

is this possible?

Link to comment
Share on other sites

5 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  754
  • Reputation:   186
  • Joined:  05/22/12
  • Last Seen:  

you can do this

if(pc_readglobalreg(sd, "hehe") == 1){
end;
}

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  7
  • Topics Per Day:  0.00
  • Content Count:  113
  • Reputation:   5
  • Joined:  06/06/12
  • Last Seen:  

hmm, set a value for what ? can you explain more what you're trying to accomplish ?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  120
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   6
  • Joined:  12/02/11
  • Last Seen:  

you can do this

if(pc_readglobalreg(sd, "hehe") == 1){
end;
}

is this in the npc or in the source code?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  754
  • Reputation:   186
  • Joined:  05/22/12
  • Last Seen:  

source code.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  120
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   6
  • Joined:  12/02/11
  • Last Seen:  

hmm, set a value for what ? can you explain more what you're trying to accomplish ?

hmm let me give you an example:

when player 1 talk to npc 1 it will set the "set hehe,1;" and the atcommand example atcommand go will check it @go 1

"if ( hehe == 1 ) {"

"clif_displaymessage(fd, "Hehe is activated.");"

"}"

is this possible?

source code.

wooo it works! thank you clydelion ^_^

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...