Client Scripting Events: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
This is a list of client-side scripting events that currently exist. More will come soon.
This is a list of client-side scripting events that currently exist. More will come soon.


===Client Events===
==Colshape events==
void [[onClientResourceStart]] ( [[resource]] resource )
*[[onClientColShapeHit]]
*[[onClientColShapeLeave]]
*[[onClientElementColShapeHit]]
*[[onClientElementColShapeLeave]]


void [[onClientResourceStop]] ( [[resource]] resource )
==Element events==
*[[onClientElementDataChange]]


void [[onClientElementDataChange]] ( string name )
==GUI events==
*[[onClientGUIClick]]
*[[onClientGUIDoubleClick]]
*[[onClientGUIChanged]]
*[[onClientGUIAccepted]]
*[[onClientConsole]]
*[[onClientClick]]
*[[onClientDoubleClick]]
*[[onClientMouseMove]]
*[[onClientCursorMove]]
*[[onClientGUIMove]]
*[[onClientGUISize]]


void [[onClientPlayerJoin]] ( void )
==Player events==
*[[onClientPlayerJoin]]
*[[onClientPlayerQuit]]
*[[onClientPlayerWeaponFire]]
*[[onClientPlayerWeaponSwitch]]
*[[onClientPlayerTarget]]
*[[onClientPlayerDamage]]
*[[onClientPlayerSpawn]]
*[[onClientPlayerWasted]]
*[[onClientPlayerVehicleEnter]]
*[[onClientPlayerVehicleExit]]
*[[onClientPlayerChangeNick]]
*[[onClientPlayerTask]]
*[[onClientPlayerStuntStart]]
*[[onClientPlayerStuntFinish]]


void [[onClientPlayerQuit]] ( string reason )
==Resource events==
*[[onClientResourceStart]]
*[[onClientResourceStop]]


void [[onClientPlayerWeaponFire]] ( int weapon, int ammo, int ammoInClip, float hitX, float hitY, float hitZ, [[element]] hitElement )
==Vehicle events==
*[[onClientVehicleRespawn]]
*[[onClientVehicleEnter]]
*[[onClientVehicleExit]]
*[[onClientVehicleStartEnter]]
*[[onClientVehicleStartExit]]
*[[onClientTrailerAttach]]
*[[onClientTrailerDetach]]


void [[onClientPlayerWeaponSwitch]] ( int previous, int current )
==Other events==
 
*[[onClientRender]]
void [[onClientPlayerTarget]] ( [[element]] target )
 
void [[onClientPlayerDamage]] ( [[element]] attacker, int weapon, int bodypart )
 
void [[onClientPlayerSpawn]] ( [[team]] hisTeam )
 
void [[onClientPlayerWasted]] ( [[element]] attacker, int weapon, int bodypart )
 
void [[onClientPlayerVehicleEnter]] ( [[vehicle]] theVehicle, int seat )
 
void [[onClientPlayerVehicleExit]] ( [[vehicle]] theVehicle, int seat )
 
void [[onClientPlayerChangeNick]] ( string oldNick )
 
void [[onClientPlayerTask]] ( string priority, int type, string name )
 
void [[onClientPlayerStuntStart]] ( string type )
 
void [[onClientPlayerStuntFinish]] ( string type, int time_ms, float distance )
 
void [[onClientVehicleRespawn]] ( void )
 
void [[onClientVehicleEnter]] ( [[player]] thePlayer, int seat )
 
void [[onClientVehicleExit]] ( [[player]] thePlayer, int seat )
 
void [[onClientVehicleStartEnter]] ( [[player]] thePlayer, int seat )
 
void [[onClientVehicleStartExit]] ( [[player]] thePlayer, int seat )
 
void [[onClientTrailerAttach]] ( [[vehicle]] towedBy )
 
void [[onClientTrailerDetach]] ( [[vehicle]] towedBy )
 
void [[onClientGUIClick]] ( string button, string state, int absoluteX, int absoluteY )
 
void [[onClientGUIDoubleClick]] ( string button, string state, int absoluteX, int absoluteY )
 
void [[onClientGUIChanged]] ( [[element]] theElement )
 
void [[onClientGUIAccepted]] ( [[element]] theElement )
 
void [[onClientConsole]] ( text )
 
void [[onClientRender]] ( )
 
void [[onClientClick]] ( string button, string state, int absoluteX, int absoluteY, float worldX, float worldY, float worldZ, [[element]] clicked )
 
void [[onClientDoubleClick]] ( string button, string state, float cursorX, float cursorY, float worldX, float worldY, float worldZ, [[element]] clicked )
 
void [[onClientMouseMove]] ( int absoluteX, int absoluteY )
 
void [[onClientCursorMove]] ( float cursorX, float cursorY, int absoluteX, int absoluteY, float worldX, float worldY, float worldZ )
 
void [[onClientGUIMove]] ()
 
void [[onClientGUISize]] ()
 
void [[onClientColShapeHit]] ( [[entity]] theEntity, bool matchingDimension )
 
void [[onClientColShapeLeave]] ( [[entity]] theEntity, bool matchingDimension )
 
void [[onClientElementColShapeHit]] ( [[colshape]] theShape, bool matchingDimension )
 
void [[onClientElementColShapeLeave]] ( [[colshape]] theShape, bool matchingDimension )

Revision as of 17:39, 30 December 2007