mirror of
https://github.com/appgurueu/modlib.git
synced 2024-11-22 07:13:45 +01:00
Fix quaternion.from_euler_rotation
This commit is contained in:
parent
002d1e187b
commit
d1a285be33
@ -12,9 +12,9 @@ function from_euler_rotation(rotation)
|
||||
local cos = vector.apply(rotation, math.cos)
|
||||
local sin = vector.apply(rotation, math.sin)
|
||||
return {
|
||||
sin.z * cos.x * cos.y - cos.z * sin.x * sin.y,
|
||||
cos.z * sin.x * cos.y + sin.z * cos.x * sin.y,
|
||||
cos.z * cos.x * sin.y - sin.z * sin.x * cos.y,
|
||||
sin.z * cos.x * cos.y - cos.z * sin.x * sin.y,
|
||||
cos.z * cos.x * cos.y + sin.z * sin.x * sin.y
|
||||
}
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user