From 75444c75ec0e5507640aef91933d94aa87fc7e09 Mon Sep 17 00:00:00 2001
From: Michieru <Michieru@users.noreply.github.com>
Date: Mon, 8 Dec 2014 22:47:29 +0100
Subject: fix /mineffect or /minimize when change map This commit was made by
 Master Ind

---
 src/map/clif.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

(limited to 'src')

diff --git a/src/map/clif.c b/src/map/clif.c
index 5e459f6a7..71feaa05c 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -17722,16 +17722,17 @@ void clif_parse_CashShopReqTab(int fd, struct map_session_data *sd) {
 	WFIFOSET(fd, 10 + ( clif->cs.item_count[tab] * 6 ));
 }
 /* [Ind/Hercules] */
-void clif_maptypeproperty2(struct block_list *bl,enum send_target t) {
-#if PACKETVER >= 20121010
-	struct packet_maptypeproperty2 p;
-
-	p.PacketType = maptypeproperty2Type;
-	p.type = 0x28;
+void clif_maptypeproperty2(struct block_list *bl,enum send_target t) {
+#if PACKETVER >= 20121010
+	struct packet_maptypeproperty2 p;
+	struct map_session_data *sd = BL_CAST(BL_PC, bl);
+
+	p.PacketType = maptypeproperty2Type;
+	p.type = 0x28;
 	p.flag.party = map->list[bl->m].flag.pvp ? 1 : 0;
 	p.flag.guild = (map->list[bl->m].flag.battleground || map_flag_gvg(bl->m)) ? 1 : 0;
 	p.flag.siege = (map->list[bl->m].flag.battleground || map_flag_gvg2(bl->m)) ? 1: 0;
-	p.flag.mineffect = map_flag_gvg(bl->m); // FIXME/CHECKME Forcing /mineffect in castles during WoE (probably redundant? I'm not sure)
+	p.flag.mineffect = map_flag_gvg(bl->m) ? 1 : ( (sd && sd->state.lesseffect) ? 1 : 0); // Forcing /mineffect in castles during WoE (probably redundant? I'm not sure)
 	p.flag.nolockon = 0; // TODO
 	p.flag.countpk = map->list[bl->m].flag.pvp ? 1 : 0;
 	p.flag.nopartyformation = map->list[bl->m].flag.partylock ? 1 : 0;
-- 
cgit v1.2.3-70-g09d2