change my character when colliding with an actor (resolved)

Hello, I would like to know if my character (dwarf Mario) who is a character can change character (normal Mario) when colliding with the mushroom

cap4

You can’t actually change the character. You have to spawn the new one, posses it, and destroy the old one.

It’s also a bit more complicated than that, because you can’t spawn the new one where the old one is, because of collisions. There are various solutions for that.

Is it really a new character you need, or do things just need to look different?

1 Like

You could also change the mesh. But replacing the entire pawn is also an option.

1 Like

Yes, you can change the characters. it would be ideal

Then you need to

  1. Turn off the collision on the current player
  2. Spawn the new player and possess
  3. Destroy the old player

I think that should work :slight_smile:

Yes, it is an option but you saw that the two marios have different morphology. The dwarf is more stubborn and the normal one is more sterilized. If dwarf Mario grows up he would look like a big headed Mario

It looks interesting, what would it be like graphically? I’m a bit of a novice :laughing:

Something like this maybe ( untested )

( This code is in the current player )

1 Like

great, it turned out perfect, thank you

1 Like