diff options
| author | Andrei Karas <akaras@inbox.ru> | 2016-03-15 16:27:33 +0300 |
|---|---|---|
| committer | Andrei Karas <akaras@inbox.ru> | 2018-01-16 02:25:51 +0300 |
| commit | 4b9f7c06571f662914845f54d6924e8cc4bc46f2 (patch) | |
| tree | 5f89010cf548e1189d99c697ef2a69ae696d281f | |
| parent | 5808b1363619a4d1ece4e89a464c0f48225f3a23 (diff) | |
| download | hercules-4b9f7c06571f662914845f54d6924e8cc4bc46f2.tar.gz hercules-4b9f7c06571f662914845f54d6924e8cc4bc46f2.tar.bz2 hercules-4b9f7c06571f662914845f54d6924e8cc4bc46f2.tar.xz hercules-4b9f7c06571f662914845f54d6924e8cc4bc46f2.zip | |
Hide area packets from hidden players/gms.
| -rw-r--r-- | src/map/clif.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 988e821e7..877a723fd 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -419,8 +419,14 @@ bool clif_send(const void* buf, int len, struct block_list* bl, enum send_target sd = BL_CAST(BL_PC, bl); - switch(type) { + if (sd != NULL && pc_isinvisible(sd)) { + if (type == AREA || type == BG || type == BG_AREA) + type = SELF; + else if (type == AREA_WOS || type == BG_WOS || type == BG_AREA_WOS) + return true; + } + switch(type) { case ALL_CLIENT: //All player clients. iter = mapit_getallusers(); while ((tsd = BL_UCAST(BL_PC, mapit->next(iter))) != NULL) { |