diff options
author | Jesusaves <cpntb1@ymail.com> | 2024-05-04 19:00:38 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2024-05-04 19:00:38 -0300 |
commit | 08f0fe566e7a5d3aedfaaac17c5523b2dc890deb (patch) | |
tree | 24c855b71073995374a1d09bceff1cd264e73299 /npc/craft/options.txt | |
parent | 5c39c8f3f49105a1e330a63a9e72d1df62e77526 (diff) | |
download | serverdata-08f0fe566e7a5d3aedfaaac17c5523b2dc890deb.tar.gz serverdata-08f0fe566e7a5d3aedfaaac17c5523b2dc890deb.tar.bz2 serverdata-08f0fe566e7a5d3aedfaaac17c5523b2dc890deb.tar.xz serverdata-08f0fe566e7a5d3aedfaaac17c5523b2dc890deb.zip |
[DESIGN] Limit how far the options level can go depending on how much game needs.
If the game global storyline requires low power, do not allow high power.
This avoids it from getting broken OP levels when game is not designed for that.
Diffstat (limited to 'npc/craft/options.txt')
-rw-r--r-- | npc/craft/options.txt | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/npc/craft/options.txt b/npc/craft/options.txt index f8948b614..ce0658617 100644 --- a/npc/craft/options.txt +++ b/npc/craft/options.txt @@ -1112,9 +1112,17 @@ function script csysGUI_RaiseOpt { .@sk=getarg(0); .@pc=csysGUI_OptPrice(.@sk); .@lv=getd("CRAFTSYS["+.@sk+"]"); + // Check the current skill cap + if ($GAME_STORYLINE >= 5) + .@mx = CRAFT_MAXLV1; + else if ($GAME_STORYLINE >= 4) + .@mx = CRAFT_MAXLV2; + else + .@mx = CRAFT_MAXLV3; + // Check if you can upgrade the skill if (csysGUI_OptReq(.@sk)) { - if (.@lv > CRAFT_MAXLV) { - mesc l("You cannot raise crafting skills beyond level @@!", CRAFT_MAXLV), 1; + if (.@lv > .@mx) { + mesc l("You cannot raise crafting skills beyond level @@!", .@mx), 1; return false; } if (Mobpt >= .@pc) { |