Skip to content
Adam Martin edited this page May 16, 2015 · 2 revisions

Overview

Commands are used to control flow of systems. Each command is a function object that gets passed a pointer to the calling system. Commands are processed at the beginning of each system's update method and therefore are free to modify the system's state. Component state can be read safely, but can't be modified.

Usage

auto function = [](CommandSystem* caller) {};
CommandSystem::QueueCommand(std::move(function));
Clone this wiki locally