Added prefabs

This commit is contained in:
2024-12-02 20:00:54 -06:00
parent 9fd4c2399f
commit e660fade95
28 changed files with 332 additions and 268 deletions

27
assets/test_cube.json Normal file
View File

@ -0,0 +1,27 @@
{
"name": "Test Cube",
"assets": {
"rosa": {
"type": "texture",
"path": "rosa.texture"
}
},
"position": [ 0, 0, 0 ],
"components": {
"mat": {
"type": "SimpleTexturedMaterial",
"color": "blue"
},
"renderer": {
"type": "MeshRenderer"
},
"mesh": {
"type": "CubeMesh"
}
}
}

View File

@ -4,32 +4,29 @@
"rosa": {
"type": "texture",
"path": "rosa.texture"
},
"cube": {
"type": "prefab",
"path": "test_cube.json"
}
},
"items": {
"camera": {
"lookAt": {
"position": [ 5, 5, 5 ],
"position": [ 3, 3, 3 ],
"look": [ 0, 0, 0 ],
"view": [ 0, 1, 0 ]
},
"components": {
"camera": {
"type": "Camera",
"fov": 90
"type": "Camera"
}
}
},
"cube": {
"position": [ 0, 0, 0 ],
"scale": [ 3, 3, 3 ],
"components": {
"mat": { "type": "SimpleTexturedMaterial", "color": "blue", "texture": "rosa" },
"renderer": { "type": "MeshRenderer" },
"mesh": { "type": "CubeMesh" }
}
"prefab": "cube"
}
}
}