OpenClonk
C4Constants.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define C4GRI_SCENARIO   0
 
#define C4GRI_SEASON   1
 
#define C4GRI_RESERVED1   2
 
#define C4GRI_DAYTIME   3
 
#define C4GRI_RESERVED2   4
 
#define C4GRI_LIGHTNING   5
 
#define C4GRI_MAGIC   6
 
#define C4GRI_RESERVED3   7
 
#define C4GRI_USER   8
 

Enumerations

enum  C4LeagueDisconnectReason { C4LDR_Unknown, C4LDR_ConnectionFailed, C4LDR_Desync }
 
enum  C4PlayerType { C4PT_None = 0, C4PT_User = 1, C4PT_Script = 2 }
 
enum  C4AllowPictureStack { APS_Color = 1<<0, APS_Graphics = 1<<1, APS_Name = 1<<2, APS_Overlay = 1<<3 }
 

Variables

const size_t C4MaxTitle = 512
 
const int C4MaxDefString = 100
 
const int C4MaxMessage = 256
 
const int C4RetireDelay = 60
 
const int C4MaxKey = 12
 
const int C4MaxKeyboardSet = 4
 
const int C4MaxControlSet = C4MaxKeyboardSet+4
 
const int C4MaxControlRate = 20
 
const int C4MaxGammaUserRamps = 8
 
const int C4MaxGammaRamps = C4MaxGammaUserRamps+1
 
const int C4M_MaxName = 15
 
const int C4M_MaxDefName = 2*C4M_MaxName+1
 
const int C4M_MaxTexIndex = 255
 
const int C4S_MaxPlayer = 4
 
const int C4D_MaxVertex = 30
 
const int C4SymbolSize = 35
 
const int C4UpperBoardHeight = 50
 
const int C4PictureSize = 64
 
const int C4MaxBigIconSize = 64
 
const int C4P_MaxPosition = 4
 
const int C4ViewportScrollBorder = 40
 
const int C4XRV_Completed = 0
 
const int C4XRV_Failure = 1
 
const int C4XRV_Aborted = 2
 
const uint32_t OCF_None = 0
 
const uint32_t OCF_All = ~OCF_None
 
const uint32_t OCF_Normal = 1
 
const uint32_t OCF_Construct = 1<<1
 
const uint32_t OCF_Grab = 1<<2
 
const uint32_t OCF_Carryable = 1<<3
 
const uint32_t OCF_OnFire = 1<<4
 
const uint32_t OCF_HitSpeed1 = 1<<5
 
const uint32_t OCF_FullCon = 1<<6
 
const uint32_t OCF_Inflammable = 1<<7
 
const uint32_t OCF_Rotate = 1<<9
 
const uint32_t OCF_Exclusive = 1<<10
 
const uint32_t OCF_Entrance = 1<<11
 
const uint32_t OCF_HitSpeed2 = 1<<12
 
const uint32_t OCF_HitSpeed3 = 1<<13
 
const uint32_t OCF_Collection = 1<<14
 
const uint32_t OCF_HitSpeed4 = 1<<16
 
const uint32_t OCF_NotContained = 1<<18
 
const uint32_t OCF_CrewMember = 1<<19
 
const uint32_t OCF_InLiquid = 1<<20
 
const uint32_t OCF_InSolid = 1<<21
 
const uint32_t OCF_InFree = 1<<22
 
const uint32_t OCF_Available = 1<<23
 
const uint32_t OCF_Container = 1<<24
 
const uint32_t OCF_Alive = 1<<25
 
const BYTE CNAT_None = 0
 
const BYTE CNAT_Left = 1
 
const BYTE CNAT_Right = 2
 
const BYTE CNAT_Top = 4
 
const BYTE CNAT_Bottom = 8
 
const BYTE CNAT_Center = 16
 
const BYTE CNAT_MultiAttach = 32
 
const BYTE CNAT_NoCollision = 64
 
const BYTE CNAT_PhaseHalfVehicle = 128
 
const BYTE CNAT_Flags = CNAT_MultiAttach | CNAT_NoCollision | CNAT_PhaseHalfVehicle
 
const BYTE COM_MenuEnter = 38
 
const BYTE COM_MenuEnterAll = 39
 
const BYTE COM_MenuClose = 40
 
const BYTE COM_MenuShowText = 42
 
const BYTE COM_MenuLeft = 52
 
const BYTE COM_MenuRight = 53
 
const BYTE COM_MenuUp = 54
 
const BYTE COM_MenuDown = 55
 
const BYTE COM_MenuSelect = 60
 
const int NO_OWNER = -1
 
const int ANY_OWNER = -2
 
const int32_t C4M_Vehicle = 100
 
const int32_t C4M_Solid = 50
 
const int32_t C4M_SemiSolid = 25
 
const int32_t C4M_Liquid = 25
 
const int32_t C4M_Background = 0
 
const int32_t MNone = -1
 
const int32_t FullCon = 100000
 

Macro Definition Documentation

◆ C4GRI_DAYTIME

#define C4GRI_DAYTIME   3

Definition at line 41 of file C4Constants.h.

◆ C4GRI_LIGHTNING

#define C4GRI_LIGHTNING   5

Definition at line 43 of file C4Constants.h.

◆ C4GRI_MAGIC

#define C4GRI_MAGIC   6

Definition at line 44 of file C4Constants.h.

◆ C4GRI_RESERVED1

#define C4GRI_RESERVED1   2

Definition at line 40 of file C4Constants.h.

◆ C4GRI_RESERVED2

#define C4GRI_RESERVED2   4

Definition at line 42 of file C4Constants.h.

◆ C4GRI_RESERVED3

#define C4GRI_RESERVED3   7

Definition at line 45 of file C4Constants.h.

◆ C4GRI_SCENARIO

#define C4GRI_SCENARIO   0

Definition at line 38 of file C4Constants.h.

◆ C4GRI_SEASON

#define C4GRI_SEASON   1

Definition at line 39 of file C4Constants.h.

◆ C4GRI_USER

#define C4GRI_USER   8

Definition at line 46 of file C4Constants.h.

Enumeration Type Documentation

◆ C4AllowPictureStack

Enumerator
APS_Color 
APS_Graphics 
APS_Name 
APS_Overlay 

Definition at line 160 of file C4Constants.h.

161 {
162  APS_Color = 1<<0,
163  APS_Graphics = 1<<1,
164  APS_Name = 1<<2,
165  APS_Overlay = 1<<3
166 };

◆ C4LeagueDisconnectReason

Enumerator
C4LDR_Unknown 
C4LDR_ConnectionFailed 
C4LDR_Desync 

Definition at line 142 of file C4Constants.h.

◆ C4PlayerType

Enumerator
C4PT_None 
C4PT_User 
C4PT_Script 

Definition at line 151 of file C4Constants.h.

152 {
153  C4PT_None = 0,
154  C4PT_User = 1, // Normal player
155  C4PT_Script = 2 // AI players, etc.
156 };

Variable Documentation

◆ ANY_OWNER

◆ C4D_MaxVertex

const int C4D_MaxVertex = 30

Definition at line 55 of file C4Constants.h.

Referenced by C4Shape::AddVertex(), and C4Shape::InsertVertex().

◆ C4M_Background

const int32_t C4M_Background = 0

Definition at line 175 of file C4Constants.h.

Referenced by C4ConsoleGUIPreviewWindow::Close().

◆ C4M_Liquid

const int32_t C4M_Liquid = 25

Definition at line 174 of file C4Constants.h.

Referenced by DensityLiquid(), FindTunnelHeight(), ObjectComJump(), and SimFlightHitsLiquid().

◆ C4M_MaxDefName

const int C4M_MaxDefName = 2*C4M_MaxName+1

Definition at line 50 of file C4Constants.h.

◆ C4M_MaxName

◆ C4M_MaxTexIndex

◆ C4M_SemiSolid

const int32_t C4M_SemiSolid = 25

Definition at line 173 of file C4Constants.h.

Referenced by DensitySemiSolid().

◆ C4M_Solid

◆ C4M_Vehicle

const int32_t C4M_Vehicle = 100

Definition at line 171 of file C4Constants.h.

Referenced by C4SolidMask::DensityProvider::GetDensity().

◆ C4MaxBigIconSize

const int C4MaxBigIconSize = 64

Definition at line 61 of file C4Constants.h.

Referenced by C4StartupPlrPropertiesDlg::OnClosed().

◆ C4MaxControlRate

const int C4MaxControlRate = 20

Definition at line 33 of file C4Constants.h.

Referenced by C4Control::CompileFunc(), and C4GameControl::Default().

◆ C4MaxControlSet

const int C4MaxControlSet = C4MaxKeyboardSet+4

Definition at line 32 of file C4Constants.h.

Referenced by C4StartupPlrPropertiesDlg::C4StartupPlrPropertiesDlg().

◆ C4MaxDefString

const int C4MaxDefString = 100

Definition at line 27 of file C4Constants.h.

◆ C4MaxGammaRamps

const int C4MaxGammaRamps = C4MaxGammaUserRamps+1

Definition at line 35 of file C4Constants.h.

Referenced by C4Weather::CompileFunc().

◆ C4MaxGammaUserRamps

const int C4MaxGammaUserRamps = 8

Definition at line 34 of file C4Constants.h.

Referenced by C4Game::SetDefaultGamma().

◆ C4MaxKey

const int C4MaxKey = 12

Definition at line 30 of file C4Constants.h.

Referenced by C4StartupOptionsDlg::OnBackBtn().

◆ C4MaxKeyboardSet

const int C4MaxKeyboardSet = 4

Definition at line 31 of file C4Constants.h.

◆ C4MaxMessage

◆ C4MaxTitle

◆ C4P_MaxPosition

const int C4P_MaxPosition = 4

Definition at line 63 of file C4Constants.h.

Referenced by C4Player::ScenarioInit().

◆ C4PictureSize

const int C4PictureSize = 64

Definition at line 60 of file C4Constants.h.

Referenced by C4Menu::InitLocation().

◆ C4RetireDelay

const int C4RetireDelay = 60

Definition at line 29 of file C4Constants.h.

Referenced by C4Player::Eliminate(), and C4Player::Surrender().

◆ C4S_MaxPlayer

const int C4S_MaxPlayer = 4

◆ C4SymbolSize

◆ C4UpperBoardHeight

◆ C4ViewportScrollBorder

const int C4ViewportScrollBorder = 40

Definition at line 65 of file C4Constants.h.

Referenced by C4Viewport::AdjustPosition(), and C4Player::ScrollView().

◆ C4XRV_Aborted

const int C4XRV_Aborted = 2

Definition at line 72 of file C4Constants.h.

◆ C4XRV_Completed

const int C4XRV_Completed = 0

Definition at line 70 of file C4Constants.h.

◆ C4XRV_Failure

const int C4XRV_Failure = 1

Definition at line 71 of file C4Constants.h.

Referenced by main().

◆ CNAT_Bottom

◆ CNAT_Center

const BYTE CNAT_Center = 16

◆ CNAT_Flags

Definition at line 119 of file C4Constants.h.

Referenced by C4Shape::Attach().

◆ CNAT_Left

◆ CNAT_MultiAttach

const BYTE CNAT_MultiAttach = 32

Definition at line 115 of file C4Constants.h.

Referenced by C4Shape::CompileFunc().

◆ CNAT_NoCollision

◆ CNAT_None

◆ CNAT_PhaseHalfVehicle

const BYTE CNAT_PhaseHalfVehicle = 128

Definition at line 117 of file C4Constants.h.

Referenced by C4Shape::CompileFunc(), and C4Shape::GetVertexOutline().

◆ CNAT_Right

◆ CNAT_Top

◆ COM_MenuClose

const BYTE COM_MenuClose = 40

◆ COM_MenuDown

const BYTE COM_MenuDown = 55

◆ COM_MenuEnter

const BYTE COM_MenuEnter = 38

◆ COM_MenuEnterAll

const BYTE COM_MenuEnterAll = 39

Definition at line 125 of file C4Constants.h.

Referenced by C4Menu::Control(), and C4PlayerControl::ExecuteControlPacket().

◆ COM_MenuLeft

const BYTE COM_MenuLeft = 52

◆ COM_MenuRight

const BYTE COM_MenuRight = 53

◆ COM_MenuSelect

const BYTE COM_MenuSelect = 60

Definition at line 132 of file C4Constants.h.

Referenced by C4Menu::Control(), and C4PlayerControl::ExecuteControlPacket().

◆ COM_MenuShowText

const BYTE COM_MenuShowText = 42

Definition at line 127 of file C4Constants.h.

Referenced by C4Menu::Control(), and C4PlayerControl::ExecuteControlPacket().

◆ COM_MenuUp

const BYTE COM_MenuUp = 54

◆ FullCon

◆ MNone

◆ NO_OWNER

const int NO_OWNER = -1

Definition at line 137 of file C4Constants.h.

Referenced by C4FullScreen::ActivateMenuMain(), C4MainMenu::ActivateObserver(), C4Landscape::P::BlastMaterial2Objects(), C4PlayerControl::Clear(), C4Player::ClearControl(), C4ScriptGuiWindow::Close(), C4ViewportList::CloseViewport(), C4SortObjectValue::CompareGetValue(), C4Control::CompileFunc(), C4Object::CompileFunc(), C4SoundInstance::Create(), C4Game::CreateInfoObject(), C4Game::CreateObjectConstruction(), C4MainMenu::Default(), C4MouseControl::Default(), C4Object::Default(), C4Landscape::P::DigMaterial2Objects(), C4Game::DoKeyboardInput(), C4MainMenu::DoRefillInternal(), C4ObjectMenu::DoRefillInternal(), C4GraphicsSystem::DoSaveScreenshot(), C4ControlPlayerMouse::DragDrop(), C4EditCursor::Draw(), C4Game::DrawCrewOverheadText(), C4Menu::DrawElement(), C4Viewport::EnableFoW(), C4RoundResults::EvaluateGame(), C4Object::ExecLife(), C4Viewport::Execute(), C4Command::Fail(), C4Player::FindNewOwner(), C4ViewportList::FreeScroll(), GameMsgObject(), GameMsgObjectDw(), C4ObjectMenu::GetControllingPlayer(), C4Menu::GetControllingPlayer(), C4Object::GetGraphics(), C4ViewportList::GetViewport(), C4Menu::HasMouse(), C4Game::HasScenario(), C4ViewportWindow::Init(), C4Viewport::Init(), C4Player::Init(), C4Object::Init(), C4Player::InitControl(), C4Console::InitGame(), C4ControlPlayerAction::InitPlayerControl(), C4FindObjectOwner::IsImpossible(), C4FindObjectController::IsImpossible(), C4MouseControl::IsPassive(), C4Object::IsPlayerObject(), C4Object::IsVisible(), C4MainMenu::MenuCommand(), C4ScriptGuiWindow::MouseEnter(), C4ScriptGuiWindow::MouseInput(), C4ScriptGuiWindow::MouseLeave(), C4MouseControl::Move(), C4MaterialMap::mrfIncinerate(), C4Viewport::NextPlayer(), C4Game::PlaceAnimal(), C4Game::PlaceInEarth(), C4MessageInput::ProcessCommand(), C4ScriptGuiWindow::ProcessMouseInput(), C4GameObjects::ResetAudibility(), C4Game::SetGlobalSoundModifier(), C4ControlPlayerAction::SetHostility(), C4Object::SetOwner(), C4SoundInstance::SetVolumeByPos(), C4Viewport::SetZoom(), C4Object::ValidateOwner(), C4FullScreen::ViewportCheck(), C4Console::ViewportNew(), C4ViewportList::ViewportNextPlayer(), and C4ControlEMMoveObject::~C4ControlEMMoveObject().

◆ OCF_Alive

const uint32_t OCF_Alive = 1<<25

Definition at line 103 of file C4Constants.h.

Referenced by C4GameObjects::CrossCheck(), C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_All

const uint32_t OCF_All = ~OCF_None

Definition at line 78 of file C4Constants.h.

Referenced by C4ObjectList::GetLastObject(), C4Command::Grab(), and C4Game::HasScenario().

◆ OCF_Available

const uint32_t OCF_Available = 1<<23

Definition at line 101 of file C4Constants.h.

Referenced by C4Command::Acquire(), C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_Carryable

const uint32_t OCF_Carryable = 1<<3

◆ OCF_Collection

const uint32_t OCF_Collection = 1<<14

◆ OCF_Construct

const uint32_t OCF_Construct = 1<<1

Definition at line 80 of file C4Constants.h.

Referenced by C4Object::DrawTopFace(), C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_Container

const uint32_t OCF_Container = 1<<24

Definition at line 102 of file C4Constants.h.

Referenced by C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_CrewMember

◆ OCF_Entrance

◆ OCF_Exclusive

const uint32_t OCF_Exclusive = 1<<10

◆ OCF_FullCon

const uint32_t OCF_FullCon = 1<<6

◆ OCF_Grab

const uint32_t OCF_Grab = 1<<2

Definition at line 81 of file C4Constants.h.

Referenced by C4Object::Push(), C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_HitSpeed1

const uint32_t OCF_HitSpeed1 = 1<<5

◆ OCF_HitSpeed2

◆ OCF_HitSpeed3

const uint32_t OCF_HitSpeed3 = 1<<13

◆ OCF_HitSpeed4

const uint32_t OCF_HitSpeed4 = 1<<16

Definition at line 95 of file C4Constants.h.

Referenced by C4Object::ContactAction(), C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_Inflammable

const uint32_t OCF_Inflammable = 1<<7

Definition at line 86 of file C4Constants.h.

Referenced by C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_InFree

const uint32_t OCF_InFree = 1<<22

Definition at line 100 of file C4Constants.h.

Referenced by C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_InLiquid

const uint32_t OCF_InLiquid = 1<<20

Definition at line 98 of file C4Constants.h.

Referenced by C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_InSolid

const uint32_t OCF_InSolid = 1<<21

◆ OCF_None

const uint32_t OCF_None = 0

Definition at line 77 of file C4Constants.h.

Referenced by C4GameObjects::CrossCheck().

◆ OCF_Normal

const uint32_t OCF_Normal = 1

Definition at line 79 of file C4Constants.h.

Referenced by C4Command::Get(), C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_NotContained

const uint32_t OCF_NotContained = 1<<18

◆ OCF_OnFire

const uint32_t OCF_OnFire = 1<<4

Definition at line 83 of file C4Constants.h.

Referenced by C4Object::SetOCF(), and C4Object::UpdateOCF().

◆ OCF_Rotate

const uint32_t OCF_Rotate = 1<<9

Definition at line 88 of file C4Constants.h.

Referenced by C4Object::DoMovement(), C4Object::SetOCF(), and C4Object::UpdateOCF().