Spectators
Is there any chance to catch events from spectators (dead players)?
I would like to write a plugin that lets admins spectate all players, but non admins can only spectate teammates. I like to avoid tasks, and striktly use events. Is this possible? Are there any info sent to the server when spectators shift players or mode? Or is spectating commands client side only? Anyone plz help |
I don't think there is an event for when spectators hit their attack button. You'd have to do client_PreThink with get_user_button(id) & IN_ATTACK. It would still be sorta screwed though, then you'd have to spawn an ent above a player, and attach_view to that.
This has been tried before but no one was ever able to. What I put above is just throwing out random ideas, don't take it for writing in stone. |
Also, Any view function in AMXX seems to be broken, it will place or you view at the origin 0, 0, 0
|
If it is a client side only function... then info must be sent from server to client, is here a way to alter this info? I mean can it be done to change "mp_forcechasecam 1" to "mp_forcechasecam 0" in the serverinfo for just the admins?
..just a thought |
You may be able to catch right before some presses the attack button to switch view, and then do mp_forcechasecamera 1, then right when he's done pressing it, set it to 0. The only problem is, the engine might push him back to the mp_forcechasecamera 0 view after it's set, rather than waiting until he naturally moves out.
Another problem, catching +attack. It's a bit value, and the only way I know for sure you can catch it is get_user_button(id) & IN_ATTACK, which works after the player pressed the button. |
| All times are GMT -4. The time now is 00:04. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.