Blockland Forums > Modification Help

While left button is held down

Pages: (1/1)

halcynthis:

I could use this. What is the script for, while your holding the left mouse button, it will do something? Thanks for anyone that helps, or even trys to help. It is highly appreciated.

lilboarder32:


--- Quote from: halcynthis on August 15, 2010, 02:51:06 PM ---I could use this. What is the script for, while your holding the left mouse button, it will do something? Thanks for anyone that helps, or even trys to help. It is highly appreciated.

--- End quote ---
Armor::onTrigger(%this, %obj, %slot, %val)

Where %val is a boolean where 1 is held down and 0 is released.
%obj is obviously the obj performing the action
%slot is what they are "triggering". I'm not sure what all of them are, but 4 is right click and 2 is crouching I'm pretty sure.
Package that function and check if %slot == 1 or 3 (not sure which one is left click) and check if %val == 1 and then start a loop until it's called again with %val equating to 0.

Also, not sure if this is default, but there is a Player variable called fire. You can check if(%player.fire)

otto-san:

hi hal

basically do what lil said

it should work

Pages: (1/1)

Go to full version