naming conventions act 2: the end

This commit is contained in:
lustlion
2022-03-06 09:35:45 +01:00
parent edd064c2fd
commit 05bf757ea5
29 changed files with 509 additions and 536 deletions

View File

@@ -1,20 +1,18 @@
HookAnchor = Entity:new()
function HookAnchor:new(x,y,hookDistance)
function HookAnchor:new(x,y,hook_distance)
local o = Entity:new(x,y)
o.type = "hook_anchor"
o.pos = {x = x, y = y}
o.hookDistance = hookDistance or 100
o.hook_distance = hook_distance or 100
-- animations
o.body = Animation:new(animation.fairy.flying)
o:centerOffset(o.body)
o:createBox(o.body)
table.insert(LoadedObjects.Entities,o)
o.id = #LoadedObjects.Entities
o:id()
setmetatable(o, self)
self.__index = self
@@ -33,7 +31,7 @@ function HookAnchor:drawBackground()
"fill",
-Camera.pos.x + self.pos.x,
-Camera.pos.y + self.pos.y,
self.hookDistance
self.hook_distance
)
end