Bicameral Engine
GPU-resident engine for a magic-research open-world game
Loading...
Searching...
No Matches
bicameral::editor::TimeControl Class Reference

#include <time_control.h>

Public Member Functions

void Apply (const TimeRequest &request, frame::SimScheduler &scheduler)
void AdvanceRealTime (double seconds, frame::SimScheduler &scheduler, double gameSpeed=1.0) const
bool Paused () const
uint32_t SpeedIndex () const
double Speed () const
uint64_t SteppedTicks () const

Private Attributes

bool m_paused = false
uint32_t m_speedIndex = NORMAL_SPEED_INDEX
uint64_t m_steppedTicks = 0

Detailed Description

Definition at line 36 of file time_control.h.

Member Function Documentation

◆ AdvanceRealTime()

void bicameral::editor::TimeControl::AdvanceRealTime ( double seconds,
frame::SimScheduler & scheduler,
double gameSpeed = 1.0 ) const

Definition at line 32 of file time_control.cpp.

References bicameral::frame::SimScheduler::AddRealTime(), m_paused, and Speed().

Here is the call graph for this function:

◆ Apply()

void bicameral::editor::TimeControl::Apply ( const TimeRequest & request,
frame::SimScheduler & scheduler )

◆ Paused()

bool bicameral::editor::TimeControl::Paused ( ) const
inlinenodiscard

Definition at line 44 of file time_control.h.

References m_paused.

Referenced by bicameral::editor::EditorOverlay::BuildTimePanel(), and bicameral::editor::EditorOverlay::TakeShortcuts().

Here is the caller graph for this function:

◆ Speed()

double bicameral::editor::TimeControl::Speed ( ) const
inlinenodiscard

Definition at line 46 of file time_control.h.

References m_speedIndex, and bicameral::editor::TIME_SPEEDS.

Referenced by AdvanceRealTime(), and bicameral::editor::EditorOverlay::BuildTimePanel().

Here is the caller graph for this function:

◆ SpeedIndex()

uint32_t bicameral::editor::TimeControl::SpeedIndex ( ) const
inlinenodiscard

Definition at line 45 of file time_control.h.

References m_speedIndex.

◆ SteppedTicks()

uint64_t bicameral::editor::TimeControl::SteppedTicks ( ) const
inlinenodiscard

Definition at line 47 of file time_control.h.

References m_steppedTicks.

Referenced by bicameral::editor::EditorOverlay::BuildTimePanel().

Here is the caller graph for this function:

Member Data Documentation

◆ m_paused

bool bicameral::editor::TimeControl::m_paused = false
private

Definition at line 50 of file time_control.h.

Referenced by AdvanceRealTime(), Apply(), and Paused().

◆ m_speedIndex

uint32_t bicameral::editor::TimeControl::m_speedIndex = NORMAL_SPEED_INDEX
private

Definition at line 51 of file time_control.h.

Referenced by Apply(), Speed(), and SpeedIndex().

◆ m_steppedTicks

uint64_t bicameral::editor::TimeControl::m_steppedTicks = 0
private

Definition at line 52 of file time_control.h.

Referenced by Apply(), and SteppedTicks().


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