|
|
@@ -127,7 +127,8 @@ namespace physics_resource_internal
|
|
|
cd.local_tm = MATRIX4X4_IDENTITY;
|
|
|
cd.size = 0;
|
|
|
DynamicString source(ta);
|
|
|
- sjson::parse_string(obj["source"], source);
|
|
|
+ if (json_object::has(obj, "source"))
|
|
|
+ sjson::parse_string(obj["source"], source);
|
|
|
bool explicit_collider = source == "mesh" || json_object::has(obj, "scene");
|
|
|
|
|
|
if (explicit_collider) {
|
|
|
@@ -235,7 +236,6 @@ namespace physics_resource_internal
|
|
|
Quaternion rotation = sjson::parse_quaternion(collider_data["rotation"]);
|
|
|
Vector3 position = sjson::parse_vector3(collider_data["position"]);
|
|
|
Matrix4x4 matrix_local = matrix4x4(rotation, position);
|
|
|
- matrix_local.t = vector4(position.x, position.y, position.z, 1.0f);
|
|
|
cd.local_tm = matrix_local;
|
|
|
|
|
|
if (cd.type == ColliderType::SPHERE) {
|