Jump to content
  • 0

Check players title


WhiteEagle

Question


  • Group:  Members
  • Topic Count:  76
  • Topics Per Day:  0.02
  • Content Count:  455
  • Reputation:   57
  • Joined:  08/28/12
  • Last Seen:  

Hey folks,
at first "Merry Xmas" ^-^

Is there any way to check per script what title a player has selected?
I want it to know for items like the Kafra Uniform. It gives bonis when a player uses the title 'Kafra'.
 

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

  • Group:  Forum Moderator
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  796
  • Reputation:   101
  • Joined:  05/23/12
  • Last Seen:  

@WhiteEagle

I've selected the wrong row I saw it yet. It's should of course be:

query_sql("SELECT `title_id` FROM `char` WHERE `char_id`="+getcharid(0),.@title_id);

 

Instead of:

query_sql("SELECT `char_id` FROM `char` WHERE `char_id`="+getcharid(0),.@title_id);

 

Please let us know if u solved it.

 

Best regards,

Rynbef~

Edited by Rynbef
  • Upvote 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  25
  • Topics Per Day:  0.01
  • Content Count:  283
  • Reputation:   76
  • Joined:  06/13/13
  • Last Seen:  

just use function in your item bonus, in the function you can query to sql db to get the tittle currenty used.

Link to comment
Share on other sites

  • 0

  • Group:  Forum Moderator
  • Topic Count:  47
  • Topics Per Day:  0.01
  • Content Count:  796
  • Reputation:   101
  • Joined:  05/23/12
  • Last Seen:  

Idk which title u exactly means. The char database just contains a title id as int.

query_sql("SELECT `title_id` FROM `char` WHERE `char_id`="+getcharid(0),.@title_id);

 

I don't think u means an buying or vending store title?

 

Rynbef~

 

Edited by Rynbef
wrong statement
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  76
  • Topics Per Day:  0.02
  • Content Count:  455
  • Reputation:   57
  • Joined:  08/28/12
  • Last Seen:  

6 hours ago, Rynbef said:

I don't think u means an buying or vending store title?

Haha, you're right. xD
And thanks for your help.

I am interested in items that give bonuses related to titles.
Like for example:

"_______________________",
"When equipped with \"Kafra\" title: Exp gained +5%, Item drop rate +5%, All Stats +4.",
"_______________________",


Thanks, that should work.

6 hours ago, Rynbef said:

query_sql("SELECT `char_id` FROM `char` WHERE `char_id`="+getcharid(0),.@title_id);

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  76
  • Topics Per Day:  0.02
  • Content Count:  455
  • Reputation:   57
  • Joined:  08/28/12
  • Last Seen:  

It now works as it should, except for the fact that if you reselect the title, you have to log in again before it will be recognized.
Apart from that, I don't find any problems so far.

Thanks Rynbef~

WhiteEagle

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