From ef8245d71254969f7674d82fe81695abb71676d9 Mon Sep 17 00:00:00 2001 From: sergeypdev Date: Sun, 27 Apr 2025 17:13:21 +0400 Subject: [PATCH] Add a ramp --- game/game.odin | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/game/game.odin b/game/game.odin index b7b03ec..ba36cd8 100644 --- a/game/game.odin +++ b/game/game.odin @@ -259,6 +259,17 @@ update_runtime_world :: proc(runtime_world: ^Runtime_World, dt: f32) { }, ) + physics.immediate_body( + &world.physics_scene, + &runtime_world.solver_state, + #hash("ramp", "fnv32a"), + physics.Body_Config { + initial_pos = {0, 0, 0}, + initial_rot = linalg.quaternion_from_euler_angle_x_f32(-10 * math.RAD_PER_DEG), + shape = physics.Shape_Box{size = {5, 1, 10}}, + }, + ) + car_convex := assets.get_convex(&g_mem.assetman, "assets/car_convex.obj") runtime_world.car_handle = physics.immediate_body(