beo6 Posted February 8, 2014 Share Posted February 8, 2014 In the Documentation quaternion is documented as a entity attribute. However it has Vec3 as Type? Is that really correct? Also i wasn't successful even getting the quaternion value of an entity: System:Print("entity quaternion:"..self.entity.quaternion:ToString()) --------------------------- Error --------------------------- attempt to index field 'quaternion' (a nil value) --------------------------- OK --------------------------- Quote Link to comment Share on other sites More sharing options...
Josh Posted February 8, 2014 Share Posted February 8, 2014 The quat class is not exposed to Lua because it is only used for internal rotations. I've removed that member from the documentation. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
beo6 Posted February 8, 2014 Author Share Posted February 8, 2014 wait wait. its ok when you remove the attribute of the entity. But removing the whole Quat class is a bit too much. And also it seems to work creating a Quat in lua. And how are we supposed to make something like this without a Quat? http://www.leadwerks.com/werkspace/topic/8487-question-about-physic/page__st__20#entry66616 Quote Link to comment Share on other sites More sharing options...
Josh Posted February 8, 2014 Share Posted February 8, 2014 Well, I used the quat class in one place in the FPS Player script: self.carryrotation = Transform:Rotation(pickInfo.entity:GetQuaternion(true),nil,self.camera) Since I used it, that means it is part of the official supported API and it should be documented. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Roland Posted August 19, 2015 Share Posted August 19, 2015 Well, I used the quat class in one place in the FPS Player script: self.carryrotation = Transform:Rotation(pickInfo.entity:GetQuaternion(true),nil,self.camera) Since I used it, that means it is part of the official supported API and it should be documented. So after 5 months it is still not documented. Maybe time to .. Quote Roland Strålberg Website: https://rstralberg.com Link to comment Share on other sites More sharing options...
beo6 Posted August 19, 2015 Author Share Posted August 19, 2015 5 Months? Which Year do you live in? Quote Link to comment Share on other sites More sharing options...
Roland Posted August 19, 2015 Share Posted August 19, 2015 Oh my good. It was even worse. Its one year and five months Quote Roland Strålberg Website: https://rstralberg.com Link to comment Share on other sites More sharing options...
Josh Posted August 19, 2015 Share Posted August 19, 2015 Entity:SetQuaternion, Entity:GetQuaternion, and Transform:Rotation() are the only relevant commands. 1 Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
beo6 Posted August 19, 2015 Author Share Posted August 19, 2015 Entity:SetQuaternion is not documented Entity:GetQuaternion is not documented that Transform:Rotation() accepts Quaternions is not documented. i guess these are the points from Roland. Quote Link to comment Share on other sites More sharing options...
Josh Posted August 19, 2015 Share Posted August 19, 2015 I am saying these are not very useful or important. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
beo6 Posted August 19, 2015 Author Share Posted August 19, 2015 then either no one want to align stuff to the terrain like here: http://www.leadwerks.com/werkspace/topic/8487-question-about-physic/page__st__20#entry66616 or i am just too stupid to find the Leadwerks own function to do that. I really hope it is the second option. Quote Link to comment Share on other sites More sharing options...
Josh Posted August 19, 2015 Share Posted August 19, 2015 You have a point that Slerp() can be useful. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Josh Posted August 20, 2015 Share Posted August 20, 2015 Okee-dokee, here it is: http://www.leadwerks.com/werkspace/page/api-reference/_/quat/ Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.