forked from MineClone5/MineClone5
Fix boat initialization failure
This commit is contained in:
parent
f204470052
commit
663c2bedbb
|
@ -166,12 +166,14 @@ function boat.on_activate(self, staticdata, dtime_s)
|
||||||
self._last_v = self._v
|
self._last_v = self._v
|
||||||
self._itemstring = data.itemstring
|
self._itemstring = data.itemstring
|
||||||
|
|
||||||
|
if data.textures then
|
||||||
while #data.textures < 5 do
|
while #data.textures < 5 do
|
||||||
table.insert(data.textures, data.textures[1])
|
table.insert(data.textures, data.textures[1])
|
||||||
end
|
end
|
||||||
|
|
||||||
self.object:set_properties({textures = data.textures})
|
self.object:set_properties({textures = data.textures})
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function boat.get_staticdata(self)
|
function boat.get_staticdata(self)
|
||||||
|
|
Loading…
Reference in New Issue