Skip to content

Commit

Permalink
Tutorials update for HARFANG v3.0.0:
Browse files Browse the repository at this point in the history
* Fixed the spatialized sound Lua tutorial.
* Updated the tutorials impacted by the SetViewPerspective or SetView2D API change.
* Updated the VR tutorial to explicitely create a SceneForwardPipelinePassViewId.
* Added a new tutorial to demonstrate the Python/Lua communication.
* Updated the core shaders.
  • Loading branch information
astrofra committed Oct 13, 2021
1 parent 9f34c09 commit 3038f18
Show file tree
Hide file tree
Showing 61 changed files with 352 additions and 119 deletions.
25 changes: 21 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,26 @@
# HARFANG® 2.0 Tutorials
# HARFANG® 3.0 Tutorials

These **tutorials** demonstrate the usage of the HARFANG 2.0 API in **Python** and **Lua**.
If you want to know more about HARFANG, please visit the [official website](https://www.harfang3d.com).

To **run the tutorials**, please follow the **instructions** here : https://www.harfang3d.com/docs/2.0.111/man.quickstart/
To run the tutorials:

1. Download or clone this repository to your computer _(eg. in `d:/tutorials-hg2`)_.
2. Download _assetc_ for your platform from [here](https://harfang3d.com/releases) to compile the tutorial resources.
3. Drag and drop the tutorial resources folder on the assetc executable **-OR-** execute assetc passing it the path to the tutorial resources folder _(eg. `assetc d:/tutorials-hg2/resources`)_.

![assetc drag & drop](https://github.com/harfang3d/image-storage/raw/main/tutorials/assetc.gif)

After the compilation process finishes, you will see a `resources_compiled` folder next to the tutorials resources folder.

You can now execute the tutorials from the folder you unzipped them to.

```bash
D:\tutorials-hg2>python draw_lines.py
```

Alternatively, you can open the tutorial folder using [Visual Studio Code](https://code.visualstudio.com/) and use the provided debug targets to run the tutorials.

**If you want to know more about HARFANG**, please visit the [official website](https://www.harfang3d.com).

## Screenshots
* AAA Rendering Pipeline
Expand Down Expand Up @@ -34,4 +51,4 @@ To **run the tutorials**, please follow the **instructions** here : https://www.
![Lights priority](screenshots/scene_light_priority.png)

* Dear ImGui edition
![Dear ImGui edition](screenshots/imgui_edit.png)
![Dear ImGui edition](screenshots/imgui_edit.png)
2 changes: 1 addition & 1 deletion audio_play_sound_spatialized.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
hg = require("harfang")

hg.InputInit()
hg.WindowSystemInit()
hg.AudioInit()

hg.AddAssetsFolder("resources_compiled")

Expand Down
2 changes: 1 addition & 1 deletion draw_model_no_pipeline.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ while not hg.ReadKeyboard():Key(hg.K_Escape) do
angle = angle + hg.time_to_sec_f(dt)

viewpoint = hg.TranslationMat4(hg.Vec3(0, 1, -3))
hg.SetViewPerspective(0, res_x, res_y, viewpoint)
hg.SetViewPerspective(0, 0, 0, res_x, res_y, viewpoint)

hg.DrawModel(0, cube_mdl, shader, {}, {}, hg.TransformationMat4(hg.Vec3(0, 1, 0), hg.Vec3(angle, angle, angle)))
hg.DrawModel(0, ground_mdl, shader, {}, {}, hg.TranslationMat4(hg.Vec3(0, 0, 0)))
Expand Down
2 changes: 1 addition & 1 deletion draw_models_no_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
angle = angle + hg.time_to_sec_f(dt)

viewpoint = hg.TranslationMat4(hg.Vec3(0, 1, -3))
hg.SetViewPerspective(0, res_x, res_y, viewpoint)
hg.SetViewPerspective(0, 0, 0, res_x, res_y, viewpoint)

hg.DrawModel(0, cube_mdl, shader, [], [], hg.TransformationMat4(hg.Vec3(0, 1, 0), hg.Vec3(angle, angle, angle)))
hg.DrawModel(0, ground_mdl, shader, [], [], hg.TranslationMat4(hg.Vec3(0, 0, 0)))
Expand Down
2 changes: 1 addition & 1 deletion draw_text.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ text_render_state = hg.ComputeRenderState(hg.BM_Alpha, hg.DT_Always, hg.FC_Disab

-- main loop
while not hg.ReadKeyboard('default'):Key(hg.K_Escape) do
hg.SetView2D(0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.ColorI(32, 32, 32), 0, 1)
hg.SetView2D(0, 0, 0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.ColorI(32, 32, 32), 0, 1)

hg.DrawText(0, font, 'Hello world!', font_prg, 'u_tex', 0, hg.Mat4.Identity, hg.Vec3(res_x / 2, res_y / 2, 0), hg.DTHA_Center, hg.DTVA_Center, text_uniform_values, {}, text_render_state)

Expand Down
2 changes: 1 addition & 1 deletion draw_text.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

# main loop
while not hg.ReadKeyboard('default').Key(hg.K_Escape):
hg.SetView2D(0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.ColorI(32, 32, 32), 0, 1)
hg.SetView2D(0, 0, 0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.ColorI(32, 32, 32), 0, 1)

hg.DrawText(0, font, 'Hello world!', font_prg, 'u_tex', 0, hg.Mat4.Identity, hg.Vec3(res_x / 2, res_y / 2, 0), hg.DTHA_Center, hg.DTVA_Center, text_uniform_values, [], text_render_state)

Expand Down
4 changes: 2 additions & 2 deletions draw_text_over_models.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@ while not hg.ReadKeyboard():Key(hg.K_Escape) do

-- 3D view
viewpoint = hg.TranslationMat4(hg.Vec3(0, 1, -3))
hg.SetViewPerspective(0, res_x, res_y, viewpoint, 0.01, 5000)
hg.SetViewPerspective(0, 0, 0, res_x, res_y, viewpoint, 0.01, 5000)

hg.DrawModel(0, cube_mdl, shader, {}, {}, hg.TransformationMat4(hg.Vec3(0, 1, 0), hg.Vec3(angle, angle, angle)))
hg.DrawModel(0, ground_mdl, shader, {}, {}, hg.TranslationMat4(hg.Vec3(0, 0, 0)))

-- 2D view, note that only the depth buffer is cleared
hg.SetView2D(1, res_x, res_y, -1, 1, hg.CF_Depth, hg.ColorI(32, 32, 32), 1, 0)
hg.SetView2D(1, 0, 0, res_x, res_y, -1, 1, hg.CF_Depth, hg.ColorI(32, 32, 32), 1, 0)

hg.DrawText(1, font, 'Hello world!', font_prg, 'u_tex', 0, hg.Mat4.Identity, hg.Vec3(res_x / 2, res_y / 2, 0), hg.DTHA_Center, hg.DTVA_Center, text_uniform_values, {}, text_render_state)

Expand Down
4 changes: 2 additions & 2 deletions draw_text_over_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@

# 3D view
viewpoint = hg.TranslationMat4(hg.Vec3(0, 1, -3))
hg.SetViewPerspective(0, res_x, res_y, viewpoint, 0.01, 5000)
hg.SetViewPerspective(0, 0, 0, res_x, res_y, viewpoint, 0.01, 5000)

hg.DrawModel(0, cube_mdl, shader, [], [], hg.TransformationMat4(hg.Vec3(0, 1, 0), hg.Vec3(angle, angle, angle)))
hg.DrawModel(0, ground_mdl, shader, [], [], hg.TranslationMat4(hg.Vec3(0, 0, 0)))

# 2D view, note that only the depth buffer is cleared
hg.SetView2D(1, res_x, res_y, -1, 1, hg.CF_Depth, hg.ColorI(32, 32, 32), 1, 0)
hg.SetView2D(1, 0, 0, res_x, res_y, -1, 1, hg.CF_Depth, hg.ColorI(32, 32, 32), 1, 0)

hg.DrawText(1, font, 'Hello world!', font_prg, 'u_tex', 0, hg.Mat4.Identity, hg.Vec3(res_x / 2, res_y / 2, 0), hg.DTHA_Center, hg.DTVA_Center, text_uniform_values, [], text_render_state)

Expand Down
2 changes: 1 addition & 1 deletion game_mouse_flight.lua
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ while not keyboard:Down(hg.K_Escape) do
view_id, passes_id = hg.SubmitSceneToPipeline(view_id, scene, hg.IntRect(0, 0, res_x, res_y), true, pipeline, res)

-- draw 2D GUI
hg.SetView2D(view_id, res_x, res_y, -1, 1, hg.CF_Depth, hg.Color.Black, 1, 0, true)
hg.SetView2D(view_id, 0, 0, res_x, res_y, -1, 1, hg.CF_Depth, hg.Color.Black, 1, 0, true)
draw_circle(view_id, hg.Vec3(mouse_x, mouse_y, 0), 20, hg.Color.White) -- display mouse cursor

-- end of frame
Expand Down
2 changes: 1 addition & 1 deletion game_mouse_flight.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def update_chase_camera(target_pos):
view_id, passes_id = hg.SubmitSceneToPipeline(view_id, scene, hg.IntRect(0, 0, int(res_x), int(res_y)), True, pipeline, res)

# draw 2D GUI
hg.SetView2D(view_id, res_x, res_y, -1, 1, hg.CF_Depth, hg.Color.Black, 1, 0, True)
hg.SetView2D(view_id, 0, 0, res_x, res_y, -1, 1, hg.CF_Depth, hg.Color.Black, 1, 0, True)
draw_circle(view_id, hg.Vec3(mouse_x, mouse_y, 0), 20, hg.Color.White) # display mouse cursor

# end of frame
Expand Down
2 changes: 1 addition & 1 deletion imgui_basic.lua
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ while not hg.ReadKeyboard():Key(hg.K_Escape) do
end
hg.ImGuiEnd()

hg.SetView2D(0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.Color.Black, 1, 0)
hg.SetView2D(0, 0, 0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.Color.Black, 1, 0)
hg.ImGuiEndFrame(0)

hg.Frame()
Expand Down
2 changes: 1 addition & 1 deletion imgui_basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
hg.ImGuiText('Hello World!')
hg.ImGuiEnd()

hg.SetView2D(0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.Color.Black, 1, 0)
hg.SetView2D(0, 0, 0, res_x, res_y, -1, 1, hg.CF_Color | hg.CF_Depth, hg.Color.Black, 1, 0)
hg.ImGuiEndFrame(0)

hg.Frame()
Expand Down
2 changes: 1 addition & 1 deletion imgui_edit.lua
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ while not hg.ReadKeyboard():Key(hg.K_Escape) do
end
hg.ImGuiEnd()

hg.SetView2D(imgui_output_view, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, imgui_view_clear_color, 1, 0)
hg.SetView2D(imgui_output_view, 0, 0, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, imgui_view_clear_color, 1, 0)
hg.ImGuiEndFrame(imgui_output_view)

-- rendering frame
Expand Down
2 changes: 1 addition & 1 deletion imgui_edit.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@

hg.ImGuiEnd()

hg.SetView2D(imgui_output_view, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, imgui_view_clear_color, 1, 0)
hg.SetView2D(imgui_output_view, 0, 0, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, imgui_view_clear_color, 1, 0)
hg.ImGuiEndFrame(imgui_output_view)

# rendering frame
Expand Down
2 changes: 1 addition & 1 deletion imgui_mouse_capture.lua
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ while not hg.ReadKeyboard():Key(hg.K_Escape) do
end
end

hg.SetView2D(0, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, clear_color, 1, 0)
hg.SetView2D(0, 0, 0, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, clear_color, 1, 0)

hg.ImGuiSetNextWindowPosCenter(hg.ImGuiCond_Once)
hg.ImGuiSetNextWindowSize(hg.Vec2(700, 96), hg.ImGuiCond_Once)
Expand Down
2 changes: 1 addition & 1 deletion imgui_mouse_capture.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
else:
clear_color = hg.Color.Red if mouse.Down(hg.MB_0) else hg.Color.Black

hg.SetView2D(0, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, clear_color, 1, 0)
hg.SetView2D(0, 0, 0, res_x, res_y, -1, 0, hg.CF_Color | hg.CF_Depth, clear_color, 1, 0)

hg.ImGuiSetNextWindowPosCenter(hg.ImGuiCond_Once)
hg.ImGuiSetNextWindowSize(hg.Vec2(700, 96), hg.ImGuiCond_Once)
Expand Down
14 changes: 8 additions & 6 deletions physics_impulse.lua
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ ground_node = hg.CreatePhysicCube(scene, hg.Vec3(100, 0.02, 100), hg.Translation
clocks = hg.SceneClocks()

-- scene physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics:SceneCreatePhysicsFromAssets(scene)
physics_step = hg.time_from_sec_f(1 / 30)
physics_step = hg.time_from_sec_f(1 / 60)

-- main loop
keyboard = hg.Keyboard()
Expand All @@ -51,15 +51,17 @@ while not keyboard:Down(hg.K_Escape) do
dt = hg.TickClock()

if keyboard:Pressed(hg.K_I) then
physics:NodeWake(cube_node)
world_pos = hg.GetT(cube_node:GetTransform():GetWorld())
physics:NodeAddImpulse(cube_node, hg.Vec3(0, 2, 0), world_pos, physics_step)
physics:NodeAddImpulse(cube_node, hg.Vec3(0, 8, 0), world_pos)
end
if keyboard:Pressed(hg.K_F) then
physics:NodeWake(cube_node)
world_pos = hg.GetT(cube_node:GetTransform():GetWorld())
physics:NodeAddForce(cube_node, hg.Vec3(0, 2, 0), world_pos)
physics:NodeAddForce(cube_node, hg.Vec3(0, 8, 0), world_pos)
end

hg.SceneUpdateSystems(scene, clocks, dt, physics, physics_step, 1000)
hg.SceneUpdateSystems(scene, clocks, dt, physics, physics_step, 3)
hg.SubmitSceneToPipeline(0, scene, hg.IntRect(0, 0, res_x, res_y), true, pipeline, res)

hg.Frame()
Expand All @@ -70,4 +72,4 @@ hg.RenderShutdown()
hg.DestroyWindow(win)

hg.WindowSystemShutdown()
hg.InputShutdown()
hg.InputShutdown()
42 changes: 30 additions & 12 deletions physics_impulse.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
hg.WindowSystemInit()

res_x, res_y = 1280, 720
win = hg.RenderInit('Harfang - Physics Impulse', res_x, res_y, hg.RF_VSync | hg.RF_MSAA4X)
win = hg.RenderInit('Harfang - Physics Force/Impulse (Press space to alternate)', res_x, res_y, hg.RF_VSync | hg.RF_MSAA4X)

pipeline = hg.CreateForwardPipeline()
res = hg.PipelineResources()
Expand All @@ -32,32 +32,50 @@

lgt = hg.CreateLinearLight(scene, hg.TransformationMat4(hg.Vec3(0, 0, 0), hg.Vec3(hg.Deg(30), hg.Deg(59), 0)), hg.Color(1, 1, 1), hg.Color(1, 1, 1), 10, hg.LST_Map, 0.002, hg.Vec4(2, 4, 10, 16))

cube_node = hg.CreatePhysicCube(scene, hg.Vec3(1, 1, 1), hg.TranslationMat4(hg.Vec3(0, 2.5, 0)), cube_ref, [mat], 2)
cube_node = hg.CreatePhysicCube(scene, hg.Vec3(1, 1, 1), hg.TranslationMat4(hg.Vec3(0, 1.5, 0)), cube_ref, [mat], 2)
ground_node = hg.CreatePhysicCube(scene, hg.Vec3(100, 0.02, 100), hg.TranslationMat4(hg.Vec3(0, -0.005, 0)), ground_ref, [mat], 0)

clocks = hg.SceneClocks()

# scene physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics.SceneCreatePhysicsFromAssets(scene)
physics_step = hg.time_from_sec_f(1 / 30)
physics_step = hg.time_from_sec_f(1 / 60)

# main loop
keyboard = hg.Keyboard()

use_force = True

while not keyboard.Down(hg.K_Escape):
keyboard.Update()

dt = hg.TickClock()

if keyboard.Pressed(hg.K_I):
world_pos = hg.GetT(cube_node.GetTransform().GetWorld())
physics.NodeAddImpulse(cube_node, hg.Vec3(0, 2, 0), world_pos, physics_step)
if keyboard.Pressed(hg.K_F):
world_pos = hg.GetT(cube_node.GetTransform().GetWorld())
physics.NodeAddForce(cube_node, hg.Vec3(0, 2, 0), world_pos)
if keyboard.Pressed(hg.K_Space):
use_force = not use_force

world_pos = hg.GetT(cube_node.GetTransform().GetWorld())
dist_to_ground = world_pos.y - 0.5

if dist_to_ground < 1.0:
k = -(dist_to_ground - 1.0)

if use_force:
F = hg.Vec3(0, 1, 0) * k * 80 # apply a force inversely proportional to the distance to the ground
physics.NodeAddForce(cube_node, F, world_pos)
else:
stiffness = 10

cur_velocity = physics.NodeGetLinearVelocity(cube_node)
tgt_velocity = hg.Vec3(0, 1, 0) * k * stiffness # compute a velocity that brings us to 1 meter above the ground

I = tgt_velocity - cur_velocity # an impulse is an instantaneous change in velocity
physics.NodeAddImpulse(cube_node, I, world_pos)

physics.NodeWake(cube_node)

hg.SceneUpdateSystems(scene, clocks, dt, physics, physics_step, 1000)
hg.SceneUpdateSystems(scene, clocks, dt, physics, physics_step, 3)
hg.SubmitSceneToPipeline(0, scene, hg.IntRect(0, 0, res_x, res_y), True, pipeline, res)

hg.Frame()
Expand All @@ -67,4 +85,4 @@
hg.DestroyWindow(win)

hg.WindowSystemShutdown()
hg.InputShutdown()
hg.InputShutdown()
6 changes: 3 additions & 3 deletions physics_kapla.lua
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,9 @@ cam_pos = hg.Vec3(28.3, 31.8, 26.9)
cam_rot = hg.Vec3(0.6, -2.38, 0)

-- setup physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics:SceneCreatePhysicsFromAssets(scene)
physics_step = hg.time_from_sec_f(1 / 50)
physics_step = hg.time_from_sec_f(1 / 60)

-- main loop
while not keyboard:Down(hg.K_Escape) do
Expand All @@ -114,7 +114,7 @@ while not keyboard:Down(hg.K_Escape) do
if keyboard:Pressed(hg.K_Space) then
node = hg.CreatePhysicSphere(scene, 0.5, hg.TranslationMat4(cam_pos), sphere_ref, {mat_spheres}, 0.5)
physics:NodeCreatePhysicsFromAssets(node)
physics:NodeAddImpulse(node, hg.GetZ(cam:GetTransform():GetWorld()) * 50.0, cam_pos, physics_step)
physics:NodeAddImpulse(node, hg.GetZ(cam:GetTransform():GetWorld()) * 25.0, cam_pos)
end

hg.SceneUpdateSystems(scene, clocks, dt, physics, physics_step, 1)
Expand Down
6 changes: 3 additions & 3 deletions physics_kapla.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ def fill_ring(r, ring_y, size, r_adjust, y_off):
cam_rot = hg.Vec3(0.6, -2.38, 0)

# setup physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics.SceneCreatePhysicsFromAssets(scene)
physics_step = hg.time_from_sec_f(1 / 50)
physics_step = hg.time_from_sec_f(1 / 60)

# main loop
while not keyboard.Down(hg.K_Escape):
Expand All @@ -106,7 +106,7 @@ def fill_ring(r, ring_y, size, r_adjust, y_off):
if keyboard.Pressed(hg.K_Space):
node = hg.CreatePhysicSphere(scene, 0.5, hg.TranslationMat4(cam_pos), sphere_ref, [mat_spheres], 0.5)
physics.NodeCreatePhysicsFromAssets(node)
physics.NodeAddImpulse(node, hg.GetZ(cam.GetTransform().GetWorld()) * 50.0, cam_pos, physics_step)
physics.NodeAddImpulse(node, hg.GetZ(cam.GetTransform().GetWorld()) * 25.0, cam_pos)

hg.SceneUpdateSystems(scene, clocks, dt, physics, physics_step, 1)
hg.SubmitSceneToPipeline(0, scene, hg.IntRect(0, 0, res_x, res_y), True, pipeline, res)
Expand Down
2 changes: 1 addition & 1 deletion physics_manual_setup.lua
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ cube_node:SetRigidBody(rb)
cube_node:SetCollision(0, collision)

-- scene physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics:SceneCreatePhysicsFromAssets(scene)

-- main loop
Expand Down
2 changes: 1 addition & 1 deletion physics_manual_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
cube_node.SetCollision(0, collision)

# scene physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics.SceneCreatePhysicsFromAssets(scene)

# main loop
Expand Down
2 changes: 1 addition & 1 deletion physics_overrides_matrix.lua
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ ground_node = hg.CreatePhysicCube(scene, hg.Vec3(100, 0.02, 100), hg.Translation
clocks = hg.SceneClocks()

-- scene physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics:SceneCreatePhysicsFromAssets(scene)

-- main loop
Expand Down
2 changes: 1 addition & 1 deletion physics_overrides_matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
clocks = hg.SceneClocks()

# scene physics
physics = hg.SceneNewtonPhysics()
physics = hg.SceneBullet3Physics()
physics.SceneCreatePhysicsFromAssets(scene)

# main loop
Expand Down
Loading

0 comments on commit 3038f18

Please sign in to comment.