Skip to content

Commit d9e6913

Browse files
author
nitrocaster
committed
Delete unused code.
1 parent 9d51bc3 commit d9e6913

17 files changed

+8
-2167
lines changed

src/utils/xrAI/alife_artefact_order.cpp

Lines changed: 0 additions & 39 deletions
This file was deleted.

src/utils/xrAI/alife_artefact_order.h

Lines changed: 0 additions & 25 deletions
This file was deleted.

src/utils/xrAI/buffer_vector.cpp

Lines changed: 0 additions & 92 deletions
This file was deleted.

src/utils/xrAI/compiler.cpp

Lines changed: 3 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,14 @@
11
#include "stdafx.h"
22
#include "compiler.h"
3-
43
#include "xrCDB/Intersect.hpp"
54

65
CDB::MODEL Level;
76
CDB::COLLIDER XRC;
8-
97
Nodes g_nodes;
108
xr_vector<SCover> g_covers_palette;
11-
129
Lights g_lights;
1310
SAIParams g_params;
1411
Fbox LevelBB;
15-
//Vectors Emitters;
16-
17-
void vertex::PointLF(Fvector& D)
18-
{
19-
Fvector d; d.set(0,-1,0);
20-
Fvector v = Pos;
21-
float s = g_params.fPatchSize/2;
22-
v.x -= s;
23-
v.z += s;
24-
Plane.intersectRayPoint(v,d,D);
25-
}
26-
27-
void vertex::PointFR(Fvector& D)
28-
{
29-
Fvector d; d.set(0,-1,0);
30-
Fvector v = Pos;
31-
float s = g_params.fPatchSize/2;
32-
v.x += s;
33-
v.z += s;
34-
Plane.intersectRayPoint(v,d,D);
35-
}
36-
37-
void vertex::PointRB(Fvector& D)
38-
{
39-
Fvector d; d.set(0,-1,0);
40-
Fvector v = Pos;
41-
float s = g_params.fPatchSize/2;
42-
v.x += s;
43-
v.z -= s;
44-
Plane.intersectRayPoint(v,d,D);
45-
}
46-
47-
void vertex::PointBL(Fvector& D)
48-
{
49-
Fvector d; d.set(0,-1,0);
50-
Fvector v = Pos;
51-
float s = g_params.fPatchSize/2;
52-
v.x -= s;
53-
v.z -= s;
54-
Plane.intersectRayPoint(v,d,D);
55-
}
5612

5713
void mem_Optimize ()
5814
{
@@ -64,36 +20,13 @@ void xrCompiler (LPCSTR name, bool draft_mode, bool pure_covers, LPCSTR out_name
6420
{
6521
Logger.Phase("Loading level...");
6622
xrLoad (name,draft_mode);
67-
mem_Optimize();
68-
69-
// Phase("Building nodes...");
70-
// xrBuildNodes();
71-
// Msg("%d nodes created",int(g_nodes.size()));
72-
// mem_Optimize();
73-
//
74-
// Phase("Smoothing nodes...");
75-
// xrSmoothNodes();
76-
// mem_Optimize();
77-
78-
if (!draft_mode) {
79-
Logger.Phase("Lighting nodes...");
80-
xrLight ();
81-
// xrDisplay ();
82-
mem_Optimize();
83-
23+
mem_Optimize();
24+
if (!draft_mode)
25+
{
8426
Logger.Phase("Calculating coverage...");
8527
xrCover (pure_covers);
8628
mem_Optimize();
8729
}
88-
/////////////////////////////////////
89-
90-
// Phase("Palettizing cover values...");
91-
// xrPalettizeCovers();
92-
// mem_Optimize();
93-
94-
// Phase("Visualizing nodes...");
95-
// xrDisplay ();
96-
9730
Logger.Phase("Saving nodes...");
9831
xrSaveNodes (name,out_name);
9932
mem_Optimize();

src/utils/xrAI/compiler.h

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -50,16 +50,6 @@ struct vertex // definition of "patch" or "node"
5050
};
5151

5252
DEF_VECTOR(DWORDs,u32);
53-
//struct NodeMerged
54-
//{
55-
// DWORDs neighbours; // list of neighbours
56-
// DWORDs contains; // while merging - contains list of elementar nodes
57-
// Fplane plane;
58-
// Fvector P; // min
59-
// WORD sector;
60-
// BYTE light;
61-
// float cover[4];
62-
//};
6353

6454
#include "level_graph.h"
6555

@@ -89,7 +79,6 @@ struct SCover {
8979
};
9080

9181
DEF_VECTOR(Nodes,vertex );
92-
//DEF_VECTOR(Merged,NodeMerged );
9382
DEF_VECTOR(Vectors,Fvector );
9483
DEF_VECTOR(Marks,BYTE );
9584
DEF_VECTOR(Lights,R_Light );
@@ -102,7 +91,6 @@ extern SAIParams g_params;
10291
extern CDB::MODEL Level;
10392
extern CDB::COLLIDER XRC;
10493
extern Fbox LevelBB;
105-
//extern Vectors Emitters;
10694

10795
struct b_BuildTexture : public b_texture
10896
{
@@ -137,14 +125,7 @@ extern xr_vector<b_rc_face> g_rc_faces ;
137125

138126
// phases
139127
void xrLoad (LPCSTR name, bool draft_mode);
140-
//void xrBuildNodes ();
141-
void xrSmoothNodes ();
142-
void xrLight ();
143128
void xrCover (bool pure_covers);
144-
void xrMerge ();
145-
void xrConvertAndLink();
146-
void xrDisplay ();
147-
//void xrPalettizeCovers();
148129
void xrSaveNodes (LPCSTR name, LPCSTR out_name);
149130

150131
// constants

0 commit comments

Comments
 (0)