mirror of
https://github.com/isledecomp/isle.git
synced 2026-01-24 00:31:16 +00:00
Use MxS8 for Compare return type
This commit is contained in:
parent
c970d08557
commit
6c914e0700
@ -15,7 +15,7 @@ class MxCollection : public MxCore {
|
||||
virtual ~MxCollection() {}
|
||||
|
||||
static void Destroy(T){};
|
||||
virtual MxBool Compare(T, T) { return 0; }
|
||||
virtual MxS8 Compare(T, T) { return 0; }
|
||||
|
||||
protected:
|
||||
MxU32 m_count; // +0x8
|
||||
|
||||
@ -61,14 +61,14 @@ class MxHashTable : protected MxCollection<T> {
|
||||
|
||||
MxHashTableNode<T>** m_slots; // +0x10
|
||||
MxU32 m_numSlots; // +0x14
|
||||
MxU32 m_autoResizeRatio;
|
||||
HashTableOpt m_resizeOption; // +0x1c
|
||||
MxU32 m_autoResizeRatio; // +0x18
|
||||
HashTableOpt m_resizeOption; // +0x1c
|
||||
// FIXME: or FIXME? This qword is used as an integer or double depending
|
||||
// on the value of m_resizeOption. Hard to say whether this is how the devs
|
||||
// did it, but a simple cast in either direction doesn't match.
|
||||
union {
|
||||
MxU32 m_increaseAmount;
|
||||
double m_increaseFactor;
|
||||
MxU32 m_increaseAmount; // +0x20
|
||||
double m_increaseFactor; // +0x20
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@ -18,7 +18,7 @@ class MxString : public MxCore {
|
||||
MxString operator+(const char*);
|
||||
MxString& operator+=(const char*);
|
||||
|
||||
inline MxBool Compare(const MxString& p_str) const { return strcmp(m_data, p_str.m_data); }
|
||||
inline MxS8 Compare(const MxString& p_str) const { return strcmp(m_data, p_str.m_data); }
|
||||
inline const char* GetData() const { return m_data; }
|
||||
|
||||
private:
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
#include "mxvariabletable.h"
|
||||
|
||||
// OFFSET: LEGO1 0x100b7330
|
||||
MxBool MxVariableTable::Compare(MxVariable* p_var0, MxVariable* p_var1)
|
||||
MxS8 MxVariableTable::Compare(MxVariable* p_var0, MxVariable* p_var1)
|
||||
{
|
||||
return p_var0->GetKey()->Compare(*p_var1->GetKey());
|
||||
}
|
||||
|
||||
@ -17,8 +17,8 @@ class MxVariableTable : public MxHashTable<MxVariable*> {
|
||||
// OFFSET: LEGO1 0x100afdb0
|
||||
static void Destroy(MxVariable* p_obj) { p_obj->Destroy(); }
|
||||
|
||||
virtual MxBool Compare(MxVariable*, MxVariable*) override; // +0x14
|
||||
virtual MxU32 Hash(MxVariable*) override; // +0x18
|
||||
virtual MxS8 Compare(MxVariable*, MxVariable*) override; // +0x14
|
||||
virtual MxU32 Hash(MxVariable*) override; // +0x18
|
||||
};
|
||||
|
||||
// OFFSET: LEGO1 0x100afcd0 TEMPLATE
|
||||
|
||||
Loading…
Reference in New Issue
Block a user