diff options
Diffstat (limited to 'npc')
64 files changed, 976 insertions, 287 deletions
diff --git a/npc/002-3/nard.txt b/npc/002-3/nard.txt index f4b08c1cf..e8ce86333 100644 --- a/npc/002-3/nard.txt +++ b/npc/002-3/nard.txt @@ -57,7 +57,7 @@ L_Checker: mesq l("Ship travels are not free. Also, I have a few friends on the Island, and I would like you to check out on them."); next; showavatar NPC_ELMO; - setcamnpc "Elmo"; + setcamnpc instance_npcname("Elmo"); mesn l("Elmo"); mesq l("I, Elmo, captain's deputy, will help you to make the maximum possible money in Candor!"); mesc l("Talk to Elmo to get an EXP UP Boost until level 15!"), 2; @@ -72,6 +72,7 @@ L_Checker: mesc l("EXP Gain raised in @@% for one hour!", .@BONUS), 2; next; showavatar NPC_NARD; + setcamnpc; mesn; mesq l("After that, we're going to Tulimshar. Tulim is the most important city on the world, and the Alliance have an office there."); next; @@ -224,6 +225,7 @@ L_NotYet: next; mesn; mesq l("The Alliance have records of everyone. And if you need another trip, talk to me!"); + mesc l("PROTIP: Every quest you complete in a location, will make ship travels to and from them cheaper!"); } else { mesq l("You still haven't completed your tasks."); diff --git a/npc/003-0-1/professor.txt b/npc/003-0-1/professor.txt index e454e1805..dbde5ce08 100644 --- a/npc/003-0-1/professor.txt +++ b/npc/003-0-1/professor.txt @@ -35,7 +35,8 @@ OnSpeeching: // If you have been IDLE for at least 2 seconds (max AFK 15 minutes) // You'll get the EXP. Note you don't need to sit, only be idle. if (is_between(2, 900, checkidle())) { - getexp 1+getskilllv(TMW2_SPEECH),1; + .@sk=getskilllv(TMW2_SPEECH); + getexp 1+.@sk,1+(.@sk/2); // dispbottom l("It is a boring speech..."); // If you are learning TMW2_READANCIENTLANGUAGES diff --git a/npc/003-1-1/_import.txt b/npc/003-1-1/_import.txt index 3acc019ee..56c456ab0 100644 --- a/npc/003-1-1/_import.txt +++ b/npc/003-1-1/_import.txt @@ -2,5 +2,6 @@ // This file is generated automatically. All manually added changes will be removed when running the Converter. "npc/003-1-1/_mobs.txt", "npc/003-1-1/_warps.txt", +"npc/003-1-1/downpath.txt", "npc/003-1-1/treasure.txt", "npc/003-1-1/yetiking.txt", diff --git a/npc/003-1-1/downpath.txt b/npc/003-1-1/downpath.txt new file mode 100644 index 000000000..fd0c77480 --- /dev/null +++ b/npc/003-1-1/downpath.txt @@ -0,0 +1,30 @@ +// TMW2 scripts. +// Author: +// Jesusalva +// Notes: +// TW: Tulimshar, West +// TE: Tulimshar, East + +003-1-1,100,58,0 script #SewerDD-TW NPC_NO_SPRITE,{ + mesc l("There's a small, damp corritor, which you could crawl though."); + mesc l("It's not possible to see any light, and it seems to small and damp to have monsters."); + mesc l("You could barely fit on it, and your clothes will be ruined, in need of washing."); + next; + mesc l("Descend into the small corritor?"); + mesc l("Note: You'll be vulnerable for a short while!"), 1; + if (askyesno() == ASK_YES) { + closedialog; + sc_start SC_STUN, 3000, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, getcharid(3); + sleep2(3000); + warp "003-1-3", 45, 36; + dispbottom l("At long last, you see the end of the corritor."); + end; + } + close; +} + +003-1-1,150,140,0 script #SewerDD-TE NPC_NO_SPRITE,{ + dispbottom l("The sewer mouth is locked."); + end; +} + diff --git a/npc/003-2/lua.txt b/npc/003-2/lua.txt index 557d6dfee..d29e34b1f 100644 --- a/npc/003-2/lua.txt +++ b/npc/003-2/lua.txt @@ -96,13 +96,16 @@ L_GMEventShop: mesc l("@@ - @@ coins", getitemlink(PrismGift), 80*.@inf); mesc l("@@ - @@ coins", getitemlink(SupremeGift), 160*.@inf); mes ""; + mesc l("Fruits - @@ coins", 30*.@inf); + mes ""; menuint "Return to main menu", -1, rif(.@s > 10*.@inf, "Bronze Gift"), 10, rif(.@s > 20*.@inf, "Silver Gift"), 20, rif(.@s > 40*.@inf, "Golden Gift"), 40, rif(.@s > 80*.@inf, "Prism Gift"), 80, - rif(.@s > 160*.@inf, "Supreme Gift"), 160; + rif(.@s > 160*.@inf, "Supreme Gift"), 160, + rif(.@s > 30*.@inf, "Statusup Fruits"), 30; if (@menuret == -1) goto L_Menu; @@ -119,6 +122,17 @@ L_GMEventShop: getitem PrismGift, 1; break; case 160: getitem SupremeGift, 1; break; + case 30: + menuint + "Strength Fruit",StrengthFruit, + "Agility Fruit",AgilityFruit, + "Vitality Fruit",VitalityFruit, + "Intelligence Fruit",IntelligenceFruit, + "Dexterity Fruit",DexterityFruit, + "Luck Fruit",LuckFruit, + "Mysterious Fruit",MysteriousFruit; + mes ""; + getitem @menuret, 1; break; default: mesc(l("A script error happened, please report: @@", @menuret), 1); break; } diff --git a/npc/003-3/malindou.txt b/npc/003-3/malindou.txt index f2efd46ce..e15d0cf1f 100644 --- a/npc/003-3/malindou.txt +++ b/npc/003-3/malindou.txt @@ -418,6 +418,51 @@ OnInit: debugmes "* Magic Class Removed"; debugmes ""; } + // Current UPDATE value: Sab Ago 24 17:42:24 -03 2019 + // Political System + if ($UPDATE < 1566679344) { + $UPDATE=1566679344; + // $LOC_MAYOR$ - Stores the name of current Hurnscald Mayor + // $LOC_MONEY - Total money reserves of Hurnscald + // $LOC_TAX - How much in % is charged as taxes. (OnBuy income) + // $LOC_EXPORT - Defines how much Hurnscald exports (weekly income) + // $LOC_REPUTATION - Town reputation. Affects Max Tax and Weekly Income. + + // Tulim + $TULIM_MAYOR$="Saulc GM"; + $TULIM_TAX=100; + $TULIM_EXPORT=5000; + $TULIM_REPUTATION=50; + // Halin + $HALIN_MAYOR$="Saulc GM"; + $HALIN_TAX=100; + $HALIN_EXPORT=2000; + $HALIN_REPUTATION=50; + // Hurns + $HURNS_MAYOR$="Saulc GM"; + $HURNS_TAX=100; + $HURNS_EXPORT=3000; + $HURNS_REPUTATION=50; + // LoF + $LOF_MAYOR$="Jesus Saves"; + $LOF_TAX=100; + $LOF_EXPORT=4000; + $LOF_REPUTATION=50; + // Nival + $NIVAL_MAYOR$="Jesus Saves"; + $NIVAL_TAX=100; + $NIVAL_EXPORT=3000; + $NIVAL_REPUTATION=50; + // Frostia + $FROSTIA_MAYOR$="Jesus Saves"; + $FROSTIA_TAX=100; + $FROSTIA_EXPORT=3000; + $FROSTIA_REPUTATION=50; + + debugmes ""; + debugmes "* Political System Base"; + debugmes ""; + } diff --git a/npc/003-8/intensebeard.txt b/npc/003-8/intensebeard.txt index 1189bba0d..8c3a08f7c 100644 --- a/npc/003-8/intensebeard.txt +++ b/npc/003-8/intensebeard.txt @@ -239,7 +239,7 @@ L_Learn: mesq l("There, now you can not only craft items, but craft AWESOME ITEMS!"); RECIPES_EQUIPMENT[CraftDagger]=true; - mesc l("You've also learned how to craft Daggers! These will NOT count towards crafting total score, and serves solely for training purposes."); + mesc l("You've also learned how to craft Daggers! It serves solely for training purposes. You get crafting points for every 40 levels crafted on the item."); } close; diff --git a/npc/004-1/_import.txt b/npc/004-1/_import.txt index a98e3d86b..f53a35438 100644 --- a/npc/004-1/_import.txt +++ b/npc/004-1/_import.txt @@ -4,3 +4,4 @@ "npc/004-1/_warps.txt", "npc/004-1/anwar.txt", "npc/004-1/elanore.txt", +"npc/004-1/sign.txt", diff --git a/npc/004-1/sign.txt b/npc/004-1/sign.txt new file mode 100644 index 000000000..4c0057355 --- /dev/null +++ b/npc/004-1/sign.txt @@ -0,0 +1,19 @@ +// TMW2 Script. +// Author: +// Jesusalva +// Description: +// Sign + +004-1,65,74,0 script Sign#HalinarzoGoto NPC_SWORDS_SIGN,{ + mesc "↑ "+l("Tulimshar"); + mesc "→ "+l("Halinarzo Route"); + mesc "← "+l("Tulimshar Beach"); + mesc "↓ "+l("Tulimshar Mines"); + close; + +OnInit: + .sex = G_OTHER; + .distance = 3; + end; +} + diff --git a/npc/012-1/mahad.txt b/npc/012-1/mahad.txt index 859573754..e37cc6902 100644 --- a/npc/012-1/mahad.txt +++ b/npc/012-1/mahad.txt @@ -35,6 +35,7 @@ } inventoryplace GrassCarp, .@count, BottleOfWoodlandWater, .@count; + delitem EmptyBottle, .@count; // Calculate how many grass carp you'll get .@iced=0; diff --git a/npc/012-1/shoppakep.txt b/npc/012-1/shoppakep.txt index ee65b7d9b..2ee13acc2 100644 --- a/npc/012-1/shoppakep.txt +++ b/npc/012-1/shoppakep.txt @@ -9,6 +9,7 @@ mesq lg("Welcome! Only the finest wares!"); next; closedialog; + npcshopattach(.name$); shop .name$; close; @@ -69,4 +70,10 @@ OnClock0546: .CurrentItem=ShoppaKepItem(); sellitem .CurrentItem, -1, rand(1,4); end; + +// Pay your taxes! +OnBuyItem: + debugmes("Purchase confirmed"); + PurchaseTaxes("Hurns"); + end; } diff --git a/npc/012-2/melina.txt b/npc/012-2/melina.txt index bdb40dbc4..83e78b578 100644 --- a/npc/012-2/melina.txt +++ b/npc/012-2/melina.txt @@ -10,6 +10,7 @@ 012-2,54,43,0 script Melina NPC_FEMALE,{ hello; +npcshopattach(.name$); shop .name$; close; @@ -59,5 +60,9 @@ OnClock2358: else restoreshopitem Beer, 150, ($HELENA_ST/3)+1; end; +// Pay your taxes! +OnBuyItem: + PurchaseTaxes("Hurns"); + end; } diff --git a/npc/012-3/alan.txt b/npc/012-3/alan.txt index 286270e78..6ec713590 100644 --- a/npc/012-3/alan.txt +++ b/npc/012-3/alan.txt @@ -27,6 +27,7 @@ rif(.@q == 1 && .@q2 == .@q3 && .@q2 == 99, l("I have the sturdy wood and the string.")), L_Craft; L_Shop: + npcshopattach(.name$); openshop; closedialog; close; @@ -125,5 +126,11 @@ OnClock1800: restoreshopitem CursedArrow, -1, (($ARKIM_ST-1400)/200); if ($ARKIM_ST > 5600) restoreshopitem PoisonArrow, -1, (($ARKIM_ST-2800)/200); + end; + +// Pay your taxes! +OnBuyItem: + PurchaseTaxes("Hurns"); + end; } diff --git a/npc/012-5/nicholas.txt b/npc/012-5/nicholas.txt index 7ffbd14d5..c6043e786 100644 --- a/npc/012-5/nicholas.txt +++ b/npc/012-5/nicholas.txt @@ -97,6 +97,7 @@ L_Menu: mes ""; switch (@menu) { case 1: + npcshopattach(.name$); openshop; closedialog; close; @@ -248,4 +249,8 @@ OnClock1801: restoreshopitem Dagger, 600, 5; restoreshopitem SharpKnife, 450, 10; end; +// Pay your taxes! +OnBuyItem: + PurchaseTaxes("Hurns"); + end; } diff --git a/npc/014-5-1/sagratha.txt b/npc/014-5-1/sagratha.txt index 5ac046a61..e5f31475c 100644 --- a/npc/014-5-1/sagratha.txt +++ b/npc/014-5-1/sagratha.txt @@ -15,20 +15,20 @@ function script SaggyMobCount { switch (killedrid) { // She gets angry case AlphaMouboo: - SaggyScoreUpdate(-5); + SaggyScoreUpdate(-3); break; case Mouboo: - SaggyScoreUpdate(-4); + SaggyScoreUpdate(any(-2, -3)); break; case Pollet: case Fluffy: case IcedFluffy: - SaggyScoreUpdate(-3); + SaggyScoreUpdate(any(-1, -2, -3)); break; case PoisonSpikyMushroom: case LogHead: case ForestMushroom: - SaggyScoreUpdate(-2); + SaggyScoreUpdate(any(-1, -2)); break; case Squirrel: case SpringSquirrel: diff --git a/npc/014-5/sagratha.txt b/npc/014-5/sagratha.txt index a871ea7f5..a5e2ebfb9 100644 --- a/npc/014-5/sagratha.txt +++ b/npc/014-5/sagratha.txt @@ -37,6 +37,13 @@ function script SaggyInstCheck { setq2 HurnscaldQuest_Sagratha, .@inst; } + // It broke + if (getmapinfo(MAPINFO_SIZE_X, .@mapn$) <= 0) { + setq2 HurnscaldQuest_Sagratha, 0; + // Infinite Loop? + return callfunc("SaggyInstCheck", .@house); + } + if (.@house) { return .@mapn$; } else { @@ -129,10 +136,17 @@ L_Open: select l("Knock on the door?"), l("Attempt to lockpick?"), + l("Say that Mouboos are Cute?"), l("Leave it alone?"); mes ""; - if (@menu == 3) + if (@menu == 4) close; + if (@menu == 3) { + mesc l("Surprisingly, nothing happens."); + next; + mesc l("A close inspection suggests the lock was busted. You approach to inspect."); + next; + } mesc l("*CREAK*"); mesc l("The pressure you did made the door burst open. It is unusually quiet inside..."); next; diff --git a/npc/015-2/ben.txt b/npc/015-2/ben.txt index d64a9619f..080b32279 100644 --- a/npc/015-2/ben.txt +++ b/npc/015-2/ben.txt @@ -37,6 +37,7 @@ L_Quest: mesq l("Congrats! You rank up! You are now a(n) @@!", thiefrank()); if (THIEF_RANK == 2) goto L_Rank2; if (THIEF_RANK == 3) goto L_Rank3; + if (THIEF_RANK == 4) goto L_Rank4; } else { mesn; mesq l("Well, you need more experience. Keep trying!"); @@ -85,6 +86,18 @@ L_Rank3: mesq l("You now gained two extra kilograms to your weight quota! Ka-pow, that's fantastic! Good luck!"); close; +// Learn OVERCHARGE +L_Rank4: + skill(MC_OVERCHARGE,1,0); + next; + mesn; + mesq l("Now, you'll learn an important trick! Stealing is nice, but scamming is even better!"); + mesc l("We must blame Saulc!"); + next; + mesn; + mesq l("This new skill will allow you to pinch every gold piece from a NPC when selling stuff! Ka-pow, now you can steal items and resell them for moar GP! AMAZING!"); + close; + // Allow to level up thief skills L_Menu: next; @@ -97,6 +110,7 @@ L_Menu: select rif(getskilllv(TF_STEAL), l("Improve Stealing to level ")+getskilllv(TF_STEAL)+1), rif(getskilllv(ALL_INCCARRY), l("Improve Max Weight to level ")+getskilllv(ALL_INCCARRY)+1), + rif(getskilllv(MC_OVERCHARGE), l("Improve Barter to level ")+getskilllv(MC_OVERCHARGE)+1), l("None at the moment."); mes ""; // BlueCoral, {CrocClaw, OceanCrocClaw: Empty Box}, PlushroomBox @@ -114,6 +128,12 @@ L_Menu: Mobpt-=1000; break; case 3: + if (!mlearn(MC_OVERCHARGE, 8, 1, PlushroomBox, 2*getskilllv(MC_OVERCHARGE))) // Max 21% discount (out of 24%) + mesc l("You do not meet all requisites for this skill."), 1; + else + Mobpt-=1000; + break; + default: close; } goto L_Menu; diff --git a/npc/015-8-1/campaign.txt b/npc/015-8-1/campaign.txt index 810ebc385..ce1884d78 100644 --- a/npc/015-8-1/campaign.txt +++ b/npc/015-8-1/campaign.txt @@ -28,8 +28,8 @@ OnBegin: unitstop(.SAGRATHA); unitstop(.BOSS); - sc_start(SC_STUN, 4500, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, .SAGRATHA); - sc_start(SC_STUN, 4500, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, .BOSS); + sc_start(SC_STUN, 9000, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, .SAGRATHA); + sc_start(SC_STUN, 9000, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, .BOSS); // FIXME: Seems like this is an "unsafe command" in 4144's opinion // Prevent players from engaging Sagratha and allies @@ -41,7 +41,7 @@ OnBegin: unittalk(.SAGRATHA, l("What are you doing here, @@!", get_race())); - addtimer(1000, .@n$+"::OnS02"); + addtimer(2000, .@n$+"::OnS02"); end; OnS02: @@ -51,7 +51,7 @@ OnS02: unittalk(.SAGRATHA, l("I don't need help!")); unittalk(.BOSS, l("Die already!")); - addtimer(1500, .@n$+"::OnS03"); + addtimer(3000, .@n$+"::OnS03"); end; OnS03: @@ -61,7 +61,7 @@ OnS03: unittalk(.SAGRATHA, l("If you don't want to die, fight!")); unittalk(.BOSS, lg("Murder her too!", "Murder him too!")); - addtimer(1500, .@n$+"::OnS04"); + addtimer(3000, .@n$+"::OnS04"); end; OnS04: @@ -245,6 +245,8 @@ OnSW05: OnSW06: .@m$=getmap(); .@n$=instance_npcname(.name$); + if (getq(HurnscaldQuest_Sagratha) < 5) + end; mesn l("Sagratha"); mesq l("@@, we should leave here now.", strcharinfo(0)); diff --git a/npc/017-1/stranger.txt b/npc/017-1/stranger.txt index 9d75731d1..2a2ddccae 100644 --- a/npc/017-1/stranger.txt +++ b/npc/017-1/stranger.txt @@ -5,7 +5,7 @@ // Jesusalva // Description: // Special quest, can be done every three months, on days 18~25. -// Months: February, May, August, September +// Months: February, May, August, November 017-1,44,37,0 script Stranger#LoF NPC_LOF_STRANGER,{ if (!$@GM_OVERRIDE && (gettime(GETTIME_MONTH) % 3 != 2 || (gettime(GETTIME_DAYOFMONTH) < 18 && gettime(GETTIME_DAYOFMONTH) > 25))) { diff --git a/npc/017-1/townhall.txt b/npc/017-1/townhall.txt index 35482d5ed..61df25334 100644 --- a/npc/017-1/townhall.txt +++ b/npc/017-1/townhall.txt @@ -6,6 +6,7 @@ 017-1,180,20,0 script #LoF_Townhall01 NPC_HIDDEN,{ end; + OnTouch: // Sponsor and Main Quest 17+ - access granted .@q=getq(General_Narrator); @@ -21,6 +22,7 @@ OnInit: 017-1,182,20,0 script #LoF_Townhall02 NPC_HIDDEN,{ end; + OnTouch: // Sponsor and Main Quest 17+ - access granted .@q=getq(General_Narrator); @@ -35,6 +37,7 @@ OnInit: 017-1,171,20,0 script #LoF_Townhall03 NPC_HIDDEN,{ end; + OnTouch: // Sponsor and Main Quest 17+ - access granted .@q=getq(General_Narrator); @@ -49,6 +52,7 @@ OnInit: 017-1,190,20,0 script #LoF_Townhall04 NPC_HIDDEN,{ end; + OnTouch: // Sponsor and Main Quest 17+ - access granted .@q=getq(General_Narrator); @@ -60,4 +64,60 @@ OnInit: .distance=1; end; } +///////////////////////////// +// Main Quest 6 +// LoF Arc +///////////////// +// Check instances and rebuild if needed +// Returns map name +// BarbaraInstCheck( {submap=mines} ) +// 0- Chamber ; 1 - Mines ; 2 - Hall ; 3 - Shrine +function script BarbaraInstCheck { + .@house=getarg(0, true); + + .@q2=getq2(LoFQuest_Barbara); + // Map name limit: 4 chars (sgt1) + .@map0$="brb0@"+getcharid(0); + .@map1$="brb1@"+getcharid(0); + .@map2$="brb2@"+getcharid(0); + .@map3$="brb3@"+getcharid(0); + if (!(isinstance(.@q2) && .@q2 != 0)) { + .@inst = instance_create("Forgotten Shrine "+getcharid(0), getcharid(3), IOT_CHAR); + instance_attachmap("018-6-0", .@inst, false, .@map0$); + instance_attachmap("018-6-1", .@inst, false, .@map1$); + //instance_attachmap("018-6-2", .@inst, false, .@map2$); + //instance_attachmap("018-6-3", .@inst, false, .@map3$); + // Instance lasts two hours + instance_set_timeout(7200, 7200, .@inst); + instance_init(.@inst); + setq2 LoFQuest_Barbara, .@inst; + } + + // It broke + if (getmapinfo(MAPINFO_SIZE_X, .@map1$) <= 0) { + setq2 LoFQuest_Barbara, 0; + // Infinite Loop? + return callfunc("BarbaraInstCheck", .@house); + } + + // Return map name + return getd(".@map"+.@house+"$"); +} + +017-1,32,44,0 script #LoF_EleniumMines NPC_HIDDEN,{ + end; + +OnTouch: + // TODO: OnQuest: Instance + .@q=getq(LoFQuest_Barbara); + if (.@q >= 1) { + warp BarbaraInstCheck(1), 80, 199; + } else { + warp "018-6-1", 80, 199; + } + end; +OnInit: + .distance=1; + end; +} diff --git a/npc/017-10/_import.txt b/npc/017-10/_import.txt index ce6916310..ddd202783 100644 --- a/npc/017-10/_import.txt +++ b/npc/017-10/_import.txt @@ -1,4 +1,4 @@ -// Map 017-10: Tech-User Forge +// Map 017-10: LoF Townhall // This file is generated automatically. All manually added changes will be removed when running the Converter. "npc/017-10/_warps.txt", "npc/017-10/dispatcher.txt", diff --git a/npc/017-10/_warps.txt b/npc/017-10/_warps.txt index 636b97e54..b4d6087eb 100644 --- a/npc/017-10/_warps.txt +++ b/npc/017-10/_warps.txt @@ -1,5 +1,5 @@ // This file is generated automatically. All manually added changes will be removed when running the Converter. -// Map 017-10: Tech-User Forge warps +// Map 017-10: LoF Townhall warps 017-10,36,79,0 warp #017-10_36_79 0,0,017-1,171,21 017-10,56,79,0 warp #017-10_56_79 0,0,017-1,180,21 017-10,60,79,0 warp #017-10_60_79 0,0,017-1,182,21 diff --git a/npc/017-10/dispatcher.txt b/npc/017-10/dispatcher.txt index 82be5fd2a..e612cd65f 100644 --- a/npc/017-10/dispatcher.txt +++ b/npc/017-10/dispatcher.txt @@ -31,6 +31,17 @@ break; case 2: mesc l("Your homunculus is already on a mission!"), 1; + + // Homunculus should return from mission + if (gettimetick(2) > HOMUN_DEPLOYDATE) { + select + l("Recall"); + recallhomunculus(); + .@xp=lootField(HOMUN_DEPLOYFIELD); + gethomunexp(.@xp); + getexp 0, (.@lv*min(10000, gethominfo(3))/10000)*5; + close; + } mesc l("It should be back in @@", FuzzyTime(HOMUN_DEPLOYDATE)), 1; close; break; @@ -45,17 +56,6 @@ close; } - // Homunculus should return from mission - if (homstatus()) { - select - l("Recall"); - recallhomunculus(); - .@xp=lootField(HOMUN_DEPLOYFIELD); - gethomunexp(.@xp); - getexp 0, (.@lv*min(10000, gethominfo(3))/10000)*5; - close; - } - L_Main: select l("Deploy to Piou Fields [1h]"), @@ -169,7 +169,7 @@ L_Main: getitemlink(IcedBottle)); next; .@dest=HCD_SLIMENEST; - .@hours=3; + .@hours=2; break; case 6: mesc ".:: " + l("Snake Pit") + " ::."; @@ -265,7 +265,7 @@ L_Main: deployhomunculus(); mesc l("Deployed!"), 2; HOMUN_DEPLOYFIELD=.@dest; - HOMUN_DEPLOYDATE=gettimetick(2)+(60*.@hours); + HOMUN_DEPLOYDATE=gettimetick(2)+(60*60*.@hours); } close; @@ -327,14 +327,14 @@ function lootField { .@val+=800; anyloot(MaggotSlime, .@lv, 10000, Arrow, .@lv, 9000, - IronArrow, .@lv, 4000, + IronArrow, .@lv, 4000, TreasureKey, max(1, .@lv/10), 6000, CactusDrink, limit(1, .@lv/10, 3), 4000, - CoinBag, limit(1, .@lv/8, 5), 4000, + CoinBag, limit(1, .@lv/8, 5), 4000, CasinoCoins, limit(1, .@lv/6, 10), 3200, - Coal, limit(1, .@lv/10, 3), 3000, - Dagger, limit(1, .@lv/15, 3), 3000, - Candy, limit(1, .@lv/5, 6), 2000, + Coal, limit(1, .@lv/10, 3), 3000, + Dagger, limit(1, .@lv/15, 3), 3000, + Candy, limit(1, .@lv/5, 6), 2000, ChocolateBar, limit(1, .@lv/20, 3), 1000, Milk, 1, 200, IcedBottle, 1, 60); diff --git a/npc/017-4/refine.txt b/npc/017-4/refine.txt index 874cc6c99..4c3e472d7 100644 --- a/npc/017-4/refine.txt +++ b/npc/017-4/refine.txt @@ -20,12 +20,52 @@ OnInit: 017-4,23,23,0 script Fusus NPC_FUSUS,{ showavatar NPC_FUSUS; + select + l("Repair items"), + l("Compact forge stones"); + mes ""; + if (@menu == 2) + goto L_Fusus; @menu=0; do { repairMaster(); } while (getbrokencount() >= 0); +L_Fusus: + inventoryplace Iten, 1; + mesn; + mesq l("I can fuse an @@ and 20 @@, besides @@ GP, into 3~5 @@.", getitemlink(CopperIngot), getitemlink(SilkCocoon), 500, getitemlink(Wurtizite)); + mesc l("5 @@ can be fused in a @@", getitemlink(Wurtizite), getitemlink(Graphene)); + mesc l("5 @@ can be fused in a @@", getitemlink(Graphene), getitemlink(Arcanum)); + select + rif(Zeny >= 500, l("I want the Wurtizite")), + rif(countitem(Wurtizite) >= 5, l("I want Graphene")), + rif(countitem(Graphene) >= 5, l("I want Arcanum")), + l("Do nothing"); + mes ""; + switch (@menu) { + case 4: + close; + case 1: + if (!transcheck(CopperIngot, 1, SilkCocoon, 20)) + close; + Zeny -= 500; + getitem Wurtizite, any(3,3,4,4,4,5); // 3: ~33%. 4: =50%. 5: ~17%. AVG: 3.8 + break; + case 2: + delitem Wurtizite, 5; + getitem Graphene, 1; + break; + case 3: + delitem Graphene, 5; + getitem Arcanum, 1; + break; + } + mesc l("Done!"), 2; + next; + goto L_Fusus; + OnInit: .sex=G_MALE; .distance=5; diff --git a/npc/017-6/azwell.txt b/npc/017-6/azwell.txt index 79fa73dd7..af7f3bf2a 100644 --- a/npc/017-6/azwell.txt +++ b/npc/017-6/azwell.txt @@ -54,47 +54,7 @@ L_ResetStats: mesq l("Status point reset can't be undone. Do you really want this?"); L_ConfirmReset: - select - lg("Yes, I am sure."), - lg("I need to think about it..."); - - switch (@menu) - { - case 1: - speech S_FIRST_BLANK_LINE | S_LAST_NEXT, - l("Let me just have a quick look at you. Hm... I will need @@ GP to reset your stats.", .@plush_count); - - select - rif(Zeny >= .@plush_count, l("Here, take as much as you need, I have plenty!")), - rif(Zeny > 0 && Zeny < .@plush_count, l("I don't have enough money...")), - rif(Zeny == 0, l("Oh no, I don't have any money on me right now.")), - l("I have to go, sorry."); - - if (@menu > 1) { - goto L_Quit; - } - - // TODO: I think there were functions to deal with GP - set Zeny, Zeny-.@plush_count; - - speech S_FIRST_BLANK_LINE | S_LAST_NEXT, - l("Thank you."), - l("Now stand still... It should not take much time..."); - - .@wasSP = StatusPoint; - resetstatus; - if (StatusPoint == .@wasSP) { - speech S_LAST_NEXT, - l("It seems that you have no status points to reset!"), - l("But the money you brought was really awesome you know."), - l("Come back when you will really need me."); - } else { - speech S_LAST_NEXT, - l("Let's see... @@ of your status points have just been reset!", StatusPoint - .@wasSP), - l("Spend it wisely this time."), - l("But you are welcome to reset your stats again! I need the money."); - } - } + ConfirmStatusReset(); goto L_Quit; L_Quit: diff --git a/npc/018-2-2/main.txt b/npc/018-2-2/main.txt index 5bd683233..1c236e997 100644 --- a/npc/018-2-2/main.txt +++ b/npc/018-2-2/main.txt @@ -190,287 +190,477 @@ OnTimer3000: // So killing a Mouboo with 20 luck will give: 1% (luck) + 7% (level) + 0.3% (jexp) => 8.3% drop chance OnNovice0: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[0])*4)+strmobinfo(7,.Novice_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[0])*4)+strmobinfo(7,.Novice_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[0]), .Novice_Mobs[0], 1, "#HH_CONTROLLER01::OnNovice0"; end; OnNovice1: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[1])*4)+strmobinfo(7,.Novice_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[1])*4)+strmobinfo(7,.Novice_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[1]), .Novice_Mobs[1], 1, "#HH_CONTROLLER01::OnNovice1"; end; OnNovice2: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[2])*4)+strmobinfo(7,.Novice_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[2])*4)+strmobinfo(7,.Novice_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[2]), .Novice_Mobs[2], 1, "#HH_CONTROLLER01::OnNovice2"; end; OnNovice3: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[3])*4)+strmobinfo(7,.Novice_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[3])*4)+strmobinfo(7,.Novice_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[3]), .Novice_Mobs[3], 1, "#HH_CONTROLLER01::OnNovice3"; end; OnNovice4: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[4])*4)+strmobinfo(7,.Novice_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[4])*4)+strmobinfo(7,.Novice_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[4]), .Novice_Mobs[4], 1, "#HH_CONTROLLER01::OnNovice4"; end; OnNovice5: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[5])*4)+strmobinfo(7,.Novice_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[5])*4)+strmobinfo(7,.Novice_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[5]), .Novice_Mobs[5], 1, "#HH_CONTROLLER01::OnNovice5"; end; OnNovice6: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[6])*4)+strmobinfo(7,.Novice_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[6])*4)+strmobinfo(7,.Novice_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[6]), .Novice_Mobs[6], 1, "#HH_CONTROLLER01::OnNovice6"; end; OnNovice7: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[7])*4)+strmobinfo(7,.Novice_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[7])*4)+strmobinfo(7,.Novice_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[7]), .Novice_Mobs[7], 1, "#HH_CONTROLLER01::OnNovice7"; end; OnNovice8: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[8])*4)+strmobinfo(7,.Novice_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[8])*4)+strmobinfo(7,.Novice_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[8]), .Novice_Mobs[8], 1, "#HH_CONTROLLER01::OnNovice8"; end; OnNovice9: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[9])*4)+strmobinfo(7,.Novice_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[9])*4)+strmobinfo(7,.Novice_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[9]), .Novice_Mobs[9], 1, "#HH_CONTROLLER01::OnNovice9"; end; OnNovice10: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[10])*4)+strmobinfo(7,.Novice_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[10])*4)+strmobinfo(7,.Novice_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[10]), .Novice_Mobs[10], 1, "#HH_CONTROLLER01::OnNovice10"; end; OnNovice11: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[11])*4)+strmobinfo(7,.Novice_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[11])*4)+strmobinfo(7,.Novice_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[11]), .Novice_Mobs[11], 1, "#HH_CONTROLLER01::OnNovice11"; end; OnNovice12: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[12])*4)+strmobinfo(7,.Novice_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[12])*4)+strmobinfo(7,.Novice_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[12]), .Novice_Mobs[12], 1, "#HH_CONTROLLER01::OnNovice12"; end; OnNovice13: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[13])*4)+strmobinfo(7,.Novice_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[13])*4)+strmobinfo(7,.Novice_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[13]), .Novice_Mobs[13], 1, "#HH_CONTROLLER01::OnNovice13"; end; OnNovice14: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[14])*4)+strmobinfo(7,.Novice_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[14])*4)+strmobinfo(7,.Novice_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[14]), .Novice_Mobs[14], 1, "#HH_CONTROLLER01::OnNovice14"; end; OnNovice15: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[15])*4)+strmobinfo(7,.Novice_Mobs[15])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[15])*4)+strmobinfo(7,.Novice_Mobs[15])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[15]), .Novice_Mobs[15], 1, "#HH_CONTROLLER01::OnNovice15"; end; OnNovice16: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[16])*4)+strmobinfo(7,.Novice_Mobs[16])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[16])*4)+strmobinfo(7,.Novice_Mobs[16])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[16]), .Novice_Mobs[16], 1, "#HH_CONTROLLER01::OnNovice16"; end; OnNovice17: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[17])*4)+strmobinfo(7,.Novice_Mobs[17])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[17])*4)+strmobinfo(7,.Novice_Mobs[17])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[17]), .Novice_Mobs[17], 1, "#HH_CONTROLLER01::OnNovice17"; end; OnNovice18: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[18])*4)+strmobinfo(7,.Novice_Mobs[18])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[18])*4)+strmobinfo(7,.Novice_Mobs[18])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[18]), .Novice_Mobs[18], 1, "#HH_CONTROLLER01::OnNovice18"; end; OnNovice19: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[19])*4)+strmobinfo(7,.Novice_Mobs[19])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[19])*4)+strmobinfo(7,.Novice_Mobs[19])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[19]), .Novice_Mobs[19], 1, "#HH_CONTROLLER01::OnNovice19"; end; OnNovice20: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[20])*4)+strmobinfo(7,.Novice_Mobs[20])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Novice_Mobs[20])*4)+strmobinfo(7,.Novice_Mobs[20])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 1, .@m$, .@x, .@y);} + } areamonster "018-2-2@No", 20, 20, 220, 220, strmobinfo(1, .Novice_Mobs[20]), .Novice_Mobs[20], 1, "#HH_CONTROLLER01::OnNovice20"; end; + + OnInterm0: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[0])*4)+strmobinfo(7,.Interm_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[0]), .Interm_Mobs[0], 1, "#HH_CONTROLLER01::OnInterm0"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[0])*4)+strmobinfo(7,.Interm_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[0]), .Interm_Mobs[0], 1, "#HH_CONTROLLER01::OnInterm0"; end; OnInterm1: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[1])*4)+strmobinfo(7,.Interm_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[1]), .Interm_Mobs[1], 1, "#HH_CONTROLLER01::OnInterm1"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[1])*4)+strmobinfo(7,.Interm_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[1]), .Interm_Mobs[1], 1, "#HH_CONTROLLER01::OnInterm1"; end; OnInterm2: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[2])*4)+strmobinfo(7,.Interm_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[2]), .Interm_Mobs[2], 1, "#HH_CONTROLLER01::OnInterm2"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[2])*4)+strmobinfo(7,.Interm_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[2]), .Interm_Mobs[2], 1, "#HH_CONTROLLER01::OnInterm2"; end; OnInterm3: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[3])*4)+strmobinfo(7,.Interm_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[3]), .Interm_Mobs[3], 1, "#HH_CONTROLLER01::OnInterm3"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[3])*4)+strmobinfo(7,.Interm_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[3]), .Interm_Mobs[3], 1, "#HH_CONTROLLER01::OnInterm3"; end; OnInterm4: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[4])*4)+strmobinfo(7,.Interm_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[4]), .Interm_Mobs[4], 1, "#HH_CONTROLLER01::OnInterm4"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[4])*4)+strmobinfo(7,.Interm_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[4]), .Interm_Mobs[4], 1, "#HH_CONTROLLER01::OnInterm4"; end; OnInterm5: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[5])*4)+strmobinfo(7,.Interm_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[5]), .Interm_Mobs[5], 1, "#HH_CONTROLLER01::OnInterm5"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[5])*4)+strmobinfo(7,.Interm_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[5]), .Interm_Mobs[5], 1, "#HH_CONTROLLER01::OnInterm5"; end; OnInterm6: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[6])*4)+strmobinfo(7,.Interm_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[6]), .Interm_Mobs[6], 1, "#HH_CONTROLLER01::OnInterm6"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[6])*4)+strmobinfo(7,.Interm_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[6]), .Interm_Mobs[6], 1, "#HH_CONTROLLER01::OnInterm6"; end; OnInterm7: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[7])*4)+strmobinfo(7,.Interm_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[7]), .Interm_Mobs[7], 1, "#HH_CONTROLLER01::OnInterm7"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[7])*4)+strmobinfo(7,.Interm_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[7]), .Interm_Mobs[7], 1, "#HH_CONTROLLER01::OnInterm7"; end; OnInterm8: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[8])*4)+strmobinfo(7,.Interm_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[8]), .Interm_Mobs[8], 1, "#HH_CONTROLLER01::OnInterm8"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[8])*4)+strmobinfo(7,.Interm_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[8]), .Interm_Mobs[8], 1, "#HH_CONTROLLER01::OnInterm8"; end; OnInterm9: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[9])*4)+strmobinfo(7,.Interm_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[9]), .Interm_Mobs[9], 1, "#HH_CONTROLLER01::OnInterm9"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[9])*4)+strmobinfo(7,.Interm_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[9]), .Interm_Mobs[9], 1, "#HH_CONTROLLER01::OnInterm9"; end; OnInterm10: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[10])*4)+strmobinfo(7,.Interm_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[10]), .Interm_Mobs[10], 1, "#HH_CONTROLLER01::OnInterm10"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[10])*4)+strmobinfo(7,.Interm_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[10]), .Interm_Mobs[10], 1, "#HH_CONTROLLER01::OnInterm10"; end; OnInterm11: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[11])*4)+strmobinfo(7,.Interm_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[11]), .Interm_Mobs[11], 1, "#HH_CONTROLLER01::OnInterm11"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[11])*4)+strmobinfo(7,.Interm_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[11]), .Interm_Mobs[11], 1, "#HH_CONTROLLER01::OnInterm11"; end; OnInterm12: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[12])*4)+strmobinfo(7,.Interm_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[12]), .Interm_Mobs[12], 1, "#HH_CONTROLLER01::OnInterm12"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[12])*4)+strmobinfo(7,.Interm_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[12]), .Interm_Mobs[12], 1, "#HH_CONTROLLER01::OnInterm12"; end; OnInterm13: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[13])*4)+strmobinfo(7,.Interm_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[13]), .Interm_Mobs[13], 1, "#HH_CONTROLLER01::OnInterm13"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[13])*4)+strmobinfo(7,.Interm_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[13]), .Interm_Mobs[13], 1, "#HH_CONTROLLER01::OnInterm13"; end; OnInterm14: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[14])*4)+strmobinfo(7,.Interm_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[14]), .Interm_Mobs[14], 1, "#HH_CONTROLLER01::OnInterm14"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[14])*4)+strmobinfo(7,.Interm_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[14]), .Interm_Mobs[14], 1, "#HH_CONTROLLER01::OnInterm14"; end; OnInterm15: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[15])*4)+strmobinfo(7,.Interm_Mobs[15])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[15]), .Interm_Mobs[15], 1, "#HH_CONTROLLER01::OnInterm15"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[15])*4)+strmobinfo(7,.Interm_Mobs[15])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[15]), .Interm_Mobs[15], 1, "#HH_CONTROLLER01::OnInterm15"; end; OnInterm16: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[16])*4)+strmobinfo(7,.Interm_Mobs[16])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[16]), .Interm_Mobs[16], 1, "#HH_CONTROLLER01::OnInterm16"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[16])*4)+strmobinfo(7,.Interm_Mobs[16])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[16]), .Interm_Mobs[16], 1, "#HH_CONTROLLER01::OnInterm16"; end; OnInterm17: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[17])*4)+strmobinfo(7,.Interm_Mobs[17])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[17]), .Interm_Mobs[17], 1, "#HH_CONTROLLER01::OnInterm17"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[17])*4)+strmobinfo(7,.Interm_Mobs[17])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[17]), .Interm_Mobs[17], 1, "#HH_CONTROLLER01::OnInterm17"; end; OnInterm18: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[18])*4)+strmobinfo(7,.Interm_Mobs[18])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[18]), .Interm_Mobs[18], 1, "#HH_CONTROLLER01::OnInterm18"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[18])*4)+strmobinfo(7,.Interm_Mobs[18])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[18]), .Interm_Mobs[18], 1, "#HH_CONTROLLER01::OnInterm18"; end; OnInterm19: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[19])*4)+strmobinfo(7,.Interm_Mobs[19])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} - areamonster "018-2-2@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[19]), .Interm_Mobs[19], 1, "#HH_CONTROLLER01::OnInterm19"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Interm_Mobs[19])*4)+strmobinfo(7,.Interm_Mobs[19])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 2, .@m$, .@x, .@y);} + } + areamonster "018-2-3@In", 20, 20, 220, 220, strmobinfo(1, .Interm_Mobs[19]), .Interm_Mobs[19], 1, "#HH_CONTROLLER01::OnInterm19"; end; + + OnAdvanc0: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[0])*4)+strmobinfo(7,.Advanc_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[0])*4)+strmobinfo(7,.Advanc_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[0]), .Advanc_Mobs[0], 1, "#HH_CONTROLLER01::OnAdvanc0"; end; OnAdvanc1: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[1])*4)+strmobinfo(7,.Advanc_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[1])*4)+strmobinfo(7,.Advanc_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[1]), .Advanc_Mobs[1], 1, "#HH_CONTROLLER01::OnAdvanc1"; end; OnAdvanc2: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[2])*4)+strmobinfo(7,.Advanc_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[2])*4)+strmobinfo(7,.Advanc_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[2]), .Advanc_Mobs[2], 1, "#HH_CONTROLLER01::OnAdvanc2"; end; OnAdvanc3: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[3])*4)+strmobinfo(7,.Advanc_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[3])*4)+strmobinfo(7,.Advanc_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[3]), .Advanc_Mobs[3], 1, "#HH_CONTROLLER01::OnAdvanc3"; end; OnAdvanc4: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[4])*4)+strmobinfo(7,.Advanc_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[4])*4)+strmobinfo(7,.Advanc_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[4]), .Advanc_Mobs[4], 1, "#HH_CONTROLLER01::OnAdvanc4"; end; OnAdvanc5: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[5])*4)+strmobinfo(7,.Advanc_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[5])*4)+strmobinfo(7,.Advanc_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[5]), .Advanc_Mobs[5], 1, "#HH_CONTROLLER01::OnAdvanc5"; end; OnAdvanc6: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[6])*4)+strmobinfo(7,.Advanc_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[6])*4)+strmobinfo(7,.Advanc_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[6]), .Advanc_Mobs[6], 1, "#HH_CONTROLLER01::OnAdvanc6"; end; OnAdvanc7: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[7])*4)+strmobinfo(7,.Advanc_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[7])*4)+strmobinfo(7,.Advanc_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[7]), .Advanc_Mobs[7], 1, "#HH_CONTROLLER01::OnAdvanc7"; end; OnAdvanc8: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[8])*4)+strmobinfo(7,.Advanc_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[8])*4)+strmobinfo(7,.Advanc_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[8]), .Advanc_Mobs[8], 1, "#HH_CONTROLLER01::OnAdvanc8"; end; OnAdvanc9: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[9])*4)+strmobinfo(7,.Advanc_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[9])*4)+strmobinfo(7,.Advanc_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[9]), .Advanc_Mobs[9], 1, "#HH_CONTROLLER01::OnAdvanc9"; end; OnAdvanc10: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[10])*4)+strmobinfo(7,.Advanc_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[10])*4)+strmobinfo(7,.Advanc_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[10]), .Advanc_Mobs[10], 1, "#HH_CONTROLLER01::OnAdvanc10"; end; OnAdvanc11: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[11])*4)+strmobinfo(7,.Advanc_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[11])*4)+strmobinfo(7,.Advanc_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[11]), .Advanc_Mobs[11], 1, "#HH_CONTROLLER01::OnAdvanc11"; end; OnAdvanc12: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[12])*4)+strmobinfo(7,.Advanc_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[12])*4)+strmobinfo(7,.Advanc_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[12]), .Advanc_Mobs[12], 1, "#HH_CONTROLLER01::OnAdvanc12"; end; OnAdvanc13: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[13])*4)+strmobinfo(7,.Advanc_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[13])*4)+strmobinfo(7,.Advanc_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[13]), .Advanc_Mobs[13], 1, "#HH_CONTROLLER01::OnAdvanc13"; end; OnAdvanc14: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[14])*4)+strmobinfo(7,.Advanc_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[14])*4)+strmobinfo(7,.Advanc_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[14]), .Advanc_Mobs[14], 1, "#HH_CONTROLLER01::OnAdvanc14"; end; OnAdvanc15: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[15])*4)+strmobinfo(7,.Advanc_Mobs[15])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[15])*4)+strmobinfo(7,.Advanc_Mobs[15])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[15]), .Advanc_Mobs[15], 1, "#HH_CONTROLLER01::OnAdvanc15"; end; OnAdvanc16: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[16])*4)+strmobinfo(7,.Advanc_Mobs[16])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[16])*4)+strmobinfo(7,.Advanc_Mobs[16])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[16]), .Advanc_Mobs[16], 1, "#HH_CONTROLLER01::OnAdvanc16"; end; OnAdvanc17: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[17])*4)+strmobinfo(7,.Advanc_Mobs[17])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Advanc_Mobs[17])*4)+strmobinfo(7,.Advanc_Mobs[17])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 4, .@m$, .@x, .@y);} + } areamonster "018-2-2@Ad", 20, 20, 220, 220, strmobinfo(1, .Advanc_Mobs[17]), .Advanc_Mobs[17], 1, "#HH_CONTROLLER01::OnAdvanc17"; end; + + OnExpert0: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[0])*4)+strmobinfo(7,.Expert_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[0]), .Expert_Mobs[0], 1, "#HH_CONTROLLER01::OnExpert0"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[0])*4)+strmobinfo(7,.Expert_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[0]), .Expert_Mobs[0], 1, "#HH_CONTROLLER01::OnExpert0"; end; OnExpert1: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[1])*4)+strmobinfo(7,.Expert_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[1]), .Expert_Mobs[1], 1, "#HH_CONTROLLER01::OnExpert1"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[1])*4)+strmobinfo(7,.Expert_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[1]), .Expert_Mobs[1], 1, "#HH_CONTROLLER01::OnExpert1"; end; OnExpert2: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[2])*4)+strmobinfo(7,.Expert_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[2]), .Expert_Mobs[2], 1, "#HH_CONTROLLER01::OnExpert2"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[2])*4)+strmobinfo(7,.Expert_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[2]), .Expert_Mobs[2], 1, "#HH_CONTROLLER01::OnExpert2"; end; OnExpert3: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[3])*4)+strmobinfo(7,.Expert_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[3]), .Expert_Mobs[3], 1, "#HH_CONTROLLER01::OnExpert3"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[3])*4)+strmobinfo(7,.Expert_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[3]), .Expert_Mobs[3], 1, "#HH_CONTROLLER01::OnExpert3"; end; OnExpert4: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[4])*4)+strmobinfo(7,.Expert_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[4]), .Expert_Mobs[4], 1, "#HH_CONTROLLER01::OnExpert4"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[4])*4)+strmobinfo(7,.Expert_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[4]), .Expert_Mobs[4], 1, "#HH_CONTROLLER01::OnExpert4"; end; OnExpert5: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[5])*4)+strmobinfo(7,.Expert_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[5]), .Expert_Mobs[5], 1, "#HH_CONTROLLER01::OnExpert5"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[5])*4)+strmobinfo(7,.Expert_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[5]), .Expert_Mobs[5], 1, "#HH_CONTROLLER01::OnExpert5"; end; OnExpert6: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[6])*4)+strmobinfo(7,.Expert_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[6]), .Expert_Mobs[6], 1, "#HH_CONTROLLER01::OnExpert6"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[6])*4)+strmobinfo(7,.Expert_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[6]), .Expert_Mobs[6], 1, "#HH_CONTROLLER01::OnExpert6"; end; OnExpert7: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[7])*4)+strmobinfo(7,.Expert_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[7]), .Expert_Mobs[7], 1, "#HH_CONTROLLER01::OnExpert7"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[7])*4)+strmobinfo(7,.Expert_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[7]), .Expert_Mobs[7], 1, "#HH_CONTROLLER01::OnExpert7"; end; OnExpert8: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[8])*4)+strmobinfo(7,.Expert_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[8]), .Expert_Mobs[8], 1, "#HH_CONTROLLER01::OnExpert8"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[8])*4)+strmobinfo(7,.Expert_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[8]), .Expert_Mobs[8], 1, "#HH_CONTROLLER01::OnExpert8"; end; OnExpert9: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[9])*4)+strmobinfo(7,.Expert_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[9]), .Expert_Mobs[9], 1, "#HH_CONTROLLER01::OnExpert9"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[9])*4)+strmobinfo(7,.Expert_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[9]), .Expert_Mobs[9], 1, "#HH_CONTROLLER01::OnExpert9"; end; OnExpert10: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[10])*4)+strmobinfo(7,.Expert_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[10]), .Expert_Mobs[10], 1, "#HH_CONTROLLER01::OnExpert10"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[10])*4)+strmobinfo(7,.Expert_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[10]), .Expert_Mobs[10], 1, "#HH_CONTROLLER01::OnExpert10"; end; OnExpert11: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[11])*4)+strmobinfo(7,.Expert_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[11]), .Expert_Mobs[11], 1, "#HH_CONTROLLER01::OnExpert11"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[11])*4)+strmobinfo(7,.Expert_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[11]), .Expert_Mobs[11], 1, "#HH_CONTROLLER01::OnExpert11"; end; OnExpert12: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[12])*4)+strmobinfo(7,.Expert_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[12]), .Expert_Mobs[12], 1, "#HH_CONTROLLER01::OnExpert12"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[12])*4)+strmobinfo(7,.Expert_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[12]), .Expert_Mobs[12], 1, "#HH_CONTROLLER01::OnExpert12"; end; OnExpert13: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[13])*4)+strmobinfo(7,.Expert_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[13]), .Expert_Mobs[13], 1, "#HH_CONTROLLER01::OnExpert13"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[13])*4)+strmobinfo(7,.Expert_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[13]), .Expert_Mobs[13], 1, "#HH_CONTROLLER01::OnExpert13"; end; OnExpert14: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[14])*4)+strmobinfo(7,.Expert_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} - areamonster "018-2-2@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[14]), .Expert_Mobs[14], 1, "#HH_CONTROLLER01::OnExpert14"; end; + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Expert_Mobs[14])*4)+strmobinfo(7,.Expert_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 8, .@m$, .@x, .@y);} + } + areamonster "018-2-3@Ex", 20, 20, 220, 220, strmobinfo(1, .Expert_Mobs[14]), .Expert_Mobs[14], 1, "#HH_CONTROLLER01::OnExpert14"; end; + + OnMaster0: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[0])*4)+strmobinfo(7,.Master_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[0])*4)+strmobinfo(7,.Master_Mobs[0])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[0]), .Master_Mobs[0], 1, "#HH_CONTROLLER01::OnMaster0"; end; OnMaster1: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[1])*4)+strmobinfo(7,.Master_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[1])*4)+strmobinfo(7,.Master_Mobs[1])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[1]), .Master_Mobs[1], 1, "#HH_CONTROLLER01::OnMaster1"; end; OnMaster2: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[2])*4)+strmobinfo(7,.Master_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[2])*4)+strmobinfo(7,.Master_Mobs[2])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[2]), .Master_Mobs[2], 1, "#HH_CONTROLLER01::OnMaster2"; end; OnMaster3: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[3])*4)+strmobinfo(7,.Master_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[3])*4)+strmobinfo(7,.Master_Mobs[3])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[3]), .Master_Mobs[3], 1, "#HH_CONTROLLER01::OnMaster3"; end; OnMaster4: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[4])*4)+strmobinfo(7,.Master_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[4])*4)+strmobinfo(7,.Master_Mobs[4])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[4]), .Master_Mobs[4], 1, "#HH_CONTROLLER01::OnMaster4"; end; OnMaster5: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[5])*4)+strmobinfo(7,.Master_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[5])*4)+strmobinfo(7,.Master_Mobs[5])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[5]), .Master_Mobs[5], 1, "#HH_CONTROLLER01::OnMaster5"; end; OnMaster6: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[6])*4)+strmobinfo(7,.Master_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[6])*4)+strmobinfo(7,.Master_Mobs[6])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[6]), .Master_Mobs[6], 1, "#HH_CONTROLLER01::OnMaster6"; end; OnMaster7: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[7])*4)+strmobinfo(7,.Master_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[7])*4)+strmobinfo(7,.Master_Mobs[7])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[7]), .Master_Mobs[7], 1, "#HH_CONTROLLER01::OnMaster7"; end; OnMaster8: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[8])*4)+strmobinfo(7,.Master_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[8])*4)+strmobinfo(7,.Master_Mobs[8])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[8]), .Master_Mobs[8], 1, "#HH_CONTROLLER01::OnMaster8"; end; OnMaster9: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[9])*4)+strmobinfo(7,.Master_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[9])*4)+strmobinfo(7,.Master_Mobs[9])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[9]), .Master_Mobs[9], 1, "#HH_CONTROLLER01::OnMaster9"; end; OnMaster10: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[10])*4)+strmobinfo(7,.Master_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[10])*4)+strmobinfo(7,.Master_Mobs[10])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[10]), .Master_Mobs[10], 1, "#HH_CONTROLLER01::OnMaster10"; end; OnMaster11: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[11])*4)+strmobinfo(7,.Master_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[11])*4)+strmobinfo(7,.Master_Mobs[11])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[11]), .Master_Mobs[11], 1, "#HH_CONTROLLER01::OnMaster11"; end; OnMaster12: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[12])*4)+strmobinfo(7,.Master_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[12])*4)+strmobinfo(7,.Master_Mobs[12])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[12]), .Master_Mobs[12], 1, "#HH_CONTROLLER01::OnMaster12"; end; OnMaster13: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[13])*4)+strmobinfo(7,.Master_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[13])*4)+strmobinfo(7,.Master_Mobs[13])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[13]), .Master_Mobs[13], 1, "#HH_CONTROLLER01::OnMaster13"; end; OnMaster14: - if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[14])*4)+strmobinfo(7,.Master_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + if (playerattached()) { + if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.Master_Mobs[14])*4)+strmobinfo(7,.Master_Mobs[14])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, 16, .@m$, .@x, .@y);} + } areamonster "018-2-5@Ma", 20, 20, 220, 220, strmobinfo(1, .Master_Mobs[14]), .Master_Mobs[14], 1, "#HH_CONTROLLER01::OnMaster14"; end; } /*python -df=[('Novice', 21, 1), - ('Interm', 20, 2), - ('Advanc', 18, 4), - ('Expert', 15, 8), - ('Master', 15, 16)] +# df (name, mobs, reward, mapid) +df=[('Novice', 21, 1, 2), + ('Interm', 20, 2, 3), + ('Advanc', 18, 4, 2), + ('Expert', 15, 8, 3), + ('Master', 15, 16,5)] for a in df: + print("\n") i=0 while (i < a[1]): print('On%s%d:' % (a[0], i)) - print(' if (rand(0, 2000) <= readparam(Luk)+(strmobinfo(3,.%s_Mobs[%d])*4)+strmobinfo(7,.%s_Mobs[%d])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, %s, .@m$, .@x, .@y);}' % (a[0], i, a[0], i, a[2])) - print(' areamonster "018-2-2@%s", 20, 20, 220, 220, strmobinfo(1, .%s_Mobs[%d]), .%s_Mobs[%d], 1, "#HH_CONTROLLER01::On%s%d"; end;' % (a[0][:2],a[0],i,a[0],i,a[0],i)) + print(' if (playerattached()) {') + print(' if (rand2(0, 2000) <= readparam(Luk)+(strmobinfo(3,.%s_Mobs[%d])*4)+strmobinfo(7,.%s_Mobs[%d])) {getmapxy(.@m$, .@x, .@y, 0); makeitem(HeroCoin, %s, .@m$, .@x, .@y);}' % (a[0], i, a[0], i, a[2])) + print(' }') + print(' areamonster "018-2-%d@%s", 20, 20, 220, 220, strmobinfo(1, .%s_Mobs[%d]), .%s_Mobs[%d], 1, "#HH_CONTROLLER01::On%s%d"; end;' % (a[3], a[0][:2],a[0],i,a[0],i,a[0],i)) i+=1 */ diff --git a/npc/018-6-0/_import.txt b/npc/018-6-0/_import.txt new file mode 100644 index 000000000..45be6bdab --- /dev/null +++ b/npc/018-6-0/_import.txt @@ -0,0 +1,2 @@ +// Map 018-6-0: Sanctuary - Forgotten Chamber +// This file is generated automatically. All manually added changes will be removed when running the Converter. diff --git a/npc/018-6-1/_import.txt b/npc/018-6-1/_import.txt new file mode 100644 index 000000000..de446a263 --- /dev/null +++ b/npc/018-6-1/_import.txt @@ -0,0 +1,4 @@ +// Map 018-6-1: Elenium Mines +// This file is generated automatically. All manually added changes will be removed when running the Converter. +"npc/018-6-1/_mobs.txt", +"npc/018-6-1/_warps.txt", diff --git a/npc/018-6-1/_mobs.txt b/npc/018-6-1/_mobs.txt new file mode 100644 index 000000000..fd07526ca --- /dev/null +++ b/npc/018-6-1/_mobs.txt @@ -0,0 +1,16 @@ +// This file is generated automatically. All manually added changes will be removed when running the Converter. +// Map 018-6-1: Elenium Mines mobs +018-6-1,40,49,7,8 monster Big Elenium Bif 1228,5,450000,45000 +018-6-1,95,51,7,8 monster Big Elenium Bif 1228,5,450000,45000 +018-6-1,145,83,6,5 monster Medium Elenium Bif 1227,5,400000,45000 +018-6-1,62,86,6,5 monster Medium Elenium Bif 1227,5,400000,45000 +018-6-1,65,130,6,5 monster Medium Elenium Bif 1227,5,400000,45000 +018-6-1,125,158,6,5 monster Small Elenium Bif 1226,4,300000,45000 +018-6-1,129,183,6,5 monster Small Elenium Bif 1226,4,300000,45000 +018-6-1,34,181,5,5 monster Small Elenium Bif 1226,4,300000,45000 +018-6-1,80,172,54,25 monster Black Slime 1178,16,30000,15000 +018-6-1,89,167,54,25 monster Dark Lizard 1051,8,30000,15000 +018-6-1,96,103,56,29 monster Black Scorpion 1074,18,30000,15000 +018-6-1,101,105,54,25 monster Mountain Snake 1123,10,30000,15000 +018-6-1,70,45,44,25 monster Wicked Mushroom 1176,14,30000,15000 +018-6-1,68,45,31,21 monster Archant 1026,7,30000,15000 diff --git a/npc/018-6-1/_warps.txt b/npc/018-6-1/_warps.txt new file mode 100644 index 000000000..dda336877 --- /dev/null +++ b/npc/018-6-1/_warps.txt @@ -0,0 +1,3 @@ +// This file is generated automatically. All manually added changes will be removed when running the Converter. +// Map 018-6-1: Elenium Mines warps +018-6-1,80,200,0 warp #018-6-1_80_200 0,0,017-1,32,45 diff --git a/npc/019-1/well.txt b/npc/019-1/well.txt index 6f90d5fb7..6839eae0a 100644 --- a/npc/019-1/well.txt +++ b/npc/019-1/well.txt @@ -144,6 +144,7 @@ L_Bottle: } inventoryplace IcedBottle, .@count, BottleOfWoodlandWater, .@count; + delitem EmptyBottle, .@count; // Calculate how many iced bottles you'll get .@iced=0; diff --git a/npc/020-3/mede.txt b/npc/020-3/mede.txt index d35e7624d..52a3c5e79 100644 --- a/npc/020-3/mede.txt +++ b/npc/020-3/mede.txt @@ -38,10 +38,7 @@ L_ResetStats: mesq l("Status point reset can't be undone. Do you really want this?"); L_ConfirmReset: - if (BaseLevel <= 10) - ConfirmStatusReset(0); - else - ConfirmStatusReset(); + ConfirmStatusReset(); goto L_Quit; L_MonsterPot: diff --git a/npc/020-5/bracco.txt b/npc/020-5/bracco.txt index 9452de333..f30bc7fd9 100644 --- a/npc/020-5/bracco.txt +++ b/npc/020-5/bracco.txt @@ -14,26 +14,22 @@ .@index=getarg(0); .@price=getarg(1); + + // Confirmation mesn; mesc l("Really melt down your @@? It'll cost you @@ GP. This action cannot be undone!", getinvindexlink(.@index), .@price), 1; next; if (askyesno() == ASK_NO || Zeny < .@price) return; - //failedremovecardsindex .@index, 0; // TODO: Fix this and upgrade server - delinventorylist(); - getinventorylist(); - .@item=@inventorylist_id[.@index]; - - if (.@item <= 0) { - Exception(l("Error translating item ID @@ to @@ (Bracco, idx, id)", .@index, .@item), RB_DEFAULT|RB_SPEECH|RB_ISFATAL); - } + // Report it was done + mesc l("@@ melt down your @@...", .name$, getinvindexlink(.@index)); - delitem .@item, 1; + // Effective: delete item and GP + delitemidx .@index, 1; Zeny-=.@price; - mesc l("@@ melt down your @@...", .name$, getinvindexlink(.@index)); - // TODO: Inventoryplace + // TODO: Inventoryplace. // Add Items (if inventory is full, your fault and not mine) for (.@i=2;.@i < getargcount(); .@i++) { if (getarg(.@i+1)) {// It may be zero diff --git a/npc/_import.txt b/npc/_import.txt index d568e0aaf..c877bae5d 100644 --- a/npc/_import.txt +++ b/npc/_import.txt @@ -126,6 +126,8 @@ @include "npc/018-5-3/_import.txt" @include "npc/018-5-boss/_import.txt" @include "npc/018-5/_import.txt" +@include "npc/018-6-0/_import.txt" +@include "npc/018-6-1/_import.txt" @include "npc/019-1-1/_import.txt" @include "npc/019-1/_import.txt" @include "npc/019-2/_import.txt" diff --git a/npc/commands/debug.txt b/npc/commands/debug.txt index 70d0d8392..5ffb409bb 100644 --- a/npc/commands/debug.txt +++ b/npc/commands/debug.txt @@ -7,6 +7,7 @@ function script GlobalDebugMenu { resetstatus; resetskill; resetlvl 1; + dispbottom b("ALL PERMANENT STATUS BOOSTS WERE ALSO RESET"); dispbottom l("Reset done!"); if (getarg(0,0) == 3) { closedialog; diff --git a/npc/commands/grantpower.txt b/npc/commands/grantpower.txt index ac48c10b7..3ce37e47b 100644 --- a/npc/commands/grantpower.txt +++ b/npc/commands/grantpower.txt @@ -22,7 +22,7 @@ OnCall: } // Player is not attached - .@id = getcharid(0, .@request$); + .@id = getcharid(3, .@request$); if (!.@id) { Exception("Player not found.", RB_ISFATAL|RB_DISPBOTTOM); } @@ -43,7 +43,7 @@ OnCall: rif(countitem(AegisShield), l("Aegis Shield")), AegisShield, l("Abort"), 0; mes ""; - .@ori=getcharid(0); + .@ori=getcharid(3); .@ite=@menuret; if (!.@ite) close; diff --git a/npc/craft/recipes.txt b/npc/craft/recipes.txt index 65409aee8..98c2c2849 100644 --- a/npc/craft/recipes.txt +++ b/npc/craft/recipes.txt @@ -276,22 +276,22 @@ function readCrafting { 40, WoodenLog, 60, ManaPiouFeathers, 8, FluoPowder, - 2, GemPowder); + 1, GemPowder); showRecipe(CraftApprenticeWand, ApprenticeWand, 60, WoodenLog, 90, ManaPiouFeathers, 12, FluoPowder, - 3, GemPowder); + 1, GemPowder); showRecipe(CraftLeaderWand, LeaderWand, 100, WoodenLog, 120, ManaPiouFeathers, 15, FluoPowder, - 5, GemPowder); + 1, GemPowder); showRecipe(CraftLegendaryWand, LegendaryWand, 110, WoodenLog, 3, GoldenApple, 20, FluoPowder, - 7, GemPowder); + 1, GemPowder); next; // Firestaff Weapons: Lead + Titanium mesc "----------"+l("Fire Staffs Recipes")+"----------", 2; diff --git a/npc/craft/smith.txt b/npc/craft/smith.txt index fa866f7eb..9d0739926 100644 --- a/npc/craft/smith.txt +++ b/npc/craft/smith.txt @@ -45,9 +45,12 @@ function script SmithSystem { // Player craft item usecraft .@craft; .@it=getcraftcode(.@entry); - // Mark the crafting in your score book (except dagger) - if (.@it != Dagger) - CRAFTING_SCORE+=1; + + // Mark the crafting in your score variable + CRAFTING_SCORE_COMPLETE+=getiteminfo(.@it, ITEMINFO_ELV); + // Update your score book + CRAFTING_SCORE=(CRAFTING_SCORE_COMPLETE/40); + if (.scope == CRAFT_GUILD) getitembound(.@it, 1, 2); // Create a guild-bound item else diff --git a/npc/functions/array.txt b/npc/functions/array.txt index 1a106175e..161cedd0b 100644 --- a/npc/functions/array.txt +++ b/npc/functions/array.txt @@ -411,3 +411,25 @@ function script array_filter { freeloop(false); return .@count; } + +// array_highest(<array>) +// Returns the index of the highest value in <array> +// NOTE: Array must be an INT array! + +function script array_highest { + .@size = getarraysize(getarg(0)); + .@win=0; + .@idx=0; + freeloop(true); + + for (.@i = getarrayindex(getarg(0)); .@i < .@size; ++.@i) { + if (getelementofarray(getarg(0), .@i) > .@win) { + .@win=getelementofarray(getarg(0), .@i); + .@idx=.@i; + } + } + + freeloop(false); + return .@idx; +} + diff --git a/npc/functions/clientversion.txt b/npc/functions/clientversion.txt index 51e5eab84..94b37582f 100644 --- a/npc/functions/clientversion.txt +++ b/npc/functions/clientversion.txt @@ -579,6 +579,13 @@ function script clientupdater { getitem GoldenGift, 1; if (BaseLevel >= 75 && getq(TulimsharQuest_Eistein) >= 3) getitem GraduationRobe, 1; + // Grant you Thief Skill Tier 4 + if (THIEF_RANK >= 4) { + skill(MC_OVERCHARGE,1,0); + dispbottom l("You have learnt \"Barter\" in Thief Skills."); + } + // Update Crafting Score + CRAFTING_SCORE_COMPLETE=CRAFTING_SCORE*39; } // Test Server Updates diff --git a/npc/functions/lockpicks.txt b/npc/functions/lockpicks.txt index 88171c3dd..c8271ba3a 100644 --- a/npc/functions/lockpicks.txt +++ b/npc/functions/lockpicks.txt @@ -71,8 +71,8 @@ function script LockPicking { l("Give up!"), 0; if (!@menuret) { - // 10% chance to save the lockpick - if (rand(1,10) == 7) + // 25% chance to save the lockpick + if (rand2(1,4) == 2) getitem Lockpicks, 1; else dispbottom l("The lockpick broke."); @@ -92,8 +92,8 @@ function script LockPicking { } if (@pos >= .@d) { - // 10% chance to save the lockpick - if (rand(1,10) == 7) + // 20% chance to save the lockpick + if (rand2(1,5) == 3) getitem Lockpicks, 1; else dispbottom l("The lockpick broke."); diff --git a/npc/functions/main.txt b/npc/functions/main.txt index e1b93fa46..b54401e02 100644 --- a/npc/functions/main.txt +++ b/npc/functions/main.txt @@ -330,6 +330,13 @@ function script gf_accid { return .@value[0]; } +// Get some char id, even if offline +// ( Name ) +function script gf_charnameid { + .@nb = query_sql("SELECT char_id FROM `char` WHERE name='"+escape_sql(getarg(0))+"' LIMIT 2", .@value); + return .@value[0]; +} + // Get some char name from char ID, even if offline // ( Name ) function script gf_charname { diff --git a/npc/functions/politics.txt b/npc/functions/politics.txt new file mode 100644 index 000000000..b4ddde37d --- /dev/null +++ b/npc/functions/politics.txt @@ -0,0 +1,143 @@ +// TMW2 Script +// Author: +// Jesusalva +// Description: +// Central Town Political System Controller +// Note: The office is NOT Mayor, we have from kings to mayors here and you're +// not a citzen (yet). It'll be... I'll think in a name better than Minister. +// Perhaps, Town Administrator. +// NPCs: +// Tulim - +// Halin - +// Hurns - Airlia +// LoF - +// Nival - +// Frostia - +// Variables: +// $LOC_MAYOR$ - Stores the name of current Hurnscald Mayor +// $LOC_MONEY - Total money reserves of Hurnscald +// $LOC_TAX - How much in % is charged as taxes. (OnBuy income) +// $LOC_EXPORT - Defines how much Hurnscald exports (weekly income) +// $LOC_REPUTATION - Town reputation. Affects Max Tax and Weekly Income; +// Note: Tax cannot exceed 10% ie 1000. Reputation must be between 0 and 100. +// +// "Temporary Arrays": +// $LOC_CANDIDATE$ - Candidate for Office +// $LOC_VOTES - Number of votes of Candidate + +// Proccess Taxes from purchases +// PurchaseTaxes( Location ) +function script PurchaseTaxes { + .@tax=0; + for (.@i=0; .@i < getarraysize(@bought_nameid); .@i++) { + // Note: Some NPC might not + .@price=getiteminfo(@bought_nameid[.@i], ITEMINFO_BUYPRICE); + .@tax+=.@price*@bought_quantity[.@i]; + } + .@loc$=strtoupper(getarg(0, LOCATION$)); + .@vat=getd("$"+.@loc$+"_TAX"); + .@tax=.@tax*.@vat/10000; + if (.@tax) { + debugmes "%s paid %d in taxes to %s prefecture!", strcharinfo(0), .@tax, .@loc$; + setd("$"+.@loc$+"_TAX", .@vat+.@tax); + } + return; +} + +- script Politics NPC_HIDDEN,{ + +OnSun0000: + // Weekly income + $TULIM_MONEY+=$TULIM_EXPORT*limit(0, $TULIM_REPUTATION, 100)/100; + $HALIN_MONEY+=$HALIN_EXPORT*limit(0, $HALIN_REPUTATION, 100)/100; + $HURNS_MONEY+=$HURNS_EXPORT*limit(0, $HURNS_REPUTATION, 100)/100; + $LOF_MONEY+=$LOF_EXPORT*limit(0, $LOF_REPUTATION, 100)/100; + $NIVAL_MONEY+=$NIVAL_EXPORT*limit(0, $NIVAL_REPUTATION, 100)/100; + $FROSTIA_MONEY+=$FROSTIA_EXPORT*limit(0, $FROSTIA_REPUTATION, 100)/100; + + // Send salary to Town Administrators (20% from exports and 5GP/reputation) + .@tax=$TULIM_EXPORT*limit(0, $TULIM_REPUTATION, 100)/500; + .@tax+=$TULIM_REPUTATION*5; + .@tax=min($TULIM_MONEY, .@tax); + $TULIM_MONEY-=.@tax; + rodex_sendmail(gf_charnameid($TULIM_MAYOR$), "Tulimshar Townhall", "Term Income", "You've received the money for the term.", .@tax); + + .@tax=$HALIN_EXPORT*limit(0, $HALIN_REPUTATION, 100)/500; + .@tax+=$HALIN_REPUTATION*5; + .@tax=min($HALIN_MONEY, .@tax); + $HALIN_MONEY-=.@tax; + rodex_sendmail(gf_charnameid($HALIN_MAYOR$), "Halinarzo Townhall", "Term Income", "You've received the money for the term.", .@tax); + + .@tax=$HURNS_EXPORT*limit(0, $HURNS_REPUTATION, 100)/500; + .@tax+=$HURNS_REPUTATION*5; + .@tax=min($HURNS_MONEY, .@tax); + $HURNS_MONEY-=.@tax; + rodex_sendmail(gf_charnameid($HURNS_MAYOR$), "Hurnscald Townhall", "Term Income", "You've received the money for the term.", .@tax); + + .@tax=$LOF_EXPORT*limit(0, $LOF_REPUTATION, 100)/500; + .@tax+=$LOF_REPUTATION*5; + .@tax=min($LOF_MONEY, .@tax); + $LOF_MONEY-=.@tax; + rodex_sendmail(gf_charnameid($LOF_MAYOR$), "LoF Townhall", "Term Income", "You've received the money for the term.", .@tax); + + .@tax=$NIVAL_EXPORT*limit(0, $NIVAL_REPUTATION, 100)/500; + .@tax+=$NIVAL_REPUTATION*5; + .@tax=min($NIVAL_MONEY, .@tax); + $NIVAL_MONEY-=.@tax; + rodex_sendmail(gf_charnameid($NIVAL_MAYOR$), "Nivalis Townhall", "Term Income", "You've received the money for the term.", .@tax); + + .@tax=$FROSTIA_EXPORT*limit(0, $FROSTIA_REPUTATION, 100)/500; + .@tax+=$FROSTIA_REPUTATION*5; + .@tax=min($FROSTIA_MONEY, .@tax); + $FROSTIA_MONEY-=.@tax; + rodex_sendmail(gf_charnameid($FROSTIA_MAYOR$), "Frostia Townhall", "Term Income", "You've received the money for the term.", .@tax); + + // Conduct elections + .@w=array_highest($TULIM_VOTES); + if ($TULIM_CANDIDATE$[.@w] != "") + $TULIM_MAYOR$=$TULIM_CANDIDATE$[.@w]; + deletearray($TULIM_CANDIDATE$); + deletearray($TULIM_VOTES); + + .@w=array_highest($HALIN_VOTES); + if ($HALIN_CANDIDATE$[.@w] != "") + $HALIN_MAYOR$=$HALIN_CANDIDATE$[.@w]; + deletearray($HALIN_CANDIDATE$); + deletearray($HALIN_VOTES); + + .@w=array_highest($HURNS_VOTES); + if ($HURNS_CANDIDATE$[.@w] != "") + $HURNS_MAYOR$=$HURNS_CANDIDATE$[.@w]; + deletearray($HURNS_CANDIDATE$); + deletearray($HURNS_VOTES); + + .@w=array_highest($LOF_VOTES); + if ($LOF_CANDIDATE$[.@w] != "") + $LOF_MAYOR$=$LOF_CANDIDATE$[.@w]; + deletearray($LOF_CANDIDATE$); + deletearray($LOF_VOTES); + + .@w=array_highest($NIVAL_VOTES); + if ($NIVAL_CANDIDATE$[.@w] != "") + $NIVAL_MAYOR$=$NIVAL_CANDIDATE$[.@w]; + deletearray($NIVAL_CANDIDATE$); + deletearray($NIVAL_VOTES); + + .@w=array_highest($FROSTIA_VOTES); + if ($FROSTIA_CANDIDATE$[.@w] != "") + $FROSTIA_MAYOR$=$FROSTIA_CANDIDATE$[.@w]; + deletearray($FROSTIA_CANDIDATE$); + deletearray($FROSTIA_VOTES); + + // Notify new mayors of their victory + rodex_sendmail(gf_charnameid($TULIM_MAYOR$), "Tulimshar Townhall", "Election Victory", "You've been elected to the office!"); + rodex_sendmail(gf_charnameid($HALIN_MAYOR$), "Halinarzo Townhall", "Election Victory", "You've been elected to the office!"); + rodex_sendmail(gf_charnameid($HURNS_MAYOR$), "Hurnscald Townhall", "Election Victory", "You've been elected to the office!"); + rodex_sendmail(gf_charnameid($LOF_MAYOR$), "LoF Townhall", "Election Victory", "You've been elected to the office!"); + rodex_sendmail(gf_charnameid($NIVAL_MAYOR$), "Nivalis Townhall", "Election Victory", "You've been elected to the office!"); + rodex_sendmail(gf_charnameid($FROSTIA_MAYOR$), "Frostia Townhall", "Election Victory", "You've been elected to the office!"); + + end; + +} + diff --git a/npc/functions/refine.txt b/npc/functions/refine.txt index 1936b5542..48535f91d 100644 --- a/npc/functions/refine.txt +++ b/npc/functions/refine.txt @@ -24,6 +24,7 @@ function script refineMaster { l("Nothing, thanks"), 0, rif(getequipisequiped(EQI_HEAD_MID), l("My chestplate, @@", getequipname(EQI_HEAD_MID))), EQI_HEAD_MID, rif(getequipisequiped(EQI_HAND_R), l("My weapon, @@", getequipname(EQI_HAND_R))), EQI_HAND_R, + rif(getequipisequiped(EQI_HAND_L), l("My shield, @@", getequipname(EQI_HAND_L))), EQI_HAND_L, rif(getequipisequiped(EQI_HEAD_TOP), l("My helmet, @@", getequipname(EQI_HEAD_TOP))), EQI_HEAD_TOP, l("Item break? Too dangerous! I don't want it!!"), 0; @@ -53,7 +54,7 @@ function script refineMaster { // Not all items are refinable if (!getequipisenableref(.@it)) { mesn; - mesq l("Well, sorry, but only weapons and body armor can be refined."); + mesq l("Well, sorry, but only some items can be refined."); mesq l("There may be some exceptions. Anyway, this item clearly cannot be refined."); next; return; @@ -73,20 +74,21 @@ function script refineMaster { switch (.@rlv) { case 0: case 1: - .@rg=CopperIngot; break; case 2: case 3: - .@rg=IronIngot; break; + .@rg=Wurtizite; break; case 4: case 5: - .@rg=TitaniumIngot; break; case 6: case 7: - .@rg=LeadIngot; break; + .@amount=((.@rlv-4)/2)+1; + .@rg=Graphene; break; case 8: - .@rg=Bloodstone; break; + case 9: + case 10: default: - .@rg=BlueManaPearl; break; + .@amount=((.@rlv-8)/2)+1; + .@rg=Arcanum; break; } mesn; mesq l("This @@ is a nice stuff. I can refine it for @@ GP and @@ @@.", getitemlink(.@item), .@price, .@amount, getitemlink(.@rg)); @@ -151,8 +153,8 @@ function script refineMaster { mesc l("Weapons: +8 attack, +8 magic attack"); mesc l("Armors: +3~5 defense"); next; - // Perhaps the item has broken? - } else if (rand2(100) < .@rlv) { + // Perhaps the item has broken? (~0.01% chance) + } else if (rand2(10000) <= 1) { failedrefitem .@it; mesc l("*CRASH*"); next; @@ -162,7 +164,7 @@ function script refineMaster { mesn; mesq l("Well, you were warned. Do you have any other stuff for me?"); next; - // Item is weakened. + // Item is weakened. (1% per refine level) } else if (rand2(100) < .@rlv) { downrefitem .@it, 1; mesn; diff --git a/npc/functions/resetstatus.txt b/npc/functions/resetstatus.txt index c9744d901..e1d290499 100644 --- a/npc/functions/resetstatus.txt +++ b/npc/functions/resetstatus.txt @@ -5,6 +5,41 @@ // Description: // Status Reset NPC utils +// Reset status and return permanent bonuses +// StatusResetReinvest( - ) +function script StatusResetReinvest { + // Compulsory check + inventoryplace NPCEyes, 6; + + // Permanent boosts were now lost, return the fruits + if (STATUSUP_STR) { + getitem StrengthFruit, STATUSUP_STR; + STATUSUP_STR=0; + } + if (STATUSUP_AGI) { + getitem AgilityFruit, STATUSUP_AGI; + STATUSUP_AGI=0; + } + if (STATUSUP_VIT) { + getitem VitalityFruit, STATUSUP_VIT; + STATUSUP_VIT=0; + } + if (STATUSUP_INT) { + getitem IntelligenceFruit, STATUSUP_INT; + STATUSUP_INT=0; + } + if (STATUSUP_DEX) { + getitem DexterityFruit, STATUSUP_DEX; + STATUSUP_DEX=0; + } + if (STATUSUP_LUK) { + getitem LuckFruit, STATUSUP_LUK; + STATUSUP_LUK=0; + } + resetstatus(); + return true; +} + // Return wasSP on success, 0 on failure // ConfirmReset( {price} ) function script ConfirmStatusReset { @@ -16,6 +51,8 @@ function script ConfirmStatusReset { if (getarg(0,-1) >= 0) .@plush_count=getarg(0,-1); + mesc l("WARNING: Permanent boosts will return to their fruit form."), 1; + switch (select(lg("Yes, I am sure."), lg("I need to think about it..."), lg("I won't need it, thank you."))) @@ -38,16 +75,17 @@ function script ConfirmStatusReset { l("Thank you."), l("Now stand still... It should not take much time..."); - // Delete the GP and THEN reset the status - Zeny-=.@plush_count; + // Reset status have an inventorycheck, so we charge later. .@wasSP = StatusPoint; - resetstatus(); + StatusResetReinvest(); + + // Nothing to do: Do not charge (eg. you just got the fruits back) if (StatusPoint == .@wasSP) { speech S_LAST_NEXT, l("It seems that you have no status points to reset!"), - l("But the money you brought was really awesome you know."), l("Come back when you will really need me."); } else { + Zeny-=.@plush_count; speech S_LAST_NEXT, l("Let's see... @@ of your status points have just been reset!", StatusPoint - .@wasSP), l("Spend it wisely this time."), diff --git a/npc/functions/siege.txt b/npc/functions/siege.txt index e8f40b229..9be7a9e23 100644 --- a/npc/functions/siege.txt +++ b/npc/functions/siege.txt @@ -191,14 +191,18 @@ function script siege_check { .@mb+=mobcount(.@m$, "#SiegeCtrl::OnColonelDeath"); .@mb+=mobcount(.@m$, "#SiegeCtrl::OnGeneralDeath"); - // Players failed, so reduce score in 1~10 (like Sergeant~General). + // Players failed, so reduce score in 1~5 (like Sergeant~General). // In future, it could be inverse proportion (-9 for sergeant, -1 for general) if (.@mb) { if ($GAME_STORYLINE == 2) - $MK_TEMPVAR-=rand2(1, 10); + $MK_TEMPVAR-=rand2(1, 5); + kamibroadcast("Players failed to defend the city!!"); debugmes "Number of boss grade monsters found: %d", .@mb; $SIEGE_DIFFICULTY=max(1, ($SIEGE_DIFFICULTY/2)); + // Lower the town reputation in 10% + .@var$="$"+MapToLoc(.@m$)+"_REPUTATION"; + setd(.@var$, getd(.@var$)*9/10); } else { kamibroadcast("The city was defended with success! GG, everyone!"); $SIEGE_DIFFICULTY+=1; diff --git a/npc/functions/soul_menhir.txt b/npc/functions/soul_menhir.txt index 437e6d1e8..f44cc7b3b 100644 --- a/npc/functions/soul_menhir.txt +++ b/npc/functions/soul_menhir.txt @@ -102,6 +102,7 @@ L_Do_Save: savepoint @map$, @x, @y; specialeffect(4, SELF, getcharid(3)); } else { + EnterTown(MapToLoc(@map$)); dispbottom col(l("Your position is auto-saved when entering a town - use @ucp to change this behavior."), 1); } diff --git a/npc/functions/util.txt b/npc/functions/util.txt index 21abcd1f2..c32a831e1 100644 --- a/npc/functions/util.txt +++ b/npc/functions/util.txt @@ -743,10 +743,9 @@ function script anyloot { return Exception("Faulty anyloot skill command invoked - error"); // Get Items - for (.@i=0;.@i < getargcount(); .@i++) { + for (.@i=0;.@i < getargcount(); .@i+=3) { if (rand2(10000) < getarg(.@i+2)) getitem getarg(.@i), rand2(1, getarg(.@i+1)); - .@i++; } return true; } @@ -826,3 +825,19 @@ function script EnterTown { return; } +// Convert map name to location id +// MapToLoc( MapName ) +function script MapToLoc { + // Fill variable + .@v$=getarg(0); + + // Validade variable, see npc/000-1/exit.txt first + setarray .@mapx$, "005-1", "003-1", "009-1", "012-1", "017-1", "018-5", "020-1", "024-1"; + setarray .@locs$, "Candor", "Tulim", "Halin", "Hurns", "LoF", "Lilit", "Nival", "Frostia"; + .@lx=array_find(.@locs$, .@v$); + if (.@lx < 0) + return Exception("Invalid map passed to MapToLoc: "+.@v$, RB_DEBUGMES); + + return .@locs$[.@lx]; +} + diff --git a/npc/items/lofteleporter.txt b/npc/items/lofteleporter.txt index 8c895387b..008bb29e6 100644 --- a/npc/items/lofteleporter.txt +++ b/npc/items/lofteleporter.txt @@ -51,11 +51,11 @@ OnUse: select l("Don't warp"), - l("Land Of Fire Village (@@m)", 40-.@x), - l("Tulimshar (@@m)", 40-.@x), + l("Land Of Fire Village (@@m)", 35-.@x), + l("Tulimshar (@@m)", 35-.@x), rif(TELEPORTERS & TP_FROST, l("Frostia (@@m)", 120-.@x)), rif(TELEPORTERS & TP_HALIN, l("Halinarzo (@@m)", 120-.@x)), - rif(GSET_SOULMENHIR_MANUAL, l("Save Point (@@m)", 20-.@x)); + rif(GSET_SOULMENHIR_MANUAL, l("Save Point (@@m)", 30-.@x)); if (@menu == 1) close; @@ -70,13 +70,13 @@ OnUse: switch (@menu) { case 2: warp "017-1", 120, 89; - TELEPORTER_TIME=loftel_time(40, .@x); + TELEPORTER_TIME=loftel_time(35, .@x); LOCATION$="LoF"; @timer_navio_running=0; break; case 3: warp "003-1", 41, 49; - TELEPORTER_TIME=loftel_time(40, .@x); + TELEPORTER_TIME=loftel_time(35, .@x); LOCATION$="Tulim"; @timer_navio_running=0; break; @@ -94,7 +94,7 @@ OnUse: break; case 6: warp "Save", 0, 0; - TELEPORTER_TIME=loftel_time(20, .@x); + TELEPORTER_TIME=loftel_time(30, .@x); //LOCATION$="Save"; @timer_navio_running=0; break; diff --git a/npc/magic/cuteheart.txt b/npc/magic/cuteheart.txt index d273feb31..2030b03ff 100644 --- a/npc/magic/cuteheart.txt +++ b/npc/magic/cuteheart.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_CUTEHEART; - @mp=235; - @amp=45; + @mp=25; + @amp=4; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/dragokin.txt b/npc/magic/dragokin.txt index 2a8cb89b0..cfcc2ef44 100644 --- a/npc/magic/dragokin.txt +++ b/npc/magic/dragokin.txt @@ -25,8 +25,8 @@ OnCall: // Setup @sk=TMW2_DRAGOKIN; - @mp=500; - @amp=40; + @mp=50; + @amp=4; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/fairykingdom.txt b/npc/magic/fairykingdom.txt index 3490ab823..f8f177ccb 100644 --- a/npc/magic/fairykingdom.txt +++ b/npc/magic/fairykingdom.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_FAIRYKINGDOM; - @mp=400; - @amp=42; + @mp=40; + @amp=4; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/frozenheart.txt b/npc/magic/frozenheart.txt index 0eeec2194..1b59a53f5 100644 --- a/npc/magic/frozenheart.txt +++ b/npc/magic/frozenheart.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_FROZENHEART; - @mp=375; - @amp=55; + @mp=37; + @amp=5; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/halhiss.txt b/npc/magic/halhiss.txt index b86840cb8..e497d8826 100644 --- a/npc/magic/halhiss.txt +++ b/npc/magic/halhiss.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_HALHISS; - @mp=350; - @amp=60; + @mp=35; + @amp=6; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/kalboo.txt b/npc/magic/kalboo.txt index 6956cdc2a..17e2d64e6 100644 --- a/npc/magic/kalboo.txt +++ b/npc/magic/kalboo.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_KALBOO; - @mp=250; - @amp=55; + @mp=25; + @amp=5; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/kalmurk.txt b/npc/magic/kalmurk.txt index c9ceda89f..10ba98d7c 100644 --- a/npc/magic/kalmurk.txt +++ b/npc/magic/kalmurk.txt @@ -30,8 +30,8 @@ OnCall: // Setup @sk=TMW2_KALMURK; - @mp=200; - @amp=50; + @mp=40; + @amp=5; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/kalspike.txt b/npc/magic/kalspike.txt index f3d07c32c..14203821b 100644 --- a/npc/magic/kalspike.txt +++ b/npc/magic/kalspike.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_KALSPIKE; - @mp=250; - @amp=55; + @mp=25; + @amp=5; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/kalwulf.txt b/npc/magic/kalwulf.txt index 22b27d2d5..dc5b3e0f8 100644 --- a/npc/magic/kalwulf.txt +++ b/npc/magic/kalwulf.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_KALWURF; - @mp=450; - @amp=45; + @mp=45; + @amp=5; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/limerizer.txt b/npc/magic/limerizer.txt index a786d8eb9..cbf961387 100644 --- a/npc/magic/limerizer.txt +++ b/npc/magic/limerizer.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_LIMERIZER; - @mp=300; - @amp=30; + @mp=30; + @amp=3; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/plantkingdom.txt b/npc/magic/plantkingdom.txt index 2788f80de..2ee9e314e 100644 --- a/npc/magic/plantkingdom.txt +++ b/npc/magic/plantkingdom.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_PLANTKINGDOM; - @mp=300; - @amp=30; + @mp=30; + @amp=3; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/stoneheart.txt b/npc/magic/stoneheart.txt index c31f90f7d..38091a2f0 100644 --- a/npc/magic/stoneheart.txt +++ b/npc/magic/stoneheart.txt @@ -23,8 +23,8 @@ OnCall: // Setup @sk=TMW2_STONEHEART; - @mp=475; - @amp=55; + @mp=47; + @amp=5; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) diff --git a/npc/magic/transmigration.txt b/npc/magic/transmigration.txt index d04dc9e85..a1cb2a958 100644 --- a/npc/magic/transmigration.txt +++ b/npc/magic/transmigration.txt @@ -17,7 +17,7 @@ OnCall: } // Check requisites - if (!MagicCheck(TMW2_TRANSMIGRATION, 185, -5)) + if (!MagicCheck(TMW2_TRANSMIGRATION, 215, -5)) end; .@q=getq(General_Auldsbel); diff --git a/npc/magic/zarkor.txt b/npc/magic/zarkor.txt index 8fa29fe46..64d86d70c 100644 --- a/npc/magic/zarkor.txt +++ b/npc/magic/zarkor.txt @@ -32,8 +32,8 @@ OnCall: // Setup @sk=TMW2_ZARKOR; - @mp=400; - @amp=75; + @mp=40; + @amp=7; // Check if you have mana to cast // MagicCheck(SkillID, Mana{, MP per level}) @@ -48,7 +48,7 @@ OnCall: // set cooldown @zark_at=gettimetick(2); - @zark_at=@zark_at+20; + @zark_at=@zark_at+80; end; OnInit: diff --git a/npc/scripts.conf b/npc/scripts.conf index db4c0ca55..2e55710e7 100644 --- a/npc/scripts.conf +++ b/npc/scripts.conf @@ -56,6 +56,7 @@ "npc/functions/npcmovegraph.txt", "npc/functions/nurse.txt", "npc/functions/petsales.txt", +"npc/functions/politics.txt", "npc/functions/refine.txt", "npc/functions/resetstatus.txt", "npc/functions/riddle.txt", |