summaryrefslogtreecommitdiff
path: root/src/char_sql/int_guild.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/char_sql/int_guild.c')
-rw-r--r--src/char_sql/int_guild.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/char_sql/int_guild.c b/src/char_sql/int_guild.c
index b3da7ea91..ed30c7031 100644
--- a/src/char_sql/int_guild.c
+++ b/src/char_sql/int_guild.c
@@ -1752,6 +1752,10 @@ int mapif_parse_GuildCastleDataSave(int fd,int castle_id,int index,int value)
(g)?g->name:"??" ,gid, (value)?"occupy":"abandon", castle_id);
}
gc.guild_id = value;
+ if(gc.guild_id == 0) {
+ //Delete guardians.
+ memset(&gc.guardian, 0, sizeof(gc.guardian));
+ }
break;
case 2: gc.economy = value; break;
case 3: gc.defense = value; break;