docs.unity3d.com
    Show / Hide Table of Contents

    Class PrefabSpawnerSample

    A script that spawns and destroys a number of AssetReferences after a given delay.

    Inheritance
    Object
    PrefabSpawnerSample
    Namespace: Global Namespace
    Syntax
    public class PrefabSpawnerSample : MonoBehaviour

    Fields

    DealyBeforeDestroying

    The time, in seconds, to delay before destroying the spawned prefabs.

    Declaration
    public float DealyBeforeDestroying
    Field Value
    Type Description
    Single

    DelayBetweenSpawns

    The time, in seconds, to delay before spawning prefabs.

    Declaration
    public float DelayBetweenSpawns
    Field Value
    Type Description
    Single

    NumberOfPrefabsToSpawn

    The number of prefabs to spawn.

    Declaration
    public int NumberOfPrefabsToSpawn
    Field Value
    Type Description
    Int32

    SpawnablePrefab

    The prefab to spawn.

    Declaration
    public AssetReference SpawnablePrefab
    Field Value
    Type Description
    AssetReference
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023