Exemple #1
0
    public void DisplayCombatText(int value, Vector3 pos)
    {
        if (FloatingCombatText == null)
        {
            Debug.LogWarning("Set a DamageNumber prefab");
            return;
        }

        FloatingCombatText.enableNumber = true;
        FloatingCombatText.CreateNew(value, pos);
    }
    public void spawnText(string text)
    {
        DamageNumber spawnedText = dmgnumPrefab.CreateNew(Random.Range(1f, 10f), transform.position);

        spawnedText.prefix = text;
    }