abstract class Mud::Game::Command

Overview

The base class for all user commands.

Direct Known Subclasses

Defined in:

game/command.cr

Constant Summary

UNKNOWN = [["Sorry pard, I don't know what \"", "\" means... Highfalutin city speak, no doubt."], ["Well I declare! I ain't never heard \"", "\" before. Whatever do you mean?"], ["Say what now, friend? I don't comprehend \"", "\". When in doubt, let your horse do the thinkin'."]]

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(id : UInt16, world : Mud::Game::World) #

[View source]

Class Method Detail

def self.parse(id, input, world) : Command | Nil #

Attempts to parse user input into a command.


[View source]

Instance Method Detail

def run #

Runs the command. Mud::Game::Command sends a message indicating the command isn't implemented, but subclasses will override this.


[View source]