Rotating an object 45 degrees, plus & minus, in blueprint.
Hi! Thanks in advance to anyone that can help.
As you can see below i have a blueprint attached to cylinder and i'm trying to press a button to rotate it 45 degrees on one angle but to rotate it -45 degrees on the same angle if another button is pressed (though i'm sorting it out so that the two cannot be pressed at the same time or during rotation, it's very hacky atm).
i used this solution as a reference to what i'm trying to do https://answers.unrealengine.com/questions/35356/rotate-an-object-over-time-when-pressing-a-key.html but the issue is when i try to go activate Q rotation to rotate opposite E nothing happens. i've messed around with what i thought might be the issue, but nothing seems to get my object to rotate the opposite way by 45 degrees. if anyone has any suggestions (and improvement advice would be great too!) then i'd be all ears, though i must ask if you could explain your changes clearly as blueprint is new to me (and a bit alien) so stuff like custom functions go right over my head unless explained.
Thanks for your time!
asked Mar 24 '15 at 09:20 PM in Blueprint Scripting
No need to make this complicated actually. Right click anywhere and click on "add timeline" this would create a special type of node that would play for a duration, that can loop and gradually affect values. WHen you double click it you will be greeted with the timeline. Click on the "f+" button to create a float value that's changing over time. Shift+clicking creates points for this variable. You can then go back to the event graph and see that now your timeline has a float in put use this in combination with the execution pin to achieve what you want.
answered Mar 25 '15 at 11:54 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here