onClientKill

From Liberty Unleashed Wiki
Jump to: navigation, search
Home   |   Squirrel Scripting   |   Server Functions   |   Server Events   |   Client Functions   |   Client Events

This event is called when the local player kills somebody else.

Syntax

  1. function onClientKill( player, weapon, bodypart )

Arguments

  • player - The pointer to the player that was killed
  • weapon - The weapon used
  • bodypart - The bodypart that was hit

Returns

This event does not handle return values.

Example

This example outputs a message whenever you kill another player.

  1.  
  2. function onClientKill( player, weapon, bodypart )
  3. {
  4. // Output who you killed
  5. Message( "* You just killed " + player.Name + "!", 255, 0, 0 );
  6. return 1;
  7. }
  8.  

Notes

-- List of used functions and other notes here.

Related Events

Personal tools
Namespaces

Variants
Actions
Navigation
scripting
Toolbox