Colobot
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
CObject Class Reference

Public Member Functions

void DeleteObject (bool bAll=false)
void Simplify ()
bool ExploObject (ExploType type, float force, float decay=1.0f)
bool EventProcess (const Event &event)
void UpdateMapping ()
int CreatePart ()
void DeletePart (int part)
void SetObjectRank (int part, int objRank)
int GetObjectRank (int part)
void SetObjectParent (int part, int parent)
void SetType (ObjectType type)
ObjectType GetType ()
char * GetName ()
void SetOption (int option)
int GetOption ()
void SetID (int id)
int GetID ()
bool Write (char *line)
bool Read (char *line)
void SetDrawWorld (bool bDraw)
void SetDrawFront (bool bDraw)
bool CreateVehicle (Math::Vector pos, float angle, ObjectType type, float power, bool bTrainer, bool bToy)
bool CreateInsect (Math::Vector pos, float angle, ObjectType type)
bool CreateBuilding (Math::Vector pos, float angle, float height, ObjectType type, float power=1.0f)
bool CreateResource (Math::Vector pos, float angle, ObjectType type, float power=1.0f)
bool CreateFlag (Math::Vector pos, float angle, ObjectType type)
bool CreateBarrier (Math::Vector pos, float angle, float height, ObjectType type)
bool CreatePlant (Math::Vector pos, float angle, float height, ObjectType type)
bool CreateMushroom (Math::Vector pos, float angle, float height, ObjectType type)
bool CreateTeen (Math::Vector pos, float angle, float zoom, float height, ObjectType type)
bool CreateQuartz (Math::Vector pos, float angle, float height, ObjectType type)
bool CreateRoot (Math::Vector pos, float angle, float height, ObjectType type)
bool CreateHome (Math::Vector pos, float angle, float height, ObjectType type)
bool CreateRuin (Math::Vector pos, float angle, float height, ObjectType type)
bool CreateApollo (Math::Vector pos, float angle, ObjectType type)
bool ReadProgram (int rank, const char *filename)
bool WriteProgram (int rank, char *filename)
bool RunProgram (int rank)
int GetShadowLight ()
int GetEffectLight ()
void FlushCrashShere ()
int CreateCrashSphere (Math::Vector pos, float radius, Sound sound, float hardness=0.45f)
int GetCrashSphereTotal ()
bool GetCrashSphere (int rank, Math::Vector &pos, float &radius)
float GetCrashSphereHardness (int rank)
Sound GetCrashSphereSound (int rank)
void DeleteCrashSphere (int rank)
void SetGlobalSphere (Math::Vector pos, float radius)
void GetGlobalSphere (Math::Vector &pos, float &radius)
void SetJotlerSphere (Math::Vector pos, float radius)
void GetJotlerSphere (Math::Vector &pos, float &radius)
void SetShieldRadius (float radius)
float GetShieldRadius ()
void SetFloorHeight (float height)
void FloorAdjust ()
void SetLinVibration (Math::Vector dir)
Math::Vector GetLinVibration ()
void SetCirVibration (Math::Vector dir)
Math::Vector GetCirVibration ()
void SetInclinaison (Math::Vector dir)
Math::Vector GetInclinaison ()
void SetPosition (int part, const Math::Vector &pos)
Math::Vector GetPosition (int part)
void SetAngle (int part, const Math::Vector &angle)
Math::Vector GetAngle (int part)
void SetAngleY (int part, float angle)
void SetAngleX (int part, float angle)
void SetAngleZ (int part, float angle)
float GetAngleY (int part)
float GetAngleX (int part)
float GetAngleZ (int part)
void SetZoom (int part, float zoom)
void SetZoom (int part, Math::Vector zoom)
Math::Vector GetZoom (int part)
void SetZoomX (int part, float zoom)
float GetZoomX (int part)
void SetZoomY (int part, float zoom)
float GetZoomY (int part)
void SetZoomZ (int part, float zoom)
float GetZoomZ (int part)
float GetWaterLevel ()
void SetTrainer (bool bEnable)
bool GetTrainer ()
void SetToy (bool bEnable)
bool GetToy ()
void SetManual (bool bManual)
bool GetManual ()
void SetResetCap (ResetCap cap)
ResetCap GetResetCap ()
void SetResetBusy (bool bBusy)
bool GetResetBusy ()
void SetResetPosition (const Math::Vector &pos)
Math::Vector GetResetPosition ()
void SetResetAngle (const Math::Vector &angle)
Math::Vector GetResetAngle ()
void SetResetRun (int run)
int GetResetRun ()
void SetMasterParticle (int part, int parti)
int GetMasterParticle (int part)
void SetPower (CObject *power)
CObjectGetPower ()
void SetFret (CObject *fret)
CObjectGetFret ()
void SetTruck (CObject *truck)
CObjectGetTruck ()
void SetTruckPart (int part)
int GetTruckPart ()
void InfoFlush ()
void DeleteInfo (int rank)
void SetInfo (int rank, Info info)
Info GetInfo (int rank)
int GetInfoTotal ()
void SetInfoReturn (float value)
float GetInfoReturn ()
void SetInfoUpdate (bool bUpdate)
bool GetInfoUpdate ()
bool SetCmdLine (int rank, float value)
float GetCmdLine (int rank)
Math::MatrixGetRotateMatrix (int part)
Math::MatrixGetTranslateMatrix (int part)
Math::MatrixGetTransformMatrix (int part)
Math::MatrixGetWorldMatrix (int part)
void SetViewFromHere (Math::Vector &eye, float &dirH, float &dirV, Math::Vector &lookat, Math::Vector &upVec, Gfx::CameraType type)
void SetCharacter (Character *character)
void GetCharacter (Character *character)
CharacterGetCharacter ()
float GetAbsTime ()
void SetEnergy (float level)
float GetEnergy ()
void SetCapacity (float capacity)
float GetCapacity ()
void SetShield (float level)
float GetShield ()
void SetRange (float delay)
float GetRange ()
void SetTransparency (float value)
float GetTransparency ()
ObjectMaterial GetMaterial ()
void SetGadget (bool bMode)
bool GetGadget ()
void SetFixed (bool bFixed)
bool GetFixed ()
void SetClip (bool bClip)
bool GetClip ()
bool JostleObject (float force)
void StartDetectEffect (CObject *target, bool bFound)
void SetVirusMode (bool bEnable)
bool GetVirusMode ()
float GetVirusTime ()
void SetCameraType (Gfx::CameraType type)
Gfx::CameraType GetCameraType ()
void SetCameraDist (float dist)
float GetCameraDist ()
void SetCameraLock (bool bLock)
bool GetCameraLock ()
void SetHilite (bool bMode)
bool GetHilite ()
void SetSelect (bool bMode, bool bDisplayError=true)
bool GetSelect (bool bReal=false)
void SetSelectable (bool bMode)
bool GetSelectable ()
void SetActivity (bool bMode)
bool GetActivity ()
void SetVisible (bool bVisible)
bool GetVisible ()
void SetEnable (bool bEnable)
bool GetEnable ()
void SetCheckToken (bool bMode)
bool GetCheckToken ()
void SetProxyActivate (bool bActivate)
bool GetProxyActivate ()
void SetProxyDistance (float distance)
float GetProxyDistance ()
void SetMagnifyDamage (float factor)
float GetMagnifyDamage ()
void SetParam (float value)
float GetParam ()
void SetIgnoreBuildCheck (bool bIgnoreBuildCheck)
bool GetIgnoreBuildCheck ()
void SetExplo (bool bExplo)
bool GetExplo ()
void SetLock (bool bLock)
bool GetLock ()
void SetCargo (bool bCargo)
bool GetCargo ()
void SetBurn (bool bBurn)
bool GetBurn ()
void SetDead (bool bDead)
bool GetDead ()
bool GetRuin ()
bool GetActif ()
void SetGunGoalV (float gunGoal)
void SetGunGoalH (float gunGoal)
float GetGunGoalV ()
float GetGunGoalH ()
bool StartShowLimit ()
void StopShowLimit ()
bool IsProgram ()
void CreateSelectParticle ()
void SetRunScript (CScript *script)
CScriptGetRunScript ()
CBotVarGetBotVar ()
CPhysicsGetPhysics ()
CBrainGetBrain ()
CMotionGetMotion ()
CAutoGetAuto ()
void SetAuto (CAuto *automat)
void SetDefRank (int rank)
int GetDefRank ()
bool GetTooltipName (std::string &name)
void AddDeselList (CObject *pObj)
CObjectSubDeselList ()
void DeleteDeselList (CObject *pObj)
bool CreateShadowCircle (float radius, float intensity, Gfx::EngineShadowType type=Gfx::ENG_SHADOW_NORM)
bool CreateShadowLight (float height, Gfx::Color color)
bool CreateEffectLight (float height, Gfx::Color color)
void FlatParent ()
bool GetTraceDown ()
void SetTraceDown (bool bDown)
int GetTraceColor ()
void SetTraceColor (int color)
float GetTraceWidth ()
void SetTraceWidth (float width)
std::string GetModelDirName ()

Static Public Member Functions

static DriveType GetDriveFromObject (ObjectType type)
static ToolType GetToolFromObject (ObjectType type)

Protected Member Functions

bool EventFrame (const Event &event)
void VirusFrame (float rTime)
void PartiFrame (float rTime)
void CreateOtherObject (ObjectType type)
void InitPart (int part)
void UpdateTotalPart ()
int SearchDescendant (int parent, int n)
void UpdateEnergyMapping ()
bool UpdateTransformObject (int part, bool bForceUpdate)
bool UpdateTransformObject ()
void UpdateSelectParticle ()

Protected Attributes

CApplicationm_app
Gfx::CEnginem_engine
Gfx::CLightManagerm_lightMan
Gfx::CTerrainm_terrain
Gfx::CWaterm_water
Gfx::CCameram_camera
Gfx::CParticlem_particle
CPhysicsm_physics
CBrainm_brain
CMotionm_motion
CAutom_auto
CRobotMainm_main
CSoundInterfacem_sound
CBotVarm_botVar
CScriptm_runScript
ObjectType m_type
int m_id
char m_name [50]
Character m_character
int m_option
int m_partiReactor
int m_shadowLight
float m_shadowHeight
int m_effectLight
float m_effectHeight
Math::Vector m_linVibration
Math::Vector m_cirVibration
Math::Vector m_inclinaison
CObjectm_power
CObjectm_fret
CObjectm_truck
int m_truckLink
float m_energy
float m_lastEnergy
float m_capacity
float m_shield
float m_range
float m_transparency
int m_material
float m_aTime
float m_shotTime
bool m_bVirusMode
float m_virusTime
float m_lastVirusParticle
float m_lastParticle
bool m_bHilite
bool m_bSelect
bool m_bSelectable
bool m_bCheckToken
bool m_bVisible
bool m_bEnable
bool m_bProxyActivate
bool m_bGadget
bool m_bLock
bool m_bExplo
bool m_bCargo
bool m_bBurn
bool m_bDead
bool m_bFlat
bool m_bTrainer
bool m_bToy
bool m_bManual
bool m_bIgnoreBuildCheck
bool m_bFixed
bool m_bClip
bool m_bShowLimit
float m_showLimitRadius
float m_gunGoalV
float m_gunGoalH
Gfx::CameraType m_cameraType
float m_cameraDist
bool m_bCameraLock
int m_defRank
float m_magnifyDamage
float m_proxyDistance
float m_param
int m_crashSphereUsed
Math::Vector m_crashSpherePos [MAXCRASHSPHERE]
float m_crashSphereRadius [MAXCRASHSPHERE]
float m_crashSphereHardness [MAXCRASHSPHERE]
Sound m_crashSphereSound [MAXCRASHSPHERE]
Math::Vector m_globalSpherePos
float m_globalSphereRadius
Math::Vector m_jotlerSpherePos
float m_jotlerSphereRadius
float m_shieldRadius
int m_totalPart
ObjectPart m_objectPart [OBJECTMAXPART]
int m_totalDesectList
CObjectm_objectDeselectList [OBJECTMAXDESELLIST]
int m_partiSel [4]
ResetCap m_resetCap
bool m_bResetBusy
Math::Vector m_resetPosition
Math::Vector m_resetAngle
int m_resetRun
int m_infoTotal
Info m_info [OBJECTMAXINFO]
float m_infoReturn
bool m_bInfoUpdate
float m_cmdLine [OBJECTMAXCMDLINE]

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