Add AacAnimatorNode.At()
This commit is contained in:
@@ -30,6 +30,12 @@ namespace AnimatorAsCode.V1
|
|||||||
public TNode Over() => MoveNextTo(null, 0, -1);
|
public TNode Over() => MoveNextTo(null, 0, -1);
|
||||||
public TNode Under() => MoveNextTo(null, 0, 1);
|
public TNode Under() => MoveNextTo(null, 0, 1);
|
||||||
|
|
||||||
|
public TNode At(int x, int y)
|
||||||
|
{
|
||||||
|
SetPosition(new Vector3(x * DefaultsProvider.Grid().x, y * DefaultsProvider.Grid().y, 0));
|
||||||
|
return (TNode) this;
|
||||||
|
}
|
||||||
|
|
||||||
public TNode Shift(AacAnimatorNode otherState, int shiftX, int shiftY) => MoveNextTo(otherState, shiftX, shiftY);
|
public TNode Shift(AacAnimatorNode otherState, int shiftX, int shiftY) => MoveNextTo(otherState, shiftX, shiftY);
|
||||||
|
|
||||||
private TNode MoveNextTo(AacAnimatorNode otherStateOrSecondToLastWhenNull, int x, int y)
|
private TNode MoveNextTo(AacAnimatorNode otherStateOrSecondToLastWhenNull, int x, int y)
|
||||||
|
|||||||
Reference in New Issue
Block a user