summaryrefslogtreecommitdiff
path: root/npc/custom
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2014-11-03 08:15:05 -0200
committershennetsind <ind@henn.et>2014-11-03 08:15:05 -0200
commitbee4c9d36f4a27e39cc76dc5d6c5f876ed44a678 (patch)
tree79f9aec5171e8aed2d701bf67167f260e05f41db /npc/custom
parent239d480487e24294975f35ed55f210837ad1088e (diff)
parentce3f4bfbe016ea69c855146667ba9bd9e0e2e221 (diff)
downloadhercules-bee4c9d36f4a27e39cc76dc5d6c5f876ed44a678.tar.gz
hercules-bee4c9d36f4a27e39cc76dc5d6c5f876ed44a678.tar.bz2
hercules-bee4c9d36f4a27e39cc76dc5d6c5f876ed44a678.tar.xz
hercules-bee4c9d36f4a27e39cc76dc5d6c5f876ed44a678.zip
Merge branch 'master' of github.com:HerculesWS/Hercules
Signed-off-by: shennetsind <ind@henn.et> Conflicts: src/map/battle.c
Diffstat (limited to 'npc/custom')
-rw-r--r--npc/custom/battleground/bg_common.txt84
-rw-r--r--npc/custom/bgqueue/flavius.txt4
-rw-r--r--npc/custom/breeder.txt49
-rw-r--r--npc/custom/etc/penal_servitude.txt4
-rw-r--r--npc/custom/jobmaster.txt4
5 files changed, 76 insertions, 69 deletions
diff --git a/npc/custom/battleground/bg_common.txt b/npc/custom/battleground/bg_common.txt
index 895191961..8b99deb39 100644
--- a/npc/custom/battleground/bg_common.txt
+++ b/npc/custom/battleground/bg_common.txt
@@ -217,9 +217,9 @@ bat_room,156,178,5 script Tierra Valley Officer#1 4_M_KY_KNT,{
close;
}
- if( checkquest(2069,PLAYTIME) == 2 ) erasequest 2069;
- if( checkquest(2069,PLAYTIME) != -1 )
- {
+ if (questprogress(2069,PLAYTIME) == 2)
+ erasequest 2069;
+ if (questprogress(2069,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Tierra Gorge. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Tierra Officer]";
@@ -287,9 +287,9 @@ bat_room,156,121,1 script Tierra Valley Officer#2 4_M_CRU_KNT,{
close;
}
- if( checkquest(2069,PLAYTIME) == 2 ) erasequest 2069;
- if( checkquest(2069,PLAYTIME) != -1 )
- {
+ if (questprogress(2069,PLAYTIME) == 2)
+ erasequest 2069;
+ if (questprogress(2069,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Tierra Gorge. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Tierra Officer]";
@@ -357,9 +357,9 @@ bat_room,164,178,5 script Tierra Valley Officer#3 4_M_KY_KNT,{
close;
}
- if( checkquest(2069,PLAYTIME) == 2 ) erasequest 2069;
- if( checkquest(2069,PLAYTIME) != -1 )
- {
+ if (questprogress(2069,PLAYTIME) == 2)
+ erasequest 2069;
+ if (questprogress(2069,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Tierra Gorge. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Tierra Officer]";
@@ -427,9 +427,9 @@ bat_room,164,121,1 script Tierra Valley Officer#4 4_M_CRU_KNT,{
close;
}
- if( checkquest(2069,PLAYTIME) == 2 ) erasequest 2069;
- if( checkquest(2069,PLAYTIME) != -1 )
- {
+ if (questprogress(2069,PLAYTIME) == 2)
+ erasequest 2069;
+ if (questprogress(2069,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Tierra Gorge. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Tierra Officer]";
@@ -498,9 +498,9 @@ bat_room,172,178,5 script Flavius Officer#1 4_M_KY_KNT,{
close;
}
- if( checkquest(2070,PLAYTIME) == 2 ) erasequest 2070;
- if( checkquest(2070,PLAYTIME) != -1 )
- {
+ if (questprogress(2070,PLAYTIME) == 2)
+ erasequest 2070;
+ if (questprogress(2070,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Flavius. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Flavius Officer]";
@@ -569,9 +569,9 @@ bat_room,172,121,1 script Flavius Officer#2 4_M_CRU_KNT,{
close;
}
- if( checkquest(2070,PLAYTIME) == 2 ) erasequest 2070;
- if( checkquest(2070,PLAYTIME) != -1 )
- {
+ if (questprogress(2070,PLAYTIME) == 2)
+ erasequest 2070;
+ if (questprogress(2070,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Flavius. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Flavius Officer]";
@@ -640,9 +640,9 @@ bat_room,148,178,5 script Flavius Officer#3 4_M_KY_KNT,{
close;
}
- if( checkquest(2070,PLAYTIME) == 2 ) erasequest 2070;
- if( checkquest(2070,PLAYTIME) != -1 )
- {
+ if (questprogress(2070,PLAYTIME) == 2)
+ erasequest 2070;
+ if (questprogress(2070,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Flavius. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Flavius Officer]";
@@ -711,9 +711,9 @@ bat_room,148,121,1 script Flavius Officer#4 4_M_CRU_KNT,{
close;
}
- if( checkquest(2070,PLAYTIME) == 2 ) erasequest 2070;
- if( checkquest(2070,PLAYTIME) != -1 )
- {
+ if (questprogress(2070,PLAYTIME) == 2)
+ erasequest 2070;
+ if (questprogress(2070,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at Flavius. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[Flavius Officer]";
@@ -779,9 +779,9 @@ bat_room,140,178,5 script KVM [80-99] Officer#1 4_M_KY_KNT,{
close;
}
- if( checkquest(6025,PLAYTIME) == 2 ) erasequest 6025;
- if( checkquest(6025,PLAYTIME) != -1 )
- {
+ if (questprogress(6025,PLAYTIME) == 2)
+ erasequest 6025;
+ if (questprogress(6025,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at KvM. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[KVM Officer]";
@@ -847,9 +847,9 @@ bat_room,140,121,1 script KVM [80-99] Officer#2 4_M_CRU_KNT,{
close;
}
- if( checkquest(6025,PLAYTIME) == 2 ) erasequest 6025;
- if( checkquest(6025,PLAYTIME) != -1 )
- {
+ if (questprogress(6025,PLAYTIME) == 2)
+ erasequest 6025;
+ if (questprogress(6025,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at KvM. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[KVM Officer]";
@@ -915,9 +915,9 @@ bat_room,132,178,5 script KVM [60-79] Officer#1 4_M_KY_KNT,{
close;
}
- if( checkquest(6025,PLAYTIME) == 2 ) erasequest 6025;
- if( checkquest(6025,PLAYTIME) != -1 )
- {
+ if (questprogress(6025,PLAYTIME) == 2)
+ erasequest 6025;
+ if (questprogress(6025,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at KvM. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[KVM Officer]";
@@ -983,9 +983,9 @@ bat_room,132,121,1 script KVM [60-79] Officer#2 4_M_CRU_KNT,{
close;
}
- if( checkquest(6025,PLAYTIME) == 2 ) erasequest 6025;
- if( checkquest(6025,PLAYTIME) != -1 )
- {
+ if (questprogress(6025,PLAYTIME) == 2)
+ erasequest 6025;
+ if (questprogress(6025,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at KvM. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[KVM Officer]";
@@ -1051,9 +1051,9 @@ bat_room,124,178,5 script KVM [1-59] Officer#1 4_M_KY_KNT,{
close;
}
- if( checkquest(6025,PLAYTIME) == 2 ) erasequest 6025;
- if( checkquest(6025,PLAYTIME) != -1 )
- {
+ if (questprogress(6025,PLAYTIME) == 2)
+ erasequest 6025;
+ if (questprogress(6025,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at KvM. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[KVM Officer]";
@@ -1119,9 +1119,9 @@ bat_room,124,121,1 script KVM [1-59] Officer#2 4_M_CRU_KNT,{
close;
}
- if( checkquest(6025,PLAYTIME) == 2 ) erasequest 6025;
- if( checkquest(6025,PLAYTIME) != -1 )
- {
+ if (questprogress(6025,PLAYTIME) == 2)
+ erasequest 6025;
+ if (questprogress(6025,PLAYTIME)) {
mes "You have received an indicator showing that you've participated in the Battle at KvM. I can't let you participate in any other battles until the indicator goes off.";
next;
mes "[KVM Officer]";
diff --git a/npc/custom/bgqueue/flavius.txt b/npc/custom/bgqueue/flavius.txt
index 36e02e86d..8112be12e 100644
--- a/npc/custom/bgqueue/flavius.txt
+++ b/npc/custom/bgqueue/flavius.txt
@@ -426,14 +426,14 @@ OnTouch:
bat_b01,87,76,0 script A_CODE#bat_b01 -1,5,5,{
OnTouch:
- if (checkquest(2070) < 0)
+ if (!questprogress(2070))
setquest 2070;
end;
}
bat_b01,312,224,0 script B_CODE#bat_b01 -1,5,5,{
OnTouch:
- if (checkquest(2070) < 0)
+ if (!questprogress(2070))
setquest 2070;
end;
}
diff --git a/npc/custom/breeder.txt b/npc/custom/breeder.txt
index af4a740b4..40d94d99d 100644
--- a/npc/custom/breeder.txt
+++ b/npc/custom/breeder.txt
@@ -11,36 +11,43 @@
//============================================================
prontera,124,201,1 script Universal Rental NPC 4_F_JOB_BLACKSMITH,{
+ /* TODO: This can be optimized with just setmount(), as it can
+ auto-detect the proper mount for the class/skills. */
if (hascashmount()) {
message strcharinfo(0),"You must first remove your mount.";
end;
- }
- else if ((eaclass()&EAJ_THIRDMASK) == EAJ_RANGER && !countitem(6124)) {
- if (!checkfalcon() && getskilllv("HT_FALCON") && !checkoption(Option_Wug) && !checkoption(Option_Wugrider)) {
- if(select(" ~ Falcon: ~ Warg")==1) setfalcon;
- else getitem 6124,1;
+ } else if ((eaclass()&EAJ_THIRDMASK) == EAJ_RANGER && !countitem(Wolf's_Flute)) {
+ if (!checkfalcon() && getskilllv(HT_FALCON) && !checkwug()) {
+ if (select(" ~ Falcon: ~ Warg") == 1)
+ setfalcon;
+ else
+ getitem Wolf's_Flute, 1;
specialeffect2 EF_TEIHIT3;
close;
+ } else {
+ getitem Wolf's_Flute,1;
}
- else getitem 6124,1;
- }
- else if ((eaclass()&EAJ_THIRDMASK) == EAJ_MECHANIC && !checkcart() && getskilllv("MC_PUSHCART")) {
- if (!checkmadogear() && getskilllv("NC_MADOLICENCE")) {
- if(select(" ~ Cart: ~ Mado")==1) setcart;
- else setmadogear;
+ } else if ((eaclass()&EAJ_THIRDMASK) == EAJ_MECHANIC && !checkcart() && getskilllv(MC_PUSHCART)) {
+ if (!checkmount() != MOUNT_MADO && getskilllv(NC_MADOLICENCE)) {
+ if (select(" ~ Cart: ~ Mado") == 1) {
+ setcart;
+ } else {
+ setmount(MOUNT_MADO);
+ }
specialeffect2 EF_TEIHIT3;
close;
+ } else {
+ setcart;
}
- else setcart;
- }
- else if (!checkcart() && getskilllv("MC_PUSHCART")) setcart;
- else if (!checkfalcon() && getskilllv("HT_FALCON") && !checkoption(Option_Wug) && !checkoption(Option_Wugrider)) setfalcon;
- else if (!checkriding() && getskilllv("KN_RIDING")) {
- if ((eaclass()&EAJ_THIRDMASK) == EAJ_RUNE_KNIGHT) setdragon;
- else setriding;
- }
- else if (!checkmadogear() && getskilllv("NC_MADOLICENCE")) setmadogear;
- else {
+ } else if (!checkcart() && getskilllv(MC_PUSHCART)) {
+ setcart;
+ } else if (!checkfalcon() && getskilllv(HT_FALCON) && !checkwug()) {
+ setfalcon;
+ } else if (checkmount() == MOUNT_PECO && getskilllv(KN_RIDING)) {
+ setmount; // Peco or Dragon
+ } else if (checkmount() != MOUNT_MADO && getskilllv(NC_MADOLICENCE)) {
+ setmount(MOUNT_MADO);
+ } else {
message strcharinfo(0),"You do not meet requirements to rent.";
end;
}
diff --git a/npc/custom/etc/penal_servitude.txt b/npc/custom/etc/penal_servitude.txt
index e78833b66..b83bf3f83 100644
--- a/npc/custom/etc/penal_servitude.txt
+++ b/npc/custom/etc/penal_servitude.txt
@@ -84,9 +84,9 @@ M_Q1:
menu "OK, I'll work off!",-, "I love this prison!",M_NO_THANKS;
mes "[Saddeus]";
- if(checkcart() || checkfalcon() || checkriding()){
+ if(checkcart() || checkfalcon() || checkmount()){
emotion e_hmm;
- mes "I'm sorry, you should release your Cart, PecoPeco or Falcon!";
+ mes "I'm sorry, you should release your Cart, Mount or Falcon!";
close;
}
mes "Talk to our overseer, Oliver.";
diff --git a/npc/custom/jobmaster.txt b/npc/custom/jobmaster.txt
index e476ce2df..ca102ed76 100644
--- a/npc/custom/jobmaster.txt
+++ b/npc/custom/jobmaster.txt
@@ -24,8 +24,8 @@ prontera,153,193,6 script Job Master 2_F_MAGICMASTER,{
mes "No more jobs are available.";
close;
}
- if (checkfalcon() || checkcart() || checkriding() || hascashmount()) {
- mes "Please remove your "+((checkfalcon())?"falcon":"")+((checkcart())?"cart":"")+((checkriding())?"Peco":"")+((hascashmount())?"mount":"")
+ if (checkfalcon() || checkcart() || checkmount() || hascashmount()) {
+ mes "Please remove your "+((checkfalcon())?"falcon":"")+((checkcart())?"cart":"")+((checkmount() || hascashmount())?"mount":"")
+" before proceeding.";
close;
}