code
This commit is contained in:
parent
d05cab9c85
commit
2ee3b2a8c0
Binary file not shown.
After Width: | Height: | Size: 457 B |
|
@ -0,0 +1,449 @@
|
|||
return {
|
||||
version = "1.2",
|
||||
luaversion = "5.1",
|
||||
tiledversion = "1.2.4",
|
||||
orientation = "orthogonal",
|
||||
renderorder = "right-down",
|
||||
width = 200,
|
||||
height = 20,
|
||||
tilewidth = 32,
|
||||
tileheight = 32,
|
||||
nextlayerid = 2,
|
||||
nextobjectid = 1,
|
||||
properties = {},
|
||||
tilesets = {
|
||||
{
|
||||
name = "tile_cave_platform",
|
||||
firstgid = 1,
|
||||
tilewidth = 32,
|
||||
tileheight = 32,
|
||||
spacing = 0,
|
||||
margin = 0,
|
||||
columns = 11,
|
||||
image = "../tile_cave_platform.png",
|
||||
imagewidth = 352,
|
||||
imageheight = 384,
|
||||
tileoffset = {
|
||||
x = 0,
|
||||
y = 0
|
||||
},
|
||||
grid = {
|
||||
orientation = "orthogonal",
|
||||
width = 32,
|
||||
height = 32
|
||||
},
|
||||
properties = {
|
||||
["collidable"] = ""
|
||||
},
|
||||
terrains = {},
|
||||
tilecount = 132,
|
||||
tiles = {
|
||||
{
|
||||
id = 0,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 1,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 2,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 3,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 5,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 6,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 11,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 12,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 13,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 14,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 15,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 22,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 23,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 24,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 25,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 26,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 27,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 28,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 34,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 35,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 36,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 49,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 59,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 61,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 62,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 66,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 67,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 68,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 69,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 70,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 72,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 73,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 74,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 75,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 76,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 77,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 78,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 86,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 87,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 88,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 89,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 90,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 91,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 92,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 93,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 94,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 95,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 97,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 98,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 100,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 101,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 102,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 103,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 104,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 105,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 106,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 107,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 108,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 114,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 115,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
},
|
||||
{
|
||||
id = 116,
|
||||
properties = {
|
||||
["collidable"] = "true"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
layers = {
|
||||
{
|
||||
type = "tilelayer",
|
||||
id = 1,
|
||||
name = "Tile Layer 1",
|
||||
x = 0,
|
||||
y = 0,
|
||||
width = 200,
|
||||
height = 20,
|
||||
visible = true,
|
||||
opacity = 1,
|
||||
offsetx = 0,
|
||||
offsety = 0,
|
||||
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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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 +1,338 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map version="1.2" tiledversion="1.2.4" orientation="orthogonal" renderorder="right-down" width="200" height="20" tilewidth="32" tileheight="32" infinite="0" nextlayerid="2" nextobjectid="1">
|
||||
<tileset firstgid="1" name="tile_cave_platform" tilewidth="32" tileheight="32" tilecount="132" columns="11">
|
||||
<properties>
|
||||
<property name="collidable" type="color" value=""/>
|
||||
</properties>
|
||||
<image source="../tile_cave_platform.png" width="352" height="384"/>
|
||||
<tile id="0">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="1">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="2">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="3">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="5">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="6">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="11">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="12">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="13">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="14">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="15">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="22">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="23">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="24">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="25">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="26">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="27">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="28">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="34">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="35">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="36">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="49">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="59">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="61">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="62">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="66">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="67">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="68">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="69">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="70">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="72">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="73">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="74">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="75">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="76">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="77">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="78">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="86">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="87">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="88">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="89">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="90">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="91">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="92">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="93">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="94">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="95">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="97">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="98">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="100">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="101">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="102">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="103">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="104">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="105">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="106">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="107">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="108">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="114">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="115">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
<tile id="116">
|
||||
<properties>
|
||||
<property name="collidable" value="true"/>
|
||||
</properties>
|
||||
</tile>
|
||||
</tileset>
|
||||
<layer id="1" name="Tile Layer 1" width="200" 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,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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
|
||||
</data>
|
||||
</layer>
|
||||
</map>
|
Binary file not shown.
After Width: | Height: | Size: 28 KiB |
|
@ -0,0 +1,55 @@
|
|||
-- Represents a collection of drawable entities. Each gamestate holds one of these.
|
||||
|
||||
local Entities = {
|
||||
active = true,
|
||||
world = nil,
|
||||
entityList = {}
|
||||
}
|
||||
|
||||
function Entities:enter(world)
|
||||
self:clear()
|
||||
|
||||
self.world = world
|
||||
end
|
||||
|
||||
function Entities:add(entity)
|
||||
table.insert(self.entityList, entity)
|
||||
end
|
||||
|
||||
function Entities:addMany(entities)
|
||||
for k, entity in pairs(entities) do
|
||||
table.insert(self.entityList, entity)
|
||||
end
|
||||
end
|
||||
|
||||
function Entities:remove(entity)
|
||||
for i, e in ipairs(self.entityList) do
|
||||
if e == entity then
|
||||
table.remove(self.entityList, i)
|
||||
return
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function Entities:removeAt(index)
|
||||
table.remove(self.entityList, index)
|
||||
end
|
||||
|
||||
function Entities:clear()
|
||||
self.world = nil
|
||||
self.entityList = {}
|
||||
end
|
||||
|
||||
function Entities:draw()
|
||||
for i, e in ipairs(self.entityList) do
|
||||
e:draw(i)
|
||||
end
|
||||
end
|
||||
|
||||
function Entities:update(dt)
|
||||
for i, e in ipairs(self.entityList) do
|
||||
e:update(dt, i)
|
||||
end
|
||||
end
|
||||
|
||||
return Entities
|
|
@ -0,0 +1,26 @@
|
|||
-- Represents a single drawable object
|
||||
local Class = require 'libs.hump.class'
|
||||
|
||||
local Entity = Class{}
|
||||
|
||||
function Entity:init(world, x, y, w, h)
|
||||
self.world = world
|
||||
self.x = x
|
||||
self.y = y
|
||||
self.w = w
|
||||
self.h = h
|
||||
end
|
||||
|
||||
function Entity:getRect()
|
||||
return self.x, self.y, self.w, self.h
|
||||
end
|
||||
|
||||
function Entity:draw()
|
||||
-- Do nothing by default, but we still have to have something to call
|
||||
end
|
||||
|
||||
function Entity:update(dt)
|
||||
-- Do nothing by default, but we still have to have something to call
|
||||
end
|
||||
|
||||
return Entity
|
|
@ -0,0 +1,18 @@
|
|||
local Class = require 'libs.hump.class'
|
||||
local Entity = require 'entities.Entity'
|
||||
|
||||
local Ground = Class{
|
||||
__includes = Entity -- Ground class inherits our Entity class
|
||||
}
|
||||
|
||||
function Ground:init(world, x, y, w, h)
|
||||
Entity.init(self, world, x, y, w, h)
|
||||
|
||||
self.world:add(self, self:getRect())
|
||||
end
|
||||
|
||||
function Ground:draw()
|
||||
love.graphics.rectangle('fill', self:getRect())
|
||||
end
|
||||
|
||||
return Ground
|
|
@ -0,0 +1,91 @@
|
|||
local Class = require 'libs.hump.class'
|
||||
local Entity = require 'entities.Entity'
|
||||
|
||||
local player = Class{
|
||||
__includes = Entity -- Player class inherits our Entity class
|
||||
}
|
||||
|
||||
function player:init(world, x, y)
|
||||
self.img = love.graphics.newImage('/assets/character_block.png')
|
||||
|
||||
Entity.init(self, world, x, y, self.img:getWidth(), self.img:getHeight())
|
||||
|
||||
-- Add our unique player values
|
||||
self.xVelocity = 0 -- current velocity on x, y axes
|
||||
self.yVelocity = 0
|
||||
self.acc = 100 -- the acceleration of our player
|
||||
self.maxSpeed = 600 -- the top speed
|
||||
self.friction = 20 -- slow our player down - we could toggle this situationally to create icy or slick platforms
|
||||
self.gravity = 80 -- we will accelerate towards the bottom
|
||||
|
||||
-- These are values applying specifically to jumping
|
||||
self.isJumping = false -- are we in the process of jumping?
|
||||
self.isGrounded = false -- are we on the ground?
|
||||
self.hasReachedMax = false -- is this as high as we can go?
|
||||
self.jumpAcc = 500 -- how fast do we accelerate towards the top
|
||||
self.jumpMaxSpeed = 11 -- our speed limit while jumping
|
||||
|
||||
self.world:add(self, self:getRect())
|
||||
end
|
||||
|
||||
function player:collisionFilter(other)
|
||||
local x, y, w, h = self.world:getRect(other)
|
||||
local playerBottom = self.y + self.h
|
||||
local otherBottom = y + h
|
||||
|
||||
if playerBottom <= y then -- bottom of player collides with top of platform.
|
||||
return 'slide'
|
||||
end
|
||||
end
|
||||
|
||||
function player:update(dt)
|
||||
local prevX, prevY = self.x, self.y
|
||||
|
||||
-- Apply Friction
|
||||
self.xVelocity = self.xVelocity * (1 - math.min(dt * self.friction, 1))
|
||||
self.yVelocity = self.yVelocity * (1 - math.min(dt * self.friction, 1))
|
||||
|
||||
-- Apply gravity
|
||||
self.yVelocity = self.yVelocity + self.gravity * dt
|
||||
|
||||
if love.keyboard.isDown("left", "a") and self.xVelocity > -self.maxSpeed then
|
||||
self.xVelocity = self.xVelocity - self.acc * dt
|
||||
elseif love.keyboard.isDown("right", "d") and self.xVelocity < self.maxSpeed then
|
||||
self.xVelocity = self.xVelocity + self.acc * dt
|
||||
end
|
||||
|
||||
-- The Jump code gets a lttle bit crazy. Bare with me.
|
||||
if love.keyboard.isDown("up", "w") then
|
||||
if -self.yVelocity < self.jumpMaxSpeed and not self.hasReachedMax then
|
||||
self.yVelocity = self.yVelocity - self.jumpAcc * dt
|
||||
elseif math.abs(self.yVelocity) > self.jumpMaxSpeed then
|
||||
self.hasReachedMax = true
|
||||
end
|
||||
|
||||
self.isGrounded = false -- we are no longer in contact with the ground
|
||||
end
|
||||
|
||||
-- these store the location the player will arrive at should
|
||||
local goalX = self.x + self.xVelocity
|
||||
local goalY = self.y + self.yVelocity
|
||||
|
||||
-- Move the player while testing for collisions
|
||||
self.x, self.y, collisions, len = self.world:move(self, goalX, goalY, self.collisionFilter)
|
||||
|
||||
-- Loop through those collisions to see if anything important is happening
|
||||
for i, coll in ipairs(collisions) do
|
||||
if coll.touch.y > goalY then -- We touched below (remember that higher locations have lower y values) our intended target.
|
||||
self.hasReachedMax = true -- this scenario does not occur in this demo
|
||||
self.isGrounded = false
|
||||
elseif coll.normal.y < 0 then
|
||||
self.hasReachedMax = false
|
||||
self.isGrounded = true
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function player:draw()
|
||||
love.graphics.draw(self.img, self.x, self.y)
|
||||
end
|
||||
|
||||
return player
|
|
@ -0,0 +1,46 @@
|
|||
-- Each level will inherit from this class which itself inherits from Gamestate.
|
||||
-- This class is Gamestate but with function for loading up Tiled maps.
|
||||
|
||||
local bump = require 'libs.bump.bump'
|
||||
local Gamestate = require 'libs.hump.gamestate'
|
||||
local Class = require 'libs.hump.class'
|
||||
local sti = require 'libs.sti.sti' -- New addition here
|
||||
local Entities = require 'entities.Entities'
|
||||
local camera = require 'libs.camera' -- New addition here
|
||||
|
||||
local LevelBase = Class{
|
||||
__includes = Gamestate,
|
||||
init = function(self, mapFile)
|
||||
self.map = sti(mapFile, { 'bump' })
|
||||
self.world = bump.newWorld(32)
|
||||
self.map:resize(love.graphics.getWidth(), love.graphics.getHeight())
|
||||
|
||||
self.map:bump_init(self.world)
|
||||
|
||||
Entities:enter()
|
||||
end;
|
||||
Entities = Entities;
|
||||
camera = camera
|
||||
}
|
||||
|
||||
function LevelBase:keypressed(key)
|
||||
-- All levels will have a pause menu
|
||||
if Gamestate.current() ~= pause and key == 'p' then
|
||||
Gamestate.push(pause)
|
||||
end
|
||||
end
|
||||
|
||||
function LevelBase:positionCamera(player, camera)
|
||||
local mapWidth = self.map.width * self.map.tilewidth -- get width in pixels
|
||||
local halfScreen = love.graphics.getWidth() / 2
|
||||
|
||||
if player.x < (mapWidth - halfScreen) then -- use this value until we're approaching the end.
|
||||
boundX = math.max(0, player.x - halfScreen) -- lock camera at the left side of the screen.
|
||||
else
|
||||
boundX = math.min(player.x - halfScreen, mapWidth - love.graphics.getWidth()) -- lock camera at the right side of the screen
|
||||
end
|
||||
|
||||
camera:setPosition(boundX, 0)
|
||||
end
|
||||
|
||||
return LevelBase
|
|
@ -0,0 +1,51 @@
|
|||
-- Import our libraries.
|
||||
local Gamestate = require 'libs.hump.gamestate'
|
||||
local Class = require 'libs.hump.class'
|
||||
|
||||
-- Grab our base class
|
||||
local LevelBase = require 'gamestates.LevelBase'
|
||||
|
||||
-- Import the Entities we will build.
|
||||
local Player = require 'entities.player'
|
||||
local camera = require 'libs.camera'
|
||||
|
||||
-- Declare a couple immportant variables
|
||||
player = nil
|
||||
|
||||
local gameLevel1 = Class{
|
||||
__includes = LevelBase
|
||||
}
|
||||
|
||||
function gameLevel1:init()
|
||||
LevelBase.init(self, 'assets/levels/level_1.lua')
|
||||
end
|
||||
|
||||
function gameLevel1:enter()
|
||||
player = Player(self.world, 32, 64)
|
||||
LevelBase.Entities:add(player)
|
||||
end
|
||||
|
||||
function gameLevel1:update(dt)
|
||||
self.map:update(dt) -- remember, we inherited map from LevelBase
|
||||
LevelBase.Entities:update(dt) -- this executes the update function for each individual Entity
|
||||
|
||||
LevelBase.positionCamera(self, player, camera)
|
||||
end
|
||||
|
||||
function gameLevel1:draw()
|
||||
-- Attach the camera before drawing the entities
|
||||
camera:set()
|
||||
|
||||
self.map:draw(-camera.x, -camera.y) -- Remember that we inherited map from LevelBase
|
||||
LevelBase.Entities:draw() -- this executes the draw function for each individual Entity
|
||||
|
||||
camera:unset()
|
||||
-- Be sure to detach after running to avoid weirdness
|
||||
end
|
||||
|
||||
-- All levels will have a pause menu
|
||||
function gameLevel1:keypressed(key)
|
||||
LevelBase:keypressed(key)
|
||||
end
|
||||
|
||||
return gameLevel1
|
|
@ -0,0 +1,3 @@
|
|||
local mainMenu = {}
|
||||
|
||||
return mainMenu
|
|
@ -0,0 +1,25 @@
|
|||
pause = Gamestate.new()
|
||||
|
||||
function pause:enter(from)
|
||||
self.from = from -- record previous state
|
||||
end
|
||||
|
||||
function pause:draw()
|
||||
local w, h = love.graphics.getWidth(), love.graphics.getHeight()
|
||||
-- draw previous screen
|
||||
self.from:draw()
|
||||
|
||||
-- overlay with pause message
|
||||
love.graphics.setColor(0,0,0, 100)
|
||||
love.graphics.rectangle('fill', 0,0, w, h)
|
||||
love.graphics.setColor(255,255,255)
|
||||
love.graphics.printf('PAUSE', 0, h/2, w, 'center')
|
||||
end
|
||||
|
||||
function pause:keypressed(key)
|
||||
if key == 'p' then
|
||||
return Gamestate.pop() -- return to previous state
|
||||
end
|
||||
end
|
||||
|
||||
return pause
|
|
@ -0,0 +1,24 @@
|
|||
camera = {}
|
||||
camera.x = 0
|
||||
camera.y = 0
|
||||
|
||||
function camera:set()
|
||||
love.graphics.push()
|
||||
love.graphics.translate(-self.x, -self.y)
|
||||
end
|
||||
|
||||
function camera:unset()
|
||||
love.graphics.pop()
|
||||
end
|
||||
|
||||
function camera:move(dx, dy)
|
||||
self.x = self.x + (dx or 0)
|
||||
self.y = self.y + (dy or 0)
|
||||
end
|
||||
|
||||
function camera:setPosition(x, y)
|
||||
self.x = x or self.x
|
||||
self.y = y or self.y
|
||||
end
|
||||
|
||||
return camera
|
|
@ -0,0 +1,18 @@
|
|||
-- Pull in Gamestate from the HUMP library
|
||||
Gamestate = require 'libs.hump.gamestate'
|
||||
|
||||
-- Pull in each of our game states
|
||||
local mainMenu = require 'gamestates.mainmenu'
|
||||
local gameLevel1 = require 'gamestates.gameLevel1'
|
||||
local pause = require 'gamestates.pause'
|
||||
|
||||
function love.load()
|
||||
Gamestate.registerEvents()
|
||||
Gamestate.switch(gameLevel1)
|
||||
end
|
||||
|
||||
function love.keypressed(key)
|
||||
if key == "escape" then
|
||||
love.event.push("quit")
|
||||
end
|
||||
end
|
Loading…
Reference in New Issue