HolyLib Wiki

IGameEvent

IGameEvent

This class directly represents the IGameEvent object in c++

Metatable function Description
__tostring Returns a formated string of the IGameEvent -> IGameEvent [eventName]
__index Used to find the functions on the metatable and access saved variables
__newindex Used to allow one to save variables on the object
__gc Internally deletes the IGameEvent turning it invalid

Methods

boolean IGameEvent:GetBool( string key, boolean fallback )
Returns the boolean stored in the specific key.
number IGameEvent:GetFloat( string key, number fallback )
Returns the float stored in the specific key.
number IGameEvent:GetInt( string key, number fallback )
Returns the integer stored in the specific key.
string IGameEvent:GetName( )
Returns the gameevent(player_connect and such) of this IGameEvent.
string IGameEvent:GetString( string key, string fallback )
Returns the string stored in the specific key.
table IGameEvent:GetTable( )
Returns the lua table used by newindex and index
boolean IGameEvent:IsEmpty( )
Returns whether this IGameEvent is empty.
boolean IGameEvent:IsLocal( )
Returns whether this IGameEvent is local / serverside only.
If this returns true this event won't be networked when broadcasted.
boolean IGameEvent:IsReliable( )
Returns whether this IGameEvent is reliable.
boolean IGameEvent:IsValid( )
Returns whether this IGameEvent is valid.
IGameEvent:SetBool( string key, boolean value )
Stores the boolean with the specific key.
IGameEvent:SetFloat( string key, number value )
Stores the float with the specific key.
IGameEvent:SetInt( string key, number value )
Stores the integer with the specific key.
IGameEvent:SetString( string key, string value )
Stores the string with the specific key.