_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM
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.
0x79197F7D2BB5E73ATransitionScenarioToConditionalAnimSignature
BOOL _TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM(Ped ped, int scenarioPoint, const char* clipsetDict, const char* clipName, const char* fromConditionalAnim, int flags);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
scenarioPoint | int | — |
clipsetDict | const char* | — |
clipName | const char* | — |
fromConditionalAnim | const char* | — |
flags | int | — |
Returns BOOL
Description
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.
Meta / authoring:
- This mirrors entries in "script_common_ca.meta" where a transition links a <FromConditionalAnims> key to a target <ClipSet> (clipsetDict + clipName).
- fromConditionalAnim should match the <FromConditionalAnims> name for the transition (some scripts pass 0 when they don’t care / use the default authored path).
Notes:
- Scripts commonly call PED::_ADD_SCENARIO_TRANSITION(ped) immediately before this native.
- 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).
C++ style usage (from scripts):
- PED::_ADD_SCENARIO_TRANSITION(ped);
- if (TASK::_TRANSITION_SCENARIO_TO_CONDITIONAL_ANIM(ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, 0)) {
if (PED::IS_PED_USING_THIS_SCENARIO(ped, scenarioPoint)) {
// transition took; continue state machine
}
}Example video: https://imgur.com/a/ReSsWNj
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.
Returns true if the transition was successfully triggered, or false if it failed
Usage
local retval = TransitionScenarioToConditionalAnim(ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags)
-- always works, by hash
local retval = Citizen.InvokeNative(0x79197F7D2BB5E73A, ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags, Citizen.ReturnResultAnyway())JavaScript and C#
const retval = TransitionScenarioToConditionalAnim(ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags);
// by hash
const retval = Citizen.invokeNative('0x79197F7D2BB5E73A', ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags, Citizen.returnResultAnyway());bool retval = Function.Call<bool>((Hash)0x79197F7D2BB5E73A, ped, scenarioPoint, clipsetDict, clipName, fromConditionalAnim, flags);- The name is a community guess and may change. If the named call is missing in your client build, use
InvokeNativewith the hash — it always works.
Sources
alloc8or RDR3 NativeDB · VORPCORE RDR3natives
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.