Resolves a mapflag overlap warning with PK Mode (#7109)

* Fixes #7099.
* Hides a warning message when PK Mode is enabled and a Battleground mapflag is attempted to overwrite the PvP mapflag.
Thanks to @LolyAll!
This commit is contained in:
Aleos 2022-07-18 11:08:44 -04:00 committed by GitHub
parent caa5cdd678
commit c2303c8f65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4739,6 +4739,7 @@ bool map_setmapflag_sub(int16 m, enum e_mapflag mapflag, bool status, union u_ma
if (mapdata->flag[MF_PVP]) { if (mapdata->flag[MF_PVP]) {
mapdata->flag[MF_PVP] = false; mapdata->flag[MF_PVP] = false;
if (!battle_config.pk_mode)
ShowWarning("map_setmapflag: Unable to set PvP and Battleground flags for the same map! Removing PvP flag from %s.\n", mapdata->name); ShowWarning("map_setmapflag: Unable to set PvP and Battleground flags for the same map! Removing PvP flag from %s.\n", mapdata->name);
} }
if (mapdata->flag[MF_GVG]) { if (mapdata->flag[MF_GVG]) {