Search Results for

    Show / Hide Table of Contents

    Class LifeDisplayManager

    This class manages the display of player lives, including creating life icons and updating them based on the player's remaining lives.

    Inheritance
    object
    LifeDisplayManager
    Namespace: Game
    Assembly: cs.temp.dll.dll
    Syntax
    public class LifeDisplayManager : MonoBehaviour

    Fields

    lifeDisplays

    A dictionary mapping each player's Damageable component to their corresponding list of life icons.

    Declaration
    public Dictionary<Damageable, List<GameObject>> lifeDisplays
    Field Value
    Type Description
    Dictionary<, ><Damageable, List<><GameObject>>

    lifePrefab

    The prefab used to represent a single life icon.

    Declaration
    public GameObject lifePrefab
    Field Value
    Type Description
    GameObject

    playerPrefab

    The prefab used to represent a player in the life display.

    Declaration
    public GameObject playerPrefab
    Field Value
    Type Description
    GameObject

    players

    The parent object that contains all player life displays.

    Declaration
    public GameObject players
    Field Value
    Type Description
    GameObject

    Methods

    HideLifeDisplay()

    Hides the life display by deactivating the parent object.

    Declaration
    public void HideLifeDisplay()
    In This Article
    Back to top Example Unity documentation footer