Metroid style enemy

0 favourites
  • 3 posts
From the Asset Store
Slot Machine Games. suitable for workers who work from home because it has player names that must be played alternately
  • Hi! I'm stuck with probably the simpliest thing in the world, but stuck nonetheless.

    I need an enemy that walks on a regular solid surface but, when it hits a wall, it starts climbing it. And the same gones when it hits the ceiling. it should start walking on it. No matter what I do, I screw up with the angles and the character does all kinds of weird things.

    At the same time, I need that when the enemy stops having a solid floor under it's feet, he should descend from the border, in a very metroidish style.

    Thanks in advance. Any help will be really welcome.

  • You can define a path - say, with small invisible sprites for each point. Use MoveTo behavior to move from one point to another. Set angle to angle(startX, startY, endX, endY)+90 when the enemy is moving to the left or "-90" when moving to the right.

    The more universal solution where enemies can walk around any solid object would require more efforts. You can make your enemy to walk around sprites (demo, capx) . But you'll also need some way to determine where the enemy should stop and turn around or descend to the floor. Maybe again put an invisible sprite, on collision with which the enemy will change direction or descend.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You can define a path - say, with small invisible sprites for each point. Use MoveTo behavior to move from one point to another. Set angle to angle(startX, startY, endX, endY)+90 when the enemy is moving to the left or "-90" when moving to the right.

    The more universal solution where enemies can walk around any solid object would require more efforts. You can make your enemy to walk around sprites (demo, capx) . But you'll also need some way to determine where the enemy should stop and turn around or descend to the floor. Maybe again put an invisible sprite, on collision with which the enemy will change direction or descend.

    Thank you!! The capx example is exactly what I needed.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)