Skip to content

OnCartHorsesTired

A cart’s horses ran out of stamina - they walk until they have caught their breath.

Runs once each time the team’s stamina (GetCartStamina) reaches 0 on a cart a player drives. The team then walks, whatever the driver asks, until its stamina is back to 30; a walk or a stop brings it back (2 a second). How fast it runs dry is the cart’s weight against its horses’ pull and SetCartStaminaRate.

function OnCartHorsesTired(id)
-- ...
end
Parameter Type
id number the cart

nothing

function OnCartHorsesTired(id)
local driver = GetCartSeatPlayer(id, 0)
if driver then GameText(driver, "The horses are spent. Let them walk.", 4000) end
end

GetCartStamina · SetCartStaminaRate · GetCartPull · the Carts group of the index