OnClientTrailerDetach: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
 
(Added interwiki (ES))
 
(5 intermediate revisions by 4 users not shown)
Line 1: Line 1:
[[Category:Incomplete Event]]
{{Client event}}
__NOTOC__
This event is triggered when a trailer gets detached from its towing vehicle.


__NOTOC__
==Parameters==
This event is blahblah and is used for blahblah.
<syntaxhighlight lang="lua">
vehicle towedBy
</syntaxhighlight>
*'''towedBy:''' the vehicle that was towing the trailer.


==Syntax==  
==Source==
<syntaxhighlight lang="lua">
The source of this event is the trailer that is now detached.
void onClientTrailerDetach ( vehicle towedBy )
</syntaxhighlight>


==Example==  
==Example==  
This example does...
This example outputs to the player that's towing the trailer that "The vehicle is now detached". (TESTED!)
<syntaxhighlight lang="lua">
<syntaxhighlight lang="lua">addEventHandler("onClientTrailerDetach",root,function(towedBy)
--This line does...
player = getVehicleOccupant(towedBy,0)
blabhalbalhb --abababa
outputChatBox("The vehicle is now detached.",player)
--This line does this...
end)</syntaxhighlight>
mooo
 
</syntaxhighlight>
==See Also==
===Client vehicle events===
{{Client_vehicle_events}}
===Client event functions===
{{Client_event_functions}}
[[es:onClientTrailerDetach]]

Latest revision as of 00:41, 14 May 2012

This event is triggered when a trailer gets detached from its towing vehicle.

Parameters

vehicle towedBy
  • towedBy: the vehicle that was towing the trailer.

Source

The source of this event is the trailer that is now detached.

Example

This example outputs to the player that's towing the trailer that "The vehicle is now detached". (TESTED!)

addEventHandler("onClientTrailerDetach",root,function(towedBy)
	player = getVehicleOccupant(towedBy,0)
	outputChatBox("The vehicle is now detached.",player)
end)

See Also

Client vehicle events


Client event functions