private void OnTriggerEnter2D(Collider2D other) { //Make sure none of the static environment stuff hit our destroy collider, we're only destroying stuff that it makes sense to destroy if (!other.gameObject.CompareTag(Tags.Environment)) { if (other.gameObject.CompareTag(Tags.PlayerCharacter)) { //Destroy the player character Destroy(other.gameObject); return; } //Debug.Log("BlockDestroyer hit: " + other.gameObject); bSpawner.RemoveBlock(other.gameObject); if (!destroyedFirstBlock) { destroyedFirstBlock = true; bScroller.ScrollStartingPlatform(); } //We might have just removed a block that was not in the queue, so let's update the array tracking it bScroller.RefreshScrollingObjects(); } }