You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
454 B
17 lines
454 B
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using TMPro;
|
|
using Unity.VisualScripting;
|
|
using UnityEngine;
|
|
|
|
public class ChatText : MonoBehaviour
|
|
{
|
|
[SerializeField] private TMP_Text text;
|
|
[SerializeField] private string owner;
|
|
|
|
public void Initialize(string message, string owner, Color color)
|
|
{
|
|
text.text = $"<color=#{color.ToHexString()}><b>{owner}</b></color>: {message}";
|
|
this.owner = owner;
|
|
}
|
|
}
|
|
|