Hi.
I have a question regarding scripting in key bindings.
I wanted to:
-take a grenade,
-open the door,
-throw the grenade.
I had to add wait statements into it because everything went too fast and I got the grenade in between the nuts.
My problem is that ince the script is started by my key, I can do noting but wait 'till it finishes before moving or else.
Is it normal? Can this be avoided? Could I still be able to move while the script finishes?
Regards
Duke
defined script question
Moderator: Moderators
-
{R.E.D}**Duke Justice**
- Lance Corporal
- Posts: 23
- Joined: Thu Aug 07, 2003 9:09 pm
-
{R.E.D}**Duke Justice**
- Lance Corporal
- Posts: 23
- Joined: Thu Aug 07, 2003 9:09 pm
Ok,
alias hf1 "hud_fastswitch 1"
alias hf0 "hud_fastswitch 0"
bind t "hf1; useweaponclass grenade; wait 350; +use; wait 250; +attackprimary; hf0"
times are in milliseconds and are the minimal that I can put so this works on my PC. The total time of execution of this is about 1 second.
In this time, I can't move nor lean nor anything...
Any idea?
Best regards
Duke
alias hf1 "hud_fastswitch 1"
alias hf0 "hud_fastswitch 0"
bind t "hf1; useweaponclass grenade; wait 350; +use; wait 250; +attackprimary; hf0"
times are in milliseconds and are the minimal that I can put so this works on my PC. The total time of execution of this is about 1 second.
In this time, I can't move nor lean nor anything...
Any idea?
Best regards
Duke