layer.states.switchInstant(name)
Switch to a new state without animating.
译:切换到一个新的状态没有动画。
Arguments(参数)
name — A string, the title of the state. 译:一个字符串,该状态的标题。
layerA = new Layer
layerA.states.add
stateA:
x: 500
opacity: 0.5
layerA.states.switchInstant("stateA")