GothicKit / ZenKit

A re-implementation of file formats used by the early 2000's ZenGin
http://zk.gothickit.dev/
MIT License
49 stars 9 forks source link

[v1.1.0] `vobs::trigger_mover` keyframes are not parsed correctly #39

Closed lmichaelis closed 2 years ago

lmichaelis commented 2 years ago

Keyframes consist of a position and a rotation stored as a quaternion. Currently the rotation is parsed as a glm::mat4 and then converted to a glm::quat which is not correct.

https://github.com/lmichaelis/phoenix/blob/ffe0c0fa28a7e36181dd93d072b037ed4630b67f/source/vobs/trigger.cc#L38-L41

It should be parsed as a quaternion directly. The component order is w, x, y, z.

Source: Try/OpenGothic#362