C# Class UnityPlatformer.CharacterAnimator

Animator class Use all data available at Character & cia to know what to play
Inheritance: UnityEngine.MonoBehaviour, IUpdateEntity
Datei anzeigen Open project: llafuente/unity-platformer

Public Properties

Property Type Description
attackMelee string
character Character
crounchIdle string
crounchWalk string
fenceDown string
fenceIdle string
fenceLeft string
fenceRight string
fenceUp string
grabbing string
idle string
jump string
ladder string
maxSlope float
pulling string
pushing string
rope string
rotateOnSlopes bool
slipping string
swimming string
walk string
wallsliding string

Public Methods

Method Description
GetAnimationLength ( string animation ) : float

Get animation length in seconds

LatePlatformerUpdate ( float delta ) : void

do nothing

OnAreaChange ( Areas before, Areas after ) : void

Not used atm

OnDisable ( ) : void

sync UpdateManager

OnEnable ( ) : void

sync UpdateManager

OnInjuredCharacter ( Damage dt, CharacterHealth h, Character to ) : void

Not used atm

OnStateChange ( States before, States after ) : void

Not used atm

PlatformerUpdate ( float delta ) : void

Calculate what animation to play and do it!

Play ( string animation ) : void

Play animation NOTE this method should check that it's not currently playing the given animation, because each PlatformerUpdate you will recieve the same animation

PlaybackSpeed ( float speed ) : void

Set playback speed. 1: normal\n 0-1: slow-motion\n >1: fast-motion

Start ( ) : void

Start listening

StartPlayback ( ) : void

Continue playing current animation

StopPlayback ( ) : void

Stop current animation

Method Details

GetAnimationLength() public abstract method

Get animation length in seconds
public abstract GetAnimationLength ( string animation ) : float
animation string
return float

LatePlatformerUpdate() public method

do nothing
public LatePlatformerUpdate ( float delta ) : void
delta float
return void

OnAreaChange() public method

Not used atm
public OnAreaChange ( Areas before, Areas after ) : void
before Areas
after Areas
return void

OnDisable() public method

sync UpdateManager
public OnDisable ( ) : void
return void

OnEnable() public method

sync UpdateManager
public OnEnable ( ) : void
return void

OnInjuredCharacter() public method

Not used atm
public OnInjuredCharacter ( Damage dt, CharacterHealth h, Character to ) : void
dt Damage
h CharacterHealth
to Character
return void

OnStateChange() public method

Not used atm
public OnStateChange ( States before, States after ) : void
before States
after States
return void

PlatformerUpdate() public method

Calculate what animation to play and do it!
public PlatformerUpdate ( float delta ) : void
delta float
return void

Play() public abstract method

Play animation NOTE this method should check that it's not currently playing the given animation, because each PlatformerUpdate you will recieve the same animation
public abstract Play ( string animation ) : void
animation string
return void

PlaybackSpeed() public abstract method

Set playback speed. 1: normal\n 0-1: slow-motion\n >1: fast-motion
public abstract PlaybackSpeed ( float speed ) : void
speed float
return void

Start() public method

Start listening
public Start ( ) : void
return void

StartPlayback() public abstract method

Continue playing current animation
public abstract StartPlayback ( ) : void
return void

StopPlayback() public abstract method

Stop current animation
public abstract StopPlayback ( ) : void
return void

Property Details

attackMelee public_oe property

public string attackMelee
return string

character public_oe property

Character
public Character character
return Character

crounchIdle public_oe property

public string crounchIdle
return string

crounchWalk public_oe property

public string crounchWalk
return string

fenceDown public_oe property

public string fenceDown
return string

fenceIdle public_oe property

public string fenceIdle
return string

fenceLeft public_oe property

public string fenceLeft
return string

fenceRight public_oe property

public string fenceRight
return string

fenceUp public_oe property

public string fenceUp
return string

grabbing public_oe property

public string grabbing
return string

idle public_oe property

public string idle
return string

jump public_oe property

public string jump
return string

ladder public_oe property

public string ladder
return string

maxSlope public_oe property

Max rotation slope, above this value it will be 0ยบ
public float maxSlope
return float

pulling public_oe property

public string pulling
return string

pushing public_oe property

public string pushing
return string

rope public_oe property

public string rope
return string

rotateOnSlopes public_oe property

When a player is on a slope rotate the player the same angle?
public bool rotateOnSlopes
return bool

slipping public_oe property

public string slipping
return string

swimming public_oe property

public string swimming
return string

walk public_oe property

public string walk
return string

wallsliding public_oe property

public string wallsliding
return string