diff options
author | Lance <Lance@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-17 16:47:21 +0000 |
---|---|---|
committer | Lance <Lance@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-17 16:47:21 +0000 |
commit | ec70ae22a2125ec3b71c2318a92746c0214efeb4 (patch) | |
tree | 95da958eff529b00b9972e693872cd6010c31f18 /src/map/mob.c | |
parent | 0985a47e31a4979020a87e8cb1768f6b99cf6cbf (diff) | |
download | hercules-ec70ae22a2125ec3b71c2318a92746c0214efeb4.tar.gz hercules-ec70ae22a2125ec3b71c2318a92746c0214efeb4.tar.bz2 hercules-ec70ae22a2125ec3b71c2318a92746c0214efeb4.tar.xz hercules-ec70ae22a2125ec3b71c2318a92746c0214efeb4.zip |
* Fixed misleading and inaccurately documented events and added a missing flag.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5649 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/mob.c')
-rw-r--r-- | src/map/mob.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/src/map/mob.c b/src/map/mob.c index b54edaab7..24806b374 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -2848,16 +2848,18 @@ int mob_damage(struct block_list *src,struct mob_data *md,int damage,int type) } else if (mvp_sd) {
//lordalfa
- pc_setglobalreg(mvp_sd,"killedrid",(md->class_));
- if (script_config.event_script_type == 0) {
- struct npc_data *npc;
- if ((npc = npc_name2id("NPCKillEvent"))) {
- run_script(npc->u.scr.script,0,mvp_sd->bl.id,npc->bl.id); // NPCKillNPC
- ShowStatus("Event '"CL_WHITE"NPCKillEvent"CL_RESET"' executed.\n");
- }
+ pc_setglobalreg(mvp_sd,"killedrid",(md->class_));
+ if(sd->state.event_kill_mob){
+ if (script_config.event_script_type == 0) {
+ struct npc_data *npc;
+ if ((npc = npc_name2id(script_config.kill_mob_event_name))) {
+ run_script(npc->u.scr.script,0,mvp_sd->bl.id,npc->bl.id); // PCKillNPC [Lance]
+ ShowStatus("Event '"CL_WHITE"%s"CL_RESET"' executed.\n",script_config.kill_mob_event_name);
+ }
} else {
- ShowStatus("%d '"CL_WHITE"%s"CL_RESET"' events executed.\n",
- npc_event_doall_id("NPCKillEvent", mvp_sd->bl.id), "NPCKillEvent");
+ ShowStatus("%d '"CL_WHITE"%s"CL_RESET"' events executed.\n",
+ npc_event_doall_id(script_config.kill_mob_event_name, mvp_sd->bl.id), script_config.kill_mob_event_name);
+ }
}
}
//[lordalfa]
|