Jump to content
  • 0
Tio Akima

condition if () in skill

Question

I'm trying to put a condition on a custom skill ... But I'm having problems.
 
the condition is an if () that identifies the class of player .... and depending on the class, the skill performs a particular function.
 
I tried this:
 
if(pc->jobchange == 15 || 4016 || 4077){...break;} 

 

then I tried this:

 

if(sd->status.class_ == JOB_MONK || JOB_CHAMPION || JOB_SURA ){...break;}

 

And it did not work.
 
The intention is to verify the player's class that is using the skill.
 
help-me? 0/

Share this post


Link to post
Share on other sites

2 answers to this question

Recommended Posts

  • 0

(sd->class_&MAPID_UPPERMASK) == MAPID_STAR_GLADIATOR

 

by the way you might want to change "sd" to "tsd" or "dstsd" depending on where you are using it

Share this post


Link to post
Share on other sites
  • 0
oh thank Evilpuncker
 
in my case would be:
if(sd->class_&MAPID_UPPERMASK) == MAPID_MONK  ||  MAPID_CHAMPION ||  MAPID_SURA ){...break;}
 
you could explain to me the difference between them, '' sd '', '' tsd '' and '' dstsd '' or, in which case they apply better?
 
thank!  very thanks!

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.