summaryrefslogtreecommitdiff
path: root/src/map/script.c
diff options
context:
space:
mode:
authorLance <Lance@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-07 02:51:50 +0000
committerLance <Lance@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-07 02:51:50 +0000
commit1300e71f7b19b820dae2a984c9f59ac32c13d6c7 (patch)
tree94040e5740015eaab38f16a7fcd29700ae12f1b2 /src/map/script.c
parent7bfe279684f65846e4c2255b5ee55551d2ab0656 (diff)
downloadhercules-1300e71f7b19b820dae2a984c9f59ac32c13d6c7.tar.gz
hercules-1300e71f7b19b820dae2a984c9f59ac32c13d6c7.tar.bz2
hercules-1300e71f7b19b820dae2a984c9f59ac32c13d6c7.tar.xz
hercules-1300e71f7b19b820dae2a984c9f59ac32c13d6c7.zip
* [Improved]:
- mob_dead not to remove script controlled monsters with player sprites. (can be removed later using removemob command, it can be resurrected too :D) * [Added]: - buildin_mobdeadsit :D git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7024 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/script.c')
-rw-r--r--src/map/script.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/map/script.c b/src/map/script.c
index 932252cde..181b50084 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -430,6 +430,7 @@ int buildin_mobstop(struct script_state *st);
int buildin_mobassist(struct script_state *st);
int buildin_mobtalk(struct script_state *st);
int buildin_mobemote(struct script_state *st);
+int buildin_mobdeadsit(struct script_state *st);
int buildin_mobattach(struct script_state *st);
// <--- [zBuffer] List of mob control commands
int buildin_sleep(struct script_state *st);
@@ -770,6 +771,7 @@ struct {
{buildin_mobassist,"mobassist","i*"},
{buildin_mobtalk,"mobtalk","is"},
{buildin_mobemote,"mobemote","ii"},
+ {buildin_mobdeadsit,"mobdeadsit","ii"},
{buildin_mobattach,"mobattach","i*"},
// <--- [zBuffer] List of mob control commands
{buildin_sleep,"sleep","i"},
@@ -10762,6 +10764,25 @@ int buildin_mobemote(struct script_state *st) {
return 0;
}
+int buildin_mobdeadsit(struct script_state *st){
+ int id, action;
+ struct mob_data *md = NULL;
+ id = conv_num(st, & (st->stack->stack_data[st->start+2]));
+ action = conv_num(st, & (st->stack->stack_data[st->start+3]));
+ if((md = (struct mob_data *)map_id2bl(id)) && md->bl.type == BL_MOB){
+ if(action > -1 && action < 3){
+ md->vd->dead_sit = action;
+ } else {
+ ShowError("buildin_mobdeadsit: Unrecognized action.\n");
+ report_src(st);
+ }
+ } else {
+ ShowError("buildin_mobdeadsit: Target is not a monster.\n");
+ report_src(st);
+ }
+ return 0;
+}
+
int buildin_mobattach(struct script_state *st){
int id;
struct mob_data *md = NULL;