summaryrefslogtreecommitdiff
path: root/src/prenderer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/prenderer.cpp')
-rw-r--r--src/prenderer.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/prenderer.cpp b/src/prenderer.cpp
index 37fb113..53025b2 100644
--- a/src/prenderer.cpp
+++ b/src/prenderer.cpp
@@ -67,24 +67,23 @@ Transform_ApplyInteractive(interact_transform Interact, real32 *OutputX, real32
{
v2 BoxLength = Interact.Max - Interact.Min;
v2 Center = Interact.Max - (BoxLength/2);
- if (Interact.RadianOffset != 0.0f && Interact.Radians != 0.0f) {
+ if (Interact.RadianOffset != 0.0f) {
v2 LocalCenter = Interact.NewCenter;
real32 Rad = Interact.RadianOffset;
real32 Point0X = Center.x - Interact.OGCenter.x;
real32 Point0Y = Center.y - Interact.OGCenter.y;
- v2 XAxis = (Point0X * Interact.Scale)*V2(cos(Rad), sin(Rad));
- v2 YAxis = (Point0Y * Interact.Scale)*V2(sin(Rad), -cos(Rad));
+ v2 XAxis = (Point0X * 1.0f)*V2(cos(Rad), sin(Rad));
+ v2 YAxis = (Point0Y * 1.0f)*V2(sin(Rad), -cos(Rad));
Center = Interact.OGCenter + XAxis + YAxis;
}
-
real32 Point0X = Center.x - *OutputX;
real32 Point0Y = Center.y - *OutputY;
real32 Rad = Interact.Radians;
real32 Rotation = Rad / (PI / 180);
- v2 XAxis = (Point0X * Interact.Scale)*V2(cos(Rad), sin(Rad));
+ v2 XAxis = (Point0X * Interact.Scale)*V2(cos(Rad), sin(Rad));
v2 YAxis = (Point0Y * -Interact.Scale)*V2(sin(Rad), -cos(Rad));
real32 X0 = -XAxis.x - YAxis.x + Center.x;