Scenario transitions
Categoryanimations
Rows1,305
Notes from the author
These are commands for transitioning from one conditional anim to another within some scenario.
Citizen.CreateThread(function()
while true do
Citizen.Wait(0)
if Citizen.InvokeNative(0x91AEF906BCA88877,0, 0x17BEC168) then -- pressed E
-- TASK_START_SCENARIO_IN_PLACE_HASH with conditional anim WORLD_PLAYER_MOONSHINE_CUSTOMER_SOBER_MALE_A. Works for male player peds:
Citizen.InvokeNative(0x524B54361229154F, PlayerPedId(), GetHashKey("WORLD_PLAYER_MOONSHINE_CUSTOMER"), 0, 1, GetHashKey("WORLD_PLAYER_MOONSHINE_CUSTOMER_SOBER_MALE_A"), -1.0, 0)
end
if Citizen.InvokeNative(0x91AEF906BCA88877,0, 0x956C2A0E) then -- pressed R
local ped_command_hash=GetHashKey("ORDER_DRINK")
local ped_command_hash_activation_duration=5.0 -- 5 seconds
-- _ACTIVATE_PED_COMMAND_HASH (as result, ped plays animation for ORDER_DRINK while ped command hash is active)
Citizen.InvokeNative(0xD65FDC686A031C83, PlayerPedId(), ped_command_hash, ped_command_hash_activation_duration)
-- _FORCE_SCENARIO_TRANSITION:
Citizen.InvokeNative(0x6D07B371E9439019, PlayerPedId() )
end
end
end)
local ped_commands = {
{ConditionalAnimTransition, ped_command_hash, FromConditionalAnims, TransitionToConditionalAnimsList,},
}| # | transition | ped_command | from | to | Note |
|---|---|---|---|---|---|
| 1301 | WORLD_PLAYER_MP_STEW_POT_DONATION_MALE__TRANS | STEWPOT_ACTION | WORLD_PLAYER_MP_STEW_POT_DONATION_MALE | WORLD_PLAYER_MP_STEW_POT_DONATION_MALE | |
| 1302 | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR__TRANS__CRAFTING_ARTHUR | TRANS_USE_ITEM | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR | WORLD_PLAYER_SLEEP_BEDROLL_CRAFTING_ARTHUR | |
| 1303 | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR__TRANS__PROP_PLAYER_SLEEP_TENT_MALE_A | RESTING_TRANS_SLEEP_W_HAT | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR | PROP_PLAYER_SLEEP_TENT_MALE_A | |
| 1304 | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR__TRANS__PROP_PLAYER_SLEEP_TENT_MALE_A_V2 | RESTING_TRANS_SLEEP_W_HAT | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR | PROP_PLAYER_SLEEP_TENT_MALE_A | |
| 1305 | WORLD_PLAYER_SLEEP_BEDROLL_CRAFTING_ARTHUR__TRANS__ARTHUR | TRANS_STOP_USE_ITEM | WORLD_PLAYER_SLEEP_BEDROLL_CRAFTING_ARTHUR | WORLD_PLAYER_SLEEP_BEDROLL_ARTHUR |