diff options
author | Reid <reidyaro@gmail.com> | 2015-02-03 03:01:45 +0100 |
---|---|---|
committer | Reid <reidyaro@gmail.com> | 2015-02-03 03:01:45 +0100 |
commit | 905524504b35896248a6cad997037aa8f3453261 (patch) | |
tree | bf508cca83e6ee4b0612a35eb4747d0c99f6cb79 | |
parent | f9836c9d3033f46ed15d7669cbec412af4f8b49b (diff) | |
download | serverdata-905524504b35896248a6cad997037aa8f3453261.tar.gz serverdata-905524504b35896248a6cad997037aa8f3453261.tar.bz2 serverdata-905524504b35896248a6cad997037aa8f3453261.tar.xz serverdata-905524504b35896248a6cad997037aa8f3453261.zip |
Correct peter script.
-rw-r--r-- | npc/000-2-1/peter.txt | 9 | ||||
-rw-r--r-- | npc/001-2-22/peter.txt | 51 | ||||
-rw-r--r-- | npc/001-2-23/doors.txt | 2 | ||||
-rw-r--r-- | npc/001-2-23/ratto.txt | 16 |
4 files changed, 44 insertions, 34 deletions
diff --git a/npc/000-2-1/peter.txt b/npc/000-2-1/peter.txt index d09c8d3f..681b6def 100644 --- a/npc/000-2-1/peter.txt +++ b/npc/000-2-1/peter.txt @@ -46,7 +46,7 @@ OnTouch: if ($@RAT_SAILOR_COUNTDOWN == 0) goto L_NoCountDown; if ((gettimetick(2) - $@RAT_SAILOR_COUNTDOWN) < 10) goto L_NoGoodTick; if (($@RAT_SAILOR_OLD_HELPER$ == strcharinfo(0)) && ((gettimetick(2) - $@RAT_SAILOR_COUNTDOWN) < 60)) goto L_NoGoodTick; - $@RAT_SAILOR_COUNTDOWN = ""; + $@RAT_SAILOR_COUNTDOWN = 0; L_NoCountDown: if ($@RAT_SAILOR_HELPER$ != "") goto L_Occupied; @@ -81,6 +81,8 @@ L_Rfail: L_Rwin: doevent "Peter::OnReturnWin"; + close; + L_NoGoodTick: doevent "Peter::OnNoGoodTick"; @@ -92,7 +94,7 @@ L_NoGoodTick: if ($@RAT_SAILOR_COUNTDOWN == 0) goto L_NoCountDown; if ((gettimetick(2) - $@RAT_SAILOR_COUNTDOWN) < 10) goto OnNoGoodTick; if (($@RAT_SAILOR_OLD_HELPER$ == strcharinfo(0)) && ((gettimetick(2) - $@RAT_SAILOR_COUNTDOWN) < 60)) goto OnNoGoodTick; - $@RAT_SAILOR_COUNTDOWN = ""; + $@RAT_SAILOR_COUNTDOWN = 0; L_NoCountDown: .@peter = getq(ShipQuests_Peter); @@ -150,6 +152,7 @@ OnReturnFail: goto L_Quit; OnReturnWin: + .@peter = getq(ShipQuests_Peter); mesn; mesq l("Thanks again for helping me. Drats these rattos for infesting our fair vessal! They are a permanent problem; so you can always be sure that your help with the extermination, to keep their numbers under control, is very welcome indeed. But the situation is, that I can give you a reward only the one time."); next; @@ -181,6 +184,7 @@ L_BonusTask: lg("Okay, I'm ready to work!"), -, l("What? This reward is too small!"), L_Quit; + .@peter = getq(ShipQuests_Peter); if ($@RAT_SAILOR_HELPER$ != "") goto OnDontneedHelp; if (.@peter == 6) setq ShipQuests_Peter, 2; if (.@peter == 3) setq ShipQuests_Peter, 4; @@ -188,6 +192,7 @@ L_BonusTask: goto L_Start; L_Task: + .@peter = getq(ShipQuests_Peter); if ($@RAT_SAILOR_HELPER$ != "") goto OnDontneedHelp; if (.@peter == 6) setq ShipQuests_Peter, 1; .@peter = getq(ShipQuests_Peter); diff --git a/npc/001-2-22/peter.txt b/npc/001-2-22/peter.txt index 767c2a83..977d1ce0 100644 --- a/npc/001-2-22/peter.txt +++ b/npc/001-2-22/peter.txt @@ -21,7 +21,7 @@ // 5 Task done and reward given. // 6 Did not start the quest. // Others: -// .@peter = Peter variable. +// .@peter = Peter#001-2-22 variable. // "001-2-23.gat" - map with mobs. // "$@ARTIS_RAT1_HELPER$" - Name of the participant. // "$@ARTIS_RAT1_DEATHS - Number of deaths when the participant starts the fight. @@ -46,7 +46,7 @@ OnTouch: if ($@ARTIS_RAT1_COUNTDOWN == 0) goto L_NoCountDown; if ((gettimetick(2) - $@ARTIS_RAT1_COUNTDOWN) < 10) goto L_NoGoodTick; if (($@ARTIS_RAT1_OLD_HELPER$ == strcharinfo(0)) && ((gettimetick(2) - $@ARTIS_RAT1_COUNTDOWN) < 60)) goto L_NoGoodTick; - $@ARTIS_RAT1_COUNTDOWN = ""; + $@ARTIS_RAT1_COUNTDOWN = 0; L_NoCountDown: if ($@ARTIS_RAT1_HELPER$ != "") goto L_Occupied; @@ -55,34 +55,36 @@ L_NoCountDown: if (.@peter == 1 || .@peter == 2) goto L_Rfail; if (.@peter == 3 || .@peter == 4) goto L_Rwin; if (.@peter > 5) goto L_SecondTime; - doevent "Peter::OnReturnWin"; + doevent "Peter#001-2-22::OnReturnWin"; close; L_Stop: - doevent "Peter::OnStop"; + doevent "Peter#001-2-22::OnStop"; close; L_Occupied: - doevent "Peter::OnDontneedHelp"; + doevent "Peter#001-2-22::OnDontneedHelp"; close; L_Task: - doevent "Peter::OnGiveTask"; + doevent "Peter#001-2-22::OnGiveTask"; close; L_Rfail: - doevent "Peter::OnReturnFail"; + doevent "Peter#001-2-22::OnReturnFail"; close; L_Rwin: - doevent "Peter::OnReturnWin"; + doevent "Peter#001-2-22::OnReturnWin"; + + close; L_NoGoodTick: - doevent "Peter::OnNoGoodTick"; + doevent "Peter#001-2-22::OnNoGoodTick"; close; } @@ -92,7 +94,7 @@ L_NoGoodTick: if ($@ARTIS_RAT1_COUNTDOWN == 0) goto L_NoCountDown; if ((gettimetick(2) - $@ARTIS_RAT1_COUNTDOWN) < 10) goto OnNoGoodTick; if (($@ARTIS_RAT1_OLD_HELPER$ == strcharinfo(0)) && ((gettimetick(2) - $@ARTIS_RAT1_COUNTDOWN) < 60)) goto OnNoGoodTick; - $@ARTIS_RAT1_COUNTDOWN = ""; + $@ARTIS_RAT1_COUNTDOWN = 0; L_NoCountDown: .@peter = getq(ShipQuests_Peter); @@ -150,6 +152,7 @@ OnReturnFail: goto L_Quit; OnReturnWin: + .@peter = getq(ShipQuests_Peter); mesn; mesq l("Thanks again for helping me. Drats these rattos for infesting our fair vessal! They are a permanent problem; so you can always be sure that your help with the extermination, to keep their numbers under control, is very welcome indeed. But the situation is, that I can give you a reward only the one time."); next; @@ -181,6 +184,7 @@ L_BonusTask: lg("Okay, I'm ready to work!"), -, l("What? This reward is too small!"), L_Quit; + .@peter = getq(ShipQuests_Peter); if ($@ARTIS_RAT1_HELPER$ != "") goto OnDontneedHelp; if (.@peter == 6) setq ShipQuests_Peter, 2; if (.@peter == 3) setq ShipQuests_Peter, 4; @@ -188,6 +192,7 @@ L_BonusTask: goto L_Start; L_Task: + .@peter = getq(ShipQuests_Peter); if ($@ARTIS_RAT1_HELPER$ != "") goto OnDontneedHelp; if (.@peter == 6) setq ShipQuests_Peter, 1; .@peter = getq(ShipQuests_Peter); @@ -203,7 +208,7 @@ OnStartOutside: $@ARTIS_RAT1_DEATHS = PC_DIE_COUNTER; initnpctimer; warp "001-2-23.gat", 48, 28; - doevent "RattosControl::OnSpawn"; + doevent "RattosControl#001-2-23::OnSpawn"; goto L_Quit; @@ -223,10 +228,10 @@ L_CheckRattos: if ($@ARTIS_RAT1_CONTROL[2]) $@ARTIS_RAT1_CONTROL[6] = $@ARTIS_RAT1_CONTROL[6] + 2; if ($@ARTIS_RAT1_CONTROL[3]) $@ARTIS_RAT1_CONTROL[7] = $@ARTIS_RAT1_CONTROL[7] + 2; if ($@ARTIS_RAT1_CONTROL[4]) $@ARTIS_RAT1_CONTROL[8] = $@ARTIS_RAT1_CONTROL[8] + 2; - if ($@ARTIS_RAT1_CONTROL[5] > 40) doevent "RattosControl::OnRatto1Respawn"; - if ($@ARTIS_RAT1_CONTROL[6] > 40) doevent "RattosControl::OnRatto2Respawn"; - if ($@ARTIS_RAT1_CONTROL[7] > 40) doevent "RattosControl::OnRatto3Respawn"; - if ($@ARTIS_RAT1_CONTROL[8] > 40) doevent "RattosControl::OnRatto4Respawn"; + if ($@ARTIS_RAT1_CONTROL[5] > 40) doevent "RattosControl#001-2-23::OnRatto1Respawn"; + if ($@ARTIS_RAT1_CONTROL[6] > 40) doevent "RattosControl#001-2-23::OnRatto2Respawn"; + if ($@ARTIS_RAT1_CONTROL[7] > 40) doevent "RattosControl#001-2-23::OnRatto3Respawn"; + if ($@ARTIS_RAT1_CONTROL[8] > 40) doevent "RattosControl#001-2-23::OnRatto4Respawn"; L_NotYet: setnpctimer 0; @@ -271,10 +276,10 @@ L_CleaningEnd: $@ARTIS_RAT1_HELPER$ = ""; $@ARTIS_RAT1_DEATHS = 0; cleararray $@ARTIS_RAT1_CONTROL, 0, 11; - killmonster "001-2-23.gat", "RattosControl::OnRatto1Death"; - killmonster "001-2-23.gat", "RattosControl::OnRatto2Death"; - killmonster "001-2-23.gat", "RattosControl::OnRatto3Death"; - killmonster "001-2-23.gat", "RattosControl::OnRatto4Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto1Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto2Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto3Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto4Death"; end; @@ -284,10 +289,10 @@ L_CleaningClose: $@ARTIS_RAT1_HELPER$ = ""; $@ARTIS_RAT1_DEATHS = 0; cleararray $@ARTIS_RAT1_CONTROL, 0, 11; - killmonster "001-2-23.gat", "RattosControl::OnRatto1Death"; - killmonster "001-2-23.gat", "RattosControl::OnRatto2Death"; - killmonster "001-2-23.gat", "RattosControl::OnRatto3Death"; - killmonster "001-2-23.gat", "RattosControl::OnRatto4Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto1Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto2Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto3Death"; + killmonster "001-2-23.gat", "RattosControl#001-2-23::OnRatto4Death"; $@ARTIS_RAT1_COUNTDOWN = gettimetick(2); close; diff --git a/npc/001-2-23/doors.txt b/npc/001-2-23/doors.txt index abfa89cb..71783816 100644 --- a/npc/001-2-23/doors.txt +++ b/npc/001-2-23/doors.txt @@ -30,7 +30,7 @@ L_Warn: close; L_Warp: - warp "001-2-23", 72, 36; + warp "001-2-22", 72, 36; closedialog; close; } diff --git a/npc/001-2-23/ratto.txt b/npc/001-2-23/ratto.txt index 6b22ed2b..c3212778 100644 --- a/npc/001-2-23/ratto.txt +++ b/npc/001-2-23/ratto.txt @@ -20,32 +20,32 @@ 001-2-23,47,30,0 script RattosControl#001-2-23 32767,{ OnSpawn: - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto1Death"; - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto2Death"; - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto3Death"; - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto4Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto1Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto2Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto3Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto4Death"; close; OnRatto1Respawn: - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto1Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto1Death"; $@ARTIS_RAT1_CONTROL[1] = 0; $@ARTIS_RAT1_CONTROL[5] = 0; end; OnRatto2Respawn: - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto2Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto2Death"; $@ARTIS_RAT1_CONTROL[2] = 0; $@ARTIS_RAT1_CONTROL[6] = 0; end; OnRatto3Respawn: - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto3Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto3Death"; $@ARTIS_RAT1_CONTROL[3] = 0; $@ARTIS_RAT1_CONTROL[7] = 0; end; OnRatto4Respawn: - areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl::OnRatto4Death"; + areamonster "001-2-23.gat", 23, 19, 50, 40, "Ratto", 1005, 1, "RattosControl#001-2-23::OnRatto4Death"; $@ARTIS_RAT1_CONTROL[4] = 0; $@ARTIS_RAT1_CONTROL[8] = 0; end; |