{"hash":"0x79197F7D2BB5E73A","ns":"TASK","name":"_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM","slug":"_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM","official":false,"named":true,"luaName":"TransitionScenarioToConditionalAnim","game":"rdr3","apiset":"client","returnType":"BOOL","params":[{"name":"ped","type":"Ped"},{"name":"scenarioPoint","type":"int"},{"name":"clipsetDict","type":"const char*"},{"name":"clipName","type":"const char*"},{"name":"fromConditionalAnim","type":"const char*"},{"name":"flags","type":"int"}],"summary":"Requests an authored transition for a ped that is currently using a scenario point, switching into a specific conditional/clipset branch defined for that scenario.","descriptions":[{"source":"alloc8or","format":"text","body":"Requests an authored transition for a ped that is currently using a scenario point, switching into a specific conditional/clipset branch defined for that scenario.\n\nMeta / authoring:\n- This mirrors entries in \"script_common_ca.meta\" where a transition links a <FromConditionalAnims> key to a target <ClipSet> (clipsetDict + clipName).\n- fromConditionalAnim should match the <FromConditionalAnims> name for the transition (some scripts pass 0 when they don’t care / use the default authored path).\n\nNotes:\n- Scripts commonly call PED::_ADD_SCENARIO_TRANSITION(ped) immediately before this native.\n- Return value only indicates the transition request was accepted/triggered; scripts often verify the ped is still using the scenario point afterward (PED::IS_PED_USING_THIS_SCENARIO).\n\nC++ style usage (from scripts):\n- PED::_ADD_SCENARIO_TRANSITION(ped);\n- if (TASK::_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM(ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, 0)) {\n    if (PED::IS_PED_USING_THIS_SCENARIO(ped, scenarioPoint)) {\n      // transition took; continue state machine\n    }\n  }\n\nExample video: https://imgur.com/a/ReSsWNj"},{"source":"vorp","format":"text","body":"Smoothly transitions an active scenario actor (ped) into a specific conditional / clipset defined in the scenario's conditional-anim graph, breaking or restarting the scenario.\nReturns `true` if the transition was successfully triggered, or `false` if it failed"}],"examples":[],"aliases":[],"enums":[],"related":[],"build":"1207","sources":["alloc8or","vorp"],"doc":2,"url":"https://natives.borderlinerp.com/natives/TASK/_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM","markdownUrl":"https://natives.borderlinerp.com/natives/TASK/_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM.md","snippets":{"lua":"local retval = TransitionScenarioToConditionalAnim(ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags)","luaInvoke":"local retval = Citizen.InvokeNative(0x79197F7D2BB5E73A, ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags, Citizen.ReturnResultAnyway())","js":"const retval = TransitionScenarioToConditionalAnim(ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags);","jsInvoke":"const retval = Citizen.invokeNative('0x79197F7D2BB5E73A', ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags, Citizen.returnResultAnyway());","csharp":"bool retval = Function.Call<bool>((Hash)0x79197F7D2BB5E73A, ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags);","notes":["The name is a community guess and may change. If the named call is missing in your client build, use `InvokeNative` with the hash — it always works."]}}