summaryrefslogtreecommitdiff
path: root/world.lua
diff options
context:
space:
mode:
authorcursed22bc <admin@pixeldawn.org>2026-03-01 11:17:23 +0200
committercursed22bc <admin@pixeldawn.org>2026-03-01 11:17:23 +0200
commit8f9182baff36d33c07c5eb8df795e3cfcd5307a5 (patch)
tree97d66e64e36f447b950609d5e849e24f2c438731 /world.lua
parent6eacf393b370a7586276108705b805e222a069a5 (diff)
improved tileset and load
Diffstat (limited to 'world.lua')
-rw-r--r--world.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/world.lua b/world.lua
index 2098040..6890e60 100644
--- a/world.lua
+++ b/world.lua
@@ -21,17 +21,17 @@ function World:new()
return self
end
-function World:load(levelPath)
+function World:load(mapPath, tilesetPath)
if self.physicsWorld then
self.groundEntities = {}
end
self.physicsWorld = love.physics.newWorld(0, GRAVITY)
self.physicsWorld:setCallbacks(nil, nil, nil, nil)
- self.tilemap = Tilemap:new(levelPath)
+ self.tilemap = Tilemap:new(mapPath, tilesetPath)
self.mapData = self.tilemap:getMapData()
if not self.mapData then
- error("World:load - no map data from " .. tostring(levelPath))
+ error("World:load - no map data from " .. tostring(mapPath))
end
local tileWidth = self.tilemap:getTileWidth()