Skip to content

Commit e3b7e65

Browse files
committed
feat: add map and lfs support
1 parent e82b339 commit e3b7e65

4 files changed

Lines changed: 39 additions & 27 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: 34 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
"window": {
44
"title": "Default Game Window",
55
"size": {
6-
"width": 1280,
7-
"height": 720
6+
"width": 1920,
7+
"height": 1080
88
},
99
"fullscreen": false
1010
},
@@ -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": {
@@ -308,37 +310,43 @@
308310
"layer": "player",
309311
"radius": 0.45,
310312
"height": 1.8
311-
},
312-
{
313-
"type": "light",
314-
"lightType": "spot",
315-
"color": [1, 1, 1],
316-
"attenuation": [1.0, 0.22, 0.2],
317-
"spotAngles": [2, 5]
318313
}
319-
]
320-
},
321-
{
322-
"name": "Ground",
323-
"position": [0.0, 0.0, 0.0],
324-
"rotation": [-90.0, 0.0, 0.0],
325-
"scale": [120.0, 120.0, 1.0],
326-
"components": [
314+
],
315+
"children": [
327316
{
328-
"type": "Mesh Renderer",
329-
"mesh": "plane",
330-
"material": "ground"
317+
"position": [1, -1, -2],
318+
"rotation": [0, 0, 0],
319+
"scale": [0.3, 0.3, 0.3],
320+
"components": [
321+
{
322+
"type": "Model Renderer",
323+
"model": "gun"
324+
}
325+
],
326+
"children": [
327+
{
328+
"position": [0, 0, 0],
329+
"components": [
330+
{
331+
"type": "light",
332+
"lightType": "spot",
333+
"color": [1, 0.8, 0.6],
334+
"attenuation": [1.0, 0.14, 0.07],
335+
"spotAngles": [15, 20]
336+
}
337+
]
338+
}
339+
]
331340
}
332341
]
333342
},
334343
{
335-
"position": [2, 1, -2],
336-
"scale": [5, 5, 5],
344+
"name": "map",
345+
"position": [0, 0, 0],
337346
"components": [
338347
{
339-
"type": "Mesh Renderer",
340-
"mesh": "monkey",
341-
"material": "monkey"
348+
"type": "Model Renderer",
349+
"model": "map"
342350
}
343351
]
344352
}

0 commit comments

Comments
 (0)