Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


AddTransition

Utility function to add an outgoing transition.
Read time 1 minuteLast updated 12 days ago

Definition

AddTransition(AnimatorStateTransition)

Utility function to add an outgoing transition.
public void AddTransition(AnimatorStateTransition transition)

Parameters

The transition to add.

Remarks

This function pushes an Undo operation.

AddTransition(AnimatorState)

Utility function to add an outgoing transition to the destination state.
public AnimatorStateTransition AddTransition(AnimatorState destinationState)

Parameters

destinationState

The destination state.

Returns

Remarks

The transition asset that is created is added as a sub asset of the state. This function pushes an Undo operation.

AddTransition(AnimatorStateMachine)

Utility function to add an outgoing transition to the destination state machine.
public AnimatorStateTransition AddTransition(AnimatorStateMachine destinationStateMachine)

Parameters

destinationStateMachine

The destination state machine.

Returns

Remarks

The transition asset that is created is added as a sub asset of the state. This function pushes an Undo operation.

AddTransition(AnimatorState, bool)

Utility function to add an outgoing transition to the destination state.
public AnimatorStateTransition AddTransition(AnimatorState destinationState, bool defaultExitTime)

Parameters

destinationState

The destination state.

defaultExitTime

If true, the exit time will be the equivalent of 0.25 second.

Returns

Remarks

The transition asset that is created is added as a sub asset of the state. This function pushes an Undo operation.

AddTransition(AnimatorStateMachine, bool)

Utility function to add an outgoing transition to the destination state machine.
public AnimatorStateTransition AddTransition(AnimatorStateMachine destinationStateMachine, bool defaultExitTime)

Parameters

destinationStateMachine

The destination state machine.

defaultExitTime

If true, the exit time will be the equivalent of 0.25 second.

Returns

Remarks

The transition asset that is created is added as a sub asset of the state. This function pushes an Undo operation.