File tree Expand file tree Collapse file tree 4 files changed +7
-34
lines changed Expand file tree Collapse file tree 4 files changed +7
-34
lines changed Original file line number Diff line number Diff line change @@ -211,13 +211,6 @@ namespace RTE {
211
211
}
212
212
213
213
214
-
215
-
216
-
217
-
218
-
219
-
220
-
221
214
// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
222
215
223
216
void ModuleMan::LoadOfficialModules () {
@@ -231,7 +224,7 @@ namespace RTE {
231
224
// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
232
225
233
226
bool ModuleMan::LoadAllDataModules () {
234
- // Destroy any possible loaded modules
227
+ // Destroy any possible loaded modules.
235
228
Destroy ();
236
229
237
230
LoadOfficialModules ();
Original file line number Diff line number Diff line change @@ -42,11 +42,7 @@ namespace RTE {
42
42
// / Gets the total number of modules loaded so far, official or not.
43
43
// / </summary>
44
44
// / <returns>The number of modules loaded so far, both official and non.</returns>
45
- size_t GetTotalModuleCount () const { return m_LoadedDataModules.size (); }
46
-
47
-
48
-
49
-
45
+ int GetTotalModuleCount () const { return m_LoadedDataModules.size (); }
50
46
51
47
52
48
@@ -101,8 +97,7 @@ namespace RTE {
101
97
// / </summary>
102
98
// / <param name="whichModule">The ID of the module to get.</param>
103
99
// / <returns>The requested DataModule. Ownership is NOT transferred!</returns>
104
- const DataModule * GetDataModule (int whichModule = 0 );
105
-
100
+ DataModule * GetDataModule (int whichModule = 0 );
106
101
107
102
108
103
@@ -150,18 +145,6 @@ namespace RTE {
150
145
// / <returns>The complete path to the file, including Data/, Userdata/ or Mods/ based on whether or not it's part of an official module or userdata.</returns>
151
146
std::string GetFullModulePath (const std::string &modulePath) const ;
152
147
153
-
154
-
155
-
156
-
157
-
158
-
159
-
160
-
161
-
162
-
163
-
164
-
165
148
#pragma endregion
166
149
167
150
#pragma region Contrete Methods
@@ -196,9 +179,8 @@ namespace RTE {
196
179
197
180
#pragma region Module Loading Breakdown
198
181
// / <summary>
199
- // /
182
+ // / Loads all the official DataModules individually with LoadDataModule.
200
183
// / </summary>
201
- // / <returns></returns>
202
184
void LoadOfficialModules ();
203
185
204
186
// / <summary>
Original file line number Diff line number Diff line change @@ -19,10 +19,8 @@ namespace RTE {
19
19
20
20
// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
21
21
22
- void PresetMan::RegisterGroup (const std::string &newGroup, int whichModule) {
23
- RTEAssert (whichModule >= 0 && whichModule < g_ModuleMan.GetTotalModuleCount (), " Tried to access an out of bounds data module number!" );
24
-
25
- g_ModuleMan.GetLoadedDataModules ()[whichModule]->RegisterGroup (newGroup);
22
+ void PresetMan::RegisterGroup (const std::string &newGroup, int whichModule) const {
23
+ g_ModuleMan.GetDataModule (whichModule)->RegisterGroup (newGroup);
26
24
}
27
25
28
26
// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ namespace RTE {
40
40
// / </summary>
41
41
// / <param name="groupName">The group to register.</param>
42
42
// / <param name="whichModule">The ID of the module in which at least one Entity of this group can be found.</param>
43
- void RegisterGroup (const std::string &groupName, int whichModule);
43
+ void RegisterGroup (const std::string &groupName, int whichModule) const ;
44
44
45
45
// / <summary>
46
46
// / Fills out a list with all groups registered in a specific module.
You can’t perform that action at this time.
0 commit comments