diff options
Diffstat (limited to 'src/map/pc.c')
-rw-r--r-- | src/map/pc.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/map/pc.c b/src/map/pc.c index 62e2cd5..bed6fc6 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -7765,3 +7765,18 @@ pc_cleanup(struct map_session_data *sd) { magic_stop_completely(sd); } + + +void +pc_invisibility(struct map_session_data *sd, int enabled) +{ + if (enabled && !(sd->status.option & OPTION_INVISIBILITY)) { + clif_clearchar_area(&sd->bl, 3); + sd->status.option |= OPTION_INVISIBILITY; + clif_status_change(&sd->bl, CLIF_OPTION_SC_INVISIBILITY, 1); + } else { + sd->status.option &= ~OPTION_INVISIBILITY; + clif_status_change(&sd->bl, CLIF_OPTION_SC_INVISIBILITY, 0); + pc_setpos(sd, map[sd->bl.m].name, sd->bl.x, sd->bl.y, 3); + } +} |