Merge branch 'master' of github.com:vrld/HardonCollider

This commit is contained in:
Matthias Richter 2011-02-01 23:42:04 +01:00
commit fae80f07a0

View File

@ -57,6 +57,11 @@ end
local Shape = Class{name = 'Shape', function(self, t)
self._type = t
end}
function Shape:moveTo(x,y)
local current = vector( self:center() )
local to = vector.isvector(x) and x or vector(x,y)
self:move( to-current )
end
function Shape:moveTo(x,y)
if y then x = vector(x,y) end