ソースを参照

Update 01-physics sample

Daniele Bartolini 9 年 前
コミット
6a953cdbde

+ 5 - 0
samples/01-physics/core/units/camera.mesh

@@ -11,3 +11,8 @@ geometries = {
         }
         }
     }
     }
 }
 }
+nodes = {
+	"Cube" = {
+		matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
+	}
+}

+ 5 - 0
samples/01-physics/core/units/light.mesh

@@ -11,3 +11,8 @@ geometries = {
         }
         }
     }
     }
 }
 }
+nodes = {
+	"Icosphere" = {
+		matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
+	}
+}

+ 1 - 1
samples/01-physics/core/units/primitives/cone.mesh

@@ -13,6 +13,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Cone" = {
     "Cone" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 1 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/core/units/primitives/cone.unit

@@ -29,7 +29,7 @@ components = {
 	"1862249c-206a-4fdb-9e3f-c37a149e58d8" = {
 	"1862249c-206a-4fdb-9e3f-c37a149e58d8" = {
 		type = "actor"
 		type = "actor"
 		data = {
 		data = {
-			class = "dynamic"
+			class = "static"
 			mass = 1
 			mass = 1
 			collision_filter = "default"
 			collision_filter = "default"
 		}
 		}

+ 1 - 1
samples/01-physics/core/units/primitives/cube.mesh

@@ -13,6 +13,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Cube" = {
     "Cube" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 1 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/core/units/primitives/cube.unit

@@ -29,7 +29,7 @@ components = {
 	"b15082c5-3aaf-4c9a-8925-e5c958d49171" = {
 	"b15082c5-3aaf-4c9a-8925-e5c958d49171" = {
 		type = "actor"
 		type = "actor"
 		data = {
 		data = {
-			class = "dynamic"
+			class = "static"
 			mass = 1
 			mass = 1
 			collision_filter = "default"
 			collision_filter = "default"
 		}
 		}

+ 1 - 1
samples/01-physics/core/units/primitives/cylinder.mesh

@@ -13,6 +13,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Cylinder" = {
     "Cylinder" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 1 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/core/units/primitives/cylinder.unit

@@ -29,7 +29,7 @@ components = {
 	"f1539903-68cd-4d86-bada-501be048c1c7" = {
 	"f1539903-68cd-4d86-bada-501be048c1c7" = {
 		type = "actor"
 		type = "actor"
 		data = {
 		data = {
-			class = "dynamic"
+			class = "static"
 			mass = 1
 			mass = 1
 			collision_filter = "default"
 			collision_filter = "default"
 		}
 		}

+ 1 - 1
samples/01-physics/core/units/primitives/plane.mesh

@@ -13,6 +13,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Plane" = {
     "Plane" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/core/units/primitives/plane.unit

@@ -29,7 +29,7 @@ components = {
 	"b5f0e7bd-e78b-4447-acd3-37ca73020177" = {
 	"b5f0e7bd-e78b-4447-acd3-37ca73020177" = {
 		type = "actor"
 		type = "actor"
 		data = {
 		data = {
-			class = "dynamic"
+			class = "static"
 			mass = 1
 			mass = 1
 			collision_filter = "default"
 			collision_filter = "default"
 		}
 		}

+ 1 - 1
samples/01-physics/core/units/primitives/sphere.mesh

@@ -13,6 +13,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Sphere" = {
     "Sphere" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 1 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/core/units/primitives/sphere.unit

@@ -29,7 +29,7 @@ components = {
 	"b90d4427-bc08-4d40-aaf5-9d0eb80be391" = {
 	"b90d4427-bc08-4d40-aaf5-9d0eb80be391" = {
 		type = "actor"
 		type = "actor"
 		data = {
 		data = {
-			class = "dynamic"
+			class = "static"
 			mass = 1
 			mass = 1
 			collision_filter = "default"
 			collision_filter = "default"
 		}
 		}

+ 1 - 1
samples/01-physics/cube.mesh

@@ -19,6 +19,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Cube" = {
     "Cube" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
     }
     }
 }
 }

+ 0 - 2
samples/01-physics/lua/game.lua

@@ -29,8 +29,6 @@ function init()
 
 
 	-- Spawn skydome
 	-- Spawn skydome
 	skydome = World.spawn_unit(wd, "skydome")
 	skydome = World.spawn_unit(wd, "skydome")
-	local skydome_transform = SceneGraph.transform_instances(sg, skydome)
-	SceneGraph.set_local_scale(sg, skydome_transform, Vector3(500, 500, 500))
 
 
 	-- Load test level
 	-- Load test level
 	World.load_level(wd, "test", Vector3(0, 0.1, 0))
 	World.load_level(wd, "test", Vector3(0, 0.1, 0))

+ 5 - 0
samples/01-physics/plane.mesh

@@ -13,3 +13,8 @@ geometries = {
         }
         }
     }
     }
 }
 }
+nodes = {
+	"Plane" = {
+		matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
+	}
+}

+ 1 - 1
samples/01-physics/ramp.mesh

@@ -19,6 +19,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Cube" = {
     "Cube" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/skydome.mesh

@@ -19,6 +19,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Sphere" = {
     "Sphere" = {
-        matrix_local = [ 256.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -256.000000 0.000000 0.000000 256.000000 0.000000 0.000000 0.000000 -0.500000 0.000000 1.000000 ]
+        matrix_local = [ 512 0 0 0 0 512 0 0 0 0 512 0 0 0 0 1 ]
     }
     }
 }
 }

+ 1 - 1
samples/01-physics/sphere.mesh

@@ -19,6 +19,6 @@ geometries = {
 }
 }
 nodes = {
 nodes = {
     "Sphere" = {
     "Sphere" = {
-        matrix_local = [ 1.000000 0.000000 0.000000 0.000000 0.000000 0.000000 -1.000000 0.000000 0.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000 1.000000 ]
+        matrix_local = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ]
     }
     }
 }
 }