Class: TDebugPanel
Defined in: debug/debug-panel.ts:24
The debug panel holds a number of stats to display on the UI. The panel also acts as the default section.
Extends
TDebugPanelSection
Constructors
Constructor
new TDebugPanel(
events,isOpen?,engine):TDebugPanel
Defined in: debug/debug-panel.ts:27
Parameters
events
isOpen?
boolean = false
engine
Returns
TDebugPanel
Overrides
TDebugPanelSection.constructor
Properties
dead
dead:
boolean=false
Defined in: debug/debug-panel-section.ts:29
Inherited from
TDebugPanelSection.dead
name
name:
string
Defined in: debug/debug-panel-section.ts:34
Inherited from
TDebugPanelSection.name
rows
rows:
IDebugPanelRow[] =[]
Defined in: debug/debug-panel-section.ts:28
Inherited from
TDebugPanelSection.rows
startOpen
startOpen:
boolean
Defined in: debug/debug-panel-section.ts:35
Inherited from
TDebugPanelSection.startOpen
uuid
uuid:
string
Defined in: debug/debug-panel-section.ts:30
Inherited from
TDebugPanelSection.uuid
Methods
addButtons()
addButtons(
label, ...buttons):TDebugPanelButtons
Defined in: debug/debug-panel-section.ts:69
Add new row to the section with buttons
Parameters
label
string
Text label for row
buttons
...TButton[]
Array of buttons for the row
Returns
TDebugPanelButtons
Inherited from
TDebugPanelSection.addButtons
addCheckbox()
addCheckbox(
label,startingValue,onChange):TDebugPanelCheckbox
Defined in: debug/debug-panel-section.ts:102
Add new row to the section with a checkbox
Parameters
label
string
startingValue
boolean
onChange
(value) => void
Returns
TDebugPanelCheckbox
Inherited from
TDebugPanelSection.addCheckbox
addColorPicker()
addColorPicker(
label,startingValue,onChange):TDebugPanelColorPicker
Defined in: debug/debug-panel-section.ts:139
Parameters
label
string
startingValue
vec3
onChange
(value) => void
Returns
TDebugPanelColorPicker
Inherited from
TDebugPanelSection.addColorPicker
addInput()
addInput(
label,inputType,startingValue,onChange,inputProps?):TDebugPanelInput
Defined in: debug/debug-panel-section.ts:79
Add new row to the section with an input
Parameters
label
string
inputType
TDebugInputTypes
startingValue
string
onChange
(value) => void
inputProps?
TDebugInputProps
Returns
TDebugPanelInput
Inherited from
TDebugPanelSection.addInput
addSection()
addSection(
name,startOpen?):TDebugPanelSection
Defined in: debug/debug-panel.ts:67
Add new section to the debug panel
Parameters
name
string
Name of section
startOpen?
boolean = false
Returns
TDebugPanelSection
addSelect()
addSelect(
label,options,startingValue,onChange):TDebugPanelSelect
Defined in: debug/debug-panel-section.ts:121
Add new row to the section with a select box
Parameters
label
string
options
TDebugSelectOption[]
startingValue
string
onChange
(value) => void
Returns
TDebugPanelSelect
Inherited from
TDebugPanelSection.addSelect
addValue()
addValue(
label,updateFunction):TDebugPanelValue
Defined in: debug/debug-panel-section.ts:54
Add new row to the section with string value
Parameters
label
string
Text label for row
updateFunction
TUpdateFunction
Function to return value every update
Returns
TDebugPanelValue
Inherited from
TDebugPanelSection.addValue
getData()
getData():
TDebugPanelSectionSerializedData
Defined in: debug/debug-panel-section.ts:40
Returns
TDebugPanelSectionSerializedData
Inherited from
TDebugPanelSection.getData
remove()
remove():
void
Defined in: debug/debug-panel-section.ts:173
Remove section from the debug panel
Returns
void
Inherited from
TDebugPanelSection.remove
toggle()
toggle():
void
Defined in: debug/debug-panel.ts:89
Toggle visibily of the debug panel
Returns
void
update()
update(
engine,delta):void
Defined in: debug/debug-panel.ts:47
Runs every update to keep rows up to date
Parameters
engine
delta
number
Returns
void
Overrides
TDebugPanelSection.update