Hi, I’m tring to create a movement system for a space schip. I chek the “Use Controller Rotation Yaw” in the Class Deafaults Deatails tab so the ship rotate with the camera when I move the mouse. I’d also want add a tilt of the ship when the player turn left or right. I tried to do this adding a “SetActorRelativeRotation” node and connecting into its Roll input the Axis Value multiplied by another value that determinetes the tilt amount. But doing this the the ship make the same rotation every time i move the mouse. I’d want that the tilt is according with the mouse movement amount. Ther is a way to do this? Thanks!
that amount you multiply it by, you can set that to how much the mouse moved instead of just if its moving. you can find that by storing a variable in event tick to the mouse position (do this all the way at the end). and before that, subtract current mouse position from that variable
Thank you for answering! I tried to do as you said, but I think I did something wrong because it doesn’t work… So I add the Get Mouse Position node with target Player Controller then I saved as vriable the X Location output. This variable should give me the mouse position on X. Should I multiply the Axis Value by the mouse position?
you might consider using… Get Angular Rotation or Controller Yaw Input multiplied by an amount (called a scalar) plugged into Set Actor Location (to roll the whole spaceship, including the collision promitive and it’s components… I’d do it this way) or Set Relative Location (to roll the mesh) which you can tweak to suit the look you prefer.