KarmaEngine
Game Engine for practical learning and research purposes
Loading...
Searching...
No Matches
Karma::KEngine Class Reference

Base class of all Engine classes, responsible for management of systems critical to editor or game systems. Also defines default classes for certain engine systems. More...

#include <Engine.h>

Inheritance diagram for Karma::KEngine:
Collaboration diagram for Karma::KEngine:

Public Member Functions

 KEngine ()
 Default constructor. Includes setting up UGameInstance.
 
void Init ()
 Set up UGameInstance for the constructor.
 
virtual void Tick (float DeltaSeconds, bool bIdleMode)
 Update everything (UWorlds and subsequently all the AActors). Should be economic for processor and rest of the resources.
 
void CleanupGameViewport ()
 
FWorldContextCreateNewWorldContext (EWorldType::Type WorldType)
 Create a context for new world.
 
virtual void WorldAdded (UWorld *World)
 
virtual void WorldDestroyed (UWorld *InWorld)
 
virtual class UGameInstanceGetCurrentGameInstance () const
 
- Public Member Functions inherited from Karma::UObject
 UObject ()
 
virtual void FinishDestroy ()
 
virtual const std::string & GetDesc ()
 Return a one line description of an object for viewing in the thumbnail view of the generic browser.
 
virtual class UWorldGetWorld () const
 Returns what UWorld this object is contained within.
 
bool IsValidChecked (const UObject *Test)
 
virtual void BeginDestroy ()
 Called before destroying the object. This is called immediately upon deciding to destroy the object, to allow the object to begin an asynchronous cleanup process.
 
FORCEINLINE bool Modify (bool bAlwaysMarkDirty=true)
 
bool IsSelected () const
 Test the selection state of a UObject.
 
- Public Member Functions inherited from Karma::UObjectBase
 UObjectBase (UClass *inClass, EObjectFlags inFlags, EInternalObjectFlags inInternalFlags, UObject *inOuter, const std::string &inName)
 
UPackageGetPackage () const
 
UPackageGetExternalPackage () const
 
bool IsUnreachable () const
 
FORCEINLINE void SetInternalIndex (uint32_t StoreIndex)
 
FORCEINLINE uint32_t GetInternalIndex () const
 
void MarkAsGarbage ()
 
void ClearGarbage ()
 
FORCEINLINE const std::string & GetName () const
 
FORCEINLINE void SetObjectName (const std::string &aName)
 
FORCEINLINE UObjectGetOuter () const
 
UObjectGetTypedOuter (UClass *Target) const
 
template<typename T>
T * GetTypedOuter () const
 
bool IsValidLowLevel () const
 
template<typename OtherClassType>
FORCEINLINE bool IsA (OtherClassType SomeBase) const
 
FORCEINLINE UClassGetClass () const
 
FORCEINLINE EObjectFlags GetFlags () const
 
FORCEINLINE void SetFlags (EObjectFlags NewFlags)
 
FORCEINLINE void ClearFlags (EObjectFlags FlagsToClear)
 
FORCEINLINE bool HasAnyFlags (EObjectFlags FlagsToCheck) const
 
FORCEINLINE bool HasAnyInternalFlags (EInternalObjectFlags FlagsToCheck) const
 
FORCEINLINE void SetInternalFlags (EInternalObjectFlags FlagsToSet) const
 
FORCEINLINE void AddToRoot ()
 

Protected Attributes

KarmaVector< FWorldContext * > m_WorldList
 

Additional Inherited Members

- Static Public Member Functions inherited from Karma::UObject
static const char * StaticConfigName ()
 
- Static Public Member Functions inherited from Karma::UObjectBase
static FORCEINLINE EInternalObjectFlags FixGarbageOrPendingKillInternalObjectFlags (const EInternalObjectFlags InFlags)
 
- Protected Member Functions inherited from Karma::UObjectBase
 UObjectBase ()
 Providing a default constructor.
 
FORCEINLINE void SetFlagsTo (EObjectFlags NewFlags)
 

Detailed Description

Base class of all Engine classes, responsible for management of systems critical to editor or game systems. Also defines default classes for certain engine systems.

ATM we have only this class. In future we may subclass to EditorEngine and GameEngine subclasses

Constructor & Destructor Documentation

◆ KEngine()

Karma::KEngine::KEngine ( )

Default constructor. Includes setting up UGameInstance.

Since
Karma 1.0.0
See also
KEngine::Init()

Member Function Documentation

◆ CleanupGameViewport()

void Karma::KEngine::CleanupGameViewport ( )

Clean up the GameViewport

Todo
Write the logic once viewport is implemented
Since
Karma 1.0.0

◆ CreateNewWorldContext()

FWorldContext & Karma::KEngine::CreateNewWorldContext ( EWorldType::Type WorldType)

Create a context for new world.

Parameters
WorldTypeSpecifies the type of world whose context is being created
See also
UGameInstance::InitializeStandalone
Since
Karma 1.0.0

◆ GetCurrentGameInstance()

virtual class UGameInstance * Karma::KEngine::GetCurrentGameInstance ( ) const
inlinevirtual

Get current gameinstance.

Since
Karma 1.0.0

◆ Init()

void Karma::KEngine::Init ( )

Set up UGameInstance for the constructor.

Since
Karma 1.0.0
See also
KEngine::KEngine()

◆ Tick()

void Karma::KEngine::Tick ( float DeltaSeconds,
bool bIdleMode )
virtual

Update everything (UWorlds and subsequently all the AActors). Should be economic for processor and rest of the resources.

Remarks
Called by main application loop.
Since
Karma 1.0.0
See also
Application::Run()

◆ WorldAdded()

virtual void Karma::KEngine::WorldAdded ( UWorld * World)
inlinevirtual

Needs to be called when a world is added to broadcast messages.

Todo
Not functional
Since
Karma 1.0.0

◆ WorldDestroyed()

virtual void Karma::KEngine::WorldDestroyed ( UWorld * InWorld)
inlinevirtual

Needs to be called when a world is destroyed to broadcast messages.

Todo
Not functional
Since
Karma 1.0.0

The documentation for this class was generated from the following files: