Compare commits
2 Commits
487175f126
...
659c25dbe5
| Author | SHA1 | Date | |
|---|---|---|---|
| 659c25dbe5 | |||
| 9f9189e60e |
@@ -76,6 +76,8 @@ MAX_CHILDREN :: 16;
|
||||
dynamic_friction: float;
|
||||
restitution: float;
|
||||
|
||||
collider_color: Color;
|
||||
|
||||
lock: Physics_Lock;
|
||||
offset: Vector3;
|
||||
|
||||
|
||||
@@ -7,13 +7,11 @@ Mesh_Entity :: struct {
|
||||
}
|
||||
|
||||
init_entity :: (e: *Mesh_Entity) {
|
||||
log_error("Missing collision on Mesh Entities\n");
|
||||
assert(false);
|
||||
if e.model_path.count > 0 {
|
||||
load_model_into_entity(e, get_or_load_model(e.model_path));
|
||||
//e.flags |= .COLLISION | .STATIC;
|
||||
//e.collider.type = .MESH;
|
||||
//e.collider.bake_mode = .FULL_MESH;
|
||||
e.flags |= .PHYSICS;
|
||||
e.physics.type = .BOX;
|
||||
e.physics.box.half_extent = .{0.5,0.5,0.5};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,7 +35,7 @@ mesh_entity_visitor :: (info : *File_Visit_Info, files: *[..] Mesh_Entity_Info)
|
||||
}
|
||||
|
||||
find_all_mesh_entities :: () {
|
||||
path := "../assets/models/level_design/";
|
||||
path := "../assets/models/level_design";
|
||||
|
||||
visit_files(path, true, *mesh_entity_files, mesh_entity_visitor);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user