diff options
author | Jesusaves <cpntb1@ymail.com> | 2019-07-24 23:01:47 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2019-07-24 23:01:47 -0300 |
commit | c76f1f5e34e644f68519677532bed8b751462a80 (patch) | |
tree | 912d712a521fdf4396b9ef3f4c59a2f08f478504 | |
parent | f737474e4dba902effe21b50efc43fe744bcfb24 (diff) | |
parent | aea3099eb95f7cac7a97b34c9b19ad2006007abf (diff) | |
download | serverdata-c76f1f5e34e644f68519677532bed8b751462a80.tar.gz serverdata-c76f1f5e34e644f68519677532bed8b751462a80.tar.bz2 serverdata-c76f1f5e34e644f68519677532bed8b751462a80.tar.xz serverdata-c76f1f5e34e644f68519677532bed8b751462a80.zip |
Merge branch 'master' into testserver
-rw-r--r-- | db/re/item_db.conf | 23 | ||||
-rw-r--r-- | npc/003-1-1/yetiking.txt | 1 | ||||
-rw-r--r-- | npc/003-1/eugene.txt | 8 | ||||
-rw-r--r-- | npc/003-1/wateranimation.txt | 27 | ||||
-rw-r--r-- | npc/003-2/lua.txt | 2 | ||||
-rw-r--r-- | npc/functions/fishing.txt | 60 |
6 files changed, 88 insertions, 33 deletions
diff --git a/db/re/item_db.conf b/db/re/item_db.conf index cc0c5b935..0df6a5510 100644 --- a/db/re/item_db.conf +++ b/db/re/item_db.conf @@ -5423,6 +5423,17 @@ item_db: ( Weight: 40 Refine: false }, +{ + Id: 890 + AegisName: "SmallFishingNet" + Name: "Small Fishing Net" + Type: "IT_ETC" + Buy: 5000 + Sell: 150 + Weight: 60 + Refine: false + ViewSprite: 890 +}, // <!-- ID 900~910 Reserved --> { Id: 911 @@ -13144,6 +13155,7 @@ item_db: ( Weight: 158 Atk: 0 Matk: 140 + Range: 8 Loc: "EQP_HAND_R" WeaponLv: 1 EquipLv: 20 @@ -13166,6 +13178,7 @@ item_db: ( } ViewSprite: 7000 Script: <" + bonus bAttack2,-100; bonus bMaxSP,10; bonus bSPrecovRate,20; "> @@ -13180,6 +13193,7 @@ item_db: ( Weight: 158 Atk: 0 Matk: 280 + Range: 8 Loc: "EQP_HAND_R" WeaponLv: 1 EquipLv: 40 @@ -13202,6 +13216,7 @@ item_db: ( } ViewSprite: 7001 Script: <" + bonus bAttack2,-150; bonus bMaxSP,20; bonus bSPrecovRate,20; "> @@ -13216,6 +13231,7 @@ item_db: ( Weight: 158 Atk: 0 Matk: 420 + Range: 8 Loc: "EQP_HAND_R" WeaponLv: 1 EquipLv: 60 @@ -13238,6 +13254,7 @@ item_db: ( } ViewSprite: 7002 Script: <" + bonus bAttack2,-200; bonus bMaxSP,30; bonus bSPrecovRate,20; "> @@ -13252,6 +13269,7 @@ item_db: ( Weight: 158 Atk: 0 Matk: 576 + Range: 8 Loc: "EQP_HAND_R" WeaponLv: 1 EquipLv: 80 @@ -13274,6 +13292,7 @@ item_db: ( } ViewSprite: 7003 Script: <" + bonus bAttack2,-250; bonus bMaxSP,40; bonus bSPrecovRate,20; "> @@ -13288,6 +13307,7 @@ item_db: ( Weight: 158 Atk: 0 Matk: 740 + Range: 8 Loc: "EQP_HAND_R" WeaponLv: 1 EquipLv: 100 @@ -13310,6 +13330,7 @@ item_db: ( } ViewSprite: 7004 Script: <" + bonus bAttack2,-300; bonus bMaxSP,50; bonus bSPrecovRate,20; "> @@ -13324,6 +13345,7 @@ item_db: ( Weight: 158 Atk: 0 Matk: 370 + Range: 9 Loc: "EQP_HAND_R" WeaponLv: 1 EquipLv: 50 @@ -13346,6 +13368,7 @@ item_db: ( } ViewSprite: 7005 Script: <" + bonus bAttack2,-125; bonus bMaxSP,25; bonus bSPrecovRate,20; "> diff --git a/npc/003-1-1/yetiking.txt b/npc/003-1-1/yetiking.txt index c298fd47b..e6f311217 100644 --- a/npc/003-1-1/yetiking.txt +++ b/npc/003-1-1/yetiking.txt @@ -15,6 +15,7 @@ if (.@q > 1 && .@q < 99) setq HurnscaldQuest_Celestia, 1; if (.@q == 1 && !.inUse) goto L_Summon; + if (!.@q) dispbottom l("I do not know how to trigger this summoning circle."); end; L_Summon: diff --git a/npc/003-1/eugene.txt b/npc/003-1/eugene.txt index e1aad9187..c7bb3c580 100644 --- a/npc/003-1/eugene.txt +++ b/npc/003-1/eugene.txt @@ -98,6 +98,7 @@ OnInit: .BaitCount = 10; tradertype(NST_MARKET); + sellitem SmallFishingNet, -1, 1; sellitem FishBox, -1, 5; sellitem CommonCarp, -1, 3; sellitem GrassCarp, -1, 1; @@ -110,9 +111,10 @@ OnClock0611: OnClock1200: OnClock1801: OnClock0003: - restoreshopitem FishBox, -1, 5; - restoreshopitem CommonCarp, -1, 3; - restoreshopitem GrassCarp, -1, 1; + restoreshopitem SmallFishingNet, 1; + restoreshopitem FishBox, 5; + restoreshopitem CommonCarp, 3; + restoreshopitem GrassCarp, 1; end; } diff --git a/npc/003-1/wateranimation.txt b/npc/003-1/wateranimation.txt index f99753da9..c1cecbe09 100644 --- a/npc/003-1/wateranimation.txt +++ b/npc/003-1/wateranimation.txt @@ -32,3 +32,30 @@ OnInit: 003-1,83,140,0 duplicate(#water_animation0) #water_animation13 NPC_WATER_SPLASH 003-1,72,147,0 duplicate(#water_animation0) #water_animation14 NPC_WATER_SPLASH 003-1,72,122,0 duplicate(#water_animation0) #water_animation15 NPC_WATER_SPLASH + + +003-1,71,58,0 script #lowsea_tulim0 NPC_WATER_SPLASH,{ + + fishing; // begin or continue fishing + close; + +OnInit: + .sex = G_OTHER; + .distance = 4; + .rod=SmallFishingNet; + .net_ratio=3; + .catch_time=8000; // You have 3 more seconds to pull here + .wait_time_min=8000; + .wait_time_max=21000; + .pull_rand_max=1600; + .regen_time=30; + end; +} + +003-1,95,47,0 duplicate(#lowsea_tulim0) #lowsea_tulim1 NPC_WATER_SPLASH +003-1,121,48,0 duplicate(#lowsea_tulim0) #lowsea_tulim2 NPC_WATER_SPLASH +003-1,121,36,0 duplicate(#lowsea_tulim0) #lowsea_tulim3 NPC_WATER_SPLASH +003-1,32,107,0 duplicate(#lowsea_tulim0) #lowsea_tulim4 NPC_WATER_SPLASH +003-1,25,78,0 duplicate(#lowsea_tulim0) #lowsea_tulim5 NPC_WATER_SPLASH +003-1,16,50,0 duplicate(#lowsea_tulim0) #lowsea_tulim6 NPC_WATER_SPLASH + diff --git a/npc/003-2/lua.txt b/npc/003-2/lua.txt index a4ef87f1e..627960f17 100644 --- a/npc/003-2/lua.txt +++ b/npc/003-2/lua.txt @@ -236,7 +236,7 @@ L_Task: mes l("There are some sailors near the forge. Think outside the box - or rather, inside it, unless you have a fortune to buy the items."); mes ""; } - if (CRAFTQUEST || MPQUEST) { + if (!(CRAFTQUEST || MPQUEST)) { mes lg("To register as a craftswoman, you need to talk to Intense Beard in Terranite Forge. The forge is in the Bazar.", "To register as a craftsman, you need to talk to Intense Beard in Terranite Forge. The forge is in the Bazar."); mes l("To register as a hunter, talk to Aidan, also in the marketplace - the Bazar."); mesc l("You can, and @@, register on both programs, but only one is required for this quest.", b("SHOULD")); diff --git a/npc/functions/fishing.txt b/npc/functions/fishing.txt index 57df44956..0e6a8c62e 100644 --- a/npc/functions/fishing.txt +++ b/npc/functions/fishing.txt @@ -89,6 +89,9 @@ function script fishing { .@rod = getvariableofnpc(.fishing_rod, .@npc$); // the fishing rod required for this spot .@rod = (.@rod ? .@rod : FishingRod); + .@net_ratio = getvariableofnpc(.net_ratio, .@npc$); // How many fishes and baits are required? + .@net_ratio = min(1, (.@net_ratio ? .@net_ratio : 1)); + .@regen_time = getvariableofnpc(.cooldown, .@npc$); // cooldown for the fishing spot .@regen_time = (.@regen_time ? .@regen_time : 20); @@ -204,34 +207,32 @@ function script fishing { return -4; } - // RNG to obtain a rare fish or common fish - // Luck can increase up to 5% when it is at 100. - // Level can increase up to 10% when it is at 100. - .@boost=(readparam(bLuk)/20)+(BaseLevel/10); - if (rand2(0, 100) < getvariableofnpc(.bait_ids[@bait_d+1], .@npc$)+.@boost) - { - //debugmes("[FISH] Got a rare with %d drop chances", getarraysize(.@rare_fish)); - .@fish_id = any_of(.@rare_fish); - } else { - //debugmes("[FISH] Got a common with %d drop chances", getarraysize(.@common_fish)); - .@fish_id = any_of(.@common_fish); - } // RNG to obtain a fish - if (rand(gettimetick(0) - @fishing_tick) <= .@pull_rand_max) + if (rand2(gettimetick(0) - @fishing_tick) <= .@pull_rand_max) { - specialeffect(.@success_fx, SELF, playerattached()); // event success - getexp getvariableofnpc(.bait_ids[@bait_d+1], .@npc$)+(BaseLevel/10), 0; // xp gain is equivalent to bait rarity + BaseLevel boost - - if(!checkweight(.@fish_id, 1)) - { - dispbottom l("You caught a @@ but had no room in your inventory to carry it.", getitemlink(.@fish_id)); - makeitem .@fish_id, 1, .@mapbis$, .@xbis, .@ybis; // drop on the ground - return 0; + for (.@i=0 ; .@i < .@net_ratio ; .@i++) { + // RNG to obtain a rare fish or common fish + // Luck can increase up to 5% when it is at 100. + // Level can increase up to 10% when it is at 100. + .@boost=(readparam(bLuk)/20)+(BaseLevel/10); + if (rand2(0, 100) < getvariableofnpc(.bait_ids[@bait_d+1], .@npc$)+.@boost) + { + .@fish_id = any_of(.@rare_fish); + } else { + .@fish_id = any_of(.@common_fish); + } + specialeffect(.@success_fx, SELF, playerattached()); + getexp getvariableofnpc(.bait_ids[@bait_d+1], .@npc$)+(BaseLevel/10), 0; // xp gain is equivalent to bait rarity + BaseLevel boost + + if(!checkweight(.@fish_id, 1)) + { + dispbottom l("You caught a @@ but had no room in your inventory to carry it.", getitemlink(.@fish_id)); + makeitem .@fish_id, 1, .@mapbis$, .@xbis, .@ybis; // drop on the ground + return 0; + } + getitem .@fish_id, 1; } - - //dispbottom l("You caught a @@!", getitemlink(.@fish_id)); <= already shows "you picked up [...]" - getitem .@fish_id, 1; } else { @@ -255,21 +256,22 @@ function script fishing { // begin fishing narrator S_LAST_NEXT, l("You see some fish reflecting the sun on the surface of the water."), - l("What will be the bait for the fish?"); + (.@net_ratio == 1 ? l("What will be the bait for the fish?") : l("You need @@ units of bait for this fishing spot. What will you use?", .@net_ratio)); mes "##B" + l("Drag and drop an item from your inventory.") + "##b"; .@bait = requestitem(); .@bait_c = false; - if (.@bait < 1) { + if (.@bait < .@net_ratio) { narrator S_FIRST_BLANK_LINE, - l("You take your fishing rod and leave."); + l("You take your @@ and leave.", getitemlink(.@rod)); return -6; } - if (countitem(.@bait) < 1) { + if (countitem(.@bait) < .@net_ratio) { + mesc l("You do not have enough bait for fishing here."); return -6; } @@ -303,7 +305,7 @@ function script fishing { set getvariableofnpc(.char_id, .@npc$), getcharid(CHAR_ID_CHAR); // record char id set getvariableofnpc(.last_used, .@npc$), gettimetick(2); getmapxy(@fishing_loc$[0], @fishing_loc[0], @fishing_loc[1], 0); // record char pos - delitem .@bait, 1; + delitem .@bait, .@net_ratio; // The player uses this spot, his bait is ready, he just has to wait for the signal. closedialog; |