summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author4144 <andrei@karas>2018-02-26 19:06:35 -0300
committerjesusalva <cpntb1@ymail.com>2018-02-26 19:06:35 -0300
commit734e9d74d9ab2c1b6650c08993e0e98de9273d01 (patch)
tree42c4043514c4dbb287c93cd3a345062f35289f6e
parent2b3a96763832b422a093c2e8cdb41edcd34fe191 (diff)
downloadserverdata-734e9d74d9ab2c1b6650c08993e0e98de9273d01.tar.gz
serverdata-734e9d74d9ab2c1b6650c08993e0e98de9273d01.tar.bz2
serverdata-734e9d74d9ab2c1b6650c08993e0e98de9273d01.tar.xz
serverdata-734e9d74d9ab2c1b6650c08993e0e98de9273d01.zip
Bugfixes
-rw-r--r--npc/008-1/confused-tree.txt2
-rw-r--r--npc/test/test1.txt22
2 files changed, 22 insertions, 2 deletions
diff --git a/npc/008-1/confused-tree.txt b/npc/008-1/confused-tree.txt
index 2d5a53631..202fb53ca 100644
--- a/npc/008-1/confused-tree.txt
+++ b/npc/008-1/confused-tree.txt
@@ -303,7 +303,7 @@
}
function seen_me {
- if (playerattached() > 0)
+ if (playerattached() > 0 && htexists(.seen_ht))
{
htput(.seen_ht, strcharinfo(PC_NAME), gettimetick(2));
}
diff --git a/npc/test/test1.txt b/npc/test/test1.txt
index a6e6d4b94..52f788bbc 100644
--- a/npc/test/test1.txt
+++ b/npc/test/test1.txt
@@ -30,7 +30,7 @@ test,10,5,0 script test1 NPC_HAT_BOX,{
if (.var != 4)
mes "Error: testing test2 npc variables.";
test1function;
- mes "Formatting testing...";
+ mes "Formatting testing for sex: " + str(Sex);
if (l("test @@", "") != "test ")
mes "Error: format string 'l(\"test @@\", \"\")': " + l("test @@", "");
if (l("test @@", "1") != "test 1")
@@ -43,6 +43,26 @@ test,10,5,0 script test1 NPC_HAT_BOX,{
mes "Error: format string 'l(\"@@ @@ @@\", \"this\", \"is\", \"test\") != \"this is test\"': " + l("@@ @@ @@", "this", "is", "test");
if (l("data @@ @@ @@ data", "this", "is", "test") != "data this is test data")
mes "Error: format string 'l(\"data @@ @@ @@ data\", \"this\", \"is\", \"test\")': " + l("data @@ @@ @@ data", "this", "is", "test");
+ if (l("test") != "test")
+ mes "Error: l(\"test\"): " + l("test");
+ if (Sex == 1)
+ {
+ if (lg("test") != "test#1")
+ mes "Error: lg(\"test\"): " + lg("test");
+ if (lg("test1", "test2") != "test2#1")
+ mes "Error: lg(\"test1\", \"test2\"): " + lg("test1", "test2");
+ if (lg("test1 @@", "test2 @@", "line") != "test2 line#1")
+ mes "Error: lg(\"test1 @@\", \"test2 @@\", \"line\"): " + lg("test1 @@", "test2 @@", "line");
+ }
+ else if (Sex == 0)
+ {
+ if (lg("test") != "test#0")
+ mes "Error: lg(\"test\"): " + lg("test");
+ if (lg("test1", "test2") != "test1#0")
+ mes "Error: lg(\"test1\", \"test2\"): " + lg("test1", "test2");
+ if (lg("test1 @@", "test2 @@", "line") != "test1 line#0")
+ mes "Error: lg(\"test1 @@\", \"test2 @@\", \"line\"): " + lg("test1 @@", "test2 @@", "line");
+ }
mes "Quest vars testing...";
.@time = 1000;
setq Test_testing1, 1, 2, 3, .@time;