add inertia & update drop visuals

This commit is contained in:
MihailRis
2024-10-27 17:47:19 +03:00
parent b93668ba94
commit a4cf1e4820
2 changed files with 14 additions and 6 deletions
+1 -3
View File
@@ -36,9 +36,7 @@ end
function on_grounded(force)
local matrix = mat4.idt()
mat4.rotate(matrix, {0, 1, 0}, math.random()*360, matrix)
if model == "aabb" then
mat4.rotate(matrix, {1, 0, 0}, 90, matrix)
end
mat4.rotate(matrix, {1, 0, 0}, 90, matrix)
mat4.scale(matrix, scale, matrix)
rig:set_matrix(0, matrix)
inair = false