diff options
author | Kenpachi Developer <Kenpachi.Developer@gmx.de> | 2020-06-22 03:13:25 +0200 |
---|---|---|
committer | Kenpachi Developer <Kenpachi.Developer@gmx.de> | 2020-06-22 03:13:25 +0200 |
commit | f170e3487ec91f5f5a9e17acffc6cd499df373eb (patch) | |
tree | 339683348b87138327d2156062af675cdcf9bbad /src/map/clif.c | |
parent | 196c182f11aa46056a70507fcd93c97db9be911e (diff) | |
download | hercules-f170e3487ec91f5f5a9e17acffc6cd499df373eb.tar.gz hercules-f170e3487ec91f5f5a9e17acffc6cd499df373eb.tar.bz2 hercules-f170e3487ec91f5f5a9e17acffc6cd499df373eb.tar.xz hercules-f170e3487ec91f5f5a9e17acffc6cd499df373eb.zip |
Add battle flag for overweight messages display
Diffstat (limited to 'src/map/clif.c')
-rw-r--r-- | src/map/clif.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index f7f22f7b0..517b03add 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -10787,10 +10787,6 @@ static void clif_parse_LoadEndAck(int fd, struct map_session_data *sd) // Check for and delete unavailable/disabled items. pc->checkitem(sd); - // Send the character's weight to the client. - clif->updatestatus(sd, SP_WEIGHT); - clif->updatestatus(sd, SP_MAXWEIGHT); - // Send character's guild info to the client. Call this before clif->spawn() to show guild emblems correctly. if (sd->status.guild_id != 0) guild->send_memberinfoshort(sd, 1); @@ -10819,6 +10815,17 @@ static void clif_parse_LoadEndAck(int fd, struct map_session_data *sd) map->addblock(&sd->bl); // Add the character to the map. clif->spawn(&sd->bl); // Spawn character client side. + if (((battle_config.display_overweight_messages & 0x1) != 0 && sd->state.connect_new != 0) + || ((battle_config.display_overweight_messages & 0x2) != 0 && sd->state.connect_new == 0 && sd->state.changemap != 0)) { + // Send the character's weight to the client. (With displaying overweight messages.) + clif->updatestatus(sd, SP_MAXWEIGHT); + clif->updatestatus(sd, SP_WEIGHT); + } else { + // Send the character's weight to the client. (Without displaying overweight messages.) + clif->updatestatus(sd, SP_WEIGHT); + clif->updatestatus(sd, SP_MAXWEIGHT); + } + struct party_data *p = NULL; if (sd->status.party_id != 0) |