modules/world: handle differently the coordinate system for 2D actors
This commit is contained in:
parent
b754501102
commit
0fba67f212
1 changed files with 2 additions and 2 deletions
|
@ -187,8 +187,8 @@ end
|
||||||
|
|
||||||
function Actor2D:drawSprite(x, y, r, sx, sy, ox, oy, kx, ky)
|
function Actor2D:drawSprite(x, y, r, sx, sy, ox, oy, kx, ky)
|
||||||
if (self.sprite.name ~= nil) then
|
if (self.sprite.name ~= nil) then
|
||||||
local ox = oy or self.sprite.ox
|
local x = x + self.sprite.ox
|
||||||
local oy = oy or self.sprite.oy
|
local y = y + self.sprite.oy
|
||||||
local sx = sx or self.sprite.sx
|
local sx = sx or self.sprite.sx
|
||||||
local sy = sy or self.sprite.sy
|
local sy = sy or self.sprite.sy
|
||||||
self.assets.sprites[self.sprite.name]:drawAnimation(x, y, r, sx, sy, ox, oy, kx, ky)
|
self.assets.sprites[self.sprite.name]:drawAnimation(x, y, r, sx, sy, ox, oy, kx, ky)
|
||||||
|
|
Loading…
Reference in a new issue