IsFalling Function not working properly on 2d project

Hi I want to use IsFalling functionality from FloatingMovementComponent, but somehow function returns always false.
Do I need to add volume?

GetMovementComponent()->IsFalling()

I could only get answer about courses?

You would have to wait longer and see if someone can answer it or help you.

But you can search more as well for example IsFalling in C++ and see if that will help you.

You assume that, I never search widely and came here.
Basically its unreal bug, when you try to use function isfalling or isflying in pawn movements.
Its working nice with only character class implementation and its component.
So basically even if you had isfalling in your movement component, no its not working.

The reason why I assumed that is that UFloatingPawnMovement doesn’t appear to support that.

“gravity is not implemented.”

If gravity is not implemented for what you’re doing then how can what you’re doing ever fall? Falling requires gravity.

Someone can correct me if I’m wrong but its just like expecting USpectatorPawnMovement to also have IsFalling() when probably its beyond its use.


.UActorComponent <----
…UMovementComponent <----
… UNavMovementComponent
… UPawnMovementComponent
… UFloatingPawnMovement <----
… USpectatorPawnMovement <----

UNavMovementComponent contains the IsFalling() function. The function cannot return true if other parts that it needs for returning true do not happen.

If it always returns false then its probably because of what you’re doing is beyond its use.

You may only have two choices, create your own custom code or change your approach.

If that still doesn’t work for you then I can’t for the life of me figure out what you’re trying to do lol.

"FloatingMovementPawn is essentially used for the Spectator cam, and not for an actual character used in-game.

Try CharacterMovementComponent with MovementMode set to Flying."

"For simpler elements that would just need to be driven around the scene by AI, for example, you can generally get away with using a Pawn. "

“You will notice that we mention two potential classes here: Pawn and Character. Both are used for entities in the game that are either controlled by the player or by in-game AI. The key difference is that the Character class is an extension of the Pawn class, adding in player physics, support for a specific mesh, and the general types of handling needed when creating a playable in-game character.”

2 Likes

Thats is the expansion of problem, very good in detail.
But my pawn is bouncing ball. It’s bouncing nicely on ground, it has gravity and simulating physics.
Currently couldnt find a way but thanks for narrowing my search.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms