1
Rock = WrapTile:extend {
2
image = 'data/rock.png',
4
--self.velocity = util.shortestVector(self, the.player):normalized() * 10
6
onEndFrame = function(self, dt)
7
-- onEndFrame to give a chance to go out of bounds then wrap
9
if DEBUG and the.console.visible then
11
self.text = Text:new()
12
the.view:add(self.text)
15
local pVec = util.shortestVector(self, the.player)
16
self.text.text = pVec.x .. ', ' .. pVec.y
17
self.text.x, self.text.y = self.x, self.y
18
self.text.visible = true
21
self.text.visible = false
b'\\ No newline at end of file'