Displaying your own values
Displaying values
public class ExampleScript: MonoBehaviour
{
public DisplayerValueAssigner ExampleAssigner = new DisplayerValueAssigner();
private void Update()
{
//You have to specify a tag that can be configured in the displayer itself
//'main' is the default tag for a displayer
//You can have multiple displayers in the scene, depending on your needs
//With value assigner
ExampleAssigner.DisplayValue("Example value", "main");
//Directly
InfoDisplayer.DisplayValue("position", Player.position, "main");
}
}Toggling values
public class ExampleScript: MonoBehaviour
{
public DisplayerValueAssigner ExampleAssigner = new DisplayerValueAssigner();
private void Update()
{
//You have to specify a tag that can be configured in the displayer itself
//'main' is the default tag for a displayer
//You can have multiple displayers in the scene, depending on your needs
//With value assigner
ExampleAssigner.ToggleValue(true, "main");
//Directly
InfoDisplayer.ToggleValue("position", true, "main");
}
}Last updated