my actor has no physics (resolved)

Hello, I created an actor (pawn) where it moves alone, that is fine, but it only floats and does not collide with anything, how can I solve that?

cap3

cap4

Can we see the pawn hierarchy? All that is needed to move a pawn → right ->, with physics included:

Are you sure you want physics here? Do you mean gravity?


image

Don’t use both. Stick with the movement Input only.

It sends me that error: “Invalid Simulate Options: Body (Hongo1.Hongo Hongo) is set to simulate physics but Collision Enabled is incompatible”

It probably means the mesh asset has no collision or the collision is disabled. Or the collision is set to overlapping. For physics to work, you need blocking collision.

Share the component hierarchy and collision settings of the Pawn’s root element if you need more help.

I did a test with a sphere and the physics occurs but it doesn’t move forward.

cap5

The static mesh is in the wrong place in hierarchy, compare it to mine. Drag it to the root.

1 Like

I stayed very well

cap6

but there is a problem when I use it to get it out of the box

That’s when I add the collision to the mushroom.

cap1

There the physics is general but it is seen that it collides with the box and generates the error

this is in the box

this in the mushroom

here when I play without physics

cap2

and here with physics

cap7

this is the error text

Blueprint Runtime Error: “Attempted to access Hongo1_C_0 via property Hongo, but Hongo1_C_0 is not valid (pending kill or garbage)”. Node: Set Actor Location Graph: EventGraph Function: Execute Ubergraph Caja Acertijo Poder Blueprint: Caja_acertijoPoder

It is quite possible Hongo never spawns as you spawn it inside the cube. The spawn actor node has an override for that but that’s not a great solution.

What I’d do, I’d change the collision of the spawned actor in such a way that it does not interfere with the box until the timeline has finished playing.

Would you show me what it would be like? I never changed collisions in time

1 Like

The cube:

Its Object Type is set to :red_circle: WorldStatic. It blocks :yellow_circle: Tracing and :large_blue_circle: Object Responses (collision) of other types listed below.

Hongo’s collider:

It blocks anything that is :large_blue_circle: World Static - like the cube’s :red_circle: World Static object type. In short: cube’s word static responds to the pawn’s world static by blocking it:

If I change the Hongo’s collision to overlapping against World Static types:

Hongo will Overlap them, they can easily spawn inside of it, and hop out of it, no problems. But he cannot stand on it… That’s where your Timeline comes in. When it Completes, we can restore Hongo’s collision:

image

They are now blocking World Static as soon as they pop out of the box.

Quick summary:

  • in Hongo’s BP, set the :large_blue_circle: Object Responses to Overlap or Ignore the Object Type of the box
  • when the Timeline completes, use the Set Collision Response to Channel node to Block it

The above gives you a lot of granularity regarding who blocks whom and responds to what, when and how. You can (and often should) add more channels and object types (last link at the bottom of this post). For example: when Mario shoots projectiles, they should not be able to accidentally hit him. Understanding Collision Filtering would allow you to efficiently set that up.


tl;dr: alternatively:

  • disable collision on the pawn initially:

  • and then enable it when needed:

This is pretty ham-fisted, though. Having a decent grasp on how the channels work pays off in the long run. Decide for yourself if you’re into this for the long run or just doing homework. :innocent:


More reading:

2 Likes

Hey. I think here is simple decision. Just make box mesh without top. From side view nobody see it. And. Not forget make collision repeating the shape, not standard. What’s it called? Just double-click on the actor’s blueprint and you’ll figure it out.

1 Like

Hello, very good information, I really liked it but it’s not working for me yet, I don’t know what I’m doing wrong but the champion keeps colliding with the box

cap3

that’s the box

that’s the championship

image

This looks like some additional collision box… Either use a mesh to block or the collision box. Don’t use both. I mean, you can, but then you’d need to do everything twice.

1 Like

It already crosses the box but falls on me :smile:
There is physics but it does not follow its path

cap5

here in the box

and add the node here

  • you are still using 2 colliders. The mesh and the collision box. Don’t. Or adjust both. You’re overcomplicating things. Or don’t even touch the box. We only care about Hongo’s collision.

image

  • looks like the TL offset (80) is not enough (at a glance, at least)

Also:

This makes no sense. We are changing the collision of Hongo, not the cube.

  • hongo spawns inside the cube with no collision
  • hongo goes to the top → enable hongo’s collision

This Lil’ But Very Copyrighted :registered: Dude :tm: :

Change his collision.

1 Like

Yes, but you have to know that Mario can also step on the box.

I think we are close. I put in the championion as a non-collision and it came out of the box and held up with the physics, it shows. but unfortunately it is not progressing

cap11

1 Like

Hongo:

image

It’s probably because of no controller.


championion

Unrelated, I thought you were saying champion but you’re saying mushroom, right?

1 Like

yes jaja :smile:

brilliant!!! it worked. thank you so much

cap12

1 Like