Keep GM on map after Emperium breaks

evilpuncker

vai se tratar garota
Messages
2,178
Points
0
Age
109
Location
bronzil
Github
EPuncker
Emulator
Client Version
2019-05-30a MAIN
Hello, I want to request a mod that would change the actual behavior:

actual: when emp got destroyed everyone except the guild that broke it will be warped out, even GMs (lvl 99 if possible)

what I want: when emp got destroyed everyone except the guild that broke it and GMs (lvl 99 if possible), will be warped out

Hope it is clear
default_smile.png


 
script.c

int buildin_maprespawnguildid_sub_pc(struct map_session_data* sd, va_list ap){ int16 m=va_arg(ap,int); int g_id=va_arg(ap,int); int flag=va_arg(ap,int); if(!sd || sd->bl.m != m) return 0; if( (sd->status.guild_id == g_id && flag&1) //Warp out owners || (sd->status.guild_id != g_id && flag&2) //Warp out outsiders || (sd->status.guild_id == 0) // Warp out players not in guild [Valaris] ) pc->setpos(sd,sd->status.save_point.map,sd->status.save_point.x,sd->status.save_point.y,CLR_TELEPORT); return 1;}add if ( pc_get_group_level(sd) < 99 ) somewhere inside heresure you can do it yourself

 
Last edited by a moderator:
thanks annie, just tested and it works flawlessly
default_smile.png
I love you

 
thanks annie, just tested and it works flawlessly
default_smile.png
I love you
hello could you tell me where u put if ( pc_get_group_level(sd) < 99 )?

Code:
int buildin_maprespawnguildid_sub_pc(struct map_session_data* sd, va_list ap){	int16 m=va_arg(ap,int);	int g_id=va_arg(ap,int);	int flag=va_arg(ap,int);	if(!sd || sd->bl.m != m)		return 0;	if(pc_get_group_level(sd) == 99)		return 0;	if(	    (sd->status.guild_id == g_id && flag&1) //Warp out owners	 || (sd->status.guild_id != g_id && flag&2) //Warp out outsiders	 || (sd->status.guild_id == 0)              // Warp out players not in guild [Valaris]	  )		pc->setpos(sd,sd->status.save_point.map,sd->status.save_point.x,sd->status.save_point.y,CLR_TELEPORT);	return 1;}
 
thanks annie, just tested and it works flawlessly
default_smile.png
I love you
hello could you tell me where u put if ( pc_get_group_level(sd) < 99 )?

int buildin_maprespawnguildid_sub_pc(struct map_session_data* sd, va_list ap){ int16 m=va_arg(ap,int); int g_id=va_arg(ap,int); int flag=va_arg(ap,int); if(!sd || sd->bl.m != m) return 0; if(pc_get_group_level(sd) == 99) return 0; if( (sd->status.guild_id == g_id && flag&1) //Warp out owners || (sd->status.guild_id != g_id && flag&2) //Warp out outsiders || (sd->status.guild_id == 0) // Warp out players not in guild [Valaris] ) pc->setpos(sd,sd->status.save_point.map,sd->status.save_point.x,sd->status.save_point.y,CLR_TELEPORT); return 1;}
+1 
default_meh.gif


 
Back
Top