Richard Boegli's CnC_Generals_Zero_Hour Fork WIP
This is documentation of Richard Boegil's Zero Hour Fork
 
Loading...
Searching...
No Matches
CommandTranslator Class Reference

#include <CommandXlat.h>

Inherits GameMessageTranslator.

Public Types

enum  CommandEvaluateType { DO_COMMAND , DO_HINT , EVALUATE_ONLY }
 

Public Member Functions

 CommandTranslator ()
 
 ~CommandTranslator ()
 
GameMessage::Type evaluateForceAttack (Drawable *draw, const Coord3D *pos, CommandEvaluateType type)
 
GameMessage::Type evaluateContextCommand (Drawable *draw, const Coord3D *pos, CommandEvaluateType type)
 
- Public Member Functions inherited from GameMessageTranslator
virtual ~GameMessageTranslator ()
 

Detailed Description

Definition at line 38 of file CommandXlat.h.

Member Enumeration Documentation

◆ CommandEvaluateType

Enumerator
DO_COMMAND 
DO_HINT 
EVALUATE_ONLY 

Definition at line 45 of file CommandXlat.h.

Constructor & Destructor Documentation

◆ CommandTranslator()

CommandTranslator::CommandTranslator ( )

Definition at line 1319 of file CommandXlat.cpp.

◆ ~CommandTranslator()

CommandTranslator::~CommandTranslator ( )

Definition at line 1332 of file CommandXlat.cpp.

Member Function Documentation

◆ evaluateContextCommand()

GameMessage::Type CommandTranslator::evaluateContextCommand ( Drawable * draw,
const Coord3D * pos,
CommandEvaluateType type )

This method and the order of operations in the check here, determine what command would actually happen (if type parameter == DO_COMMAND) if the user clicked on the drawable 'draw'. If type == DO_HINT, then the user hasn't actually clicked, but has moused over the drawable 'draw' and we want to generate a hint message as to what the actual command would be if clicked NOTE: draw can be NULL, in which case we give a hint for the location

Definition at line 1425 of file CommandXlat.cpp.

◆ evaluateForceAttack()

GameMessage::Type CommandTranslator::evaluateForceAttack ( Drawable * draw,
const Coord3D * pos,
CommandEvaluateType type )

Definition at line 1339 of file CommandXlat.cpp.


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