Implement transform update for static judge anchor.
This commit is contained in:
@@ -93,7 +93,6 @@ namespace Cryville.Crtr {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public override void Update(ContainerState s, StampedEvent ev) {
|
public override void Update(ContainerState s, StampedEvent ev) {
|
||||||
base.Update(s, ev);
|
|
||||||
if (s.CloneType <= 2) {
|
if (s.CloneType <= 2) {
|
||||||
Position = GetFramePoint(s.Parent, s.Track);
|
Position = GetFramePoint(s.Parent, s.Track);
|
||||||
Rotation = GetFrameRotation(s.Parent, s.Track);
|
Rotation = GetFrameRotation(s.Parent, s.Track);
|
||||||
@@ -113,6 +112,19 @@ namespace Cryville.Crtr {
|
|||||||
ChartPlayer.etor.ContextEvent = null;
|
ChartPlayer.etor.ContextEvent = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (s.CloneType == 2 && ev != null && ev.Unstamped is Chart.Judge) {
|
||||||
|
var anchor = judges[(Chart.Judge)ev.Unstamped].StaticAnchor;
|
||||||
|
#if UNITY_5_6_OR_NEWER
|
||||||
|
anchor.Transform.SetPositionAndRotation(Position, Rotation);
|
||||||
|
#else
|
||||||
|
anchor.Transform.position = Position;
|
||||||
|
anchor.Transform.rotation = Rotation;
|
||||||
|
#endif
|
||||||
|
OpenAnchor(anchor);
|
||||||
|
base.Update(s, ev);
|
||||||
|
CloseAnchor();
|
||||||
|
}
|
||||||
|
else base.Update(s, ev);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void EndGraphicalUpdate(ContainerState s) {
|
public override void EndGraphicalUpdate(ContainerState s) {
|
||||||
|
|||||||
Reference in New Issue
Block a user