G.SendUserMessage

From GMod Wiki

Revision as of 17:52, 17 July 2011 by TheFreeman193 (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Function
Syntax SendUserMessage( String message_name,CRecipientFilter :Player entity [, ...] )
Where is this used?
Description:
Convenience function for sending a list of values to clients using a User Message
Returns: nil
Part of Library: Global Functions
Realm: NewerServer.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=G.SendUserMessage]G.SendUserMessage [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Example

DescriptionThose two functions perform the same task.
Used onNewerServer.png
Code
function SendData1(ply)
	umsg.Start("my_message", ply)
		umsg.String("hai")
		umsg.Long(1337)
	umsg.End()
end
 
function SendData2(ply)
	SendUserMessage("my_message", ply, "hai", 1337)
end
OutputN/A


Additional Notes

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox