DIsableing buttons Created 19 years ago2005-07-19 17:18:53 UTC by Ichthyosaur Ichthyosaur

Created 19 years ago2005-07-19 17:18:53 UTC by Ichthyosaur Ichthyosaur

Posted 19 years ago2005-07-19 17:18:53 UTC Post #122136
Disabling buttons

Hey there guys I have what may seem like an idiotic question but here gose.
I have been working a lot with long and complicated button sequences, what I mean is when you press a button the button will do something for example:

?OnDamage / sound / playsound? at time 0.00

Then after that it will do the next thing on list:

?OnDamage / sound2 / playsound? at time 5.00

Anyhow the sequence I am doing takes over a minute to complete and if it is interrupted, it begins to do it over again before it?s done and messes things up really badly. What I have been trying to do is make the button unusable for the duration of the sequence, so it can?t be messed up. Ideally I would like the button to be pressed (or shot) and if it is pressed again it will have no affect. I have tried to have a separate button to lock the first one but it doesn?t work, and there are no enable/disable options on it. Anyone know how to do this without the help of a multisouce (because hl2 doesn?t have em)?
Thanks
Posted 19 years ago2005-07-19 21:43:18 UTC Post #122161
Ok, in properties, there is a thing called "Delay Before Reset" Change that to the proper number of seconds (till sequence is done) and then it will be unactive till that ammount of time is up
Posted 19 years ago2005-07-20 06:46:11 UTC Post #122220
Well Thank you for that man, but I've still been having some problems.

Seems the "Delay Before Reset" thing is for the movment of the button. now my button didn't move but just to test it I changes it so it would and made the delay longer then the sequence in the hopes that the button would be disabled while it moved. But sadly that was not the case and it was interupted. for the moment I have come up with a way to cover the button with a funk_door rotating, like one of thse fancy ones from the movies... you know, the ones that blow up stuff....

Anyhow that has solved it for the moment yet I still do not have a way of stopping the use of the button while another button is in use. Like if button A rotates a door one way and button B moves the door the other way and 2 people push them at the same time... well it causes a mess. Anyway thanks for your help, I always feel bad asking questions and answering so few but i guess when some one asks this one again I'll Have the answer. Thanks again! :)
Posted 19 years ago2005-07-20 06:51:04 UTC Post #122221
Hey, don't worry about it, just answer stuff where you can :).
Seventh-Monkey Seventh-MonkeyPretty nifty
Posted 19 years ago2005-07-20 12:21:40 UTC Post #122307
Use a fire input form a ambient_gen on a logic_timer and then on fire- timer- start. Then "on timer"- ambient_gen-play noise. This might not be entirely accurate but its the basic idea that is pretty much down to common sense.
You must be logged in to post a response.