UOperatingSystemWorldSubsystem
#include <OperatingSystemSimulator/Public/Subsystems/OperatingSystemWorldSubsystem.h>class UOperatingSystemWorldSubsystemDefined in OperatingSystemWorldSubsystem.h:18
Inherits:
UWorldSubsystem
Inheritance diagram
Section titled “Inheritance diagram”---
config:
class:
hideEmptyMembersBox: true
---
classDiagram
class UOperatingSystemWorldSubsystem["UOperatingSystemWorldSubsystem"]
class UWorldSubsystem["UWorldSubsystem"]
UWorldSubsystem <|-- UOperatingSystemWorldSubsystem
Collaboration diagram
Section titled “Collaboration diagram”---
config:
class:
hideEmptyMembersBox: true
---
classDiagram
class UOperatingSystemWorldSubsystem["UOperatingSystemWorldSubsystem"]
class AOperatingSystemDeviceActor["AOperatingSystemDeviceActor"]
UOperatingSystemWorldSubsystem *-- AOperatingSystemDeviceActor
class UOperatingSystemUserManager["UOperatingSystemUserManager"]
UOperatingSystemWorldSubsystem *-- UOperatingSystemUserManager
Class detail
Section titled “Class detail”---
config:
class:
hideEmptyMembersBox: true
---
classDiagram
class UOperatingSystemWorldSubsystem {
+UOperatingSystemWorldSubsystem()
+Initialize(FSubsystemCollectionBase &Collection) overr
+Deinitialize() override
+RegisterDeviceActor(AOperatingSystemDeviceActor *DeviceActor)
+UnregisterDeviceActor(AOperatingSystemDeviceActor *DeviceActor)
+FindDeviceActorByTag(const FGameplayTag TestTag) AOperatingSystemDeviceActor() *
+FindDeviceActorsByTag(const FGameplayTag TestTag, TArray< AOperat
+GetUserManager() const UOperatingSystemUserManager() *
+SetTargetTexture(UTextureRenderTarget2D *TargetTexture) cons
+DrawWidget(UUserWidget *Widget, const bool bDeferUpdat bool
+Get(const UObject *WorldContextObject) UOperatingSystemWorldSubsystem() *
+RegisteredDeviceActors : TArray< TWeakObjectPtr< AOperatingSystem
+UserManager : TObjectPtr< UOperatingSystemUserManager(
+OperatingSystemWidgetDrawerPtr : FOperatingSystemWidgetDrawerPtr()
}
Caller impact — Get
Section titled “Caller impact — Get”Documented call sites inside the plugin (5):
flowchart LR UOperatingSystemWorldSubsystem__Get["UOperatingSystemWorldSubsystem::Get"] UOperatingSystemStatics__DrawWidgetToTexture["UOperatingSystemStatics::DrawWidgetToTexture"] UOperatingSystemStatics__DrawWidgetToTexture --> UOperatingSystemWorldSubsystem__Get UOperatingSystemStatics__FindDeviceActorByTag["UOperatingSystemStatics::FindDeviceActorByTag"] UOperatingSystemStatics__FindDeviceActorByTag --> UOperatingSystemWorldSubsystem__Get UOperatingSystemStatics__FindDeviceActorsByTag["UOperatingSystemStatics::FindDeviceActorsByTag"] UOperatingSystemStatics__FindDeviceActorsByTag --> UOperatingSystemWorldSubsystem__Get UOperatingSystemStatics__FindMessengerForDevice["UOperatingSystemStatics::FindMessengerForDevice"] UOperatingSystemStatics__FindMessengerForDevice --> UOperatingSystemWorldSubsystem__Get UOperatingSystemStatics__GetUserManager["UOperatingSystemStatics::GetUserManager"] UOperatingSystemStatics__GetUserManager --> UOperatingSystemWorldSubsystem__Get
UOperatingSystemWorldSubsystem class is a subsystem of the game world that manages the operating system functionality.
Public Methods
Section titled “Public Methods”| Return | Name | Description |
|---|---|---|
UOperatingSystemWorldSubsystem | ||
void | Initialize virtual override | |
void | Deinitialize virtual override | |
void | RegisterDeviceActor | This method adds the specified device actor to the RegisteredDeviceActors array of the operating system world subsystem. |
void | UnregisterDeviceActor | This method removes the specified device actor from the RegisteredDeviceActors array of the operating system world subsystem. The array consists of weak pointers to AOperatingSystemDeviceActor instances that are registered with the subsystem. |
AOperatingSystemDeviceActor * | FindDeviceActorByTag | Searches for a device actor in the registered device actors based on the provided tag. If a matching device actor is found, it is returned. If the provided tag is not valid, an error message is logged and null is returned. If no device actor is found with the provided tag, a warning message is logged and null is returned. |
void | FindDeviceActorsByTag | Searches for device actors in the registered device actors based on the provided tag. If matching device actors are found, they are added to the OutDeviceActors array. If the provided tag is not valid, an error message is logged and the array remains empty. If no device actors are found with the provided tag, a warning message is logged and the array remains empty. |
UOperatingSystemUserManager * | GetUserManager const | Get the user manager instance. |
void | SetTargetTexture const inline | Sets the target texture for the operating system widget drawer. |
bool | DrawWidget const inline | Draws the specified widget using the operating system widget drawer. |
UOperatingSystemWorldSubsystem
Section titled “UOperatingSystemWorldSubsystem”UOperatingSystemWorldSubsystem()Defined in OperatingSystemWorldSubsystem.h:43
Section titled “Defined in OperatingSystemWorldSubsystem.h:43”Initialize
Section titled “Initialize”virtual override
virtual void Initialize(FSubsystemCollectionBase & Collection) overrideDefined in OperatingSystemWorldSubsystem.h:45
References
Section titled “References”AddUserWhoRequestedFundCanApproveCreateUserManagerDeleteFileFundRequestGetGetUserUniqueIdOperatingSystemWidgetDrawerPtrReadStructFromJsonRemainingTimeFromTimerRemoveUserWhoRequestedFundTimeUserManager
Deinitialize
Section titled “Deinitialize”virtual override
virtual void Deinitialize() overrideDefined in OperatingSystemWorldSubsystem.h:46
References
Section titled “References”RegisterDeviceActor
Section titled “RegisterDeviceActor”void RegisterDeviceActor(AOperatingSystemDeviceActor * DeviceActor)Defined in OperatingSystemWorldSubsystem.h:61 This method adds the specified device actor to the RegisteredDeviceActors array of the operating system world subsystem.
Parameters
Section titled “Parameters”DeviceActorA pointer to an instance of the AOperatingSystemDeviceActor class to be registered.
References
Section titled “References”UnregisterDeviceActor
Section titled “UnregisterDeviceActor”void UnregisterDeviceActor(AOperatingSystemDeviceActor * DeviceActor)Defined in OperatingSystemWorldSubsystem.h:69 This method removes the specified device actor from the RegisteredDeviceActors array of the operating system world subsystem. The array consists of weak pointers to AOperatingSystemDeviceActor instances that are registered with the subsystem.
Parameters
Section titled “Parameters”DeviceActorA pointer to an instance of the AOperatingSystemDeviceActor class to be unregistered.
References
Section titled “References”FindDeviceActorByTag
Section titled “FindDeviceActorByTag”AOperatingSystemDeviceActor * FindDeviceActorByTag(const FGameplayTag TestTag)Defined in OperatingSystemWorldSubsystem.h:80 Searches for a device actor in the registered device actors based on the provided tag. If a matching device actor is found, it is returned. If the provided tag is not valid, an error message is logged and null is returned. If no device actor is found with the provided tag, a warning message is logged and null is returned.
Parameters
Section titled “Parameters”TestTagThe tag used to identify the device actor.
Returns
Section titled “Returns”The device actor with the provided tag, or null if not found or if the tag is not valid.
Referenced by
Section titled “Referenced by”References
Section titled “References”IsOperatingSystemTagValidOS_LOG_ERROROS_LOG_WARNRegisteredDeviceActors
FindDeviceActorsByTag
Section titled “FindDeviceActorsByTag”void FindDeviceActorsByTag(const FGameplayTag TestTag, TArray< AOperatingSystemDeviceActor * > & OutDeviceActors)Defined in OperatingSystemWorldSubsystem.h:91 Searches for device actors in the registered device actors based on the provided tag. If matching device actors are found, they are added to the OutDeviceActors array. If the provided tag is not valid, an error message is logged and the array remains empty. If no device actors are found with the provided tag, a warning message is logged and the array remains empty.
Parameters
Section titled “Parameters”-
TestTagThe tag used to identify the device actors. -
OutDeviceActorsThe array to which the found device actors should be added.
Referenced by
Section titled “Referenced by”References
Section titled “References”IsOperatingSystemTagValidOS_CLOG_WARNOS_LOG_ERRORRegisteredDeviceActors
GetUserManager
Section titled “GetUserManager”const
UOperatingSystemUserManager * GetUserManager() constDefined in OperatingSystemWorldSubsystem.h:98 Get the user manager instance.
Returns
Section titled “Returns”The user manager instance.
Referenced by
Section titled “Referenced by”References
Section titled “References”SetTargetTexture
Section titled “SetTargetTexture”const inline
inline void SetTargetTexture(UTextureRenderTarget2D * TargetTexture) constDefined in OperatingSystemWorldSubsystem.h:105 Sets the target texture for the operating system widget drawer.
Parameters
Section titled “Parameters”TargetTextureThe UTextureRenderTarget2D instance representing the target texture.
DrawWidget
Section titled “DrawWidget”const inline
inline bool DrawWidget(UUserWidget * Widget, const bool bDeferUpdate, const float DeltaTime) constDefined in OperatingSystemWorldSubsystem.h:118 Draws the specified widget using the operating system widget drawer.
Parameters
Section titled “Parameters”-
WidgetThe UUserWidget instance to be drawn. -
bDeferUpdateWhether to defer the widget update. -
DeltaTimeThe time since the last frame.
Returns
Section titled “Returns”true if the widget was successfully drawn, false otherwise.
Public Static Methods
Section titled “Public Static Methods”| Return | Name | Description |
|---|---|---|
UOperatingSystemWorldSubsystem * | Get static | Retrieves the instance of the UOperatingSystemWorldSubsystem class that is associated with the specified WorldContextObject. |
static
static UOperatingSystemWorldSubsystem * Get(const UObject * WorldContextObject)Defined in OperatingSystemWorldSubsystem.h:54 Retrieves the instance of the UOperatingSystemWorldSubsystem class that is associated with the specified WorldContextObject.
Parameters
Section titled “Parameters”WorldContextObjectThe UObject instance representing the context of the world.
Returns
Section titled “Returns”The UOperatingSystemWorldSubsystem instance associated with the WorldContextObject.
Referenced by
Section titled “Referenced by”DrawWidgetToTextureFindDeviceActorByTagFindDeviceActorsByTagFindMessengerForDeviceGetUserManager
Private Attributes
Section titled “Private Attributes”| Return | Name | Description |
|---|---|---|
TArray< TWeakObjectPtr< AOperatingSystemDeviceActor > > | RegisteredDeviceActors | TArray of weak pointers to AOperatingSystemDeviceActor instances that are registered with the operating system world subsystem. |
TObjectPtr< UOperatingSystemUserManager > | UserManager | Pointer to an instance of the class UOperatingSystemUserManager. It manages the user functionality of the operating system world subsystem. |
FOperatingSystemWidgetDrawerPtr | OperatingSystemWidgetDrawerPtr | FOperatingSystemWidgetDrawerPtr is a shared pointer to an instance of the FOperatingSystemWidgetDrawer class. It is used to manage the lifetime and access to the operating system widget drawer. |
RegisteredDeviceActors
Section titled “RegisteredDeviceActors”TArray< TWeakObjectPtr< AOperatingSystemDeviceActor > > RegisteredDeviceActorsDefined in OperatingSystemWorldSubsystem.h:26 TArray of weak pointers to AOperatingSystemDeviceActor instances that are registered with the operating system world subsystem.
Referenced by
Section titled “Referenced by”UserManager
Section titled “UserManager”TObjectPtr< UOperatingSystemUserManager > UserManagerDefined in OperatingSystemWorldSubsystem.h:33 Pointer to an instance of the class UOperatingSystemUserManager. It manages the user functionality of the operating system world subsystem.
Referenced by
Section titled “Referenced by”OperatingSystemWidgetDrawerPtr
Section titled “OperatingSystemWidgetDrawerPtr”FOperatingSystemWidgetDrawerPtr OperatingSystemWidgetDrawerPtrDefined in OperatingSystemWorldSubsystem.h:39 FOperatingSystemWidgetDrawerPtr is a shared pointer to an instance of the FOperatingSystemWidgetDrawer class. It is used to manage the lifetime and access to the operating system widget drawer.