fix spawn and better match hitbox to player sprite
This commit is contained in:
parent
414006b667
commit
7e75b665f5
6 changed files with 42 additions and 23 deletions
|
|
@ -76,7 +76,7 @@
|
|||
:objects
|
||||
(let [objects (:content (first (filter #(= (get-in % [:attrs :name]) "objects") (:content map-tmx))))]
|
||||
(vec (map (fn [obj]
|
||||
(let [attrs (dissoc (:attrs obj) :id)
|
||||
(let [attrs (assoc (:attrs obj) :x (Double. (get-in obj [:attrs :x])) :y (Double. (get-in obj [:attrs :y])))
|
||||
tags (flatten (map :content (:content obj)))
|
||||
properties (map #(hash-map (keyword (get-in % [:attrs :name])) (get-in % [:attrs :value])) tags)]
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
{
|
||||
"activeFile": "objects.tsx",
|
||||
"activeFile": "tutorial.tmx",
|
||||
"expandedProjectPaths": [
|
||||
"/Users/she0001t/personal_projects/fennel_love2d_experiments/two_player_cleaning_game/assets",
|
||||
".",
|
||||
"/Users/she0001t/personal_projects/fennel_love2d_experiments/two_player_cleaning_game"
|
||||
"/Users/she0001t/personal_projects/fennel_love2d_experiments/two_player_cleaning_game",
|
||||
"/Users/she0001t/personal_projects/fennel_love2d_experiments/two_player_cleaning_game/assets"
|
||||
],
|
||||
"fileStates": {
|
||||
"level_001.tmx": {
|
||||
|
|
@ -30,11 +30,11 @@
|
|||
"expandedObjectLayers": [
|
||||
2
|
||||
],
|
||||
"scale": 1.1429,
|
||||
"selectedLayer": 0,
|
||||
"scale": 3.1565,
|
||||
"selectedLayer": 2,
|
||||
"viewCenter": {
|
||||
"x": 657.5378423309126,
|
||||
"y": 883.7168606177268
|
||||
"x": 612.8623475368288,
|
||||
"y": 1141.1373356565816
|
||||
}
|
||||
},
|
||||
"walls.tsx": {
|
||||
|
|
@ -60,8 +60,8 @@
|
|||
"recentFiles": [
|
||||
"level_001.tmx",
|
||||
"walls.tsx",
|
||||
"tutorial.tmx",
|
||||
"objects.tsx",
|
||||
"tutorial.tmx",
|
||||
"map_tileset.tsx"
|
||||
],
|
||||
"tileset.lastUsedFormat": "tsx",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue