summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--conf/groups.conf1
-rw-r--r--conf/messages.conf3
-rw-r--r--doc/atcommands.txt6
-rw-r--r--src/map/atcommand.c19
4 files changed, 28 insertions, 1 deletions
diff --git a/conf/groups.conf b/conf/groups.conf
index 3f0c34ffb..16eca6e96 100644
--- a/conf/groups.conf
+++ b/conf/groups.conf
@@ -126,6 +126,7 @@ groups: (
go: true
breakguild: true
channel: true
+ camerainfo: true
}
permissions: {
}
diff --git a/conf/messages.conf b/conf/messages.conf
index f986e4649..9fc85cb55 100644
--- a/conf/messages.conf
+++ b/conf/messages.conf
@@ -448,7 +448,8 @@
// Return pet to egg message
451: You can't return your pet because your inventory is full.
-//452-497 FREE
+452: usage @camerainfo range rotation latitude
+//453-497 FREE
// Messages of others (not for GM commands)
// ----------------------------------------
diff --git a/doc/atcommands.txt b/doc/atcommands.txt
index fb3628e00..b455d9151 100644
--- a/doc/atcommands.txt
+++ b/doc/atcommands.txt
@@ -1498,3 +1498,9 @@ Reloads the 'conf/clans.conf' file.
Obs: it will reload 'db/clans.conf' too since it's included inside 'conf/clans.conf'
---------------------------------------
+
+@camerainfo {<range>, <rotation>, <latitude>}
+
+Allow show/hide or change client camera parameters
+
+---------------------------------------
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index 2538f797c..a7dc5dd95 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -9810,6 +9810,24 @@ ACMD(reloadclans)
return true;
}
+// show camera window or change camera parameters
+ACMD(camerainfo)
+{
+ if (*message == '\0') {
+ clif->camera_showWindow(sd);
+ return true;
+ }
+ float range = 0;
+ float rotation = 0;
+ float latitude = 0;
+ if (sscanf(message, "%15f %15f %15f", &range, &rotation, &latitude) < 3) {
+ clif->message(fd, msg_fd(fd, 452)); // usage @camerainfo range rotation latitude
+ return false;
+ }
+ clif->camera_change(sd, range, rotation, latitude, SELF);
+ return true;
+}
+
/**
* Fills the reference of available commands in atcommand DBMap
**/
@@ -10092,6 +10110,7 @@ static void atcommand_basecommands(void)
ACMD_DEF(leaveclan),
ACMD_DEF(reloadclans),
ACMD_DEF(setzone),
+ ACMD_DEF(camerainfo),
};
int i;