lionz's Recent Forum Activity

  • This is why I shouldn't answer posts before coffee, also I misread what was wanted, I don't even use that method at all. I normally use Pick overlapping object > jackhammer overlapping rock.imagepointx, rock.imagepointy.

  • You can use jackhammer is overlapping at offset rock > offset x is jackhammer.imagepointx, offset y is jackhammer.imagepointy

  • If they are on the same layer then look at Z order : https://www.scirra.com/manual/157/z-order-bar

  • You probably want the condition:

    Is on-screen

    True if any part of the object's bounding box is within the screen area. This is not affected by the object's visibility or opacity.

  • Have you tried it? Seems like you already know what you're doing.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Yes, look at layers... https://www.scirra.com/manual/85/layers

  • heyguy np

    MatheusCastellar sorry, debug masterer. You put more effort in with a screenshot though

  • Because of the way you've set this up it's always picking the closest movement square on screen to the player regardless of which enemy it's next to. You'll have to do some checks for each enemy pick the closest movement square to the enemy that is also the closest to the player.

  • Mmmm I like this answer.

  • Yeah similar thing, the important factor is it's only possible to move to one of the 8 squares surrounding you, that's what I wanted to confirm. There's a few ways to do it I guess but I setup this kind of detection for when I had to stamp down rides in a roller coaster tycoon type thing. I had the centre object have a square attached that is slightly bigger than the square it is on. This then overlaps the 8 surrounding squares slightly. Then you put in events to say that the squares it is overlapping are 'clickable', you could change the opacity of the clickable squares for debug purposes to see what is clickable. Then you have a check for when clickable square is clicked, move player to here. That should just work. You'd obviously have to put in some checks so that the middle square cannot be accepted too and fix some other minor bugs around it during gameplay.

  • if it's player health then use a global variable, that way it is just consistent across the game. If it's any other health such as enemy HP then you're unlikely to need it between layouts.

  • What do you mean, so you are in the middle of a 3x3 grid and you can only move to one of the 8 squares around you at a time and to do this you click on it then you move to that square?

lionz's avatar

lionz

Online Now

Member since 5 Aug, 2013
Last online 16 Jan, 2025

Twitter
lionz has 72 followers

Trophy Case

  • 11-Year Club
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Forum Wizard Made 5,000 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • Unrelenting Visitor Visited Construct.net 180 days in a row
  • Continuous Visitor Visited Construct.net 365 days in a row
  • RTFM Read the fabulous manual
  • Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

24/44
How to earn trophies