From 27a9c1683ae37f8e84414ed29e750aaa583c353f Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Mon, 9 Sep 2019 13:04:54 -0300 Subject: Tweaks to new function sshake --- npc/functions/shake.txt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'npc/functions') diff --git a/npc/functions/shake.txt b/npc/functions/shake.txt index e3e5268c6..2c3c58a55 100644 --- a/npc/functions/shake.txt +++ b/npc/functions/shake.txt @@ -4,13 +4,16 @@ // Usage: // set @max_shake then call OnShake -// sshake( {max_shake} ) +// sshake( {max_shake=6,10}, {closedialog=true} ) function script sshake { @max_shake=abs(getarg(0, rand2(6,10))); for (.@s=0; .@s < @max_shake; .@s++) { movecam rand(-20,20), rand(-20,20); sleep2(50); } + restorecam; + if (getarg(1,false)) + closedialog; return; } -- cgit v1.2.3-60-g2f50