fix(boxes): correctly load textured boxes' textures
This commit is contained in:
parent
c53e91a564
commit
eb751807f4
1 changed files with 4 additions and 4 deletions
|
@ -27,14 +27,14 @@ local Box3D = require(cwd .. "parent")
|
|||
local TexturedBox = Box3D:extend()
|
||||
|
||||
function TexturedBox:new(owner, w, h, d, topTexture, bottomTexture)
|
||||
TexturedBox.super.new(self, owner, w, h, d)
|
||||
|
||||
local bottomTexture = bottomTexture or topTexture
|
||||
|
||||
self.topTexture = self.assets.texture[topTexture]
|
||||
self.bottomTexture = self.assets.texture[bottomTexture]
|
||||
self.topTexture = owner.assets.images[topTexture]
|
||||
self.bottomTexture = owner.assets.images[bottomTexture]
|
||||
|
||||
self.haveLine = false
|
||||
|
||||
TexturedBox.super.new(self, owner, w, h, d)
|
||||
end
|
||||
|
||||
function TexturedBox:drawTopTexture()
|
||||
|
|
Loading…
Reference in a new issue