examples/plateformer : make the character clone its sprite
This commit is contained in:
parent
8d655f8049
commit
8445dd2e84
1 changed files with 1 additions and 0 deletions
|
@ -4,6 +4,7 @@ local Player = Base:extend()
|
||||||
function Player:new(world, x, y, id)
|
function Player:new(world, x, y, id)
|
||||||
Player.super.new(self, world, "player", x, y, 16, 24, true)
|
Player.super.new(self, world, "player", x, y, 16, 24, true)
|
||||||
self:setSprite("player", 8, 12)
|
self:setSprite("player", 8, 12)
|
||||||
|
self:cloneSprite()
|
||||||
self:setYGravity(480)
|
self:setYGravity(480)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue