diff --git a/Spore ModAPI/SourceCode/DLL/AddressesEditors.cpp b/Spore ModAPI/SourceCode/DLL/AddressesEditors.cpp index cdad94b8..fe615275 100644 --- a/Spore ModAPI/SourceCode/DLL/AddressesEditors.cpp +++ b/Spore ModAPI/SourceCode/DLL/AddressesEditors.cpp @@ -82,7 +82,6 @@ namespace Editors DefineAddress(HandleMessage, SelectAddress(0x591C80, 0x591FA0)); - DefineAddress(GetEditorForAssetType, SelectAddress(0x433010, 0x4333e0)); DefineAddress(GetNameForAssetType, SelectAddress(0x4badc0, 0x4bba50)); DefineAddress(GetTypeIDForAssetType, SelectAddress(0x4bb110, 0x4bbda0)); @@ -277,5 +276,27 @@ namespace Editors DefineAddress(GetIconName, SelectAddress(0x5dc880, 0x5e5cb0)); DefineAddress(GetIconDescription, SelectAddress(0x5dc940, 0x5e5d70)); } + + namespace Addresses(EditorBaseHandle) + { + DefineAddress(AddRef, SelectAddress(0x4ad110, 0x51e350)); + DefineAddress(Release, SelectAddress(0x517960, 0x51e390)); + DefineAddress(Cast, SelectAddress(0x47a4d0, 0x47de10)); + DefineAddress(GetTypeID, SelectAddress(0x47a3f0, 0x47dd30)); + DefineAddress(PlaceHandle, SelectAddress(0x459650, 0x4ae770)); + DefineAddress(Init, SelectAddress(0x47a6f0, 0x47e030)); + DefineAddress(Shutdown, SelectAddress(0x47ae80, 0x47e7c0)); + DefineAddress(SetScale, SelectAddress(0x47bf80, 0x47f8e0)); + DefineAddress(GetHandlePosition, SelectAddress(0x47b1c0, 0x47eb00)); + DefineAddress(SetUIState, SelectAddress(0x47b070, 0x47e9b0)); + DefineAddress(AnimateOn, SelectAddress(0x47bf50, 0x47f8b0)); + DefineAddress(SetState, SelectAddress(0x47b7e0, 0x47f140)); + DefineAddress(GetTuningFile, SelectAddress(0x47b780, 0x47f0e0)); + DefineAddress(GetAlpha, SelectAddress(0x47b280, 0x47ebe0)); + DefineAddress(GetOverdrawAlpha, SelectAddress(0x47b3d0, 0x47ed30)); + DefineAddress(GetColor, SelectAddress(0x47b520, 0x47ee80)); + DefineAddress(GetOverdrawColor, SelectAddress(0x47b640, 0x47efa0)); + DefineAddress(GetDefaultScale, SelectAddress(0x47b760, 0x47f0c0)); + } } #endif diff --git a/Spore ModAPI/SourceCode/DLL/AddressesSimulator.cpp b/Spore ModAPI/SourceCode/DLL/AddressesSimulator.cpp index 1a8f37b3..9eedca10 100644 --- a/Spore ModAPI/SourceCode/DLL/AddressesSimulator.cpp +++ b/Spore ModAPI/SourceCode/DLL/AddressesSimulator.cpp @@ -829,6 +829,7 @@ namespace Simulator DefineAddress(SetAtmosphereColor, SelectAddress(0xF32190, 0xF31FF0)); DefineAddress(SetBeachColor, SelectAddress(0xF321E0, 0xF32040)); DefineAddress(SetCliffColor, SelectAddress(0xF32230, 0xF32090)); + DefineAddress(SetVisualEffect, SelectAddress(0xf33a30, 0xf339f0)); } namespace Addresses(cHerd) diff --git a/Spore ModAPI/SourceCode/Editors/Editor.cpp b/Spore ModAPI/SourceCode/Editors/Editor.cpp index 63a1ec85..ac24e7f3 100644 --- a/Spore ModAPI/SourceCode/Editors/Editor.cpp +++ b/Spore ModAPI/SourceCode/Editors/Editor.cpp @@ -201,7 +201,6 @@ namespace Editors auto_STATIC_METHOD_VOID(cEditor, ComputeCreatureVerbIcons, Args(cCreatureDataResource* creatureData, cSPVerbTrayCollection* VerbTrayCollection, int brainLevel, float param_4), Args(creatureData, VerbTrayCollection, brainLevel, param_4)); - auto_STATIC_METHOD(cEditor, bool, LoadCreatureData,Args(ResourceKey* creation, cCreatureDataResource** dst), Args(creation, dst)); auto_METHOD(EditorModel, int, GetSkinEffect, Args(int skinLayout), Args(skinLayout)); diff --git a/Spore ModAPI/SourceCode/Simulator/Scenario.cpp b/Spore ModAPI/SourceCode/Simulator/Scenario.cpp index 69d2bc35..a7c7ea05 100644 --- a/Spore ModAPI/SourceCode/Simulator/Scenario.cpp +++ b/Spore ModAPI/SourceCode/Simulator/Scenario.cpp @@ -45,6 +45,7 @@ namespace Simulator auto_METHOD_VOID(cScenarioTerraformMode, SetAtmosphereColor, Args(const ColorRGB& color), Args(color)); auto_METHOD_VOID(cScenarioTerraformMode, SetCliffColor, Args(const ColorRGB& color), Args(color)); auto_METHOD_VOID(cScenarioTerraformMode, SetBeachColor, Args(const ColorRGB& color), Args(color)); + auto_METHOD_VOID(cScenarioTerraformMode, SetVisualEffect, Args(const ResourceKey& visualEffect), Args(visualEffect)); auto_STATIC_METHOD(cScenarioClass, ScenarioObjectType, GetObjectType, Args(const ResourceKey& key), Args(key)); auto_METHOD_(cScenarioClass, bool, IsConsumible); diff --git a/Spore ModAPI/SourceCode/Terrain/Terrain.cpp b/Spore ModAPI/SourceCode/Terrain/Terrain.cpp index 5fee88a9..1ce2603f 100644 --- a/Spore ModAPI/SourceCode/Terrain/Terrain.cpp +++ b/Spore ModAPI/SourceCode/Terrain/Terrain.cpp @@ -136,14 +136,14 @@ namespace Terrain , mpTextureCliff() , mpAtmospherePackedCurves() , mpAboveColorRamp() - , mpAboveDetailNoise() - , mpPlanetColorRampsDead() - , mpPlanetColorRampsLiving() - , mpPlanetColorRampsIce() - , mpPlanetColorRampsLava() + , mpAbovePackedDetailNoise() + , mpAboveDeadColorRamp() + , mpAboveLiveColorRamp() + , mpAboveColorRampsIce() + , mpAboveColorRampsLava() , field_4C() - , mpJetStream() - , mpPCAWater() + , field_50() + , mpWaterPCATextureResource() { } diff --git a/Spore ModAPI/Spore/Editors/BakeManager.h b/Spore ModAPI/Spore/Editors/BakeManager.h index 65bf09d0..f7cd5373 100644 --- a/Spore ModAPI/Spore/Editors/BakeManager.h +++ b/Spore ModAPI/Spore/Editors/BakeManager.h @@ -62,8 +62,8 @@ namespace Editors /* 00h */ virtual int AddRef(); /* 04h */ virtual void Release(); /* 08h */ virtual bool Init(); - /* 0Ch */ virtual void Shutdown(); - /* 10h */ virtual void PreShutdown(); + /* 0Ch */ virtual void PreShutdown(); + /* 10h */ virtual void Shutdown(); /* 14h */ virtual void Update(); /* 18h */ virtual bool IsBakingOrBaked(const ResourceKey& nameKey); /* 1Ch */ virtual bool IsBaked(const ResourceKey& nameKey, bool param); diff --git a/Spore ModAPI/Spore/Editors/Editor.h b/Spore ModAPI/Spore/Editors/Editor.h index 6338c4df..a6e036f2 100644 --- a/Spore ModAPI/Spore/Editors/Editor.h +++ b/Spore ModAPI/Spore/Editors/Editor.h @@ -60,6 +60,7 @@ #include #include #include +#include /// Access the active editor object; check Editors::cEditor #define Editor (*Editors::GetEditor()) @@ -76,6 +77,38 @@ namespace Editors { class EditorUI; + enum eValidityTests { + kValidityTooComplex = 0, + kValidityOverBudget = 1, + kValidityIncomplete = 2, + kValidityUnloadableTextures = 3, + kValidityInvalidName = 4, + kValidityInvalidParts = 5, + kValidityInvalidParents = 6, + kValidityInvalidScales = 7, + kValidityOutOfBounds = 8, + kValidityTooSmall = 9, + kValidityNoMouth = 0xa, + kValidityNotPainted = 0xb, + kValidityStatsOutOfRange = 0xc, + kValidityHasFloatingParts = 0xd, + kValidityUnloadableBlocks = 0xe, + kValidityInvalidSymmetry = 0xf, + kValidityMissingPacks = 0x10, + kValidityHasZeroBlocks = 0x11, + kValidityInvalidPaint = 0x12, + kValidityIntersectingEndEffectors = 0x13, + kValidityBlankName = 0x14, + kValidityBadCharacters = 0x15, + kValidityTooSmallX = 0x16, + kValidityTooSmallY = 0x17, + kValidityTooSmallZ = 0x18, + kValidityTooSmallAbsoluteZ = 0x19, + kValidityFailedLoad = 0x1a, + kValidityInvalidLimb = 0x1b, + kValidityNoReason = 0x1c + }; + enum class Mode : int { BuildMode = 0, @@ -244,22 +277,16 @@ namespace Editors /* 30h */ int mMouseFlags; /* 34h */ MouseState mMouseState; - /* 38h */ bool field_38; - /* 3Ch */ int field_3C; - /* 40h */ int field_40; // not initialized - /* 44h */ int field_44; // not initialized - /* 48h */ int field_48; - /* 4Ch */ int field_4C; - /* 50h */ int field_50; - /* 54h */ int field_54; - /* 58h */ int field_58; - /* 5Ch */ int field_5C; - /* 60h */ int field_60; - /* 64h */ int field_64; - /* 68h */ float field_68; // Set to 0 when mouse click, and when changing mode + /* 38h */ bool mMouseMoved; + /* 3Ch */ int mModeModifiers; + /* 40h */ int mControlModifierMode; // not initialized + /* 44h */ int mEyeDropperModiferMode; // not initialized + /* 48h */ eastl::bitset<128> mModelValidity; + /* 58h */ eastl::bitset<128> mModelSaveValidity; + /* 68h */ float mIdleTime; // Set to 0 when mouse click, and when changing mode /// Time to wait before starting animated creature (in milliseconds). /* 6Ch */ float mCreatureIdleActivationTime; - /* 70h */ float field_70; + /* 70h */ float mSwapToModelTime; /* 74h */ bool field_74; //TODO ManagedPtr @@ -289,12 +316,11 @@ namespace Editors /* A8h */ ModelPtr mpBackgroundModel; // used in loc_5874D8 /// A background model used in accessories editors. It belongs to mpBackgroundModelWorld. /* ACh */ ModelPtr mpAccBackgroundModel; - /* B0h */ eastl::string16 field_B0; + /* B0h */ eastl::string16 mOriginalTag; // /* B9h */ bool editorShowAbilityIcons; // might also be 4B6h ? - /* C0h */ int field_C0; // not initialized // lastMouseClick[2] ? - /* C4h */ int field_C4; // not initialized - /* C8h */ int field_C8; // not initialized + /* C0h */ int mMouseDownPosition[2]; // not initialized // lastMouseClick[2] ? + /* C8h */ float mRolloverTime; // not initialized // also valid for spines /// Rigblock that is being hovered, and where actions like mouse wheel scaling will be applied diff --git a/Spore ModAPI/Spore/Editors/EditorBaseHandle.h b/Spore ModAPI/Spore/Editors/EditorBaseHandle.h index 03370624..4ea2f2ed 100644 --- a/Spore ModAPI/Spore/Editors/EditorBaseHandle.h +++ b/Spore ModAPI/Spore/Editors/EditorBaseHandle.h @@ -28,19 +28,24 @@ namespace Editors { public: static const uint32_t TYPE = 0x50A1FE5; + EditorBaseHandle(); + virtual ~EditorBaseHandle(); + virtual int AddRef() override; + virtual int Release() override; + virtual void* Cast(uint32_t typeID) const override; /* 10h */ virtual uint32_t GetTypeID(); - /* 14h */ virtual void func14h(); + /* 14h */ virtual void PlaceHandle(); // also used to unload - /* 18h */ virtual void Load(EditorRigblock* pRigblock, bool load, uint32_t modelID, uint32_t overdrawModelID); - /* 1Ch */ virtual void Dispose(); + /* 18h */ virtual void Init(EditorRigblock* pRigblock, bool initHandles, uint32_t pHandleModel, uint32_t pOverdrawHandleModel); + /* 1Ch */ virtual void Shutdown(); /// Sets the scale (scaling the model and overdraw model), which gets multiplied by `mDefaultScale` /// @param scale /* 20h */ virtual void SetScale(float scale); - /* 24h */ virtual Math::Vector3 GetPosition(); - /* 28h */ virtual void func28h(int, bool); - /* 2Ch */ virtual void func2Ch(); - /* 30h */ virtual void func30h(int, bool); + /* 24h */ virtual Math::Vector3 GetHandlePosition(); + /* 28h */ virtual void SetUIState(bool pSetHightlight, EditorHandleState state); + /* 2Ch */ virtual void AnimateOn(); + /* 30h */ virtual void SetState(EditorHandleState state, bool animateIt); /* 34h */ virtual ResourceKey GetTuningFile(); /* 38h */ virtual float GetAlpha(EditorHandleState state); /* 3Ch */ virtual float GetOverdrawAlpha(EditorHandleState state); @@ -53,7 +58,7 @@ namespace Editors /* 10h */ EditorRigblock* mpRigblock; /* 14h */ ModelPtr mpModel; /* 18h */ ModelPtr mpOverdrawModel; - /* 1Ch */ int field_1C; // not initialized, maybe state? + /* 1Ch */ EditorHandleState mCurrentState; // not initialized, maybe state? /* 20h */ float mFadeInTime; /* 24h */ float mFadeOutTime; /* 28h */ float mAnimateInTime; @@ -62,6 +67,95 @@ namespace Editors /* 3Ch */ ResourceKey mDefaultOverdrawModel; /* 48h */ bool mHasOverdraw; /* 4Ch */ float mDefaultScale; - //TODO uncompleted, 8Ch is animation ID? 11Ch is string stretchSound? }; + ASSERT_SIZE(EditorBaseHandle, 0x50); + + namespace Addresses(EditorBaseHandle) + { + DeclareAddress(AddRef); + DeclareAddress(Release); + DeclareAddress(Cast); + DeclareAddress(GetTypeID); + DeclareAddress(PlaceHandle); + DeclareAddress(Init); + DeclareAddress(Shutdown); + DeclareAddress(SetScale); + DeclareAddress(GetHandlePosition); + DeclareAddress(SetUIState); + DeclareAddress(AnimateOn); + DeclareAddress(SetState); + DeclareAddress(GetTuningFile); + DeclareAddress(GetAlpha); + DeclareAddress(GetOverdrawAlpha); + DeclareAddress(GetColor); + DeclareAddress(GetOverdrawColor); + DeclareAddress(GetDefaultScale); + } + + inline EditorBaseHandle::EditorBaseHandle() + : mpPropList(nullptr) + , mpRigblock(nullptr) + , mpModel(nullptr) + , mpOverdrawModel(nullptr) + , mCurrentState() + , mFadeInTime() + , mFadeOutTime() + , mAnimateInTime() + , mAnimateOutTime() + , mDefaultModel() + , mDefaultOverdrawModel() + , mHasOverdraw(false) + , mDefaultScale(1.0) + { + } + inline EditorBaseHandle::~EditorBaseHandle() { + EditorBaseHandle::Shutdown(); + } + inline int EditorBaseHandle::AddRef() { + return DefaultRefCounted::AddRef(); + } + inline int EditorBaseHandle::Release() { + return DefaultRefCounted::Release(); + } + inline void* EditorBaseHandle::Cast(uint32_t type) const { + CLASS_CAST(Object); + CLASS_CAST(EditorBaseHandle); + return nullptr; + } + inline float EditorBaseHandle::GetAlpha(EditorHandleState state) + { + return 1; + } + inline float EditorBaseHandle::GetOverdrawAlpha(EditorHandleState state) + { + return 1; + } + inline Math::ColorRGB EditorBaseHandle::GetColor(EditorHandleState state) + { + return { 1,1,1 }; + } + inline Math::ColorRGB EditorBaseHandle::GetOverdrawColor(EditorHandleState state) + { + return { 1,1,1 }; + } + +#ifndef SDK_TO_GHIDRA + + inline auto_METHOD_(EditorBaseHandle, uint32_t, GetTypeID); + inline auto_METHOD_VOID_(EditorBaseHandle, PlaceHandle); + inline auto_METHOD_VOID(EditorBaseHandle, Init, Args(EditorRigblock* pRigblock, bool initHandles, uint32_t pHandleModel, uint32_t pOverdrawHandleModel), Args(pRigblock, initHandles, pHandleModel, pOverdrawHandleModel)); + inline auto_METHOD_VOID_(EditorBaseHandle, Shutdown); + inline auto_METHOD_VOID(EditorBaseHandle, SetScale, Args(float scale), Args(scale)); + inline auto_METHOD_(EditorBaseHandle, Math::Vector3, GetHandlePosition); + inline auto_METHOD_VOID(EditorBaseHandle, SetUIState, Args(bool pSetHightlight, EditorHandleState state), Args(pSetHightlight, state)); + inline auto_METHOD_VOID_(EditorBaseHandle, AnimateOn); + inline auto_METHOD_VOID(EditorBaseHandle, SetState, Args(EditorHandleState state, bool animateIt), Args(state, animateIt)); + inline auto_METHOD_(EditorBaseHandle, ResourceKey, GetTuningFile); + //inline auto_METHOD(EditorBaseHandle, float, GetAlpha, Args(EditorHandleState state), Args(state)); + //inline auto_METHOD(EditorBaseHandle, float, GetOverdrawAlpha, Args(EditorHandleState state), Args(state)); + //inline auto_METHOD(EditorBaseHandle, Math::ColorRGB, GetColor, Args(EditorHandleState state), Args(state)); + //inline auto_METHOD(EditorBaseHandle, Math::ColorRGB, GetOverdrawColor, Args(EditorHandleState state), Args(state)); + inline auto_METHOD_(EditorBaseHandle, float, GetDefaultScale); + +#endif } \ No newline at end of file diff --git a/Spore ModAPI/Spore/Editors/VerbIconData.h b/Spore ModAPI/Spore/Editors/VerbIconData.h index af87e6ef..37fb0580 100644 --- a/Spore ModAPI/Spore/Editors/VerbIconData.h +++ b/Spore ModAPI/Spore/Editors/VerbIconData.h @@ -65,6 +65,7 @@ namespace Editors { public: static const uint32_t TYPE = 0x4AA0ACD; + VerbIconData(); /* 00h */ virtual int AddRef() override; /* 04h */ virtual int Release() override; @@ -74,36 +75,33 @@ namespace Editors /* 14h */ virtual void Shutdown(); /* 18h */ virtual void SetArrayIndex(int arrayIndex); /// Used to generate text - /* 20h */ virtual void SetKey(int verbIconTriggerKey); - /* 24h */ virtual eastl::string16 GetName(bool includeLevel); - /* 28h */ virtual eastl::string16 GetDescription(); /* 1Ch */ virtual void SetHotKey(int verbIconTriggerKey); - /* 20h */ virtual eastl::string16 GetIconName(eastl::string16* iconName, bool includeLevel); + /* 20h */ virtual eastl::string16 GetIconName(bool includeLevel); /* 24h */ virtual eastl::string16* GetIconDescription(); public: - /* 0Ch */ bool mVerbIconUseDescription; // true - /* 0Dh */ bool mVerbIconShowLevel; // true - /* 0Eh */ bool mPaletteItemRolloverShowLevel; // true - /* 0Fh */ bool mVerbIconRolloverShowLevel; // true - /* 10h */ bool mShowHotKey; - /* 11h */ bool mVerbIconShowZeroLevel; - /* 14h */ int mVerbIconTriggerKey; // -1 - /* 18h */ float mVerbIconLevel; // not initialized - /* 1Ch */ float mVerbIconMaxLevel; - /* 20h */ int field_20; // not initialized - /* 24h */ uint32_t mVerbIconCategory; + /* 0Ch */ bool mVerbIconUseDescription; // true + /* 0Dh */ bool mVerbIconShowLevel; // true + /* 0Eh */ bool mPaletteItemRolloverShowLevel; // true + /* 0Fh */ bool mVerbIconRolloverShowLevel; // true + /* 10h */ bool mShowHotKey; // false + /* 11h */ bool mVerbIconShowZeroLevel; // false + /* 14h */ int mVerbIconTriggerKey; // -2 + /* 18h */ float mVerbIconLevel; // not initialized + /* 1Ch */ float mVerbIconMaxLevel; // 5.0 + /* 20h */ int field_20; + /* 24h */ uint32_t mVerbIconCategory; // not initialized /* 28h */ uint32_t mVerbIconRepresentativeAnimation; // -1 /* 2Ch */ Math::ColorRGBA mVerbIconColor; /* 3Ch */ uint32_t mVerbIconRolloverLevelImageID; /* 40h */ ResourceKey mVerbIconRolloverLevelLayoutID; - /* 4Ch */ bool mVerbIconRolloverShowIcon; // not initialized - /* 4Dh */ bool mVerbIconEnforceMaxLevel; - /* 50h */ uint32_t mCreatureAbilityCategory; // not initialized + /* 4Ch */ bool mVerbIconRolloverShowIcon; + /* 4Dh */ bool mVerbIconEnforceMaxLevel; // false + /* 50h */ uint32_t mCreatureAbilityCategory; // not initialized /* 54h */ LocalizedString mCreatureAbilityName; /* 68h */ eastl::string16 field_68; /* 78h */ uint32_t mTriggerKeyForLocalization; - /* 7Ch */ int field_7C; // -1 - /* 80h */ int field_80; // -1 + /* 7Ch */ int field_7C; // -1 + /* 80h */ int field_80; // -1 /* 84h */ int field_84; /* 88h */ int field_88; /* 8Ch */ int field_8C; @@ -113,7 +111,7 @@ namespace Editors /* 9Ch */ ResourceKey mVerbIconLayout; /* A8h */ ResourceKey mVerbIconGameLayout; /* B4h */ ResourceKey mVerbIconStaticLayout; - /* C0h */ PropertyListPtr mpPropList; + /* C0h */ PropertyListPtr mpPropList; // not initialized }; ASSERT_SIZE(VerbIconData, 0xC4); @@ -128,7 +126,65 @@ namespace Editors DeclareAddress(SetArrayIndex); DeclareAddress(SetHotKey); DeclareAddress(GetIconName); - DeclareAddress(OnKeyDown); DeclareAddress(GetIconDescription); } + + inline VerbIconData::VerbIconData() + : mVerbIconUseDescription(true) + , mVerbIconShowLevel(true) + , mPaletteItemRolloverShowLevel(true) + , mVerbIconRolloverShowLevel(true) + , mShowHotKey(false) + , mVerbIconShowZeroLevel(false) + , mVerbIconTriggerKey(-2) + , mVerbIconLevel() + , mVerbIconMaxLevel(5.0) + , field_20() + , mVerbIconCategory() + , mVerbIconRepresentativeAnimation() + , mVerbIconColor() + , mVerbIconRolloverLevelImageID() + , mVerbIconRolloverLevelLayoutID() + , mVerbIconRolloverShowIcon() + , mVerbIconEnforceMaxLevel() + , mCreatureAbilityCategory() + , mCreatureAbilityName(LocalizedString()) + , field_68(eastl::string16()) + , mTriggerKeyForLocalization() + , field_7C(-1) + , field_80(-1) + , field_84() + , field_88() + , field_8C() + , mVerbIconImageID() + , mVerbIconTrayOverrideImageID() + , mVerbIconTraySmallCardOverrideImageID() + , mVerbIconLayout() + , mVerbIconGameLayout() + , mVerbIconStaticLayout() + , mpPropList(nullptr) + { + } + inline VerbIconData::~VerbIconData() {} + inline int VerbIconData::AddRef() { + return DefaultRefCounted::AddRef(); + } + inline int VerbIconData::Release() { + return DefaultRefCounted::Release(); + } + inline void* VerbIconData::Cast(uint32_t type) const { + CLASS_CAST(Object); + CLASS_CAST(VerbIconData); + return nullptr; + } +#ifndef SDK_TO_GHIDRA + + inline auto_METHOD_VOID(VerbIconData, Init, Args(App::PropertyList* propList), Args(propList)); + inline auto_METHOD_VOID_(VerbIconData, Shutdown); + inline auto_METHOD_VOID(VerbIconData, SetArrayIndex, Args(int arrayIndex), Args(arrayIndex)); + inline auto_METHOD_VOID(VerbIconData, SetHotKey, Args(int verbIconTriggerKey), Args(verbIconTriggerKey)); + inline auto_METHOD(VerbIconData, eastl::string16, GetIconName, Args(bool includeLevel), Args(includeLevel)); + inline auto_METHOD_(VerbIconData, eastl::string16*, GetIconDescription); + +#endif } diff --git a/Spore ModAPI/Spore/Editors/cSPEditorVerbTrayCollection.h b/Spore ModAPI/Spore/Editors/cSPEditorVerbTrayCollection.h index 53c6818d..1adbfcd0 100644 --- a/Spore ModAPI/Spore/Editors/cSPEditorVerbTrayCollection.h +++ b/Spore ModAPI/Spore/Editors/cSPEditorVerbTrayCollection.h @@ -12,5 +12,5 @@ namespace Editors public: static const uint32_t TYPE = 0x4aa3b42; }; - ASSERT_SIZE(cSPEditorVerbTrayCollection, 0x58); + ASSERT_SIZE(cSPEditorVerbTrayCollection, 0x54); } \ No newline at end of file diff --git a/Spore ModAPI/Spore/Editors/cSPVerbTrayCollection.h b/Spore ModAPI/Spore/Editors/cSPVerbTrayCollection.h index e9194a65..9aab24ff 100644 --- a/Spore ModAPI/Spore/Editors/cSPVerbTrayCollection.h +++ b/Spore ModAPI/Spore/Editors/cSPVerbTrayCollection.h @@ -12,15 +12,11 @@ namespace Editors { - class cSPVerbTrayCollection - : public UTFWin::IWinProc - , public DefaultRefCounted + class ISPVerbTrayCollection { public: - static const uint32_t TYPE = 0x4976064; - - /* 00h */ virtual int AddRef() override; - /* 04h */ virtual int Release() override; + //* 00h */ virtual int AddRef(); + //* 04h */ virtual int Release(); //* 08h */ virtual ~cSPVerbTrayCollection(); //* 0Ch */ virtual void* Cast(uint32_t typeID); /* 10h */ virtual void Init(App::PropertyList* propList); @@ -30,10 +26,28 @@ namespace Editors /* 20h */ virtual UTFWin::IWindow* GetTrayWindow(uint32_t controlID); /* 24h */ virtual void InitTrays(uint32_t instanceID, uint32_t typeID, uint32_t groupID); /* 28h */ virtual void LayoutCollection(); + }; + class cSPVerbTrayCollection + : public ISPVerbTrayCollection + , public DefaultRefCounted + { + public: + static const uint32_t TYPE = 0x4976064; + + /* 00h */ virtual int AddRef() override; + /* 04h */ virtual int Release() override; + //* 08h */ virtual ~cSPVerbTrayCollection(); + //* 0Ch */ virtual void* Cast(uint32_t typeID); + /* 10h */ virtual void Init(App::PropertyList* propList) override; + /* 14h */ virtual void SetTrayData(eastl::vector*) override; + /* 18h */ virtual void Shutdown() override; + /* 1Ch */ virtual void Update(App::PropertyList* propList) override; + /* 20h */ virtual UTFWin::IWindow* GetTrayWindow(uint32_t controlID) override; + /* 24h */ virtual void InitTrays(uint32_t instanceID, uint32_t typeID, uint32_t groupID) override; + /* 28h */ virtual void LayoutCollection() override; public: /* 0Ch */ eastl::vector mVerbTrays; - /* 1Ch */ int field_1C; /* 20h */ IWindowPtr mWinParent; /* 24h */ IWindowPtr mWinVerbTray; /* 28h */ eastl::map mWindowsToVerbTrays; @@ -42,6 +56,6 @@ namespace Editors /* 4Ch */ eLayoutStyle mLayoutStyle; //kFill /* 50h */ bool field_50; //false }; - ASSERT_SIZE(cSPVerbTrayCollection, 0x58); + ASSERT_SIZE(cSPVerbTrayCollection, 0x54); } diff --git a/Spore ModAPI/Spore/Simulator/cObstacle.h b/Spore ModAPI/Spore/Simulator/cObstacle.h index 16961d29..65696b0b 100644 --- a/Spore ModAPI/Spore/Simulator/cObstacle.h +++ b/Spore ModAPI/Spore/Simulator/cObstacle.h @@ -2,6 +2,7 @@ #include #include +#include #define cObstaclePtr eastl::intrusive_ptr @@ -26,22 +27,22 @@ namespace Simulator }; public: - /* 34h */ int field_34; + /* 34h */ eastl::bitset<3> mFlags; /* 38h */ Math::Vector3 mPosition; /* 44h */ float mObstacleBaseCollisionRadius; /* 48h */ float mObstacleCanopyCollisionRadius; /* 4Ch */ float mObstacleCollisionHeight; - /* 50h */ int field_50; // -1 - /* 54h */ int field_54; - /* 58h */ int field_58; - /* 5Ch */ int field_5C; // -1 - /* 60h */ int field_60; // not initialized - /* 64h */ int field_64; // -1 - /* 68h */ int field_68; // 1.0 - /* 6Ch */ int field_6C; // not initialized + /* 50h */ int mSeqID; // -1 + /* 54h */ int mDistributeEffect; + /* 58h */ int mDistributeSamples; + /* 5Ch */ int mSequenceNumIdx; // -1 + /* 60h */ uint32_t mID; // not initialized + /* 64h */ uint32_t mGridID; // -1 + /* 68h */ float mAlpha; // 1.0 + /* 6Ch */ uint32_t mModelID; // not initialized /* 70h */ ModelPtr mModel; - /* 74h */ int field_74; - /* 78h */ int field_78; + /* 74h */ uint32_t mAlphaModelID; + /* 78h */ ModelPtr mAlphaModel; /* 7Ch */ ResourceKey mSpeciesKey; /* 88h */ PlantType mPlantType; }; diff --git a/Spore ModAPI/Spore/Simulator/cScenarioTerraformMode.h b/Spore ModAPI/Spore/Simulator/cScenarioTerraformMode.h index c35f9270..b228ebc0 100644 --- a/Spore ModAPI/Spore/Simulator/cScenarioTerraformMode.h +++ b/Spore ModAPI/Spore/Simulator/cScenarioTerraformMode.h @@ -33,6 +33,8 @@ namespace Simulator void SetCliffColor(const ColorRGB& color); void SetBeachColor(const ColorRGB& color); + void SetVisualEffect(const ResourceKey& visuaiEffect); + public: /* 0Ch */ PropertyListPtr mpPropList; /* 10h */ cScenarioTerraformEconomyPtr mpEconomy; @@ -90,5 +92,6 @@ namespace Simulator DeclareAddress(SetAtmosphereColor); // 0xF32190, 0xF31FF0 DeclareAddress(SetBeachColor); // 0xF321E0, 0xF32040 DeclareAddress(SetCliffColor); // 0xF32230, 0xF32090 + DeclareAddress(SetVisualEffect); //0xf33a30, 0xf339f0 } } \ No newline at end of file diff --git a/Spore ModAPI/Spore/Sporepedia/OTDBParameters.h b/Spore ModAPI/Spore/Sporepedia/OTDBParameters.h index f89daabf..315a1418 100644 --- a/Spore ModAPI/Spore/Sporepedia/OTDBParameters.h +++ b/Spore ModAPI/Spore/Sporepedia/OTDBParameters.h @@ -65,6 +65,81 @@ namespace Sporepedia namespace Parameters { + enum eParameterIDs + { + /// General + kParameterIDPublished = 0x05fb4759, + kParameterIDFeedID = 0x03cc89b1, //kParameterIDThemeID + kParameterIDContentSource = 0x05dc0b88, + kParameterTimeDownloaded = 0x061ef9b1, + kParamIDType = 0xdd90af, + kParamIDSubType = 0x2dc9d1e, + kParameterIDGAProp = 0xcd6e902c, + kParameterIDValidationPlayable = 0x54a32960, + kParameterIDValidationPollinatable = 0x54a32961, + kParameterIDValidationViewableLarge = 0x0665f917, + kParameterIDValidationEditable = 0x067b82d8, + kParameterIDExpansionPackage = 0x17a1c72d, + + /// Creature + kParameterIDCreatureSpeciesArchetype = 0x52def3f, + kParameterIDCreatureSpeciesArchetypeQuery = 0x052def4b, + kParamIDCreatureCarnivore = 0x2f05c58, + kParamIDCreatureHerbivore = 0x2f05c59, + kParamIDCreatureTotalAttack = 0x3fea1a0, + kParamIDCreatureTotalSocial = 0x2f05c5f, + + /// Vehicle + kParameterIDVehicleDefense = 0x0429d47d, + kParameterIDVehicleSpeed = 0x0429d47e, + kParameterIDVehiclePower = 0x0429d47c, + kParameterIDVehicleTotalScore = 0x05b950d7, + kParameterIDVehicleType = 0x05c96ff0, + + /// Vehicle/Building + // F08 Build + kParameterIDBoundingBoxX = 0x05de94e6, + kParameterIDBoundingBoxY = 0x05de94e7, + kParameterIDBoundingBoxZ = 0x05de94e8, + kParameterIDBoundingBoxTotalF08 = 0x05de94e9, + + // Release + kParameterIDBoundingBoxHeight = 0x05de94ea, //BoundingBoxMaxZ + kParameterIDBoundingBoxTotal = 0x05e62409, + + /// Adventure + kParameterIDAdventureCompleted = 0x15e8afc8, //in Space Stage? + kParameterIDAdventureCannotEdit = 0xb91fba14, + kParameterIDAdventureMissingAsset = 0xd22f5e35, + kParameterIDAdventureAvatarLocked = 0x5a3584a7, + kParameterIDAdventureInvalidVersion = 0xdb4675dd + }; + + enum eFeedIDs + { + kFeedIDShippingContent = 0x913b23be, //Assembled + kFeedIDLocalContent = 0x5a3b873d, + kFeedIDPollinatedContent = 0x058669b4 //Imported + }; + + enum eContentSourceIDs + { + kContentSourceAssembled = 0, + kContentSourceMatched = 1, + kContentSourceImported = 2 + }; + + enum eExpansionPackageIDs + { + kExpansionPackageCoreGame = 1, + }; + + enum eVehicleTypes + { + kVehicleTypeWater = 0x05c972ee, + kVehicleTypeLand = 0x05c972ea, + kVehicleTypeAir = 0x05c972f1, + }; // TODO: Some of these don't seem to work; the ones that are verified to work are commented. enum Parameters : uint32_t { diff --git a/Spore ModAPI/Spore/Sporepedia/ObjectTemplateDB.h b/Spore ModAPI/Spore/Sporepedia/ObjectTemplateDB.h index efac8e98..0ba50f58 100644 --- a/Spore ModAPI/Spore/Sporepedia/ObjectTemplateDB.h +++ b/Spore ModAPI/Spore/Sporepedia/ObjectTemplateDB.h @@ -1,14 +1,65 @@ #pragma once #include +#include +#include +#include +#include +#include +#include #define ObjectTemplateDB (*Sporepedia::OTDB::cObjectTemplateDB::Get()) +#define cISummarizerPtr eastl::intrusive_ptr namespace Sporepedia { namespace OTDB { + + struct cID + { + uint32_t mnTraitClass; + uint32_t mnTraitType; + }; + struct cFeatureVector + { + //vector_map,eastl::allocator,eastl::vector,eastl::allocator>_> + eastl::vector_map mTraitMap; + float mfLen; + }; + + struct MutliModeDistance + { + /* 00h */ cFeatureVector mTraitCounts; + /* 1Ch */ cFeatureVector mInverseDocumentFrequency; + + //vector_map,eastl::allocator,eastl::vector,eastl::allocator>_> + /* 38h */ eastl::vector_map mTestTuningWeights; + /* 50h */ bool mbUseTestWeights; + /* 54h */ uint32_t mDistanceType; + }; + + struct AssetInfo + { + /* 00h */ ResourceKey mKey; + /* 0Ch */ uint32_t mnModelSubtype; + /* 10h */ cFeatureVector mFeatureVector; + /* 2Ch */ eastl::vector mConsequenceTraits; //contains ids from herdtypes~ + /* 40h */ int field_40[4]; + }; + + struct RandomLinearCongruential + { + uint32_t mnSeed; + }; + + struct cClassifierFactory + { + //vector_map,eastl::allocator,eastl::vector,eastl::allocator>_> + eastl::vector_map mFactoryFunctionMap; + }; + class ISummarizer : public DefaultRefCounted { @@ -20,219 +71,150 @@ namespace Sporepedia /* 20h */ virtual bool SetParameters(const ResourceKey& key, eastl::vector& dst) = 0; }; - enum InterfaceId + class cIMatchTuning { + public: + static const uint32_t TYPE = 0x4ed5013; + + /* 00h */ virtual int AddRef(); + /* 04h */ virtual int Release(); + /* 08h */ virtual bool GetTraitVector(const ResourceKey& key, const cFeatureVector& traits); + /* 0Ch */ virtual void* GetClassNameForTrait(const cID& traitID); + /* 10h */ virtual void* cIMatchTuning_GetClassName(uint32_t nClassifierGUID); + /* 14h */ virtual bool DescribeResource(ResourceKey*, void*); + /* 18h */ virtual void SetDistanceFunc(uint32_t); + /* 1Ch */ virtual void SetTestWeights(void*); + /* 20h */ virtual void GetTuningWeights(void*); + /* 24h */ virtual void UseTestWeights(bool); + /* 28h */ virtual bool TunningWeightsEnabled(); }; - class cObjectTemplateDB - : public Object + class IObjectTemplateDB { public: - static cObjectTemplateDB* Get(); - /* 00h */ virtual int AddRef(); /* 04h */ virtual int Release(); - /* 08h */ virtual void* Dispose(); - /* 0Ch */ virtual void* AsInterface(InterfaceId mID); + /* 08h */ virtual ~IObjectTemplateDB(); + /* 0Ch */ virtual void* AsInterface(uint32_t mID); /* 10h */ virtual bool Init(); /* 14h */ virtual bool Shutdown(); - /* 18h */ virtual bool Write(bool, bool writeSummarizers); + + //ReIndexIfNecessary + /* 18h */ virtual bool Write(bool rewriteSummarizers, bool); /* 1Ch */ virtual bool func1Ch(); /* 20h */ virtual void func20h(); - /* 24h */ virtual bool func24h(eastl::vector& creation, int, const eastl::vector& parameters); - /* 28h */ virtual bool func28h(eastl::vector& dstKeys);//, int, const eastl::vector& parameters); - /* 2Ch */ virtual void FindObjects(eastl::vector& dst, const eastl::vector& parameters); - //TODO thse functions are placeholders - /* 30h */ virtual bool func30h(eastl::vector& creations, uint32_t param_2, const eastl::vector& parameters); - /* 34h */ virtual bool func34h(eastl::vector& creations); - /* 38h */ virtual void func38h(eastl::vector& creations, const eastl::vector& parameters); - /* 3Ch */ virtual bool func3Ch(eastl::vector& creations, uint32_t param_2, const ResourceKey& creation, const eastl::vector& parameters); - /* 40h */ virtual bool func40h(uint32_t param1, int* param2); - /* 44h */ virtual bool func44h(uint32_t param1, int* param2); - /* 48h */ virtual bool func48h(uint32_t param1, int* param2, eastl::vector& creations); - /* 4Ch */ virtual bool func4Ch(uint32_t param1, int* param2, eastl::vector& creations); - /* 50h */ virtual void func50h(int param); - /* 54h */ virtual void func54h(); - /* 58h */ virtual bool func58h(const ResourceKey& creation, bool param);//ResourceKey* - /* 5Ch */ virtual bool func5Ch(const ResourceKey& creation); + + /// Creates the asset list. Used in the game modes and for plants randomizer in Scenario Mode + /// @param keyList Pointer where the asset list will be created + /// @param request determines which creations should be added to the asset list + /// @return Return true if asset list was created, otherwise return false + /* 24h */ virtual bool GetAssetList(eastl::vector& keyList, uint32_t nNumResults, const eastl::vector& request); + + /// Creates the asset list. Uknown where this is used + /// @param keyList Pointer where the asset list will be created + /// @param request determines which creations should be added to the asset list + /// @return Return true if asset list was created, otherwise return false + /* 28h */ virtual bool GetAssetListUnknown(eastl::vector& keyList, const eastl::vector& request); + + /// Creates the asset list of pollinated adventures that can be used as mission + /// @param keyList Pointer where the asset list will be created + /// @param request determines which creations should be added to the asset list + /* 2Ch */ virtual void GetPollinatedAdventureList(eastl::vector& keyList, const eastl::vector& request); + + /// Creates the asset list that can be used in adventure: creatures, vehicles and buildings + /// @param keyList Pointer where the asset list will be created + /// @param request determines which creations should be added to the asset list + /// @return Return true if asset list was created, otherwise return false + /* 30h */ virtual bool GetAssetListToAdventure(eastl::vector& keyList, uint32_t nNumResults, const eastl::vector& request); + + /// [Crash the game] Creates the asset list that can be used in new game and showed up in sporepedia + /// @param keyList Pointer where the asset list will be created + /// @return Return true if asset list was created, otherwise return false + /* 34h */ virtual bool GetBrowserAssetList(eastl::vector& keyList); + + /// Creates the asset list that can be showed up in sporepedia and used in quick play(?) + /// @param keyList Pointer where the asset list will be created + /// @param request determines which creations should be added to the asset list + /* 38h */ virtual void GetAdventureAssetList(eastl::vector& keyList, const eastl::vector& request); + + /// Creates the asset list that can be used in the Civ and Space Modes for civilizations and empires + /// @param keyList Pointer where the asset list will be created + /// @param request determines which creations should be added to the asset list + /// @return Return true if asset list was created, otherwise return false + /* 3Ch */ virtual bool GetMatchedAssetList(eastl::vector& creations, uint32_t param_2, const ResourceKey& creation, const eastl::vector& request); + + /* 40h */ virtual bool GetParameterIntValues(uint32_t parameter, eastl::vector& intValues); + /* 44h */ virtual bool GetParameterFloatValues(uint32_t parameter, eastl::vector& floatValues); + /* 48h */ virtual bool GetParameterIntInfo(uint32_t parameter, eastl::vector& intValues, eastl::vector& keyList); + /* 4Ch */ virtual bool GetParameterFloatInfo(uint32_t parameter, eastl::vector& floatValues, eastl::vector& keyList); + /* 50h */ virtual void SetTheme(uint32_t themeID); + /* 54h */ virtual void ClearTheme(); + /* 58h */ virtual bool SetInUse(const ResourceKey& key, bool bInUse); + /* 5Ch */ virtual bool IsCreationInUse(const ResourceKey& key); + + ///Add creation in asset list? /* 60h */ virtual bool func60h(const ResourceKey& creation); + /* 64h */ virtual void func64h(uint32_t param1, eastl::vector& creations, int param); /* 68h */ virtual void func68h(); /* 6Ch */ virtual void func6Ch(uint32_t param_1, uint32_t param_2); //App::Property - /* 70h */ virtual bool func70h(const ResourceKey& creation); + /* 70h */ virtual bool RegisterAsset(const ResourceKey& assetToRegist); /* 74h */ virtual bool PurgeAssetSummarizer(const ResourceKey& creation, bool param); /* 78h */ virtual void PurgeAsset(const ResourceKey& creation, bool param); /* 7Ch */ virtual bool AddSummarizer(ISummarizer* pSummarizer); - /* 80h */ virtual bool func80h(const ResourceKey& creation, int* param); + /* 80h */ virtual bool GetAssetType(const ResourceKey& creation, int* param); /* 84h */ virtual bool func84h(const ResourceKey& creation, uint32_t* param_2); /* 88h */ virtual void func88h(); + }; + class cObjectTemplateDB + : public IObjectTemplateDB + , public cIMatchTuning + , public App::IMessageListener + , public DefaultRefCounted + { public: + static cObjectTemplateDB* Get(); - /* 04h */ int field_04; - /* 08h */ int field_08; - /* 0Ch */ int field_0C; - /* 10h */ int field_10; - /* 14h */ int field_14; - /* 18h */ int field_18; - /* 1Ch */ int field_1C; - /* 20h */ int field_20; - /* 24h */ int field_24; - /* 28h */ int field_28; - /* 2Ch */ int field_2C; - /* 30h */ int field_30; - /* 34h */ int field_34; - /* 38h */ int field_38; - /* 3Ch */ int field_3C; + static const uint32_t TYPE = 0x4ed03fd; + /* 00h */ virtual int AddRef() override; + /* 04h */ virtual int Release() override; + /* 08h */ virtual ~cObjectTemplateDB(); + /* 0Ch */ virtual void* AsInterface(uint32_t mID); + + public: + /* 14h */ eastl::vector mAssetList; + /* 24h */ eastl::vector_set mFreeList; /* 40h */ bool field_40; - /* 41h */ bool field_41; - /* 42h */ bool field_42; - /* 43h */ bool field_43; - /* 44h */ int field_44; - /* 48h */ int field_48; - /* 4Ch */ int field_4C; - /* 50h */ int field_50; - /* 54h */ int field_54; - /* 58h */ int field_58; - /* 5Ch */ int field_5C; - /* 60h */ int field_60; - /* 64h */ int field_64; - /* 68h */ int field_68; - /* 6Ch */ int field_6C; - /* 70h */ int field_70; - /* 74h */ int field_74; - /* 78h */ int field_78; - /* 7Ch */ int field_7C; - /* 80h */ int field_80; - /* 84h */ int field_84; - /* 88h */ int field_88; - /* 8Ch */ int field_8C; - /* 90h */ int field_90; - /* 94h */ int field_94; - /* 98h */ int field_98; - /* 9Ch */ int field_9C; - /* A0h */ int field_A0; - /* A4h */ int field_A4; - /* A8h */ int field_A8; - /* ACh */ int field_AC; - /* B0h */ int field_B0; - /* B4h */ int field_B4; - /* B8h */ int field_B8; - /* BCh */ int field_BC; - /* C0h */ int field_C0; - /* C4h */ int field_C4; - /* C8h */ int field_C8; - /* CCh */ int field_CC; - /* D0h */ int field_D0; - /* D4h */ int field_D4; - /* D8h */ int field_D8; - /* DCh */ int field_DC; - /* E0h */ int field_E0; - /* E4h */ int field_E4; - /* E8h */ int field_E8; - /* ECh */ int field_EC; - /* F0h */ int field_F0; - /* F4h */ int field_F4; - /* F8h */ int field_F8; - /* FCh */ int field_FC; - /* 100h */ int field_100; - /* 104h */ int field_104; - /* 108h */ int field_108; - /* 10Ch */ int field_10C; - /* 110h */ int field_110; - /* 114h */ int field_114; - /* 118h */ int field_118; - /* 11Ch */ int field_11C; - /* 120h */ int field_120; - /* 124h */ int field_124; - /* 128h */ int field_128; - /* 12Ch */ int field_12C; - /* 130h */ int field_130; - /* 134h */ int field_134; - /* 138h */ int field_138; - /* 13Ch */ int field_13C; - /* 140h */ int field_140; - /* 144h */ int field_144; - /* 148h */ int field_148; - /* 14Ch */ int field_14C; - /* 150h */ int field_150; - /* 154h */ int field_154; - /* 158h */ int field_158; - /* 15Ch */ int field_15C; - /* 160h */ int field_160; - /* 164h */ int field_164; - /* 168h */ int field_168; - /* 16Ch */ int field_16C; - /* 170h */ int field_170; - /* 174h */ int field_174; - /* 178h */ int field_178; - /* 17Ch */ int field_17C; - /* 180h */ int field_180; - /* 184h */ int field_184; - /* 188h */ int field_188; - /* 18Ch */ int field_18C; - /* 190h */ int field_190; - /* 194h */ int field_194; - /* 198h */ int field_198; - /* 19Ch */ int field_19C; - /* 1A0h */ int field_1A0; - /* 1A4h */ int field_1A4; - /* 1A8h */ int field_1A8; - /* 1ACh */ int field_1AC; - /* 1B0h */ int field_1B0; - /* 1B4h */ int field_1B4; - /* 1B8h */ int field_1B8; - /* 1BCh */ int field_1BC; - /* 1C0h */ int field_1C0; - /* 1C4h */ int field_1C4; - /* 1C8h */ int field_1C8; - /* 1CCh */ int field_1CC; - /* 1D0h */ int field_1D0; - /* 1D4h */ int field_1D4; - /* 1D8h */ int field_1D8; - /* 1DCh */ int field_1DC; - /* 1E0h */ int field_1E0; - /* 1E4h */ int field_1E4; - /* 1E8h */ int field_1E8; - /* 1ECh */ int field_1EC; - /* 1F0h */ int field_1F0; - /* 1F4h */ int field_1F4; - /* 1F8h */ int field_1F8; - /* 1FCh */ int field_1FC; - /* 200h */ int field_200; - /* 204h */ int field_204; - /* 208h */ int field_208; - /* 20Ch */ int field_20C; - /* 210h */ int field_210; - /* 214h */ int field_214; - /* 218h */ int field_218; - /* 21Ch */ int field_21C; - /* 220h */ int field_220; - /* 224h */ int field_224; - /* 228h */ int field_228; - /* 22Ch */ int field_22C; - /* 230h */ int field_230; - /* 234h */ int field_234; - /* 238h */ int field_238; - /* 23Ch */ int field_23C; - /* 240h */ int field_240; - /* 244h */ int field_244; - /* 248h */ int field_248; - /* 24Ch */ int field_24C; - /* 250h */ int field_250; - /* 254h */ int field_254; - /* 258h */ int field_258; - /* 25Ch */ int field_25C; - /* 260h */ int field_260; - /* 264h */ int field_264; - /* 268h */ int field_268; - /* 26Ch */ int field_26C; - /* 270h */ int field_270; + /* 44h */ cJobPtr field_44; + /* 48h */ eastl::map field_48; + /* 64h */ eastl::vector_set mInUse; + /* 7Ch */ eastl::vector_set field_7C; + /* 94h */ eastl::vector_set field_94; + /* ACh */ eastl::vector_map mPopulationCount; + /* C4h */ eastl::vector_map mRefillCount; + /* DCh */ eastl::vector_map mTypePopulation; + /* F4h */ eastl::map mIntParameters; + /* 110h */ eastl::map mFloatParameters; + /* 12Ch */ eastl::vector_set mResultSet; + /* 144h */ eastl::vector_set mScratchSet1; + /* 15Ch */ eastl::vector_set mScratchSet2; + /* 174h */ MutliModeDistance mDistanceFunction; + /* 1CCh */ RandomLinearCongruential mRandom; + /* 1D0h */ bool mbSaveDataDirty; + /* 1D4h */ cClassifierFactory mClassifierFactory; + /* 1ECh */ eastl::multimap mSummarizerTable; //multimap,eastl::less,eastl::allocator> + /* 208h */ eastl::multimap mClassifierTable; //multimap,eastl::less,eastl::allocator> + /* 224h */ cISummarizerPtr field_224; //used to check if summary and pSummarizer are same in AddSummarizer + /* 228h */ eastl::vector_set mResourceTypesToReindex; + /* 240h */ eastl::vector_map mClassifierWeights; //vector_map,eastl::allocator,eastl::vector,eastl::allocator>_> + /* 258h */ eastl::vector mPriorityConstraints; //vector + /* 26Ch */ Resource::IResourceFactory* field_26C; }; - ASSERT_SIZE(cObjectTemplateDB, 0x274); + ASSERT_SIZE(cObjectTemplateDB, 0x270); namespace Addresses(cObjectTemplateDB) { diff --git a/Spore ModAPI/Spore/Terrain/cTerrainStateMgr.h b/Spore ModAPI/Spore/Terrain/cTerrainStateMgr.h index 7e383a6d..499ea5a3 100644 --- a/Spore ModAPI/Spore/Terrain/cTerrainStateMgr.h +++ b/Spore ModAPI/Spore/Terrain/cTerrainStateMgr.h @@ -110,23 +110,23 @@ namespace Terrain { TerrainTextures(); - /// From texture `0x9D8D0398.rw4` + /// From texture `water_foamline.rw4` /* 00h */ TexturePtr mpWaterFoamCutMap; - /// From texture `0x11B5EE6F.rw4` + /// From texture `PCAwater2_0.rw4` /* 04h */ TexturePtr mpWaterPCAComponent0; - /// From texture `0x11B5EE6E.rw4` + /// From texture `PCAwater2_1.rw4` /* 08h */ TexturePtr mpWaterPCAComponent1; - /// From texture `0x84613AC8.rw4` + /// From texture `packed_shannon_textures.rw4` /* 0Ch */ TexturePtr mpTextureAboveDetail2; - /// From texture `0xC66C3FCD.rw4` + /// From texture `seabed_grand_shallow.rw4` /* 10h */ TexturePtr mpTextureBelow; /// From texture `lava_detail.rw4` /* 14h */ TexturePtr mpLavaDetail; /// From texture `lava_ramp.rw4` /* 18h */ TexturePtr mpLavaRamp; - /// From texture `0xA5AB24F5.rw4` + /// From texture `packed_detail_texture_intertiling.rw4` /* 1Ch */ TexturePtr mpIceDetailNear; - /// From texture `0x3CEF83D5.rw4` + /// From texture `ice_lowfrequency.rw4` /* 20h */ TexturePtr mpIceDetailMid; /// From texture `ice_ramp.rw4` /* 24h */ TexturePtr mpIceRamp; @@ -138,22 +138,22 @@ namespace Terrain /* 30h */ TexturePtr mpAtmospherePackedCurves; /// Texture created in code with ID `AboveColorRamp` /* 34h */ TexturePtr mpAboveColorRamp; - /// From bitmap `0xC5D262E4.8bitImage` - /* 38h */ ResourceObjectPtr mpAboveDetailNoise; + /// From bitmap `biome_noise_modifier.8bitImage` + /* 38h */ ResourceObjectPtr mpAbovePackedDetailNoise; /// From bitmap `planet_color_ramps_dead.32bitImage` - /* 3Ch */ ResourceObjectPtr mpPlanetColorRampsDead; + /* 3Ch */ ResourceObjectPtr mpAboveDeadColorRamp; /// From bitmap `planet_color_ramps_living.32bitImage` - /* 40h */ ResourceObjectPtr mpPlanetColorRampsLiving; + /* 40h */ ResourceObjectPtr mpAboveLiveColorRamp; /// From bitmap `planet_color_ramps_ice.32bitImage` - /* 44h */ ResourceObjectPtr mpPlanetColorRampsIce; + /* 44h */ ResourceObjectPtr mpAboveColorRampsIce; /// From bitmap `planet_color_ramps_lava.32bitImage` - /* 48h */ ResourceObjectPtr mpPlanetColorRampsLava; + /* 48h */ ResourceObjectPtr mpAboveColorRampsLava; /// From bitmap `0xF30D0A76.32bitImage` /* 4Ch */ ResourceObjectPtr field_4C; /// From bitmap `JetStream.32bitImage` - /* 50h */ ResourceObjectPtr mpJetStream; + /* 50h */ ResourceObjectPtr field_50; /// `pcawater.pcaw` - /* 54h */ ResourceObjectPtr mpPCAWater; + /* 54h */ ResourceObjectPtr mpWaterPCATextureResource; /* 58h */ Math::ColorRGBA nightLightTint; /* 68h */ Math::ColorRGBA dayLightColor; /* 78h */ Math::ColorRGBA duskLightColor;