Connect An Enemy To Game Frame

Discussion in 'How Can I...?' started by bluemoonstudios, Nov 23, 2016.

  1. bluemoonstudios

    bluemoonstudios Avid Boxer

    Joined:
    Oct 8, 2015
    Messages:
    156
    Likes Received:
    56
    I have a portrait game i am making and it scrolls upward. I have the lower part of the game frame set to red so if the player stay still for too long the lower game frame will hit them and they will lose.

    I was wondering if it is somehow possible to attach an enemy object to the lower game frame so the user has a visual of the enemy about to hit them, because the game frame is invisible then the user cant see what's about to kill them.

    I hope this explanation makes sense. Any ideas??
     
  2. playsgames6666

    playsgames6666 Miniboss Boxer

    Joined:
    Nov 13, 2015
    Messages:
    1,168
    Likes Received:
    745
    You can add a linear velocity to your enemy, you will just need to play around with the speed of it, to match your game speed.
    And if your game speeds up you will need a transform to alter the speed of you enemy to match.
    Probably not the easiest way to do it, but its all i can think of at this time.
     
  3. bluemoonstudios

    bluemoonstudios Avid Boxer

    Joined:
    Oct 8, 2015
    Messages:
    156
    Likes Received:
    56
    Yeah I originally did that, but as you go up through the game and leave that enemy behind it gets removed from the game because of the destroy distance thing. And i want all the other objects to be destroyed once you go past them except for that particular enemy, if you know what i mean.

    The other way i thought of doing it can't be done either. I wanted to place an enemy at the bottom of each scene, so when you get to the next scene and go past the enemy if will wake up and and be behind you again, but you can't wake it up when you go past it, it just wakes up as soon as you are a certain distance away which means its in front of you.

    I hope that makes sense lol
     
    playsgames6666 likes this.

Share This Page