mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2025-01-20 07:20:49 +00:00
Visual Mode: fixed a problem where scaled sprites were shown with the wrong offset
This commit is contained in:
parent
63010d871a
commit
59197fdfe0
1 changed files with 2 additions and 2 deletions
|
@ -328,8 +328,8 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
// Determine sprite size and offset
|
||||
float radius = sprite.ScaledWidth * 0.5f;
|
||||
float height = sprite.ScaledHeight;
|
||||
offsets.x = radius - (sprite.OffsetX == int.MinValue ? 0 : sprite.OffsetX);
|
||||
offsets.y = (sprite.OffsetY == int.MinValue ? 0 : sprite.OffsetY) - height;
|
||||
offsets.x = radius - (sprite.OffsetX == int.MinValue ? 0 : sprite.OffsetX) * sprite.Scale.x;
|
||||
offsets.y = (sprite.OffsetY == int.MinValue ? 0 : sprite.OffsetY) * sprite.Scale.y - height;
|
||||
|
||||
// Scale by thing type/actor scale
|
||||
// We do this after the offset x/y determination above, because that is entirely in sprite pixels space
|
||||
|
|
Loading…
Reference in a new issue