Maze Builder Docs 8.10.23
Loading...
Searching...
No Matches
mazes::stringify_create_state Class Referencefinal

State for creating a maze using the stringify algorithm. More...

#include <stringify_create_state.h>

Inheritance diagram for mazes::stringify_create_state:
[legend]
Collaboration diagram for mazes::stringify_create_state:
[legend]

Public Member Functions

 stringify_create_state (const runtime_app::context &ctx, runtime_stack *rs)
std::any create (const args &a, randomizer &rng) noexcept override
Public Member Functions inherited from mazes::create_contract
template<typename T>
std::optional< T > create_as (const args &a, randomizer &rng) noexcept
 Calls create and extracts the result as T.
Public Member Functions inherited from mazes::write_to_output_state
 write_to_output_state (const runtime_app::context &ctx, runtime_stack *stack)
 Construct a new write to output state.
bool update (randomizer &rng, double delta_time) noexcept override final
 Update the state with the given arguments and delta time Common logic for parsing arguments, creating output, and writing to file.
void draw () const noexcept override
Public Member Functions inherited from mazes::state
 state (const runtime_app::context &c, runtime_stack *rs)

Protected Member Functions

bool write_output (const std::string &output_target, const std::string &output_content) noexcept override
 Write ASCII maze string to output target or stdout.
Protected Member Functions inherited from mazes::write_to_output_state
configurator make_config (const args &a) noexcept
 Builds the configuration for create(), sizing it to the current grid.
Protected Member Functions inherited from mazes::state
void request_stack_push (ID state_id) const noexcept
void request_stack_pop () const noexcept
void request_stack_clear () const noexcept
const runtime_app::context & get_context () const noexcept
runtime_stack & get_stack () const noexcept

Additional Inherited Members

Public Types inherited from mazes::state
enum class  ID : unsigned int {
  EMPTY = 0 , LINK_WITH_BINARY_TREE = 1 , LINK_WITH_DFS = 2 , LINK_WITH_SIDEWINDER = 3 ,
  LINK_WITH_PRIMS = 4 , LOAD = 5 , PARSE = 6 , WRITE_TO_IMAGE = 7 ,
  WRITE_TO_STRING = 8 , WRITE_TO_WF_OBJ = 9 , LINK_WITH_MASKED = 10 , TOTAL = 11
}
Protected Attributes inherited from mazes::write_to_output_state
args_manager * args_mapper
grid_manager * grid_mapper
processed_text_manager * processed_text_mapper
grid_identifier current_grid_id
std::string m_result

Detailed Description

State for creating a maze using the stringify algorithm.

Member Function Documentation

◆ create()

std::any mazes::stringify_create_state::create ( const args & a,
randomizer & rng )
overridevirtualnoexcept

◆ write_output()

bool mazes::stringify_create_state::write_output ( const std::string & output_target,
const std::string & output_content )
nodiscardoverrideprotectedvirtualnoexcept

Write ASCII maze string to output target or stdout.

Implements mazes::write_to_output_state.


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