Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice
  4. Dismiss Notice

Moving an object when the player crosses the trigger

Discussion in '2D' started by KadzitsuCross, Jun 29, 2021.

  1. KadzitsuCross

    KadzitsuCross

    Joined:
    Sep 26, 2020
    Posts:
    10
    I want to create a trap, its essence is that a block with spikes hangs on the chain and when the player crosses the chain, the block moves from top to bottom, if the player crosses the chain again, the block will move up and etc, like a trap in the Qomp game. But I don’t know how to do this, can someone help please?
     
  2. Cornysam

    Cornysam

    Joined:
    Feb 8, 2018
    Posts:
    1,345
    Check out the multitude of tutorials on YouTube, here is one:

     
  3. KadzitsuCross

    KadzitsuCross

    Joined:
    Sep 26, 2020
    Posts:
    10
    Thanks