Raised This Month: $ Target: $400
 0% 

OnPlayerRunCmd tip


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
exvel
SourceMod Donor
Join Date: Jun 2006
Location: Russia
Old 01-06-2010 , 02:27   Re: OnPlayerRunCmd tip
Reply With Quote #1

Quote:
Originally Posted by CrimsonGT View Post
PreThink occurs prior to any action being sent to the client. Using OnPlayerRunCmd is too late as the client has already started predicting the action, and while it wont actually happen they see it start. For example, if you block attack they will see the gun fire but it wont actually fire on the server.
Yeap, I know that. But anyway, PreThink fires before OnPlayerRunCmd in the same frame, right? So it doesn't matter for client which of them fired the first because AFAIK client starts prediction without server permission. So changing buttons in PreThink does the same effect as in OnPlayerRunCmd. But OnPlayerRunCmd is built in the core and can be used without extension.
Or PreThink can actually block predictable buttons without lag for client? If this is true I can't imagine how prediction system works.
__________________
For admins: My plugins

For developers: Colors library

Last edited by exvel; 01-06-2010 at 03:37.
exvel is offline
Send a message via ICQ to exvel
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:15.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode