Skip to content

Commit 87bcae0

Browse files
feat: add map and lfs support (#44)
* feat: add map and lfs support * chore: revert window size to 1280x720 Co-authored-by: Loay Ahmed <loayahmed304@gmail.com> --------- Co-authored-by: Loay Ahmed <loayahmed304@gmail.com>
1 parent 80c4957 commit 87bcae0

4 files changed

Lines changed: 37 additions & 25 deletions

File tree

.gitattributes

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
11
*.cpp text eol=lf
2-
*.hpp text eol=lf
2+
*.hpp text eol=lf
3+
*.jsonc text eol=lf
4+
CmakeLists.txt text eol=lf
5+
assets/shaders/** -filter -diff -merge text
6+
assets filter=lfs diff=lfs merge=lfs -text

assets/blends/map.blend

26.6 MB
Binary file not shown.

assets/gltf/map/map.glb

36.6 MB
Binary file not shown.

config/app.jsonc

Lines changed: 32 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,9 @@
179179
}
180180
},
181181
"models": {
182-
"drone": "assets/gltf/mech_drone/mech_drone.glb"
182+
"drone": "assets/gltf/mech_drone/mech_drone.glb",
183+
"map": "assets/gltf/map/map.glb",
184+
"gun": "assets/gltf/weapons/rifle.glb"
183185
}
184186
},
185187
"game": {
@@ -325,37 +327,43 @@
325327
"layer": "player",
326328
"radius": 0.45,
327329
"height": 1.8
328-
},
329-
{
330-
"type": "light",
331-
"lightType": "spot",
332-
"color": [1, 1, 1],
333-
"attenuation": [1.0, 0.22, 0.2],
334-
"spotAngles": [2, 5]
335330
}
336-
]
337-
},
338-
{
339-
"name": "Ground",
340-
"position": [0.0, 0.0, 0.0],
341-
"rotation": [-90.0, 0.0, 0.0],
342-
"scale": [120.0, 120.0, 1.0],
343-
"components": [
331+
],
332+
"children": [
344333
{
345-
"type": "Mesh Renderer",
346-
"mesh": "plane",
347-
"material": "ground"
334+
"position": [1, -1, -2],
335+
"rotation": [0, 0, 0],
336+
"scale": [0.3, 0.3, 0.3],
337+
"components": [
338+
{
339+
"type": "Model Renderer",
340+
"model": "gun"
341+
}
342+
],
343+
"children": [
344+
{
345+
"position": [0, 0, 0],
346+
"components": [
347+
{
348+
"type": "light",
349+
"lightType": "spot",
350+
"color": [1, 0.8, 0.6],
351+
"attenuation": [1.0, 0.14, 0.07],
352+
"spotAngles": [15, 20]
353+
}
354+
]
355+
}
356+
]
348357
}
349358
]
350359
},
351360
{
352-
"position": [2, 1, -2],
353-
"scale": [5, 5, 5],
361+
"name": "map",
362+
"position": [0, 0, 0],
354363
"components": [
355364
{
356-
"type": "Mesh Renderer",
357-
"mesh": "monkey",
358-
"material": "monkey"
365+
"type": "Model Renderer",
366+
"model": "map"
359367
}
360368
]
361369
}

0 commit comments

Comments
 (0)