nduart's Recent Forum Activity

  • Ah, that did the trick. Thanks! I was overthinking it, as usual.

  • I've got a pretty simple platformer, and I'm trying to get my enemy AI to patrol back and forth on the platform, without walking off the side. The best solution I have found thus far is to place invisible walls that, on overlap with the enemy sprite, trigger the sprite to walk the other direction (I'm using an instance variable for this: Patrol = 0 => simulate control right, Patrol = 1 => simulate control left). However, with a lot of enemies on a lot of platforms, that's a lot of invisible walls to build and keep track of.

    So basically, I'm trying to cheat a lil bit :/

    I created two image points on my enemy sprite, located just outside the collision polygon, and just below, on either side. I named them "floordetectorright" and "floordetectorleft". The issue I'm having is that I can't find a way to reference these image points in a condition. My goal is something like:

    floortile is NOT overlapping point (sprite.imagepointX("floordetectorright"), sprite.imagepointY("floordetectorright")) => set patrol to 1

    The above would check whether the floor detector image point is overlapping with the floor, and if it isn't, it would trigger a change in direction. However, I'm not really seeing a way to do this. I tried messing around with Pick Object Overlapping Point, but that didn't seem to work.

    Any ideas? Or should I start building a fortress of invisible walls?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • plinkie - That did the trick! Thank you

  • I feel like this should be really simple, but it doesn't really seem to be... at least not to my dumb noob self :/.

    I've got a pretty simple 2D platformer, in which the ground tiles are destructible so that the player can carve his way through the world (similar to Oxygen Not Included but waaaaaay simpler). The issue I'm having is that whenever I try to use the "Cursor is Over Object" condition to change the tile to the "highlighted" animation, it highlights all tiles of the same type that the cursor moves over, until it moves over a different tile type.

    My event sheet is roughly:

    Cursor Is Over "tile_land" > set "tile_land" animation to "highlighted"

    Negated Cursor Is Over "tile_land" > set "tile_land"animation to "Default"

    However, when there are two land tiles right next to each other, and you move the cursor over both, it highlights both tiles, and only unhighlights those tiles when you move the cursor over empty space. I've tried using the "Trigger Once" condition, but all that does is highlight only the first tile and no like tiles the cursor moves over afterwards.

    Basically, I want the cursor to highlight one and only one tile at a time, and that's the tile that it is currently hovering over, but I can't seem to figure how. I tried screwing around with instance variables and UIDs, and I think I just gave myself acute dyslexia, so any help is very much appreciated.

nduart's avatar

nduart

Member since 30 Jun, 2017

None one is following nduart yet!

Trophy Case

  • 7-Year Club
  • Email Verified

Progress

8/44
How to earn trophies