summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/script_commands.txt20
-rw-r--r--src/map/script.c2
2 files changed, 13 insertions, 9 deletions
diff --git a/doc/script_commands.txt b/doc/script_commands.txt
index 028c12791..420f31943 100644
--- a/doc/script_commands.txt
+++ b/doc/script_commands.txt
@@ -3967,16 +3967,20 @@ if War of Emperium is on and 0 if it isn't.
---------------------------------------
*isnight()
-*isday()
-These functions will return 1 or 0 depending on whether the server is in
-night mode or day mode. 'isnight' returns 1 if it's night and 0 if it
-isn't, 'isday' the other way around. They can be used interchangeably,
-pick the one you like more:
+This functions will return true or false depending on whether the server is in
+night mode or day mode:
+
+ if (!isnight()) mes "I only prowl in the night.";
+
+*isday()
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
+ @ /!\ This command is deprecated @
+ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
- // These two are equivalent:
- if (isday()) mes "I only prowl in the night.";
- if (isnight()!=1) mes "I only prowl in the night.";
+This command is deprecated and it should not be used in new scripts, as it
+is likely to be removed at a later time. Please consider using !isnight()
+instead.
---------------------------------------
diff --git a/src/map/script.c b/src/map/script.c
index fc43aa94a..a2ea86ac6 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -19384,7 +19384,7 @@ void script_parse_builtin(void) {
BUILDIN_DEF(logmes,"s"), //this command actls as MES but rints info into LOG file either SQL/TXT [Lupus]
BUILDIN_DEF(summon,"si??"), // summons a slave monster [Celest]
BUILDIN_DEF(isnight,""), // check whether it is night time [Celest]
- BUILDIN_DEF(isday,""), // check whether it is day time [Celest]
+ BUILDIN_DEF_DEPRECATED(isday,""), // check whether it is day time [Celest] // DEPRECATED 2015-01-21 [Haru]
BUILDIN_DEF(isequipped,"i*"), // check whether another item/card has been equipped [Celest]
BUILDIN_DEF(isequippedcnt,"i*"), // check how many items/cards are being equipped [Celest]
BUILDIN_DEF(cardscnt,"i*"), // check how many items/cards are being equipped in the same arm [Lupus]