ItsMods

Full Version: Code Not Working - Restriction by time
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey guys,
I tried to do a code to restrict the time when the player can open the quickmenu to choose a class.
I will put here the code: http://pastebin.com/HqS33Y37

The problem is that the "canOpenMenu" is not working properly. I want to control the time at which the player can open the "QuickMenu" to change classes, and at first he keep his class every time he dies another function separately. He can choose to open the submenu by pressing the "usebutton."
I do not know how to monitor when they have been respawned 5 seconds after the variable "self.pers [" menuallow "]" is not put in false so I can open the QuickMenu at any time without restriction, or if you shot or melee .

I hope someone can help me.
A greeting and thank you very much.



Did a new code of the canOpenMenu()
http://pastebin.com/nEtXTKy6
way i do it is...




on player spawned
variable = yes;
self thread domenu();


domenu();
wait 12;
variable = no;



so basically 12 seconds after a player fully loads into the game, the menu is removed.. until next spawn / round that is.


read what you pasted, it hurt my brain.. and even i write some really retarded shit.
(08-02-2011, 23:12)koil Wrote: [ -> ]way i do it is...




on player spawned
variable = yes;
self thread domenu();


domenu();
wait 12;
variable = no;



so basically 12 seconds after a player fully loads into the game, the menu is removed.. until next spawn / round that is.


read what you pasted, it hurt my brain.. and even i write some really retarded shit.
I think im going to make an easy menu, quickmenu is giving me several problems to control everything. Does someone knows what's src_disable_cac for?

src_disable_cac disables custom class selection or enables it pending on 0 or 1