Jump to content
  • 0

Kill Counts Script NEED HELP


luisdgs19

Question


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  30
  • Reputation:   2
  • Joined:  12/26/12
  • Last Seen:  

I'm trying to make a script that each time you kill the monster with the id 1769 on the map aev_fild01 the server adds the amount of kills to a character variable.I tried doing it this way.

-<tab>script<tab>-1,{
OnNPCKillEvent:
<tab>doSomething;
}

But it doesn't work, could you guys help me

Link to comment
Share on other sites

5 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

Basic_Scripting

-    script    #test    -1,{
OnNPCKillEvent:
   if (killedrid == 1769 && strcharinfo(3) == "aev_fild01")
       set Var, Var+1;
   end;
}

Best to just spawn the monsters with an event label, though, as OnNPCKillEvent will trigger for all mob kills.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  6
  • Topics Per Day:  0.00
  • Content Count:  439
  • Reputation:   29
  • Joined:  12/08/11
  • Last Seen:  

you can see an example here

Edit:oh... it's the same with Euphy's..

Edited by Magnetix
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  30
  • Reputation:   2
  • Joined:  12/26/12
  • Last Seen:  

Basic_Scripting

-    script    #test    -1,{
OnNPCKillEvent:
   if (killedrid == 1769 && strcharinfo(3) == "aev_fild01")
       set Var, Var+1;
   end;
}

Best to just spawn the monsters with an event label, though, as OnNPCKillEvent will trigger for all mob kills.

How do i make a mob generate an event on killed ??

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

** Create a permanent monster spawn:

<map name>,<x>,<y>,<xs>,<ys>%TAB%monster%TAB%<monster name>%TAB%<mob id>,<amount>,<delay1>,<delay2>,<event>{,<mob size>,<mob ai>}

Event is a script event to be executed when the mob is killed. The event must

be in the form "NPCName::OnEventName" to execute, and the event name label

should start with "On". As with all events, if the NPC is an on-touch NPC, the

player who triggers the script must be within 'trigger' range for the event to

work.

Link to comment
Share on other sites


  • Group:  Developer
  • Topic Count:  10
  • Topics Per Day:  0.00
  • Content Count:  2407
  • Reputation:   613
  • Joined:  07/05/12
  • Last Seen:  

https://rathena.svn....pt_commands.txt

(temporary)

*monster "<map name>",<x>,<y>,"<name to show>",<mob id>,<amount>{,"<event label>",<size>,<ai>};

or (permanent)

<map name>,<x>,<y>,<xs>,<ys>%TAB%monster%TAB%<monster name>%TAB%<mob id>,<amount>,<delay1>,<delay2>,<event>{,<mob size>,<mob ai>}

Example:

splendide,237,143,5,	script	mlkjhg	456,{
monster "splendide",237,143,"--ja--",1002,1,"mlkjhg::OnMyMobDead";
end;

OnMyMobDead:
dispbottom "Quack quack goes a duck!";
end;
}

Edit : >.<

Edited by Capuche
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...