Stop a bullet from passing through enemy

Discussion in 'How Can I...?' started by jermaine150, Nov 24, 2015.

  1. jermaine150

    jermaine150 Boxer

    Joined:
    Nov 10, 2015
    Messages:
    8
    Likes Received:
    2
    I have a character which can shoot bullets. In the character's shoot animation I've added an existing object which functions as the bullet. The bullet object has health:1 and damage:1.
    When the bullet hit's an enemy (health:1 damage:1) the enemy dies but the bullet stays 'alive' and hits the enemy behind him.
    How can i change this so the bullet also dissapears when hitting an enemy?
     
  2. admkpk2

    admkpk2 Boxer

    Joined:
    Sep 25, 2015
    Messages:
    9
    Likes Received:
    3
    I had been trying the same thing. Initially it seemed to work as expected, but I began having the same problem that you are having. I sent a request to support and they were looking into it but to my knowledge the issue was never fixed.
     
  3. Lazlow

    Lazlow Boxer

    Joined:
    Nov 23, 2015
    Messages:
    50
    Likes Received:
    6
    Along those same lines, I'd like a bullet that bounces off of objects. Is this possible?
     
  4. Taimoor Javaid

    Taimoor Javaid Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    274
    Likes Received:
    211
    @Lazlow You may use the transform logic i'm not sure but give it a try.
     
    Taimoormalik8 likes this.
  5. dhawal_tamakuwala

    dhawal_tamakuwala Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    120
    Likes Received:
    46
    yea from the transform logic lt will possible.
     
  6. Lazlow

    Lazlow Boxer

    Joined:
    Nov 23, 2015
    Messages:
    50
    Likes Received:
    6
    will give it a go, thanks.
     
  7. jermaine150

    jermaine150 Boxer

    Joined:
    Nov 10, 2015
    Messages:
    8
    Likes Received:
    2
    I've been trying everything but still the bullets are passing through the enemies. Ideas on how to fix this anyone?
     
  8. dhawal_tamakuwala

    dhawal_tamakuwala Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    120
    Likes Received:
    46
    Place the Transform logic with the object to whom the bullet is colliding. use transform logic / In that add value in position modifier (eg 500 to 1000) in x and y both.
     
  9. jermaine150

    jermaine150 Boxer

    Joined:
    Nov 10, 2015
    Messages:
    8
    Likes Received:
    2
    For others that might run into this:
    What helped me eventually was running in debug mode! When doing this I saw that there was an object attached to my character which was also firing next to my bullet. This object's image was somehow gone so it wasn't visible untill I ran the game in debug mode.

    What was happening was that the second object would hit the first enemy and my bullet was passing through and hit the second enemy. All is working now! :)
     
  10. dhawal_tamakuwala

    dhawal_tamakuwala Avid Boxer

    Joined:
    Oct 5, 2015
    Messages:
    120
    Likes Received:
    46

Share This Page