Problem with trying to smoothly transition a zoom effect with blueprints

Sorry if this is messy I’m very new to blueprints and I am unsure of how to organize or what a good work flow organization looks like. I’ve only ever coded in syntax based languages so visual coding is new to me but I swear my logic is fine and it just gives me this error:

image

Why is this I am simply looping a condition to make a smooth transition for zooming in the player camera?

Having used blueprint for a number of years now, I don’t think I’ve EVER used a while node :slight_smile:

I mean, yes, I also tried in the beginning, coming from written languages.

The BP equivalent of what you’re trying there is

I have looked into the event tick node just wasn’t sure how it would work in this scenario. I am unfamiliar with the gate node and ill do further research in the API about it but this solution seems to work thanks!

1 Like

Hi Undead Developer,

I have a weird theory as to why it detects an infinite loop: Field of view will never be exactly ‘50’ (because of floating point strangeness the best it would be is like 49.9998) Therefore the condition for it to never loop would be infinite since it would never be 50. (I am open to criticism/debunking of this theory :-D)

On the topic of controlling FOV I want to share the way I do it with a timeline. The reason for the ‘RMB Down Time’ var is the timeline is really long (Initial fast zoom then slow zoom) so instead of it taking forever to reverse the FOV, if you’ve been holding RMB for more than .5 seconds it will pop you back to start of curve)

Welcome to the Forums!

Just gotta watch how much you hang on tick, that’s all…