diff options
author | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-08-16 14:14:11 +0000 |
---|---|---|
committer | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-08-16 14:14:11 +0000 |
commit | 3c73a02748ca50a32005a5b73933a582cd87b80f (patch) | |
tree | 9c35effdea7e3bf0a2a944957b7c2e489ba68f34 /src/map/script.c | |
parent | ccc18ecfe671803c6d6b9b6dd790c45cdf28c9ac (diff) | |
download | hercules-3c73a02748ca50a32005a5b73933a582cd87b80f.tar.gz hercules-3c73a02748ca50a32005a5b73933a582cd87b80f.tar.bz2 hercules-3c73a02748ca50a32005a5b73933a582cd87b80f.tar.xz hercules-3c73a02748ca50a32005a5b73933a582cd87b80f.zip |
* Fixed npc chatrooms not being deleted on npc unload/reload (crash)
* Modified chat code a bit for more clarity
- replaced double-indirection on 'owner' with a normal pointer
- separated some common functionality to 'chat_createchat()'
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11023 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/script.c')
-rw-r--r-- | src/map/script.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/map/script.c b/src/map/script.c index d689463cf..472b4e545 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -8942,8 +8942,6 @@ BUILDIN_FUNC(waitingroom) title = script_getstr(st, 2); limit = script_getnum(st, 3); - if( limit == 0 ) - pub = 3; if( script_hasdata(st,5) ) { @@ -8957,15 +8955,16 @@ BUILDIN_FUNC(waitingroom) else {// ,"<event>",<trigger> ev = script_getstr(st, 4); - trigger=script_getnum(st,5); + trigger = script_getnum(st,5); } } else if( script_hasdata(st,4) ) {// ,"<event>" ev = script_getstr(st, 4); + trigger = limit; } if( (nd=(struct npc_data *)map_id2bl(st->oid)) != NULL ) - chat_createnpcchat(nd, limit, pub, trigger, title, ev); + chat_createnpcchat(nd, title, limit, pub, trigger, ev); return 0; } |