detect start defusing c4 stopped defusing c4
how can i detect a person "stopped defusing c4"(let go of E and defusion process terminated)
|
Re: detect start defusing c4 stopped defusing c4
Actually I don't know.
With amxx 1.8 which coming soon you may able to use ' cs_[g|s]et_c4_defusing(). ' EDIT : I've found this VEN's tuto : http://forums.alliedmods.net/showthread.php?t=40164 I don't know if it can help you. EDIT2 : You may able to use player data : Quote:
|
Re: detect start defusing c4 stopped defusing c4
Bomb defusion (without kit) started event
register_logevent("logevent_function_p", 3, "2=Begin_Bomb_Defuse_Without_Kit") // Bomb defusion (with kit) started event register_logevent("logevent_function_p", 3, "2=Begin_Bomb_Defuse_With_Kit") // Bomb planting/defusion canceled event register_event("BarTime", "event_function", "b", "1=0") // you must be sure that bomb planting/defusion is in progress! i need these events, how would i detect the person stopped defusing with "BarTime"? Note: there are other plugins in game that uses BarTime! |
Re: detect start defusing c4 stopped defusing c4
Upon defuse start BarTime is fired with the time (in seconds) it takes to "arm" the bomb. When done (break or arming sequence finished) the event is fired with "0". The BarTime event offers no info about the success of the action. You must use the logevent to check if it was successfull.
BarTime is however inaccurate as other plugins use this event to "delay" other actions. Bomb plant usually takes 5 seconds. If this event is "shared" then the other plugins musn't use the 5 sec flag in their actions. Thus all you have to do is check the time fired with the event as a delay of "5" would always mean a bomb planting. Still if you have doubts about it then is better you don't use this event. |
Re: detect start defusing c4 stopped defusing c4
how do i grab the id out of the bartime event?
|
Re: detect start defusing c4 stopped defusing c4
register_event("BarTime", "BarTime_EventHandler", "be")
// // ... // public BarTime_EventHandler(id) { // ... } |
Re: detect start defusing c4 stopped defusing c4
the (id) would do? i though i needed to read data or something
thx |
Re: detect start defusing c4 stopped defusing c4
i just used public bomb_defusing ( defuser ){ and bartime event
bartime event somehow is called 2 times and also on bomb drop |
| All times are GMT -4. The time now is 07:59. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.