summaryrefslogtreecommitdiff
path: root/npc/functions
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2020-04-24 14:12:08 -0300
committerJesusaves <cpntb1@ymail.com>2020-04-24 14:12:08 -0300
commit20014a0c0c595aebe906229a6aabd2c283157763 (patch)
treeadc7dbafd9c6f4f1574fccbd5c97b10e614524b5 /npc/functions
parent030c193444568be32f9d5317566216c710973da0 (diff)
downloadserverdata-20014a0c0c595aebe906229a6aabd2c283157763.tar.gz
serverdata-20014a0c0c595aebe906229a6aabd2c283157763.tar.bz2
serverdata-20014a0c0c595aebe906229a6aabd2c283157763.tar.xz
serverdata-20014a0c0c595aebe906229a6aabd2c283157763.zip
Allow LockPicking minigame to be called without thief skill check.
This will be useful for Kamelot
Diffstat (limited to 'npc/functions')
-rw-r--r--npc/functions/lockpicks.txt5
1 files changed, 3 insertions, 2 deletions
diff --git a/npc/functions/lockpicks.txt b/npc/functions/lockpicks.txt
index 33ee1ea4f..390a01588 100644
--- a/npc/functions/lockpicks.txt
+++ b/npc/functions/lockpicks.txt
@@ -10,7 +10,7 @@
// THIEF_RANK
// Position on the Thief Tree
-// LockPicking(num_pins, max_pins)
+// LockPicking(num_pins, max_pins, min_rank=num_pins)
// Returns 0 upon failure, 1 upon success
// Closes script if an error happen or if you give up / cannot try.
//
@@ -27,13 +27,14 @@ function script LockPicking {
.@d=getarg(0,1);
.@m=getarg(1,3);
+ .@minrank=getarg(2, .@d);
// Invalid Argument (kill script)
if (.@d < 1 || .@m < 2 || .@m > 5)
end;
// You must be rank (number of locks - 1) to try
- if (THIEF_RANK+1 < .@d) {
+ if (THIEF_RANK+1 < .@minrank) {
mesc l("This lock is beyond your current capacity."), 1;
close;
}