Elaztek Developer Hub
Blamite Game Engine - blam!  00406.12.10.23.1457.blamite
The core library for the Blamite Game Engine.
uid_cypher.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <thread>
4 
5 #include <Strings/components/classes/events/game_engine_events/NewFrame/NewFrameEvent.h>
6 #include <Strings/components/classes/events/events.h>
8 
21 class BlamUIWidget_UserIDCypher : public BlamUIWidget, public BlamEventListener
22 {
23 private:
24  BlamUIWidget_Text* text = nullptr;
25 
26 public:
33 
38 
39  void Draw() override;
40  void ShowImGuiPropertyEditor() override;
41  void UpdateMetrics() override;
42  void RefreshRelativePosition() override;
43 
44  void OnTickEvent(TickEvent* event) override;
45 };
BlamUIWidget::hidden
bool hidden
Whether or not the widget is hidden.
Definition: ui.h:107
BlamDebugMenuItem::title
std::string title
The title of the debug menu item as shown in the menu.
Definition: debug_menu.h:41
BlamUIWidget_UserIDCypher::~BlamUIWidget_UserIDCypher
~BlamUIWidget_UserIDCypher()
Destroys the user ID cypher widget.
Definition: BlamUIWidget_UserIDCypher.cpp:26
ui.h
Blam::Settings::Config::GetEngineConfiguration
BLAM BlamConfigurationFile * GetEngineConfiguration()
Retrieves the main engine configuration file.
Definition: config.cpp:58
BlamUIWidget_DebugMenu::menu_item_size
BlamVector2 menu_item_size
The size of each debug menu item widget.
Definition: debug_menu.h:197
BlamUIWidget::update
bool update
Whether or not the widget needs to be updated before the next draw call.
Definition: ui.h:106
Blam::Globals::GlobalExists
BLAM bool GlobalExists(std::string id)
Determines whether or not a global exists.
Definition: globals.cpp:27
uid_cypher.h
BlamUIWidget_Group
Class representing a Group widget.
Definition: ui.h:263
BlamDebugMenuItemType::Submenu
@ Submenu
Enters into a submenu/subscreen upon activation.
BlamUIWidget::MarkForUpdate
void MarkForUpdate()
Marks the widget as needing to be updated on the next draw call.
Definition: BlamUIWidget.cpp:392
Blam::User::GetUserID
BLAM uint32_t GetUserID()
Definition: user.cpp:3
BlamUIWidget_DebugMenu_Item::ConfigureHotkeyText
void ConfigureHotkeyText(int index)
Reconfigures the widget's hotkey text based on its index.
Definition: debug_menu_item.cpp:313
BlamUIWidget::parent
BlamUIWidget_Group * parent
The parent group of this widget, if applicable.
Definition: ui.h:130
imgui.h
BlamUIWidget_DebugMenu::GetAnimatedActiveItemBackground
BlamColor GetAnimatedActiveItemBackground()
Retrieves the animating active item background color.
Definition: debug_menu.cpp:540
BlamUIWidget_2DPrimitive::color
BlamColor color
The color of the widget.
Definition: ui.h:371
BlamUIWidget_DebugMenu::cached_scale_factor
float cached_scale_factor
The current cached UI scale factor. Used to automatically scale the UI when the scale factor is chang...
Definition: debug_menu.h:196
BlamUIWidget_Text::SetHidden
void SetHidden(bool new_hidden) override
Sets the hidden state of the widget.
Definition: text.cpp:451
BlamEngineGlobal::boolean_value
bool boolean_value
The boolean value of the global.
Definition: globals.h:66
BlamUIWidget_Group::UpdateMetrics
void UpdateMetrics() override
Updates metrics for the widget.
Definition: group.cpp:155
BlamUIWidget_DebugMenu_Item::UpdateMetrics
void UpdateMetrics() override
Updates metrics for the widget.
Definition: debug_menu_item.cpp:165
BlamUIWidget_Group::Draw
void Draw() override
Draws the widget on-screen.
Definition: group.cpp:51
BlamUIWidget_Text::ShowImGuiPropertyEditor
void ShowImGuiPropertyEditor() override
Displays an ImGUI-based property editor.
Definition: text.cpp:72
BlamUIWidget_DebugMenu_Item::Draw
void Draw() override
Draws the widget on-screen.
Definition: debug_menu_item.cpp:152
BlamUIWidget_DebugMenu_Item::SetHidden
void SetHidden(bool new_hidden) override
Sets the hidden state of the widget.
Definition: debug_menu_item.cpp:352
BlamWidgetType::UIDCypher
@ UIDCypher
Special widget. Used for the user ID cypher.
BlamUIWidget::SetPosition
virtual void SetPosition(BlamVector2 new_position)
Sets the position of the widget.
Definition: BlamUIWidget.cpp:368
BlamUIWidget::ShowImGuiPropertyEditor
virtual void ShowImGuiPropertyEditor()
Displays an ImGUI-based property editor.
Definition: BlamUIWidget.cpp:57
BlamUIWidget_UserIDCypher::OnTickEvent
void OnTickEvent(TickEvent *event) override
Definition: BlamUIWidget_UserIDCypher.cpp:52
BlamEngineGlobal::type
BlamGlobalType type
The type of the global.
Definition: globals.h:56
BlamUIWidget_DebugMenu_Item::SetMenuItem
void SetMenuItem(BlamDebugMenuItem _menu_item)
Sets the debug menu item information associated with this widget.
Definition: debug_menu_item.cpp:293
BlamUIWidget_Text::UpdateMetrics
void UpdateMetrics() override
Updates metrics for the widget.
Definition: text.cpp:98
ImGui::CollapsingHeader
IMGUI_API bool CollapsingHeader(const char *label, ImGuiTreeNodeFlags flags=0)
Definition: imgui_widgets.cpp:5422
BlamUIWidget_Text::Draw
void Draw() override
Draws the widget on-screen.
Definition: text.cpp:53
BlamWidgetAnchor::TopLeft
@ TopLeft
The widget will be placed at the top-left of the screen.
BlamUIWidget_Group::children
std::vector< BlamUIWidget * > children
The list of child widgets within this group.
Definition: ui.h:270
BlamUIWidget::display_name
std::string display_name
The display name of the widget.
Definition: ui.h:118
BlamUIWidget_Text::color
BlamColor color
The text foreground color.
Definition: ui.h:522
BlamUIWidget_2DPrimitive::SetHidden
void SetHidden(bool new_hidden) override
Sets the hidden state of the widget.
Definition: 2d_primitive.cpp:172
BlamUIWidget::SetSize
void SetSize(BlamVector2 new_size)
Sets the size of the widget.
Definition: BlamUIWidget.cpp:361
BlamWidgetType::DebugMenuItem
@ DebugMenuItem
Special widget. Represents an item within the debug menu.
String
@ String
Represents a std::string.
Definition: globals.h:39
BlamDebugMenuItemType::CommandSequence
@ CommandSequence
Runs a sequence of console commands upon activation.
BlamUIWidget_DebugMenu_Item::SetIsHeader
void SetIsHeader()
Reconfigures the widget to display as a header, rather than a standard selectable item.
Definition: debug_menu_item.cpp:282
BlamUIWidget_DebugMenu::GetHotkeyCharacterFromIndex
char GetHotkeyCharacterFromIndex(int index)
Determines the hotkey character for an item at a given index.
Definition: debug_menu.cpp:556
BlamUIWidget_UserIDCypher::RefreshRelativePosition
void RefreshRelativePosition() override
Updates the relative position of the widget, relative to its parent.
Definition: BlamUIWidget_UserIDCypher.cpp:47
BlamEngineGlobal
Structure containing data for a game engine global.
Definition: globals.h:54
BlamDebugMenuItemType::Global
@ Global
Modifies an engine global upon activation.
BlamUIWidget_DebugMenu_Item::ShowImGuiPropertyEditor
void ShowImGuiPropertyEditor() override
Displays an ImGUI-based property editor.
Definition: debug_menu_item.cpp:250
BlamDebugMenuItem::item_type
BlamDebugMenuItemType item_type
The type of menu item. See BlamDebugMenuItemType for details.
Definition: debug_menu.h:40
globals.h
BlamUIWidget_DebugMenu_Item::SetSize
void SetSize(float scale)
Sets the scale factor of the widget.
Definition: debug_menu_item.cpp:340
uint32_t
unsigned int uint32_t
Definition: stdint.h:17
BlamDebugMenuItem
Class used to store data and functions relating to an item within the engine's debug menu.
Definition: debug_menu.h:37
BlamUIWidget_BasicRectangle
Class representing a basic rectangle widget.
Definition: ui.h:402
BlamUIWidget_UserIDCypher::UpdateMetrics
void UpdateMetrics() override
Updates metrics for the widget.
Definition: BlamUIWidget_UserIDCypher.cpp:42
BlamUIWidget_UserIDCypher::BlamUIWidget_UserIDCypher
BlamUIWidget_UserIDCypher(BlamUIWidget_Group *_parent)
Constructs a new user ID cypher widget.
Definition: BlamUIWidget_UserIDCypher.cpp:10
BlamUIWidget
Base class for a UI widget.
Definition: ui.h:87
Blam::Globals::GetGlobal
BLAM BlamEngineGlobal * GetGlobal(std::string name)
Retrieves a global with the specified ID.
Definition: globals.cpp:189
BlamUIWidget_UserIDCypher
UI widget for the user ID cypher display.
Definition: uid_cypher.h:21
BlamDebugMenuItemType::Command
@ Command
Runs a console command upon activation.
BlamDebugMenuItem::global_id
std::string global_id
The ID of the engine global to modify upon activation.
Definition: debug_menu.h:54
Boolean
@ Boolean
Represents a boolean. Can be true or false.
Definition: globals.h:34
BlamUIWidget_2DPrimitive::UpdateMetrics
void UpdateMetrics() override
Updates metrics for the widget.
Definition: 2d_primitive.cpp:130
debug_menu.h
BlamUIWidget_DebugMenu
Class used for the Debug Menu UI.
Definition: debug_menu.h:119
BlamUIWidget_Text::text
std::string text
The text to display within this text widget.
Definition: ui.h:526
BlamUIWidget::RefreshRelativePosition
virtual void RefreshRelativePosition()
Updates the relative position of the widget, relative to its parent.
Definition: BlamUIWidget.cpp:212
BlamUIWidget::description
std::string description
An optional description of the widget.
Definition: ui.h:119
BlamUIWidget_DebugMenu_Item::SetActive
void SetActive(bool _active)
Definition: debug_menu_item.cpp:244
user.h
BlamUIWidget::z_index
int z_index
The Z index of the widget, where higher Z orders are drawn on top.
Definition: ui.h:125
BlamUIWidget_DebugMenu_Item::IsHeader
bool IsHeader()
Checks whether or not the current item is a header or not.
Definition: debug_menu_item.cpp:288
ImGui::Separator
IMGUI_API void Separator()
Definition: imgui_widgets.cpp:1284
BlamWidgetType
BlamWidgetType
Enumerator listing possible UI widget types.
Definition: ui.h:60
BlamUIWidget_DebugMenu_Item::BlamUIWidget_DebugMenu_Item
BlamUIWidget_DebugMenu_Item(BlamDebugMenuItem _menu_item, BlamUIWidget_DebugMenu *_debug_menu_widget, BlamUIWidget_Group *parent_group)
Constructs a new debug menu item widget.
Definition: debug_menu_item.cpp:7
config.h
BlamUIWidget_DebugMenu_Item::SetPosition
void SetPosition(BlamVector2 new_position) override
Sets the position of the widget.
Definition: debug_menu_item.cpp:334
BlamUIWidget_UserIDCypher::ShowImGuiPropertyEditor
void ShowImGuiPropertyEditor() override
Displays an ImGUI-based property editor.
Definition: BlamUIWidget_UserIDCypher.cpp:37
BlamUIWidget_BasicRectangle::ShowImGuiPropertyEditor
void ShowImGuiPropertyEditor() override
Displays an ImGUI-based property editor.
Definition: rectangle.cpp:57
BlamUIWidget::ignore_scale_factor
bool ignore_scale_factor
Whether or not this widget should ignore the UI scale factor settings.
Definition: ui.h:133
BlamUIWidget_UserIDCypher::Draw
void Draw() override
Draws the widget on-screen.
Definition: BlamUIWidget_UserIDCypher.cpp:32
BlamUIWidget_Group::SetHidden
void SetHidden(bool new_hidden) override
Sets the hidden state of the widget.
Definition: group.cpp:170
BlamEngineGlobal::value_raw
std::string value_raw
The raw value of the global as a string.
Definition: globals.h:59
BlamWidgetAnchor::TopRight
@ TopRight
The widget will be placed at the top-right of the screen.
BlamUIWidget_Text
Class representing a Text widget.
Definition: ui.h:483
name
ARPHIC PUBLIC LICENSE Ltd Yung Chi Taiwan All rights reserved except as specified below Everyone is permitted to copy and distribute verbatim copies of this license but changing it is forbidden Preamble The licenses for most software are designed to take away your freedom to share and change it By the ARPHIC PUBLIC LICENSE specifically permits and encourages you to use this provided that you give the recipients all the rights that we gave you and make sure they can get the modifications of this software Legal Terms Font means the TrueType fonts AR PL Mingti2L AR PL KaitiM AR PL KaitiM and the derivatives of those fonts created through any modification including modifying reordering converting changing font name
Definition: ARPHICPL.TXT:16
BlamUIWidget::SetAnchorPosition
void SetAnchorPosition(BlamWidgetAnchor new_anchor_position)
Sets the anchor position of the widget.
Definition: BlamUIWidget.cpp:381