summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
authorjesusalva <cpntb1@ymail.com>2018-02-22 20:41:33 -0300
committerjesusalva <cpntb1@ymail.com>2018-02-22 20:41:33 -0300
commit10a71210b827d99c5a758e2881e1482db543d9b7 (patch)
treee72f1496565b3faf4cdebc7fef68fd60684a2757 /npc
parent1956c8cbf7f65dff1459073324ed41767d072726 (diff)
downloadserverdata-10a71210b827d99c5a758e2881e1482db543d9b7.tar.gz
serverdata-10a71210b827d99c5a758e2881e1482db543d9b7.tar.bz2
serverdata-10a71210b827d99c5a758e2881e1482db543d9b7.tar.xz
serverdata-10a71210b827d99c5a758e2881e1482db543d9b7.zip
This Elanore is incomplete because missing items.
Also, you need to hear about Lifestones somewhere to talk about them! As there is no variable for that...
Diffstat (limited to 'npc')
-rw-r--r--npc/003-1/swezanne.txt3
-rw-r--r--npc/004-1/_import.txt1
-rw-r--r--npc/004-1/elanore.txt133
3 files changed, 136 insertions, 1 deletions
diff --git a/npc/003-1/swezanne.txt b/npc/003-1/swezanne.txt
index 16e6b4c90..7d1adb984 100644
--- a/npc/003-1/swezanne.txt
+++ b/npc/003-1/swezanne.txt
@@ -1,3 +1,4 @@
+// TMW-2 Script
// Author:
// Jesusalva
@@ -86,6 +87,6 @@ OnInit:
setunitdata(.@npcId, UDT_HAIRCOLOR, 7);
.sex = G_FEMALE;
- .distance = 3;
+ .distance = 5;
end;
}
diff --git a/npc/004-1/_import.txt b/npc/004-1/_import.txt
index 41c9f1f11..123369a47 100644
--- a/npc/004-1/_import.txt
+++ b/npc/004-1/_import.txt
@@ -3,3 +3,4 @@
"npc/004-1/_mobs.txt",
"npc/004-1/_warps.txt",
"npc/004-1/bgmaster.txt",
+"npc/004-1/elanore.txt",
diff --git a/npc/004-1/elanore.txt b/npc/004-1/elanore.txt
new file mode 100644
index 000000000..f57215eb5
--- /dev/null
+++ b/npc/004-1/elanore.txt
@@ -0,0 +1,133 @@
+// TMW-2 Script
+// Author:
+// Jesusalva
+
+004-1,75,62,0 script Elanore the Healer NPC_FEMALE,{
+
+ //if (sc_check(SC_POISON)) goto L_CurePoison;
+
+ mesn;
+ @temp = rand(4);
+ if(@temp == 1) goto L_Heal2;
+ if(@temp == 2) goto L_Heal3;
+ if(@temp == 3) goto L_Heal4;
+ goto L_Heal1;
+
+L_Heal1:
+ mesq l("You don't look too well; let me treat your wounds.");
+ mes "";
+ goto L_Menu;
+
+L_Heal2:
+ mesq l("I will make quick work of your wounds.");
+ mes "";
+ goto L_Menu;
+
+L_Heal3:
+ mesq l("Need a healing?");
+ mes "";
+ goto L_Menu;
+
+L_Heal4:
+ mesq l("Sometimes you just need to run from battle.");
+ mes "";
+ goto L_Menu;
+
+L_Menu:
+ .@price=(MaxHp-Hp)/5;
+ .@price=.@price+10;
+ if (BaseLevel <= 15) .@price=(.@price/10);
+ mesq l("For you, it'll be @@ GP.", .@price);
+ mes "";
+ menu
+ rif(Zeny >= .@price, l("Please heal me!")), L_Heal_L,
+ rif(BaseLevel > 15 && 1==2, l("Do you make Lifestones?")), L_Lifestones,
+ l("Another time, maybe."), L_Close;
+
+
+L_Heal_L:
+ mes "";
+ set Zeny, Zeny - .@price;
+ sc_end(SC_POISON);
+ sc_end(SC_SLOWPOISON);
+ percentheal 100,100; // We can also use "recovery(<account id>)"
+ mesn;
+ @temp = rand(1,4);
+ if(@temp == 1) mesq l("Here you go!");
+ if(@temp == 2) mesq l("Painless, wasn't it?");
+ if(@temp == 3) mesq l("You should be more careful.");
+ if(@temp == 4) mesq l("Much better, right?!");
+ goto L_Close;
+
+L_Lifestones:
+ mes "";
+ mesn;
+ mesq l("Lifestones have the potential to heal the user, and thus are used for potions.");
+ next;
+ mesq l("I will need 1 @@, 1 @@ and 100 GP to craft a single stone.", getitemlink(BugLeg), getitemlink(MaggotSlime));
+ next;
+ mes "";
+ menu
+ l("OK, I will get them."), L_Close,
+ l("No way!"), L_Close,
+ l("Here you are!")), L_Trade;
+
+L_Trade:
+ if (countitem("BugLeg") < 1) goto L_Trade_Missing;
+ if (countitem("MaggotSlime") < 1) goto L_Trade_Missing;
+ if (Zeny < 100) goto L_Trade_Missing;
+
+ // TODO: There is a function to do that check in one line
+ getinventorylist;
+ if (@inventorylist_count == 100 && countitem("Lifestone") == 0
+ && countitem("BugLeg") > 1
+ && countitem("MaggotSlime") > 1) goto L_NoRoom;
+
+ delitem "BugLeg", 1;
+ delitem "MaggotSlime", 1;
+ set Zeny, Zeny - 100;
+
+ // TODO: MISSING ITEM
+ //getitem "Lifestone", 1;
+
+ // TODO: Only grant Experience on first craft
+ getexp 80, 0;
+ mesn;
+ mesq l("These will do just fine.");
+ next;
+ mesn;
+ mes l("Elanore casts a chant over the items, closes her hands, and vĂ³ila! A lifestone.");
+ next;
+ mesq l("I guess that you could use these lifestones to gain a regeneration effect, too, but I do not know how.");
+ next;
+ mes l("She smiles.");
+ mes l("[80 experience points]");
+ goto L_Close;
+
+L_NoRoom:
+ mesn;
+ mesq l("Oh... it seems that you have no room for the lifestones. But please do come back later when you have made a little space.");
+ goto L_Close;
+
+L_Trade_Missing:
+ mesn;
+ mesq l("This is not what I asked for.");
+ goto L_Close;
+
+L_Close:
+ close;
+
+OnInit:
+ .@npcId = getnpcid(0, .name$);
+ //setunitdata(.@npcId, UDT_HEADTOP, 2929);
+ setunitdata(.@npcId, UDT_HEADMIDDLE, 1317);
+ //setunitdata(.@npcId, UDT_HEADBOTTOM, 2207);
+ setunitdata(.@npcId, UDT_WEAPON, 1802); // Boots
+ setunitdata(.@npcId, UDT_HAIRSTYLE, 8);
+ setunitdata(.@npcId, UDT_HAIRCOLOR, 17);
+
+ .sex = G_FEMALE;
+ .distance = 5;
+ end;
+
+}