Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Event Touch Trigger

What it the purpose of the event touch trigger? I have a puzzle in my game that has a switch that, conveniently enough, you aren't heavy enough to push down, so yo need to move a boulder onto it. I THOUGHT that this was what the event touch trigger was for, so I made an event with three pages, the first page has a player touch trigger, the second page has the event touch trigger, and the third is for after you activate it, it has a self switch trigger, and is just a graphic of a pushed down switch.

Here's the problem: The second event page (the one with the event touch trigger) fires when the player touches the event, not when another event does.

So, in short, what is the purpose of the event touch trigger, and if this is not what it is for, how would i go about getting the puzzle i described to work. I would post screens, but my internet is going really slow today cuz of cloudy skies.
 
The Event Touch trigger is not when two events touch, but rather when an event touches a Player.

Keeping this in mind, there are several problems with your event:
1. You have two event pages with no Conditions. Events don't work this way. They can only be on one page at a time; this page is chosen by the highest page # with all conditions met. So in this case, only your 2nd page would activate.
2. Event Touch won't work for what you have in mind.

To remedy these two problems, you should use a new Parallel Processing event instead. In the event, assign an X and a Y value to two different variables, then check if they equal the event's coordinates in a Conditional Branch. If so, turn on a switch that activates when the switch is pushed down.

Now, create the switch event as you normally would, on a Player Touch turning on a self-switch. You can have a text command/whatever you want to activate when the player steps on it. Then have a third page with the Condition switch from the PP event, and have a door open, a passage unlocked, etc.

Hope this was helpful. Good luck with it, Typhius :thumb:
 
I'm not completely sure about the "event touch trigger" thing, I've never used it myself and not quite sure what it does. However, I know a way you can do the boulder puzzle thing. You'd need to use conditional branches and variables.

You'd have to set what the X and Y positions of the boulder are. Now of course you'd be able to move the boulder (I'm guessing you already know how to do that). You could make a common event or a parallel process event on that map that would check the boulder's X and Y positions and record them in a variable. Example: (this would be a parallel process or common event)
Code:
@>Control Variables: [0001: Boulder X] = [Boulder Event]'s Map X
@>Control Variables: [0002: Boulder Y] = [Boulder Event]'s Map Y

Now, for the switch, you could have on that event page this conditional branch: (for now let's just say the switch's coordinates are say...004, 007)
Code:
@>Conditional Branch: Variable [0001: Boulder X] == 4
   @>Conditional Branch: Variable [0002: Boulder Y] == 7
      @>Control Self Switch: A =ON
      @>
    :  Branch End
   @>
 :  Branch End
@>
I think that should help. If it doesn't work just tell me and I'll try to be of assistance.
 
Well, i waited for a half hour, but i finally got photobucket to load up so i could post a screen. Honestly, you guys did help me with a separate puzzle in my game, but not the current one. As you can see in the picture, there are many many different boulders that can be put on the switch. So, i'm afraid none of your suggestions will work unless modified :(
http://i521.photobucket.com/albums/w336/Typhius/BoulderPuzzle.jpg[/img]
Sry for makin you guys give me answers to the wrong question, i didn't think it would matter that i intended for multiple solutions to the puzzle.
This puzzle wasn't intended as an escape from the room puzzle. It was merely a bonus room with extra goodies for the player.
SIDE QUESTION: Through testing this, i realized that it is possible to move the boulders in such a way that it prevents the player from successfully moving them onto the switch, thus preventing him from resetting the room. Is there an event command that can simply re-load the current map? Or would it require some complicated process?
 
Heh, well, our methods COULD work, if you used two variables for each boulder and checked all 17 events' coordinates.

About your side question, if you leave the room, the locations will automatically reset. You can try a fade to black (Change Screen Color Tone), transfer to a new map, transfer back, then tint the screen back to normal to make the positions reload.
 
Regi":3sh45v4y said:
Heh, well, our methods COULD work, if you used two variables for each boulder and checked all 17 events' coordinates.

I suppose that would work...still, do you know of any ways that are simpler than that?  If that is the simplest way to do it, ill just change one of the boulder's graphics to rock 2 (the giant lead ball thing) and make that the rock the player HAS to put on the switch.
 
Sorry, I don't know a simpler way to do it (without scripting), but I know a method that saves variables, if you'd care to find out. Just use "$game_map.events[id].x == x && $game_map.events[id].y == y" in a Conditional Branch and replace id, x, and y with the right values.
 
@Regi: hmm...i could put that to good use actually, even though its just an alternative to setting each variable individually.

On topic: Thanks for the help everyone, my puzzle is done now, i just replaced one rock with another graphic, made it the one you HAD to put on the switch. (posted this earlier, so look up a few posts) Nonetheless, thanks for the help!
@Unka: I read you tut, and it was very informative, thanks for posting it here!
@Dadevster: Thanks, that piece of info really helped me finish my puzzle!
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top