Class: MockCUIGameCustom
Mock game hud UI element.
Implements
CUIGameCustom
Constructors
Constructor
new MockCUIGameCustom(): MockCUIGameCustom;Returns
MockCUIGameCustom
Methods
create()
static create(): MockCUIGameCustom;Returns
MockCUIGameCustom
mock()
static mock(): CUIGameCustom;Returns
CUIGameCustom
Properties
AddCustomStatic
AddCustomStatic: Mock<(id: string) => StaticDrawableWrapper>;Add a custom HUD static by XML id.
Remarks
If singleInstance is true and an active static with this id already exists, that wrapper is returned.
Param
id
Static descriptor id.
Param
singleInstance
Whether an existing static with the same id should be reused.
Returns
Drawable wrapper for the static.
Implementation of
CUIGameCustom.AddCustomStaticAddDialogToRender
AddDialogToRender: Mock<() => null>;Add a dialog window to the HUD render list.
Remarks
Adds the window to the HUD dialog holder. It shows the window but does not take ownership of it.
Param
window
Dialog window.
Implementation of
CUIGameCustom.AddDialogToRenderCurrentItemAtCell
CurrentItemAtCell: Mock<() => null>;Get the inventory item currently under the actor menu cursor.
Since
OpenXRay 2015-07-07, 6e703b4c
Remarks
Requires the actor menu to have a current inventory cell.
Returns
Game object for the item, or null when the cell has no item.
Implementation of
CUIGameCustom.CurrentItemAtCellcustomStatic
customStatic: Record<string, StaticDrawableWrapper> = {};enable_fake_indicators
enable_fake_indicators: Mock<() => void>;Enable or disable fake HUD indicators.
Param
enabled
New fake-indicator state.
Implementation of
CUIGameCustom.enable_fake_indicatorsGetCustomStatic
GetCustomStatic: Mock<(id: string) => StaticDrawableWrapper>;Get an active custom HUD static by id.
Param
id
Static descriptor id.
Returns
Drawable wrapper, or null when missing.
Implementation of
CUIGameCustom.GetCustomStatichide_messages
hide_messages: Mock<() => void>;Hide HUD messages.
Implementation of
CUIGameCustom.hide_messagesHideActorMenu
HideActorMenu: Mock<() => void>;Hide the actor inventory menu.
Remarks
No-op when the actor menu is already hidden.
Implementation of
CUIGameCustom.HideActorMenuHidePdaMenu
HidePdaMenu: Mock<() => void>;Hide the PDA menu.
Remarks
No-op when the PDA menu is already hidden.
Implementation of
CUIGameCustom.HidePdaMenuRemoveCustomStatic
RemoveCustomStatic: Mock<(id: string) => void>;Remove a custom HUD static.
Remarks
Destroys the matching HUD-owned wrapper when it exists.
Param
id
Static descriptor id.
Implementation of
CUIGameCustom.RemoveCustomStaticRemoveDialogToRender
RemoveDialogToRender: Mock<() => void>;Remove a dialog window from the HUD render list.
Remarks
Hides and disables the window in the HUD dialog holder. It does not destroy the window.
Param
window
Dialog window.
Implementation of
CUIGameCustom.RemoveDialogToRendershow_messages
show_messages: Mock<() => void>;Show HUD messages.
Implementation of
CUIGameCustom.show_messagesShowActorMenu
ShowActorMenu: Mock<() => boolean>;Show the actor inventory menu.
Remarks
Toggles the actor menu. If it is already shown, the call hides it instead.
Returns
true after handling the toggle.
Implementation of
CUIGameCustom.ShowActorMenuupdate_fake_indicators
update_fake_indicators: Mock<() => void>;Update fake indicator visibility.
Param
indicator
Indicator id.
Param
enabled
New indicator state.
Implementation of
CUIGameCustom.update_fake_indicatorsUpdateActorMenu
UpdateActorMenu: Mock<() => void>;Refresh actor menu state.
Since
OpenXRay 2015-07-07, 6e703b4c
Remarks
Updates the actor menu only when it is currently shown.
Implementation of
CUIGameCustom.UpdateActorMenu