Table of Contents

Class Debug

Namespace
TinyLife
Assembly
Tiny Life.dll

This class contains a set of ways to include custom debug information in the game, including Cheats and DebugLines.

public class Debug
Inheritance
Debug
Inherited Members
Extension Methods

Fields

Cheats

A set of regular expressions that resolve into a Debug.CheatDelegate. When a cheat is entered in the F1 menu, and it matches the expression, the Debug.CheatDelegate is invoked. To register new cheats, simply add them to this dictionary.

public static readonly Dictionary<Regex, Debug.CheatDelegate> Cheats

Field Value

Dictionary<Regex, Debug.CheatDelegate>

DebugLines

A set of Debug.DebugDelegate that cause additional lines to displayed in the F1 menu. To register new debug lines, simply add them to this list. Keep in mind that, if too many debug lines are registered, they will go off-screen, so consider only displaying yours when holding certain hotkeys, or when they are necessary.

public static readonly List<Debug.DebugDelegate> DebugLines

Field Value

List<Debug.DebugDelegate>

Methods

TryCheat(string)

Tries to execute the cheat with the given name or regular expression match.

public static bool TryCheat(string text)

Parameters

text string

The cheat to execute.

Returns

bool

Whether the cheat was successfully exeucted.