Skip to content

Commit c810d6d

Browse files
tamlin-mikeXottab-DUTY
authored andcommitted
A somewhat noticeable compile-time dependencies run.
Xottab_DUTY: fix compilation
1 parent 158fe40 commit c810d6d

File tree

139 files changed

+490
-368
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

139 files changed

+490
-368
lines changed

sdk/include/loki/NullType.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515

1616
// Last update: May 19, 2002
1717

18+
#pragma once
1819
#ifndef NULLTYPE_INC_
1920
#define NULLTYPE_INC_
2021

src/Include/xrRender/animation_blend.h

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,12 @@
11
#pragma once
22

33
#include "animation_motion.h"
4+
#include "xrCore/Animation/SkeletonMotions.hpp" // PlayCallback XXX: fwd. decl. it instead?
5+
46
//*** Run-time Blend definition *******************************************************************
57

68
// XXX: This header contains a few WAY too large functions to inline.
79

8-
#ifdef DEBUG
9-
10-
class bnon_copy
11-
{
12-
protected:
13-
bnon_copy() {}
14-
protected:
15-
bnon_copy(const bnon_copy&) {}
16-
protected:
17-
const bnon_copy& operator=(const bnon_copy&) { return *this; }
18-
};
19-
#endif
2010
class CBlend
2111
{
2212
public:

src/Layers/xrRender/dxFontRender.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#include "stdafx.h"
22
#include "dxFontRender.h"
3-
43
#include "xrEngine/GameFont.h"
4+
#include "xrCore/Text/MbHelpers.h"
55

66
dxFontRender::dxFontRender() {}
77
dxFontRender::~dxFontRender()

src/utils/xrSE_Factory/xrSE_Factory.vcxproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@
133133
<ClInclude Include="..\..\xrServerEntities\script_rtoken_list.h" />
134134
<ClInclude Include="..\..\xrServerEntities\script_rtoken_list_inline.h" />
135135
<ClInclude Include="..\..\xrServerEntities\script_token_list.h" />
136-
<ClInclude Include="..\..\xrServerEntities\script_token_list_inline.h" />
137136
<ClInclude Include="..\..\xrServerEntities\script_value_container.h" />
138137
<ClInclude Include="..\..\xrServerEntities\script_value_container_impl.h" />
139138
<ClInclude Include="..\..\xrServerEntities\ShapeData.h" />

src/utils/xrSE_Factory/xrSE_Factory.vcxproj.filters

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -252,9 +252,6 @@
252252
<ClInclude Include="..\..\xrServerEntities\script_token_list.h">
253253
<Filter>Scripts\ScriptClasses\ScriptIniFile\ScriptTokenList</Filter>
254254
</ClInclude>
255-
<ClInclude Include="..\..\xrServerEntities\script_token_list_inline.h">
256-
<Filter>Scripts\ScriptClasses\ScriptIniFile\ScriptTokenList</Filter>
257-
</ClInclude>
258255
<ClInclude Include="..\..\xrServerEntities\script_rtoken_list.h">
259256
<Filter>Scripts\ScriptClasses\ScriptIniFile\ScriptRTokenList</Filter>
260257
</ClInclude>

src/xrCDB/ISpatial.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ class ISpatial
110110
virtual IRender_Light* dcast_Light() = 0;
111111
};
112112

113-
inline ISpatial::~ISpatial() {}
113+
ICF ISpatial::~ISpatial() {}
114114
class XRCDB_API SpatialBase : public virtual ISpatial
115115
{
116116
public:

src/xrCore/Containers/AssociativeVector.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
#pragma once
1010
#include "xrCore/xrCore.h"
11+
#include "xrCommon/xr_vector.h"
1112
#include "AssociativeVectorComparer.hpp"
1213
#include <algorithm>
1314
#include <functional>

src/xrCore/buffer_vector.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
// Description : buffer vector template class
77
////////////////////////////////////////////////////////////////////////////
88

9+
#pragma once
910
#ifndef BUFFER_VECTOR_H_INCLUDED
1011
#define BUFFER_VECTOR_H_INCLUDED
1112

src/xrEngine/GameFont.cpp

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
#pragma hdrstop
33

44
#include "GameFont.h"
5+
#include "xrCore/Text/MbHelpers.h"
56
#ifndef _EDITOR
67
#include "Render.h"
78
#endif
@@ -12,7 +13,7 @@ ENGINE_API Fvector2 g_current_font_scale = {1.0f, 1.0f};
1213
#include "Include/xrRender/RenderFactory.h"
1314
#include "Include/xrRender/FontRender.h"
1415

15-
CGameFont::CGameFont(LPCSTR section, u32 flags)
16+
CGameFont::CGameFont(pcstr section, u32 flags)
1617
{
1718
pFontRender = GEnv.RenderFactory->CreateFontRender();
1819
fCurrentHeight = 0.0f;
@@ -34,7 +35,7 @@ CGameFont::CGameFont(LPCSTR section, u32 flags)
3435
SetInterval(pSettings->r_fvector2(section, "interval"));
3536
}
3637

37-
CGameFont::CGameFont(LPCSTR shader, LPCSTR texture, u32 flags)
38+
CGameFont::CGameFont(pcstr shader, pcstr texture, u32 flags)
3839
{
3940
pFontRender = GEnv.RenderFactory->CreateFontRender();
4041
fCurrentHeight = 0.0f;
@@ -46,7 +47,7 @@ CGameFont::CGameFont(LPCSTR shader, LPCSTR texture, u32 flags)
4647
Initialize(shader, texture);
4748
}
4849

49-
void CGameFont::Initialize(LPCSTR cShader, LPCSTR cTextureName)
50+
void CGameFont::Initialize(pcstr cShader, pcstr cTextureName)
5051
{
5152
string_path cTexture;
5253

@@ -191,14 +192,14 @@ void CGameFont::OutSet(float x, float y)
191192
}
192193

193194
void CGameFont::OutSetI(float x, float y) { OutSet(DI2PX(x), DI2PY(y)); }
194-
u32 CGameFont::smart_strlen(const char* S) { return (IsMultibyte() ? mbhMulti2Wide(NULL, NULL, 0, S) : xr_strlen(S)); }
195+
u32 CGameFont::smart_strlen(pcstr S) { return (IsMultibyte() ? mbhMulti2Wide(NULL, NULL, 0, S) : xr_strlen(S)); }
195196
void CGameFont::OnRender()
196197
{
197198
pFontRender->OnRender(*this);
198199
strings.clear();
199200
}
200201

201-
u16 CGameFont::GetCutLengthPos(float fTargetWidth, const char* pszText)
202+
u16 CGameFont::GetCutLengthPos(float fTargetWidth, pcstr pszText)
202203
{
203204
VERIFY(pszText);
204205

@@ -224,7 +225,7 @@ u16 CGameFont::GetCutLengthPos(float fTargetWidth, const char* pszText)
224225
return wsPos[i - 1];
225226
}
226227

227-
u16 CGameFont::SplitByWidth(u16* puBuffer, u16 uBufferSize, float fTargetWidth, const char* pszText)
228+
u16 CGameFont::SplitByWidth(u16* puBuffer, u16 uBufferSize, float fTargetWidth, pcstr pszText)
228229
{
229230
VERIFY(puBuffer && uBufferSize && pszText);
230231

@@ -261,8 +262,8 @@ u16 CGameFont::SplitByWidth(u16* puBuffer, u16 uBufferSize, float fTargetWidth,
261262
return nLines;
262263
}
263264

264-
void CGameFont::MasterOut(BOOL bCheckDevice, BOOL bUseCoords, BOOL bScaleCoords, BOOL bUseSkip, float _x, float _y,
265-
float _skip, LPCSTR fmt, va_list p)
265+
void CGameFont::MasterOut(bool bCheckDevice, bool bUseCoords, bool bScaleCoords, bool bUseSkip, float _x, float _y,
266+
float _skip, pcstr fmt, va_list p)
266267
{
267268
if (bCheckDevice && (!RDEVICE.b_is_Active))
268269
return;
@@ -300,18 +301,18 @@ void CGameFont::MasterOut(BOOL bCheckDevice, BOOL bUseCoords, BOOL bScaleCoords,
300301
\
301302
}
302303

303-
void __cdecl CGameFont::OutI(float _x, float _y, LPCSTR fmt, ...)
304+
void __cdecl CGameFont::OutI(float _x, float _y, pcstr fmt, ...)
304305
{
305-
MASTER_OUT(FALSE, TRUE, TRUE, FALSE, _x, _y, 0.0f, fmt);
306+
MASTER_OUT(false, true, true, false, _x, _y, 0.0f, fmt);
306307
};
307308

308-
void __cdecl CGameFont::Out(float _x, float _y, LPCSTR fmt, ...)
309+
void __cdecl CGameFont::Out(float _x, float _y, pcstr fmt, ...)
309310
{
310-
MASTER_OUT(TRUE, TRUE, FALSE, FALSE, _x, _y, 0.0f, fmt);
311+
MASTER_OUT(true, true, false, false, _x, _y, 0.0f, fmt);
311312
};
312313

313-
void __cdecl CGameFont::OutNext(LPCSTR fmt, ...) { MASTER_OUT(TRUE, FALSE, FALSE, TRUE, 0.0f, 0.0f, 1.0f, fmt); };
314-
void CGameFont::OutNextVA(const char* format, va_list args)
314+
void __cdecl CGameFont::OutNext(pcstr fmt, ...) { MASTER_OUT(TRUE, FALSE, FALSE, TRUE, 0.0f, 0.0f, 1.0f, fmt); };
315+
void CGameFont::OutNextVA(pcstr format, va_list args)
315316
{
316317
MasterOut(TRUE, FALSE, FALSE, TRUE, 0.0f, 0.0f, 1.0f, format, args);
317318
}
@@ -322,7 +323,7 @@ float CGameFont::SizeOf_(const char cChar)
322323
return (GetCharTC((u16)(u8)(((IsMultibyte() && cChar == ' ')) ? 0 : cChar)).z * vInterval.x);
323324
}
324325

325-
float CGameFont::SizeOf_(LPCSTR s)
326+
float CGameFont::SizeOf_(pcstr s)
326327
{
327328
if (!(s && s[0]))
328329
return 0;

src/xrEngine/GameFont.h

Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
1-
#ifndef GameFontH
2-
#define GameFontH
31
#pragma once
42

5-
#include "xrEngine/Engine.h"
63
#include "xrEngine/IGameFont.hpp"
7-
#include "xrCore/Text/MbHelpers.h"
8-
#include "Include/xrRender/FontRender.h"
4+
#include "xrCommon/xr_vector.h"
5+
#include "xrCore/_vector3d.h"
6+
#ifdef DEBUG
7+
#include "xrCore/xrstring.h"
8+
#endif
9+
10+
class IFontRender;
911

1012
class ENGINE_API CGameFont : public IGameFont
1113
{
@@ -40,13 +42,14 @@ class ENGINE_API CGameFont : public IGameFont
4042
u32 uFlags;
4143

4244
protected:
43-
IC const Fvector& GetCharTC(u16 c) { return TCMap[c]; }
45+
const Fvector& GetCharTC(u16 c) { return TCMap[c]; }
46+
4447
public:
45-
CGameFont(LPCSTR section, u32 flags = 0);
46-
CGameFont(LPCSTR shader, LPCSTR texture, u32 flags = 0);
48+
CGameFont(pcstr section, u32 flags = 0);
49+
CGameFont(pcstr shader, pcstr texture, u32 flags = 0);
4750
virtual ~CGameFont();
4851

49-
virtual void Initialize(LPCSTR shader, LPCSTR texture) override;
52+
virtual void Initialize(pcstr shader, pcstr texture) override;
5053
virtual void SetColor(u32 C) override { dwCurrentColor = C; }
5154
virtual u32 GetColor() const override { return dwCurrentColor; }
5255
virtual void SetHeightI(float S) override;
@@ -55,29 +58,27 @@ class ENGINE_API CGameFont : public IGameFont
5558
virtual void SetInterval(float x, float y) override { vInterval.set(x, y); };
5659
virtual void SetInterval(const Fvector2& v) override { vInterval.set(v); };
5760
virtual void SetAligment(EAligment aligment) override { eCurrentAlignment = aligment; }
58-
virtual float SizeOf_(LPCSTR s) override;
61+
virtual float SizeOf_(pcstr s) override;
5962
virtual float SizeOf_(const wchar_t* wsStr) override;
6063
virtual float SizeOf_(const char cChar); // only ANSII
6164
virtual float CurrentHeight_() override;
6265
virtual void OutSetI(float x, float y) override;
6366
virtual void OutSet(float x, float y) override;
6467
virtual Fvector2 GetPosition() const override { return {fCurrentX, fCurrentY}; }
65-
virtual void MasterOut(BOOL bCheckDevice, BOOL bUseCoords, BOOL bScaleCoords, BOOL bUseSkip, float _x, float _y,
66-
float _skip, LPCSTR fmt, va_list p) override;
67-
virtual u32 smart_strlen(const char* S) override;
68+
virtual void MasterOut(bool bCheckDevice, bool bUseCoords, bool bScaleCoords, bool bUseSkip, float _x, float _y,
69+
float _skip, pcstr fmt, va_list p) override;
70+
virtual u32 smart_strlen(pcstr S) override;
6871
virtual BOOL IsMultibyte() const override { return (uFlags & fsMultibyte); };
69-
virtual u16 SplitByWidth(u16* puBuffer, u16 uBufferSize, float fTargetWidth, const char* pszText) override;
70-
virtual u16 GetCutLengthPos(float fTargetWidth, const char* pszText) override;
71-
virtual void OutI(float _x, float _y, LPCSTR fmt, ...) override;
72-
virtual void Out(float _x, float _y, LPCSTR fmt, ...) override;
73-
virtual void OutNext(LPCSTR fmt, ...) override;
74-
virtual void OutNextVA(const char* format, va_list args) override;
72+
virtual u16 SplitByWidth(u16* puBuffer, u16 uBufferSize, float fTargetWidth, pcstr pszText) override;
73+
virtual u16 GetCutLengthPos(float fTargetWidth, pcstr pszText) override;
74+
virtual void OutI(float _x, float _y, pcstr fmt, ...) override;
75+
virtual void Out(float _x, float _y, pcstr fmt, ...) override;
76+
virtual void OutNext(pcstr fmt, ...) override;
77+
virtual void OutNextVA(pcstr format, va_list args) override;
7578
virtual void OutSkip(float val = 1.f) override;
7679
virtual void OnRender() override;
7780
virtual void Clear() override { strings.clear(); }
7881
#ifdef DEBUG
7982
shared_str m_font_name;
8083
#endif
8184
};
82-
83-
#endif // _XR_GAMEFONT_H_

0 commit comments

Comments
 (0)