Jump to content
  • 0
Humble_Bee

Updating Race through AT Command

Question

This is my code for a race changing AT Command (the very basic start of one- I'll add more later). It is not currently updating the player's race though. Can someone more familiar with C++ show me what I would need to change? I know that stat updates show up in like 5+ places in rAthena code, so I'm not sure how much more work I'll need to do it. You would think it would be as easy as querying the server for the data and using some sort of set command, but I only "talk" the vocabulary, I don't actually know how to use it. Ha.

 

ACMD_FUNC(changerace)
{		
char xrace[20];
struct status_data *base_status;
base_status = &sd->base_status;

nullpo_retr(-1, sd);

memset(atcmd_output, '\0', sizeof(atcmd_output));

if (sscanf(message, "%20s",&xrace) > 0) {
	if (xrace == "Formless" )
		sd->base_status.race = RC_FORMLESS;
}

return 0;
}

 

Edited by Humble_Bee
Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

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

Important Information

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