Public Member Functions |
| CRobotMain (CApplication *app, bool loadProfile) |
| Constructor of robot application.
|
virtual | ~CRobotMain () |
| Destructor of robot application.
|
Gfx::CCamera * | GetCamera () |
Gfx::CTerrain * | GetTerrain () |
Ui::CInterface * | GetInterface () |
Ui::CDisplayText * | GetDisplayText () |
void | LoadSceneOnStart (const std::string &name, int rank) |
| Caused the given mission to be loaded immediately after start.
|
void | CreateIni () |
| Creates the file colobot.ini at the first time.
|
void | SetDefaultInputBindings () |
| Sets the default input bindings (key and axes)
|
void | ResetKeyStates () |
| Resets tracked key states (motion vectors)
|
void | ChangePhase (Phase phase) |
| Changes phase.
|
bool | ProcessEvent (Event &event) |
| Processes an event.
|
bool | CreateShortcuts () |
| Creates interface shortcuts to the units.
|
void | ScenePerso () |
| Load the scene for the character.
|
void | SetMovieLock (bool lock) |
| Management of the lock mode for movies.
|
bool | GetMovieLock () |
bool | GetInfoLock () |
void | SetSatComLock (bool lock) |
| Management of the blocking of the call of SatCom.
|
bool | GetSatComLock () |
void | SetEditLock (bool lock, bool edit) |
| Management of the lock mode for the edition.
|
bool | GetEditLock () |
void | SetEditFull (bool full) |
| Management of the fullscreen mode during editing.
|
bool | GetEditFull () |
bool | GetFreePhoto () |
void | SetFriendAim (bool friendAim) |
| Indicates whether mouse is on an friend object, on which we should not shoot.
|
bool | GetFriendAim () |
void | SetTracePrecision (float factor) |
| Management of the precision of drawing the ground.
|
float | GetTracePrecision () |
void | ChangePause (PauseType pause) |
| Changes on the pause mode.
|
void | SetSpeed (float speed) |
| Changes game speed.
|
float | GetSpeed () |
void | UpdateShortcuts () |
| Updates all the shortcuts.
|
void | SelectHuman () |
| Selects the human.
|
CObject * | SearchHuman () |
| Returns the object human.
|
CObject * | SearchToto () |
| Returns the object toto.
|
CObject * | SearchNearest (Math::Vector pos, CObject *pExclu) |
| Returns the nearest selectable object from a given position.
|
bool | SelectObject (CObject *pObj, bool displayError=true) |
| Selects the object aimed by the mouse.
|
CObject * | GetSelectObject () |
| Returns the object that default was select after the creation of a scene.
|
CObject * | DeselectAll () |
| Deselects everything, and returns the object that was selected.
|
bool | DeleteObject () |
| Deletes the selected object.
|
void | ResetObject () |
| Resets all objects to their original position.
|
void | ResetCreate () |
| Resets all objects to their original position.
|
void | UpdateAudio (bool frame) |
| Updates the audiotracks.
|
void | SetEndMission (Error result, float delay) |
Error | CheckEndMission (bool frame) |
| Checks if the mission is over.
|
void | CheckEndMessage (const char *message) |
| Checks if the mission is finished after displaying a message.
|
int | GetObligatoryToken () |
| Returns the number of instructions required.
|
char * | GetObligatoryToken (int i) |
| Returns the name of a required instruction.
|
int | IsObligatoryToken (const char *token) |
| Checks if an instruction is part of the obligatory list.
|
bool | IsProhibitedToken (const char *token) |
| Checks if an instruction is not part of the banned list.
|
void | UpdateMap () |
| Updates the map.
|
bool | GetShowMap () |
| Indicates whether the mini-map is visible.
|
MainMovieType | GetMainMovie () |
| Returns the type of current movie.
|
void | FlushDisplayInfo () |
| Clears the display of instructions.
|
void | StartDisplayInfo (int index, bool movie) |
void | StartDisplayInfo (const char *filename, int index) |
| Beginning of the displaying of instructions.
|
void | StopDisplayInfo () |
| End of displaying of instructions.
|
char * | GetDisplayInfoName (int index) |
| Returns the name of the text display.
|
int | GetDisplayInfoPosition (int index) |
| Returns the name of the text display.
|
void | SetDisplayInfoPosition (int index, int pos) |
| Returns the name of the text display.
|
void | StartSuspend () |
| Beginning of a dialogue during the game.
|
void | StopSuspend () |
| End of dialogue during the game.
|
float | GetGameTime () |
| Returns the absolute time of the game.
|
void | SetFontSize (float size) |
| Managing the size of the default fonts.
|
float | GetFontSize () |
void | SetWindowPos (Math::Point pos) |
| Managing the size of the default window.
|
Math::Point | GetWindowPos () |
void | SetWindowDim (Math::Point dim) |
Math::Point | GetWindowDim () |
void | SetIOPublic (bool mode) |
| Managing windows open/save.
|
bool | GetIOPublic () |
void | SetIOPos (Math::Point pos) |
Math::Point | GetIOPos () |
void | SetIODim (Math::Point dim) |
Math::Point | GetIODim () |
char * | GetTitle () |
char * | GetResume () |
char * | GetScriptName () |
char * | GetScriptFile () |
bool | GetTrainerPilot () |
| Indicates whether it is possible to control a driving robot.
|
bool | GetFixScene () |
| Indicates whether the scene is fixed, without interaction.
|
bool | GetGlint () |
bool | GetSoluce4 () |
bool | GetMovies () |
bool | GetNiceReset () |
bool | GetHimselfDamage () |
bool | GetShowSoluce () |
bool | GetSceneSoluce () |
bool | GetShowAll () |
bool | GetRadar () |
const char * | GetSavegameDir () |
const char * | GetPublicDir () |
const char * | GetFilesDir () |
bool | GetRetroMode () |
void | SetGamerName (const char *name) |
| Change the player's name.
|
char * | GetGamerName () |
| Gets the player's name.
|
int | GetGamerFace () |
| Returns the representation to use for the player.
|
int | GetGamerGlasses () |
| Returns the representation to use for the player.
|
bool | GetGamerOnlyHead () |
| Returns the mode with just the head.
|
float | GetPersoAngle () |
| Returns the angle of presentation.
|
void | StartMusic () |
| Starts music with a mission.
|
void | StartPauseMusic (PauseType pause) |
| Starts pause music.
|
void | ClearInterface () |
| Removes hilite and tooltip.
|
void | ChangeColor () |
| Change the colors and textures.
|
float | SearchNearestObject (Math::Vector center, CObject *exclu) |
| Calculates the distance to the nearest object.
|
bool | FreeSpace (Math::Vector ¢er, float minRadius, float maxRadius, float space, CObject *exclu) |
| Calculates a free space.
|
float | GetFlatZoneRadius (Math::Vector center, float maxRadius, CObject *exclu) |
| Calculates the maximum radius of a free space.
|
void | HideDropZone (CObject *metal) |
| Hides buildable area when a cube of metal is taken up.
|
void | ShowDropZone (CObject *metal, CObject *truck) |
| Shows the buildable area when a cube of metal is deposited.
|
void | FlushShowLimit (int i) |
| Erases the boundaries shown.
|
void | SetShowLimit (int i, Gfx::ParticleType parti, CObject *pObj, Math::Vector pos, float radius, float duration=SHOWLIMITTIME) |
| Specifies the boundaries to show.
|
void | AdjustShowLimit (int i, Math::Vector pos) |
| Adjusts the boundaries to show.
|
void | StartShowLimit () |
| Mount the boundaries of the selected object.
|
void | FrameShowLimit (float rTime) |
| Advances the boundaries shown.
|
void | CompileScript (bool soluce) |
| Compiles all scripts of robots.
|
void | LoadOneScript (CObject *pObj, int &nerror) |
| Load all programs of the robot.
|
void | LoadFileScript (CObject *pObj, const char *filename, int objRank, int &nerror) |
| Load all programs of the robot.
|
void | SaveAllScript () |
| Saves all programs of all the robots.
|
void | SaveOneScript (CObject *pObj) |
void | SaveFileScript (CObject *pObj, const char *filename, int objRank) |
bool | SaveFileStack (CObject *pObj, FILE *file, int objRank) |
| Saves the stack of the program in execution of a robot.
|
bool | ReadFileStack (CObject *pObj, FILE *file, int objRank) |
| Resumes the execution stack of the program in a robot.
|
bool | FlushNewScriptName () |
| Empty the list.
|
bool | AddNewScriptName (ObjectType type, char *name) |
| Adds a script name.
|
char * | GetNewScriptName (ObjectType type, int rank) |
| Seeks a script name for a given type.
|
void | WriteFreeParam () |
| Writes the global parameters for free play.
|
void | ReadFreeParam () |
| Reads the global parameters for free play.
|
bool | IsBusy () |
| Seeks if an object occupies in a spot, to prevent a backup of the game.
|
bool | IOWriteScene (const char *filename, const char *filecbot, char *info) |
| Saves the current game.
|
CObject * | IOReadScene (const char *filename, const char *filecbot) |
| Resumes some part of the game.
|
void | IOWriteObject (FILE *file, CObject *pObj, const char *cmd) |
| Writes an object into the backup file.
|
CObject * | IOReadObject (char *line, const char *filename, int objRank) |
| Resumes the game.
|
int | CreateSpot (Math::Vector pos, Gfx::Color color) |
| Creates a light spot.
|
void | SetNumericLocale () |
void | RestoreNumericLocale () |
CObject * | GetSelect () |
| Returns the selected object.
|
void | DisplayError (Error err, CObject *pObj, float time=10.0f) |
void | DisplayError (Error err, Math::Vector goal, float height=15.0f, float dist=60.0f, float time=10.0f) |
|
void | SetInputBinding (InputSlot slot, InputBinding binding) |
| Management of input bindings.
|
const InputBinding & | GetInputBinding (InputSlot slot) |
|
void | SetJoyAxisBinding (JoyAxisSlot slot, JoyAxisBinding binding) |
| Management of joystick axis bindings.
|
const JoyAxisBinding & | GetJoyAxisBinding (JoyAxisSlot slot) |
|
void | SetJoystickDeadzone (float zone) |
| Management of joystick deadzone.
|
float | GetJoystickDeadzone () |
Protected Member Functions |
bool | EventFrame (const Event &event) |
| Advances the entire scene.
|
bool | EventObject (const Event &event) |
| Makes the event for all robots.
|
void | InitEye () |
| Initializes the view.
|
void | Convert () |
| Conversion of units.
|
void | CreateScene (bool soluce, bool fixScene, bool resetObject) |
| Creates the whole scene.
|
Math::Vector | LookatPoint (Math::Vector eye, float angleH, float angleV, float length) |
| Calculates the point of arrival of the camera.
|
int | CreateLight (Math::Vector direction, Gfx::Color color) |
| Creates a directional light.
|
void | HiliteClear () |
| Removes setting evidence of the object with the mouse hovers over.
|
void | HiliteObject (Math::Point pos) |
| Highlights the object with the mouse hovers over.
|
void | HiliteFrame (float rTime) |
| Highlights the object with the mouse hovers over.
|
void | CreateTooltip (Math::Point pos, const std::string &text) |
| Creates a tooltip.
|
void | ClearTooltip () |
| Clears the previous tooltip.
|
CObject * | DetectObject (Math::Point pos) |
| Detects the object aimed by the mouse.
|
void | ChangeCamera () |
| Change the mode of the camera.
|
void | RemoteCamera (float pan, float zoom, float rTime) |
| Panned with the camera if a button is pressed.
|
void | KeyCamera (EventType event, unsigned int key) |
| Remote control the camera using the arrow keys.
|
void | AbortMovie () |
| Cancels the current movie.
|
bool | IsSelectable (CObject *pObj) |
| Indicates whether an object is selectable.
|
void | SelectOneObject (CObject *pObj, bool displayError=true) |
| Selects an object, without attending to deselect the rest.
|
void | HelpObject () |
| Displays help for an object.
|
bool | DeselectObject () |
| Deselects the selected object.
|
void | DeleteAllObjects () |
| Quickly removes all objects.
|
void | UpdateInfoText () |
| Updates the text information.
|
CObject * | SearchObject (ObjectType type) |
void | StartDisplayVisit (EventType event) |
| Start of the visit instead of an error.
|
void | FrameVisit (float rTime) |
| Move the arrow to visit.
|
void | StopDisplayVisit () |
| End of the visit instead of an error.
|
void | ExecuteCmd (char *cmd) |
| Executes a command.
|
bool | TestGadgetQuantity (int rank) |
| Updates the number of unnecessary objects.
|
void | UpdateSpeedLabel () |