Search Unity

Prefab colliders

Discussion in '2D' started by CoffeeConundrum, Jan 19, 2015.

  1. CoffeeConundrum


    Dec 30, 2013
    HI guys,

    I'm having a strange bug with one of my projects. I've currently got a sprite prefab that spawns in every so often and I'm baffled on how the collision works on them at the start of the game but then struggles later on.

    The game does involve the resolution decreasing as time goes on and the player must collect the green items to increase the resolution.

    I've attached a video that demonstrates the issue that I'm having. As you can see, I can collect a few green items before being unable to do so while the screen decreases.

    I've made sure that both player and prefab are on the same Z coordinate when they're being spawned in and I'm lost on what's going on

    I'm using OnTriggerEnter2D() to check for overlaps.