Skip to main content

PlayerCharacterStats.HasPerk

Declaration#

public virtual bool HasPerk(string id)

Parameters#

NameDescription
idId of the Perk to find

Description#

Check if object has a specific Perk

Usage#

Example
using NullSave.GDTK.Stats;using UnityEngine;
public class Example : MonoBehaviour{
    public void ExampleMethod(PlayerCharacterStats source)    {        string id = source.database.perks[0].info.id;        if(source.HasPerk(id))        {            Debug.Log("Perk is present");        }    }
}