summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/map/guild.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/map/guild.c b/src/map/guild.c
index 21d88f67b..428951a22 100644
--- a/src/map/guild.c
+++ b/src/map/guild.c
@@ -1319,7 +1319,11 @@ int guild_reply_reqalliance(struct map_session_data *sd,int account_id,int flag)
struct map_session_data *tsd;
nullpo_retr(0, sd);
- nullpo_retr(0, tsd= map_id2sd( account_id ));
+ tsd= map_id2sd( account_id );
+ if (!tsd) { //Character left? Cancel alliance.
+ clif_guild_allianceack(sd,3);
+ return 0;
+ }
if(sd->guild_alliance!=tsd->status.guild_id) // Š©—U‚ƃMƒ‹ƒhID‚ªˆá‚¤
return 0;
@@ -1370,13 +1374,13 @@ int guild_reply_reqalliance(struct map_session_data *sd,int account_id,int flag)
// ƒMƒ‹ƒhŠÖŒW‰ðÁ
int guild_delalliance(struct map_session_data *sd,int guild_id,int flag)
{
+ nullpo_retr(0, sd);
+
if(agit_flag) { // Disable alliance breaking during woe [Valaris]
clif_displaymessage(sd->fd,"Alliances cannot be broken during Guild Wars!");
return 0;
} // end addition [Valaris]
- nullpo_retr(0, sd);
-
intif_guild_alliance( sd->status.guild_id,guild_id,
sd->status.account_id,0,flag|8 );
return 0;