StOneDOes Posted Sunday at 03:13 AM Share Posted Sunday at 03:13 AM If I disable physics on my player controller (by GetEntity()->SetPhysicsMode( PHYSICS_DISABLED ) ), is there a way that I can now use SetPosition() on it to move it around for something like climbing a ladder? Because the SetPosition() function seems to have no effecf after disabling physics. Should this work? I'm pretty sure I'm not doing anything else that is grounding the player controller, given that jumping works just fine when the physics are enabled. Quote Link to comment Share on other sites More sharing options...
Dreikblack Posted Sunday at 03:57 AM Share Posted Sunday at 03:57 AM Try to do GetEntity()->Sync() after using SetPosition() Quote Link to comment Share on other sites More sharing options...
StOneDOes Posted Sunday at 05:00 AM Author Share Posted Sunday at 05:00 AM Unfortunately this did not help. Do you think there could be a bug in this? Quote Link to comment Share on other sites More sharing options...
Dreikblack Posted Sunday at 05:02 AM Share Posted Sunday at 05:02 AM idk, it used to work: player:SetPhysicsMode(PHYSICS_DISABLED) player:SetPosition(newPosition) player:Sync() player:SetPhysicsMode(PHYSICS_PLAYER) Quote Link to comment Share on other sites More sharing options...
StOneDOes Posted Sunday at 06:51 AM Author Share Posted Sunday at 06:51 AM I gave that a go as well, but still couldn't get it working. I'll keep at it and see if I can figure something out. Might report it as a bug. Quote Link to comment Share on other sites More sharing options...
Solution StOneDOes Posted Sunday at 07:39 AM Author Solution Share Posted Sunday at 07:39 AM Ok this is just my own mistake. Simply disabling physics on the entity is all that needs to be done. My camera is not being correctly updated here. Thanks for your help. Quote 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.