summaryrefslogtreecommitdiff
path: root/npc/test/karim.txt
diff options
context:
space:
mode:
authorSaulc <lucashelaine14@gmail.com>2018-02-18 02:08:36 +0100
committerSaulc <lucashelaine14@gmail.com>2018-02-18 02:08:36 +0100
commit26faa9a208a15ea858f5069a4c0d92e8a0709bdb (patch)
tree7ef0a6a5e39cb63f72ea9a6742f5a4cb320b41b4 /npc/test/karim.txt
parentb9416a07a0f085c64888ac02fecd47d43feee218 (diff)
downloadserverdata-26faa9a208a15ea858f5069a4c0d92e8a0709bdb.tar.gz
serverdata-26faa9a208a15ea858f5069a4c0d92e8a0709bdb.tar.bz2
serverdata-26faa9a208a15ea858f5069a4c0d92e8a0709bdb.tar.xz
serverdata-26faa9a208a15ea858f5069a4c0d92e8a0709bdb.zip
delete evol maps
Diffstat (limited to 'npc/test/karim.txt')
-rw-r--r--npc/test/karim.txt153
1 files changed, 153 insertions, 0 deletions
diff --git a/npc/test/karim.txt b/npc/test/karim.txt
new file mode 100644
index 000000000..743fdbc09
--- /dev/null
+++ b/npc/test/karim.txt
@@ -0,0 +1,153 @@
+// Evol scripts.
+// Author:
+// Reid
+// Description:
+// Blacksmith's assistant of Artis
+// Variables:
+// ArtisQuests_Enora
+// Values:
+// 0 Default.
+// 1 BlackSmith quest delivered.
+// 2 Chelios Quest given.
+// 3 Chelios Quest done.
+// 4 BlackSmith gave the sword.
+
+001-1,87,114,0 script karim NPC_PLAYER,{
+
+ .Item1 = RightCraftyWing;
+ .Item2 = LeftCraftyWing;
+ .ItemReward = FlightTalisman;
+
+ function quest_beggining{
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("my name is karim can you help me?.");
+
+ setq Karim_Quest, 1;
+ return;
+ }
+
+ function quest_left {
+ if (countitem(.Item2) > 0)
+ {
+ delitem .Item2, 1;
+ if (rand(10) == 1)
+ {
+ mesq l("Yay, it worked! You get a good wing.");
+ getitem .ItemReward, 1;
+ setq Karim_Quest, 2;
+ close;
+ }
+ else
+ {
+ mesq l("This one is useless! Give me another @@.", getitemlink(.Item2));
+ return;
+ }
+ }
+ else
+ {
+ mesq l("You don't have any @@, are you mocking me?", getitemlink(.Item2));
+ return ;
+ }
+ }
+
+ function quest_right {
+ if (countitem(.Item1) > 0)
+ {
+ delitem .Item1, 1;
+ if (rand(5) == 1)
+ {
+ mesq l("Yay, it worked! You get a good wing.");
+ getitem .ItemReward, 1;
+ setq Karim_Quest, 2;
+ close;
+ }
+ else
+ {
+ mesq l("This one is useless! Give me another @@.", getitemlink(.Item1));
+ next;
+ return;
+ }
+ }
+ else
+ {
+ mesq l("You don't have any @@, are you mocking me?", getitemlink(.Item1));
+ return ;
+ }
+ }
+
+ function quest_started {
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("Can you give me a @@ or a @@", getitemlink(.Item1), getitemlink(.Item2));
+
+ do
+ {
+ select
+ l("a Right Crafty Wing"),
+ l("a Left Crafty Wing"),
+ menuaction(l("Quit"));
+
+ switch (@menu)
+ {
+ case 1:
+ quest_right;
+ break;
+ case 2:
+ quest_left;
+ break;
+ }
+ } while (@menu != 3);
+ return;
+ }
+
+ function quest_completed {
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("Quest completed.");
+ return;
+ }
+
+ function quest_restart {
+ speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
+ l("Quest restart.");
+ setq Karim_Quest, 0;
+ return;
+ }
+
+ speech S_LAST_NEXT, l("Can you help me?");
+
+ do
+ {
+ .@karim = getq(Karim_Quest);
+ select
+ rif(.@karim == 2, lg("quest completed.")),
+ rif(.@karim == 1, l("Hello again can you give you give me some tentacles.")),
+ rif(.@karim == 0, l("Hello")),
+ l("Debug"),
+ menuaction(l("Quit"));
+
+ switch (@menu)
+ {
+ case 1:
+ quest_completed;
+ break;
+ case 2:
+ quest_started;
+ break;
+ case 3:
+ quest_beggining;
+ break;
+ case 4:
+ quest_restart;
+ break;
+ }
+ } while (@menu != 5);
+
+ closedialog;
+ goodbye;
+ close;
+
+OnInit:
+ .sex = G_MALE;
+ .distance = 3;
+ end;
+}
+