| 16 | namespace TEN::Animation |
| 17 | { |
| 18 | void MoveOriginCommand::Execute(ItemInfo& item, bool isFrameBased) const |
| 19 | { |
| 20 | if (isFrameBased) |
| 21 | return; |
| 22 | |
| 23 | item.Pose.Translate(item.Pose.Orientation.y, _relOffset.z, _relOffset.y, _relOffset.x); |
| 24 | |
| 25 | if (item.IsLara()) |
| 26 | { |
| 27 | // NOTE: GameBoundingBox constructor always clamps to last frame to avoid errors. |
| 28 | auto bounds = GameBoundingBox(&item); |
| 29 | UpdateLaraRoom(&item, -bounds.GetHeight() / 2, -_relOffset.x, -_relOffset.z); |
| 30 | } |
| 31 | else |
| 32 | { |
| 33 | UpdateItemRoom(item.Index); |
| 34 | } |
| 35 | } |
| 36 | |
| 37 | void JumpVelocityCommand::Execute(ItemInfo& item, bool isFrameBased) const |
| 38 | { |
no test coverage detected