Toggler
Introduction
Togglers can be used to toggle objects. They are used in things like: the Game Console or the Info Displayer to let you integrate them with your input system.
Creating your own Toggler
If the built in togglers don't suit your needs you can create your own. By Inheriting the Toggler class you can change how it get's toggled. Here's a simple example:
public class ExampleToggler : Toggler
{
public KeyCode Key;
private void Update()
{
if (Input.GetKeyDown(Key))
KeyToggle();
}
}Built in Togglers
There are two types of base togglers:
Type
Description
Toggler
Base toggler that stays in the scene.
Static Toggler
Toggler that moves from scene to scene.
Here's a list of all built in Togglers
Toggler
Description
Toggler Basic
Normal Toggler that uses KeyCodes. Works with the new Unity Input System.
Toggler Remappable
Toggler that works with the qASIC Input System, where you can remap the button in game.
Static Toggler Basic
Toggler Basic that moves from scene to scene.
Static Toggler Remappable
Toggler Remappable that moves from scene to scene.
Last updated