Search Unity

Enable spawning when object is visible

Discussion in 'Scripting' started by Vinaxis, Dec 22, 2014.

  1. Vinaxis

    Vinaxis

    Joined:
    Dec 22, 2014
    Posts:
    1
    So I want to make an infinite runner game, and I will use a bunch of prefabs for the platforms, and in every prefab, I will include a spawner which will spawn the other platform and so on. Now, what I want to do is, whenever the platform is visible, I want to make that spawner to be "enabled" and spawn the other platform. Is there anyway to do this, or are there any more efficient ways I can achieve this?