AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Code Snippets/Tutorials (https://forums.alliedmods.net/forumdisplay.php?f=83)
-   -   [INFO] Fakemeta & Ham detailed function descriptions and examples (https://forums.alliedmods.net/showthread.php?t=93229)

Arkshine 05-26-2009 18:36

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
Your example is wrong. There is not id nor origin for MSG_ALL/MSG_BROADCAST. You should add an example for all.

Starsailor 05-26-2009 20:21

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
oo yes, you are right, i have forgotten that

EDIT: Done

ConnorMcLeod 05-27-2009 01:34

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
Quote:

Originally Posted by arkshine (Post 835348)
Your example is wrong. There is not id nor origin for MSG_ALL/MSG_BROADCAST. You should add an example for all.

+ origins have to be floats.

Arkshine 05-27-2009 01:39

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
Quote:

Originally Posted by Starsailor (Post 835383)
oo yes, you are right, i have forgotten that

EDIT: Done

It's still wrong.


Code:
engfunc( EngFunc_MessageBegin, MSG_BROADCAST, SVC_TEMPENTITY ); engfunc( EngFunc_MessageBegin, MSG_ALL, SVC_TEMPENTITY ); engfunc( EngFunc_MessageBegin, MSG_ONE_UNRELIABLE, SVC_TEMPENTITY, _, id ); engfunc( EngFunc_MessageBegin, MSG_ONE, SVC_TEMPENTITY, _, id ); engfunc( EngFunc_MessageBegin, MSG_PVS, SVC_TEMPENTITY, origin, 0 ); engfunc( EngFunc_MessageBegin, MSG_PAS, SVC_TEMPENTITY, origin, 0 );

You should also comment more each MSG_*.

SchlumPF* 05-27-2009 01:44

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
EngFunc_Message_Beginuses floats, message_begin() doesnt.
if you explain such a function you should add an example when to use EngFunc_Message_Beginand when to use message_begin() because imo is EngFunc_Message_Beginkinda unnecesarry :X
also, you should explain MSG_INIT, PVS and PAS (with a short example ofc). at least because i never was able to find that out xD i mean MSG_ONE and MSG_ALL (+ the unreliable ones of them) are quite common but i guess there are a lot who never used MSG_INIT, MSG_PVS and MSG_PAS.
another thing is the origin, are there a few messages where you need it? i mean most messages need write_coord() to set the origin ^^

Arkshine 05-27-2009 02:10

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
EngFunc_MessageBegin is not unnecessary if you work with float and you use MSG_PVS/MSG_PAS. But it's true except that, message_begin() should be used.

Btw :

MSG_PVS = Potentially Visible Set = The message will be sent only to player who potentially view the provided origin.
MSG_PAS = Potentially Audible Set = The message will be sent only to player who potentially hear the sound from the provided origin.

It's useful to reduce data sent to a client.

MSG_PVS_R and MSG_PAS_R are not used. I think there is a thread about that.

Exolent[jNr] 05-27-2009 02:11

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
This is the most unorganized information tutorial I've ever seen.

Arkshine 05-27-2009 02:16

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
That's why it's better to use directly the wiki. :p

By the way, can you find for me a good page name so I can create it on the wiki, Exolent ? :p

xPaw 05-27-2009 04:08

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
Fakemeta functions and their descriptions :mrgreen:

hleV 05-27-2009 04:38

Re: [INFO] Fakemeta & Ham detailed function descriptions and examples
 
"arkshine's Wiki".


All times are GMT -4. The time now is 17:08.

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