summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorFate <fate-tmw@googlemail.com>2008-12-11 22:28:30 -0700
committerFate <fate-tmw@googlemail.com>2008-12-11 22:28:30 -0700
commit5e32a6be59536a6810bf558ec07dd3a615569c39 (patch)
tree8306d38892f6802ce7ce11541738cd947de568d8 /src/map/pc.c
parentc9e5567e98cf7e26c549f4a512eeece24a0d9c81 (diff)
downloadtmwa-5e32a6be59536a6810bf558ec07dd3a615569c39.tar.gz
tmwa-5e32a6be59536a6810bf558ec07dd3a615569c39.tar.bz2
tmwa-5e32a6be59536a6810bf558ec07dd3a615569c39.tar.xz
tmwa-5e32a6be59536a6810bf558ec07dd3a615569c39.zip
Added @invisible and @visible GM commands
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c15
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);
+ }
+}