AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   message_ questions (https://forums.alliedmods.net/showthread.php?t=84930)

toader_octavian 02-03-2009 04:14

message_ questions
 
PHP Code:

#define MSG_INIT 3 //Write to the init string
#define MSG_PVS 4 //Ents in PVS of origin
#define MSG_PAS 5 //Ents in PAS of origin
#define MSG_PVS_R 6 //Reliable to PVS
#define MSG_PAS_R 7 //Reliable to PAS 

What do these do?

Arkshine 02-03-2009 04:57

Re: message_ questions
 
MSG_PVS ( Potentially Visible Set ) and MSG_PAS ( Potentially Audible Set ) is use for filtering network messages to the client. ( From the eye position ).

I.e ; if you send TE_EXPLOSION with MSG_PVS, it means the message will be sent only to clients who are potentially visible from the provided origin. MSG_PAS means it will be sent only to clients who potentially hear the sound from the provided origin. So, It should be used when we can.

MSG_INIT I don't know. MSG_PVS_R and MSG_PAS_R are the reliable version ofr MSG_PVS and MSG_PAS but actually not used ( at least HLSDK doesn't mention about it ) because it should be never reliable since they change from frame to frame. So MSG_PVS and MSG_PAS are fine.

jim_yang 02-03-2009 05:09

Re: message_ questions
 
I saw a use of MSG_INIT when sending WeaponList msg

Arkshine 02-03-2009 05:15

Re: message_ questions
 
Yep, you're right. WeaponList is fired on map start with MSG_INIT and for all weapons.


All times are GMT -4. The time now is 01:52.

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