diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-11-10 22:47:08 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-11-10 22:47:08 +0000 |
commit | e4b7bba8793bab39f0a2ac0cb059ea9b90d89042 (patch) | |
tree | 333c801d8ca71a4739efa50540db24ad70e7272e /src | |
parent | b77170410fbc46495d9d150a501b4387e410693a (diff) | |
download | hercules-e4b7bba8793bab39f0a2ac0cb059ea9b90d89042.tar.gz hercules-e4b7bba8793bab39f0a2ac0cb059ea9b90d89042.tar.bz2 hercules-e4b7bba8793bab39f0a2ac0cb059ea9b90d89042.tar.xz hercules-e4b7bba8793bab39f0a2ac0cb059ea9b90d89042.zip |
- Fixed some line delimiter issues in script.c
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9196 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r-- | src/map/pc.c | 1 | ||||
-rw-r--r-- | src/map/script.c | 84 |
2 files changed, 42 insertions, 43 deletions
diff --git a/src/map/pc.c b/src/map/pc.c index d3eec5935..dd5ea32c3 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -783,7 +783,6 @@ int pc_authfail(struct map_session_data *sd) { //Attempts to set a mob. int pc_set_hate_mob(struct map_session_data *sd, int pos, struct block_list *bl) { - const char hate_var[3][NAME_LENGTH] = {"PC_HATE_MOB_SUN","PC_HATE_MOB_MOON","PC_HATE_MOB_STAR"}; int class_; if (!sd || !bl || pos < 0 || pos > 2) return 0; diff --git a/src/map/script.c b/src/map/script.c index 767402512..a995b12bb 100644 --- a/src/map/script.c +++ b/src/map/script.c @@ -9090,48 +9090,48 @@ int buildin_failedremovecards(struct script_state *st) return 0; } -/* ================================================================
- * mapwarp "<from map>","<to map>",<x>,<y>,<type>,<ID for Type>;
- * type: 0=everyone, 1=guild, 2=party(uncoded); [Reddozen]
- * ================================================================
- */
-int buildin_mapwarp(struct script_state *st) // Added by RoVeRT
-{
- int x,y,m,check_val=0,check_ID=0,i=0;
- char *str;
- char *mapname;
- unsigned int index;
- mapname=conv_str(st,& (st->stack->stack_data[st->start+2]));
- str=conv_str(st,& (st->stack->stack_data[st->start+3]));
- x=conv_num(st,& (st->stack->stack_data[st->start+4]));
- y=conv_num(st,& (st->stack->stack_data[st->start+5]));
- check_val=conv_num(st,& (st->stack->stack_data[st->start+6]));
- check_ID=conv_num(st,& (st->stack->stack_data[st->start+7]));
-
- if( (m=map_mapname2mapid(mapname))< 0)
- return 0;
-
- if(!(index=mapindex_name2id(str)))
- return 0;
-
- if(!(check_val))
- map_foreachinmap(buildin_areawarp_sub,
- m,BL_PC,index,x,y);
-
- if(check_val==1){
- struct guild *g = guild_search(check_ID);
-
- if (g){
- for( i=0; i < g->max_member; i++)
- {
- if(g->member[i].sd && g->member[i].sd->bl.m==m){
- pc_setpos(g->member[i].sd,index,x,y,3);
- }
- }
- }
- }
-
- return 0;
+/* ================================================================ + * mapwarp "<from map>","<to map>",<x>,<y>,<type>,<ID for Type>; + * type: 0=everyone, 1=guild, 2=party(uncoded); [Reddozen] + * ================================================================ + */ +int buildin_mapwarp(struct script_state *st) // Added by RoVeRT +{ + int x,y,m,check_val=0,check_ID=0,i=0; + char *str; + char *mapname; + unsigned int index; + mapname=conv_str(st,& (st->stack->stack_data[st->start+2])); + str=conv_str(st,& (st->stack->stack_data[st->start+3])); + x=conv_num(st,& (st->stack->stack_data[st->start+4])); + y=conv_num(st,& (st->stack->stack_data[st->start+5])); + check_val=conv_num(st,& (st->stack->stack_data[st->start+6])); + check_ID=conv_num(st,& (st->stack->stack_data[st->start+7])); + + if( (m=map_mapname2mapid(mapname))< 0) + return 0; + + if(!(index=mapindex_name2id(str))) + return 0; + + if(!(check_val)) + map_foreachinmap(buildin_areawarp_sub, + m,BL_PC,index,x,y); + + if(check_val==1){ + struct guild *g = guild_search(check_ID); + + if (g){ + for( i=0; i < g->max_member; i++) + { + if(g->member[i].sd && g->member[i].sd->bl.m==m){ + pc_setpos(g->member[i].sd,index,x,y,3); + } + } + } + } + + return 0; } int buildin_cmdothernpc(struct script_state *st) // Added by RoVeRT |