MindBeams's Recent Forum Activity

  • To correct myself: I think I understand.

    The arrow keys are placed onscreen initially, and I've set the UI layer to not scroll away. This was to keep the arrow keys visible at the same place no matter where in the game you are.

    With the "Snake detected!" message also being on that layer and having its initial placement too far offscreen to see, you can't walk over to it to see; just like the arrow keys, it always retains its position relative to the viewport since I've turned off paralax. So in essence, it was working as intended, but I didn't realize that the layer was forcing it to always stay out of range of the viewport.

    Many thanks, lionz! I don't know if I would have figured this out on my own!

  • Move it to the ingame layer and increase the range, 20 is too low and doesn't stretch past the player object. Make it something more reasonable in front of the player to detect the snake.

    That seems to have done it! I must admit I don't quite understand why being on the UI layer renders the text action invisible but not the arrow key buttons, but I can look into that.

    Thank you very much for your help!

    And thanks to you as well, oosyrag, for your contribution earlier.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • It's because the text is not in the position you think it is, you've put it on the UI paralax layer so it is always off screen, move it to the Game layer.

    I'm afraid moving it to the InGame layer is also not fixing the issue.

  • The action is not triggered regardless of how big the range is. For example, 2,000 and 20,000 also don't work.

  • Find the project file here. This question regards the "InGame" layer and event sheet.

    I am attempting to use the player sprite's Line of Sight behavior to trigger an action. In this case, just for testing, it should make the text "Snake detected!" appear on the screen:

    However, this action is not triggering. This is a snapshot of the behavior's settings:

    And here is a snapshot of the relevant event on the event sheet:

    I have attempted the following to see if anything would help, but nothing has worked:

    • Making sure the origin point of the snake sprite is in the middle for all of its animation frames.
    • Making sure the snake and the player are on the same layer within the layout.
    • Switching between "solids" and "custom" within the Line of Sight settings, just in case that made a difference.

    No matter what settings I change, the action does not trigger.

    I would appreciate any help on this matter!

    Tagged:

MindBeams's avatar

MindBeams

Member since 27 Jan, 2023

Twitter
MindBeams has 1 followers

Trophy Case

  • 1-Year Club
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

4/44
How to earn trophies