Skip to content

Commit 3e39884

Browse files
authored
A couple of small fixes (#798)
1 parent 29d0a2e commit 3e39884

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

src/game/common/modules/modulefactory.h

+3-1
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,13 @@ typedef ModuleData *(*moddatacreateproc_t)(INI *);
3434
class ModuleFactory : public SubsystemInterface, public SnapShot
3535
{
3636
ALLOW_HOOKING
37-
struct ModuleTemplate
37+
class ModuleTemplate
3838
{
39+
public:
3940
modcreateproc_t create_proc;
4041
moddatacreateproc_t create_data_proc;
4142
int which_interfaces;
43+
ModuleTemplate() : create_proc(nullptr), create_data_proc(nullptr), which_interfaces(0) {}
4244
};
4345

4446
public:

src/game/logic/object/update/aiupdate.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ class AIUpdateModuleData : public UpdateModuleData
9292
static void Parse_Turret(INI *ini, void *formal, void *store, const void *user_data);
9393

9494
private:
95-
std::map<LocomotorSetType, LocomotorTemplate const *> m_locomotorTemplates;
95+
std::map<LocomotorSetType, std::vector<LocomotorTemplate const *>> m_locomotorTemplates;
9696
TurretAIData *m_turretData[MAX_TURRETS];
9797
unsigned int m_moodAttackCheckRate;
9898
bool m_forbidPlayerCommands;

src/game/logic/scriptengine/scriptengine.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -223,10 +223,10 @@ class ScriptEngine : public SubsystemInterface, public SnapShot
223223
int m_fadeFramesHold;
224224
int m_fadeFramesDecrease;
225225
int m_objectCreationDestructionFrame;
226-
std::map<Utf8String, unsigned> m_playerObjectCounts[16];
226+
std::map<Utf8String, int> m_playerObjectCounts[MAX_PLAYER_COUNT];
227227
std::list<Utf8String> m_completedVideo;
228-
std::list<std::pair<Utf8String, unsigned>> m_completedSpeech;
229-
std::list<std::pair<Utf8String, unsigned>> m_completedAudio;
228+
std::list<std::pair<Utf8String, unsigned int>> m_completedSpeech;
229+
std::list<std::pair<Utf8String, unsigned int>> m_completedAudio;
230230
std::list<Utf8String> m_uiInteraction;
231231
std::list<std::pair<Utf8String, ObjectID>> m_triggeredSpecialPowers[MAX_PLAYER_COUNT];
232232
std::list<std::pair<Utf8String, ObjectID>> m_midwaySpecialPowers[MAX_PLAYER_COUNT];

0 commit comments

Comments
 (0)