How do you get it so when you grab a key it opens a door?

I need help with getting a door to open with a key but i do’t know how to do that so i need help with it.

There are a few ways you could do that, but here’s one:

If you look at the key’s behaviors, you’ll see that it has a collision trigger which sends the message “open” to the door object, and destroys itself.

On the door, there is a mailbox waiting for the “open” message. When that message comes in, the door is destroyed.

Let me know if you have any questions.

How do I make it so when you touch the door , you teleport to another level.?

I just updated the door/key example from above

This is what I did:

  • Added a new game object, and named it "Doorway"
  • Added a new level (Levels->"New Level") and named it "Level 2"
  • Opened up the player object, and set it to "keep between levels" so he will be automatically added to new levels when they load
  • Added two new behaviors to the "Doorway" object: A Collision trigger is connected to a Next Level behavior, with the Next Level set to "Level 2"

Now, whenever the player touches the doorway, level 2 will be loaded.

grazer I have a question: I’m trying to make a level where you click a button with your mouse, and a door shuts/opens. I have no clue what I’m doing. :stuck_out_tongue: plz respond to this as soon as you can. :slight_smile:

(I’m trying to make a Five night’s at Freddys map :D)

Five Night at Freddy’s is scary. It made me not want to walk on the floor in my room. Now I jump to get onto my bed. ( I run and jump because my bed is next to the door. )

=( :frowning:

( Quiver Quiver )

how do you make the key work between levels?

wow this started 7 years ago;; :o


crazy so grazer can you make an example of text that changes if you hit a block or object if you can please show me thanks in advance

1 Like

Please make a new topic next time. This way, Grazer can find your topic and help you easier I believe. Most people here don’t like it when someone digs up an old topic.


yeah ik but this was the first topic i found with @grazer in it

1 Like

You mention Grazer in a new topic; that’s the point.

1 Like