mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-15 13:04:05 +09:00
fixed a bug where world thumbnail is not centered to the player
This commit is contained in:
@@ -53,11 +53,11 @@ object WriteSavegame {
|
||||
val w = 960
|
||||
val h = 640
|
||||
|
||||
val cx = (1 - WorldCamera.x % 2)
|
||||
val cy = (1 - WorldCamera.y % 2)
|
||||
val cx = /*1-*/(WorldCamera.x % 2)
|
||||
val cy = /*1-*/(WorldCamera.y % 2)
|
||||
|
||||
val x = (fb.width - w) - cx // force the even-numbered position
|
||||
val y = (fb.height - h) - cy // force the even-numbered position
|
||||
val x = (fb.width - w) / 2 - cx // force the even-numbered position
|
||||
val y = (fb.height - h) / 2 - cy // force the even-numbered position
|
||||
|
||||
val p = Pixmap.createFromFrameBuffer(x, y, w, h)
|
||||
IngameRenderer.fboRGBexport = p
|
||||
|
||||
Reference in New Issue
Block a user