diff options
-rw-r--r-- | conf/battle/guild.conf | 6 | ||||
-rw-r--r-- | src/map/battle.c | 1 | ||||
-rw-r--r-- | src/map/battle.h | 1 | ||||
-rw-r--r-- | src/map/clif.c | 6 |
4 files changed, 12 insertions, 2 deletions
diff --git a/conf/battle/guild.conf b/conf/battle/guild.conf index cc22c327f..e9b025adb 100644 --- a/conf/battle/guild.conf +++ b/conf/battle/guild.conf @@ -36,3 +36,9 @@ require_glory_guild: no // If you want to change this value, clear the guild alliance table. // Default is 3 max_guild_alliance: 3 + +// When to re-display the guild notice +// Upon teleporting (regardless of changing maps): 2 (official) +// Upon changing maps: 1 +// Do not re-display: 0 (disabled) +guild_notice_changemap: 2 diff --git a/src/map/battle.c b/src/map/battle.c index 2a5e82e30..f64700f0c 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -6501,6 +6501,7 @@ static const struct _battle_data { { "packet_obfuscation", &battle_config.packet_obfuscation, 1, 0, 3, }, { "client_accept_chatdori", &battle_config.client_accept_chatdori, 0, 0, INT_MAX, }, { "snovice_call_type", &battle_config.snovice_call_type, 0, 0, 1, }, + { "guild_notice_changemap", &battle_config.guild_notice_changemap, 2, 0, 2, }, }; #ifndef STATS_OPT_OUT /** diff --git a/src/map/battle.h b/src/map/battle.h index 99856de94..bbba415f5 100644 --- a/src/map/battle.h +++ b/src/map/battle.h @@ -458,6 +458,7 @@ struct Battle_Config { int client_accept_chatdori; // [Ai4rei/Mirei] int snovice_call_type; + int guild_notice_changemap; } battle_config; diff --git a/src/map/clif.c b/src/map/clif.c index 4ad4f266b..32291e68f 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -9336,8 +9336,7 @@ void clif_hercules_chsys_mjoin(struct map_session_data *sd) { /// Notification from the client, that it has finished map loading and is about to display player's character (CZ_NOTIFY_ACTORINIT). /// 007d -void clif_parse_LoadEndAck(int fd,struct map_session_data *sd) -{ +void clif_parse_LoadEndAck(int fd,struct map_session_data *sd) { if(sd->bl.prev != NULL) return; @@ -9549,6 +9548,9 @@ void clif_parse_LoadEndAck(int fd,struct map_session_data *sd) if(sd->npc_id) npc_event_dequeue(sd); + + if( sd->guild && ( battle_config.guild_notice_changemap == 2 || ( battle_config.guild_notice_changemap == 1 && sd->state.changemap ) ) ) + clif->guild_notice(sd,sd->guild); } if( sd->state.changemap ) {// restore information that gets lost on map-change |