diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-03-15 16:27:33 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-04-24 20:58:33 +0300 |
commit | 1233f5d400e5a607fcd6636a2da6e1578ca19d88 (patch) | |
tree | b52d1aa402472cd73c357f5582abcfc981c41154 /src | |
parent | bef73e430775667740df6f3db25bb810ac50c31b (diff) | |
download | hercules-1233f5d400e5a607fcd6636a2da6e1578ca19d88.tar.gz hercules-1233f5d400e5a607fcd6636a2da6e1578ca19d88.tar.bz2 hercules-1233f5d400e5a607fcd6636a2da6e1578ca19d88.tar.xz hercules-1233f5d400e5a607fcd6636a2da6e1578ca19d88.zip |
Hide area packets from hidden players/gms.
Diffstat (limited to 'src')
-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 8ab6e71a4..73e5572f6 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -414,8 +414,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) { |