summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Changelog-Trunk.txt2
-rw-r--r--src/map/guild.c15
2 files changed, 15 insertions, 2 deletions
diff --git a/Changelog-Trunk.txt b/Changelog-Trunk.txt
index c27275dc0..cef1a50cc 100644
--- a/Changelog-Trunk.txt
+++ b/Changelog-Trunk.txt
@@ -1,5 +1,7 @@
Date Added
+2011/04/10
+ * Fixed @changegm not updating guild window interface after changing the guild leader (bugreport:408, since r2622, related r3185). [Ai4rei]
2011/04/09
* Moved duel code into a separate file. [Ai4rei]
* Added *.opt (VS6 workspace cache file) to svn:ignore. [Ai4rei]
diff --git a/src/map/guild.c b/src/map/guild.c
index e56b346ec..7eb572660 100644
--- a/src/map/guild.c
+++ b/src/map/guild.c
@@ -1604,7 +1604,7 @@ int guild_gm_changed(int guild_id, int account_id, int char_id)
{
struct guild *g;
struct guild_member gm;
- int pos;
+ int pos, i;
g=guild_search(guild_id);
@@ -1638,7 +1638,18 @@ int guild_gm_changed(int guild_id, int account_id, int char_id)
g->member[0].sd->state.gmaster_flag = g;
//Block his skills for 5 minutes to prevent abuse.
guild_block_skill(g->member[0].sd, 300000);
- }
+ }
+
+ // announce the change to all guild members
+ for( i = 0; i < g->max_member; i++ )
+ {
+ if( g->member[i].sd && g->member[i].sd->fd )
+ {
+ clif_guild_basicinfo(g->member[i].sd);
+ clif_guild_memberlist(g->member[i].sd);
+ }
+ }
+
return 1;
}