Jump to content
  • 0

Help on this one


Diconfrost VaNz

Question


  • Group:  Members
  • Topic Count:  51
  • Topics Per Day:  0.01
  • Content Count:  994
  • Reputation:   47
  • Joined:  11/13/11
  • Last Seen:  

Vengeance made me this custom commands...the problem is this...

when i try to type it...

it only show this

"You have now been warped to the Mall"

but nothing happens, i stay in the place where i am.

ACMD_FUNC(mall)
{
nullpo_retr(-1, sd);

pc_setpos(sd, "force_3-2", 19, 177, CLR_TELEPORT);
clif_displaymessage(fd, "You have now been warped to the Mall");
return 0;
}

{ "mall",				10,10,	 atcommand_mall },

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

  • 0

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

well, this is my way to create this type of stuffs..xD

/*-----------*
* @mall
*-----------*/
int atcommand_mall(const int fd, struct map_session_data *sd, const char *command, const char *message)
{
nullpo_retr(-1,sd);
npc_event(sd,"Mall::OnWarp",0);
return 0;
}

then create this NPC script

- script Mall -1,{
OnWarp:
message strcharinfo(0),"You have been warped to Mall.";
warp "mapname",0,0;
end;
}

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  51
  • Topics Per Day:  0.01
  • Content Count:  994
  • Reputation:   47
  • Joined:  11/13/11
  • Last Seen:  

oh thanks...that one works :)

can i transform it into @quest command by changing

npc_event(sd,"Quest::OnWarp",0);

Link to comment
Share on other sites

  • 0

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

/*-----------*
* @Custom
*-----------*/
int atcommand_Custom(const int fd, struct map_session_data *sd, const char *command, const char *message)
{
nullpo_retr(-1,sd);
npc_event(sd,"Custom::OnCustom",0);
return 0;
}

- script Custom -1,{
OnCustom:
<content>
end;
}

change every single Custom that i write in above

basically, this command just run the specific part / Label of NPC script you have mentioned in the SRC there

Edited by Emistry
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  51
  • Topics Per Day:  0.01
  • Content Count:  994
  • Reputation:   47
  • Joined:  11/13/11
  • Last Seen:  

oh thanks :3

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  31
  • Topics Per Day:  0.01
  • Content Count:  967
  • Reputation:   53
  • Joined:  11/13/11
  • Last Seen:  

/*-----------*
* @Custom
*-----------*/
int atcommand_Custom(const int fd, struct map_session_data *sd, const char *command, const char *message)
{
nullpo_retr(-1,sd);
npc_event(sd,"Custom::OnCustom",0);
return 0;
}

- script Custom -1,{
OnCustom:
<content>
end;
}

change every single Custom that i write in above

basically, this command just run the specific part / Label of NPC script you have mentioned in the SRC there

int_atcommand is OLD one

use ACMD_FUNC()

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  51
  • Topics Per Day:  0.01
  • Content Count:  994
  • Reputation:   47
  • Joined:  11/13/11
  • Last Seen:  

okay :)

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  114
  • Topics Per Day:  0.02
  • Content Count:  298
  • Reputation:   4
  • Joined:  03/13/12
  • Last Seen:  

this one work for eamod aswell?

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