KMBombInfo - Qkrisi/ktanemodkit GitHub Wiki

KMBombInfo

[DisallowMultipleComponent]
public class KMBombInfo : MonoBehaviour

Can be used to query information about the bomb. (widgets, modules, time, etc.)

There are extension methods in KMBombInfoExtensions.


public float GetTime()

Get the time remaining on the bomb, in seconds.


public string GetFormattedTime()

Get the text currently displayed on the bomb's timer.


public int GetStrikes()

Get the number of strikes issued on the bomb.


public List<string> GetModuleNames()

Get a list of module names on the bomb.


public List<string> GetSolvableModuleNames()

Get a list of all solvable (non-needy) module names on the bomb.


public List<string> GetSolvedModuleNames()

Get a list of the names of the already solved modules.


public List<string> GetModuleIDs()

Get a list of Module IDs on the bomb.


public List<string> GetSolvableModuleIDs()

Get a list of all solvable (non-needy) IDs on the bomb.


public List<string> GetSolvedModuleIDs()

Get a list of the IDs of the already solved modules.


public List<string> QueryWidgets(string queryKey, string queryInfo)

Get a list of all widgets that match the specified queryKey.

queryInfo is a string that is passed to the widget to get the result based on that info (not used by most of the widgets).


public static string QUERYKEY_GET_SERIAL_NUMBER;

Query key of the Serial Number widget


public static string QUERYKEY_GET_BATTERIES;

Query key of the Batteries widget


public static string QUERYKEY_GET_INDICATOR;

Query key of the Indicator widget


public static string QUERYKEY_GET_PORTS;

Query key of the Ports widget


public KMBombSolvedDelegate OnBombSolved;

Fired when the bomb is defused.

Delegate signature: delegate void KMBombSolvedDelegate()


public KMBombSolvedDelegate OnBombExploded;

Fired when the bomb explodes.

Delegate signature: delegate void KMBombExplodedDelegate()

⚠️ **GitHub.com Fallback** ⚠️