]> git.mcshandy.xyz Git - sumeriangame/commitdiff
Add a test side-scroll map that can change keymaps, some asset management fixes,... side-view
authorRandy McShandy <randy@mcshandy.xyz>
Fri, 13 Feb 2026 05:26:56 +0000 (23:26 -0600)
committerRandy McShandy <randy@mcshandy.xyz>
Fri, 13 Feb 2026 05:26:56 +0000 (23:26 -0600)
main/assets.lua
main/assets/tilesets/kenney_1_bit/Tilesheet/monochrome_ba_packed.png [new file with mode: 0644]
main/control.lua
main/main.lua
main/render.lua
main/tiled/side_scroll.lua [new file with mode: 0644]
main/tiled/side_scroll.tmx [new file with mode: 0644]
main/tiled/test_1.lua
main/tiled/test_1.tmx

index d8879baaf2d12d7661475c4c88a6e6441233f1ba..4351fdd26f1911cda8fd383eca1530003a9f6d34 100644 (file)
@@ -35,13 +35,19 @@ function assets.integrate_object_layers(pmap)
       new_layer.offsetx, new_layer.offsetx = layer.offsetx, layer.offsety
       new_layer.objects = layer.objects
 
-      -- Match objects in each layer to a pre-loaded asset-object
+      -- Match objects in each layer to a pre-loaded asset-object.
+      -- If an object (like the player) appears in multiple maps,
+      -- track unique instances of that object's positional info
+      -- for hot swapping on a map change. Otherwise, each initial load
+      -- of a map will override the first position an object is drawn in (and worse).
       for ok,ov in pairs(new_layer.objects) do
         local object = assets.get_object(ov.name)
         if object then
           object.image = love.graphics.newImage(object.path)
-          object.vec.x = ov.x
-          object.vec.y = ov.y
+          pmap[ov.name] = {}
+          -- Tiled does y values from the bottom of the sprite so pull up 1
+          pmap[ov.name].vec = vector.new_xy(ov.x, ov.y - pmap.tileheight)
+          pmap[ov.name].name = ov.name
         end
       end
 
@@ -139,9 +145,14 @@ assets.store_object('Player', {
   end
 })
 
+function assets.all_objects()
+  return AssetTables[AssetClass.Object]
+end
+
 -- STI only supports images for tilesheet sources in a tilemap, not a tsx file
 -- Mostly just embed the tileset in Tiled so it knows to reference the original
 -- tilesheet png directly.
 assets.store_map('test_map_1', 'tiled/test_1.lua')
+assets.store_map('side_scroll', 'tiled/side_scroll.lua')
 
 return assets
diff --git a/main/assets/tilesets/kenney_1_bit/Tilesheet/monochrome_ba_packed.png b/main/assets/tilesets/kenney_1_bit/Tilesheet/monochrome_ba_packed.png
new file mode 100644 (file)
index 0000000..0036d2b
Binary files /dev/null and b/main/assets/tilesets/kenney_1_bit/Tilesheet/monochrome_ba_packed.png differ
index daac70a32722fbab4da97437c20e1c64dcc0ded0..f4007f401a19c706dff795792438e76107416e04 100644 (file)
@@ -60,9 +60,22 @@ control.keymap['global']['x'] = {
   end,
 }
 
+control.keymap['global']['c'] = {
+  control = control.ControlType.System,
+  system_action = function(key)
+    render.activate_map('side_scroll')
+  end,
+}
+
+control.keymap['global']['v'] = {
+  control = control.ControlType.System,
+  system_action = function(key)
+    render.activate_map('test_map_1')
+  end,
+}
+
 function control.search_keymap(key, keymap)
   local key_found = false
-  --for k,v in pairs(control.keymap.active_keymap) do
   for k,v in pairs(keymap) do
     if key == k then
       key_found = true
index cc3e4eff32271a42533d6aeccbebb7b753ced016..b0ab40375b99cac1e67d65fd39f09e3bff47042a 100644 (file)
@@ -15,8 +15,6 @@ local render = require('render')
 player = player_module.player
 
 function love.load()
-  print(love.graphics.getRendererInfo())
-
   love.graphics.setFont(assets.get_font('Cuneiform36'))
   love.audio.play(assets.get_source('intro'))
 
index a1768808e41500c7b3411688598189a4e62e658e..e45787836a58951ee232e0dcceb0871454f06390 100644 (file)
@@ -40,7 +40,15 @@ render.activate_map = function(new_map_name)
     success = true
     render.map.active_map = new_map
     render.active_viewclass = render.ViewClassData[new_map.properties.viewclass]
-    utils.shallow_dump(render.map.active_map.properties)
+
+    -- Find all objects in the map we're switching to, and update their positional
+    -- info with the unique copy stored in each map.
+    for key,object in pairs(assets.all_objects()) do
+      local object_in_map = render.map.active_map[key]
+      if object_in_map then
+        object.vec = object_in_map.vec
+      end
+    end
 
     love.event.push('map_changed', new_map_name)
   end
diff --git a/main/tiled/side_scroll.lua b/main/tiled/side_scroll.lua
new file mode 100644 (file)
index 0000000..1b2c4c4
--- /dev/null
@@ -0,0 +1,229 @@
+return {
+  version = "1.10",
+  luaversion = "5.1",
+  tiledversion = "1.11.2",
+  class = "",
+  orientation = "orthogonal",
+  renderorder = "right-up",
+  width = 30,
+  height = 20,
+  tilewidth = 16,
+  tileheight = 16,
+  nextlayerid = 5,
+  nextobjectid = 2,
+  properties = {
+    ["viewclass"] = "sidescroll"
+  },
+  tilesets = {
+    {
+      name = "monochrome_bw_packed",
+      firstgid = 1,
+      class = "",
+      tilewidth = 16,
+      tileheight = 16,
+      spacing = 0,
+      margin = 0,
+      columns = 49,
+      image = "../assets/tilesets/kenney_1_bit/Tilesheet/monochrome_bw_packed.png",
+      imagewidth = 784,
+      imageheight = 352,
+      objectalignment = "unspecified",
+      tilerendersize = "tile",
+      fillmode = "stretch",
+      tileoffset = {
+        x = 0,
+        y = 0
+      },
+      grid = {
+        orientation = "orthogonal",
+        width = 16,
+        height = 16
+      },
+      properties = {},
+      wangsets = {},
+      tilecount = 1078,
+      tiles = {}
+    },
+    {
+      name = "monochrome_ba_packed",
+      firstgid = 1079,
+      class = "",
+      tilewidth = 16,
+      tileheight = 16,
+      spacing = 0,
+      margin = 0,
+      columns = 49,
+      image = "../assets/tilesets/kenney_1_bit/Tilesheet/monochrome_ba_packed.png",
+      imagewidth = 784,
+      imageheight = 352,
+      objectalignment = "unspecified",
+      tilerendersize = "tile",
+      fillmode = "stretch",
+      tileoffset = {
+        x = 0,
+        y = 0
+      },
+      grid = {
+        orientation = "orthogonal",
+        width = 16,
+        height = 16
+      },
+      properties = {},
+      wangsets = {},
+      tilecount = 1078,
+      tiles = {}
+    }
+  },
+  layers = {
+    {
+      type = "tilelayer",
+      x = 0,
+      y = 0,
+      width = 30,
+      height = 20,
+      id = 1,
+      name = "Background",
+      class = "",
+      visible = true,
+      opacity = 1,
+      offsetx = 0,
+      offsety = 0,
+      parallaxx = 1,
+      parallaxy = 1,
+      properties = {},
+      encoding = "lua",
+      data = {
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 106, 100, 106, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 106, 99, 99, 1, 1, 105, 106, 1, 106, 99, 99, 100, 100, 1, 1, 99, 106, 100, 99, 99, 100, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 99, 106, 106, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 99, 105, 106, 106, 99, 99, 99, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+        1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
+      }
+    },
+    {
+      type = "tilelayer",
+      x = 0,
+      y = 0,
+      width = 30,
+      height = 20,
+      id = 3,
+      name = "CityWalls_bg",
+      class = "",
+      visible = true,
+      opacity = 1,
+      offsetx = 0,
+      offsety = 0,
+      parallaxx = 1,
+      parallaxy = 1,
+      properties = {},
+      encoding = "lua",
+      data = {
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 206, 1610612941, 2684354766, 0, 0, 0, 0, 0, 0, 0, 0, 0, 206, 1610612941, 2684354766, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 205, 1, 3221225677, 0, 0, 0, 0, 0, 0, 0, 0, 0, 205, 1, 3221225677, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 206, 1610612943, 1610612941, 1610612943, 2684354766, 0, 0, 0, 0, 0, 0, 0, 206, 1610612943, 1610612941, 1610612943, 2684354766, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 205, 1, 1, 1, 205, 0, 0, 0, 0, 0, 0, 0, 205, 0, 0, 0, 205, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
+      }
+    },
+    {
+      type = "objectgroup",
+      draworder = "topdown",
+      id = 4,
+      name = "Object Layer 1",
+      class = "",
+      visible = true,
+      opacity = 1,
+      offsetx = 0,
+      offsety = 0,
+      parallaxx = 1,
+      parallaxy = 1,
+      properties = {},
+      objects = {
+        {
+          id = 1,
+          name = "Player",
+          type = "",
+          shape = "rectangle",
+          x = 112,
+          y = 256,
+          width = 16,
+          height = 16,
+          rotation = 0,
+          gid = 515,
+          visible = true,
+          properties = {}
+        }
+      }
+    },
+    {
+      type = "tilelayer",
+      x = 0,
+      y = 0,
+      width = 30,
+      height = 20,
+      id = 2,
+      name = "CityWalls_fg",
+      class = "",
+      visible = true,
+      opacity = 1,
+      offsetx = 0,
+      offsety = 0,
+      parallaxx = 1,
+      parallaxy = 1,
+      properties = {},
+      encoding = "lua",
+      data = {
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+        0, 0, 0, 0, 209, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 209, 0, 0, 0, 0, 0, 0, 0, 0, 0, 209, 0, 0, 0,
+        0, 0, 0, 0, 205, 0, 209, 0, 0, 0, 0, 0, 0, 0, 209, 0, 205, 0, 209, 0, 0, 0, 0, 0, 0, 0, 3221225677, 0, 0, 0,
+        0, 0, 0, 0, 207, 2684354765, 1610612943, 2684354765, 1610612943, 2684354765, 2684354765, 2684354765, 1610612943, 2684354765, 1610612943, 2684354765, 1610612943, 2684354765, 1610612943, 2684354765, 1610612943, 2684354765, 2684354765, 2684354765, 1610612943, 2684354765, 3221225679, 0, 0, 0,
+        0, 0, 0, 0, 205, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3221225677, 0, 0, 0,
+        0, 0, 0, 0, 205, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 256, 2684354815, 2684354816, 1, 1, 1, 1, 1, 1, 1, 1, 3221225677, 0, 0, 0,
+        0, 0, 0, 0, 205, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 255, 254, 3221225727, 1, 1, 1, 1, 1, 1, 1, 1, 3221225677, 0, 0, 0
+      }
+    }
+  }
+}
diff --git a/main/tiled/side_scroll.tmx b/main/tiled/side_scroll.tmx
new file mode 100644 (file)
index 0000000..ae974c3
--- /dev/null
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<map version="1.10" tiledversion="1.11.2" orientation="orthogonal" renderorder="right-up" width="30" height="20" tilewidth="16" tileheight="16" infinite="0" nextlayerid="5" nextobjectid="2">
+ <editorsettings>
+  <export target="side_scroll.lua" format="lua"/>
+ </editorsettings>
+ <properties>
+  <property name="viewclass" value="sidescroll"/>
+ </properties>
+ <tileset firstgid="1" name="monochrome_bw_packed" tilewidth="16" tileheight="16" tilecount="1078" columns="49">
+  <image source="../assets/tilesets/kenney_1_bit/Tilesheet/monochrome_bw_packed.png" width="784" height="352"/>
+ </tileset>
+ <tileset firstgid="1079" name="monochrome_ba_packed" tilewidth="16" tileheight="16" tilecount="1078" columns="49">
+  <image source="../assets/tilesets/kenney_1_bit/Tilesheet/monochrome_ba_packed.png" width="784" height="352"/>
+ </tileset>
+ <layer id="1" name="Background" width="30" height="20">
+  <data encoding="csv">
+1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
+1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
+1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
+1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
+1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
+1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,
+1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,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,206,1610612941,2684354766,0,0,0,0,0,0,0,0,0,206,1610612941,2684354766,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,205,1,3221225677,0,0,0,0,0,0,0,0,0,205,1,3221225677,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,206,1610612943,1610612941,1610612943,2684354766,0,0,0,0,0,0,0,206,1610612943,1610612941,1610612943,2684354766,0,0,0,0,0,
+0,0,0,0,0,0,0,0,205,1,1,1,205,0,0,0,0,0,0,0,205,0,0,0,205,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
+</data>
+ </layer>
+ <objectgroup id="4" name="Object Layer 1">
+  <object id="1" name="Player" gid="515" x="112" y="256" width="16" height="16"/>
+ </objectgroup>
+ <layer id="2" name="CityWalls_fg" width="30" height="20">
+  <data encoding="csv">
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,209,0,0,0,0,0,0,0,0,0,0,0,209,0,0,0,0,0,0,0,0,0,209,0,0,0,
+0,0,0,0,205,0,209,0,0,0,0,0,0,0,209,0,205,0,209,0,0,0,0,0,0,0,3221225677,0,0,0,
+0,0,0,0,207,2684354765,1610612943,2684354765,1610612943,2684354765,2684354765,2684354765,1610612943,2684354765,1610612943,2684354765,1610612943,2684354765,1610612943,2684354765,1610612943,2684354765,2684354765,2684354765,1610612943,2684354765,3221225679,0,0,0,
+0,0,0,0,205,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,3221225677,0,0,0,
+0,0,0,0,205,1,1,1,1,1,1,1,1,1,1,256,2684354815,2684354816,1,1,1,1,1,1,1,1,3221225677,0,0,0,
+0,0,0,0,205,1,1,1,1,1,1,1,1,1,1,255,254,3221225727,1,1,1,1,1,1,1,1,3221225677,0,0,0
+</data>
+ </layer>
+</map>
index b11069deaa5b9dcea0ad6902faa2d3dde7d52412..3e6823cca3fe23e0eaac9f01a084a614ebfa3f8a 100644 (file)
@@ -4,7 +4,7 @@ return {
   tiledversion = "1.11.2",
   class = "",
   orientation = "orthogonal",
-  renderorder = "right-down",
+  renderorder = "left-up",
   width = 30,
   height = 20,
   tilewidth = 16,
@@ -236,8 +236,8 @@ return {
           name = "Player",
           type = "",
           shape = "rectangle",
-          x = 48,
-          y = 144,
+          x = 16,
+          y = 32,
           width = 16,
           height = 16,
           rotation = 0,
index d719bf4e91bcb6d6192a291149e0c1884fa58308..3c96aa4e50aa2ef3be10592dd82daac462d680f0 100644 (file)
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<map version="1.10" tiledversion="1.11.2" orientation="orthogonal" renderorder="right-down" width="30" height="20" tilewidth="16" tileheight="16" infinite="0" nextlayerid="7" nextobjectid="13">
+<map version="1.10" tiledversion="1.11.2" orientation="orthogonal" renderorder="left-up" width="30" height="20" tilewidth="16" tileheight="16" infinite="0" nextlayerid="7" nextobjectid="13">
  <editorsettings>
   <export target="test_1.lua" format="lua"/>
  </editorsettings>
 </data>
  </layer>
  <objectgroup id="2" name="Object Layer 1">
-  <object id="11" name="Player" gid="515" x="48" y="144" width="16" height="16"/>
+  <object id="11" name="Player" gid="515" x="16" y="32" width="16" height="16"/>
  </objectgroup>
 </map>