Search Results for

    Show / Hide Table of Contents

    Class SUHealthBarLinkData

    Inheritance
    Object
    SULinkData
    SUHealthBarLinkData
    Inherited Members
    SULinkData._target
    SULinkData.Target
    Namespace: Surfer
    Assembly: cs.temp.dll.dll
    Syntax
    [Serializable]
    public class SUHealthBarLinkData : SULinkData

    Constructors

    SUHealthBarLinkData()

    Declaration
    public SUHealthBarLinkData()

    SUHealthBarLinkData(Transform, List<SUHealthBarData>, Single, Single, Single, Single, Single, Single, Single)

    Declaration
    public SUHealthBarLinkData(Transform target, List<SUHealthBarData> allData, float hp, float mp = 0F, float mpReload = 15F, float mpBarDuration = 0.15F, float damageBarDuration = 0.5F, float damageBarDelay = 0.25F, float hpFor10Lines = 100F)
    Parameters
    Type Name Description
    Transform target
    List<SUHealthBarData> allData
    Single hp
    Single mp
    Single mpReload
    Single mpBarDuration
    Single damageBarDuration
    Single damageBarDelay
    Single hpFor10Lines

    Properties

    AllData

    Declaration
    public List<SUHealthBarData> AllData { get; }
    Property Value
    Type Description
    List<SUHealthBarData>

    CurrentHp

    Declaration
    public float CurrentHp { get; set; }
    Property Value
    Type Description
    Single

    CurrentMp

    Declaration
    public float CurrentMp { get; }
    Property Value
    Type Description
    Single

    HasFullHp

    Declaration
    public bool HasFullHp { get; }
    Property Value
    Type Description
    Boolean

    HasFullMp

    Declaration
    public bool HasFullMp { get; }
    Property Value
    Type Description
    Boolean

    HasNoHp

    Declaration
    public bool HasNoHp { get; }
    Property Value
    Type Description
    Boolean

    HasNoMp

    Declaration
    public bool HasNoMp { get; }
    Property Value
    Type Description
    Boolean

    IsEmpty

    Declaration
    public bool IsEmpty { get; }
    Property Value
    Type Description
    Boolean

    Methods

    AddHp(Single)

    Call this when you're adding an armor or item that gives extra hp to the player

    Declaration
    public void AddHp(float hp)
    Parameters
    Type Name Description
    Single hp

    Amount of Hp to add

    AddMp(Single)

    Declaration
    public void AddMp(float mp)
    Parameters
    Type Name Description
    Single mp

    DamageHp(Single)

    Apply damage to the health points

    Declaration
    public void DamageHp(float damage)
    Parameters
    Type Name Description
    Single damage

    HasEnoughMp(Single)

    Declaration
    public bool HasEnoughMp(float mpCost)
    Parameters
    Type Name Description
    Single mpCost
    Returns
    Type Description
    Boolean

    HealHp(Single)

    Call this when the player takes an health potion

    Declaration
    public void HealHp(float hp)
    Parameters
    Type Name Description
    Single hp

    Amount of Hp to heal

    RemoveHp(Single)

    Call this when you're removing an armor or item that gives extra hp to the player

    Declaration
    public void RemoveHp(float hp)
    Parameters
    Type Name Description
    Single hp

    Amount of Hp to remove

    RemoveMp(Single)

    Declaration
    public void RemoveMp(float mp)
    Parameters
    Type Name Description
    Single mp

    Restart()

    Call this when the character/enemy has respawned after a death. The bar will refill and reset its values to the starting ones

    Declaration
    public void Restart()

    StartFollow()

    Make all indicators of this linkData start following the target

    Declaration
    public void StartFollow()

    StopFollow()

    Stop and destroy all indicators of this linkData

    Declaration
    public void StopFollow()

    UseMP(Single)

    Declaration
    public void UseMP(float mp)
    Parameters
    Type Name Description
    Single mp
    In This Article
    Back to top Copyright © 2021 ATStudio