Skip to content

Commit

Permalink
Merge branch 'master' of github.com:emd4600/Spore-ModAPI
Browse files Browse the repository at this point in the history
  • Loading branch information
emd4600 committed Oct 18, 2024
2 parents 3b27906 + 31c02f9 commit 2f0e7e9
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 13 deletions.
41 changes: 34 additions & 7 deletions Spore ModAPI/Spore/CommonIDs.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ namespace TypeIDs
animation = 0xEE17C6AD,
/// Data of an adventure
adventure = 0x366A930D,
adv = adventure,
/// Type for Pollinator::cAssetMetadata files
pollen_metadata = 0x30BDEE3,

Expand Down Expand Up @@ -190,7 +191,7 @@ namespace GroupIDs

/// Where editor configuration .prop files are stored
EditorSetup = 0x40600100,
EditorConfig = 0x40600100,
EditorConfig = EditorSetup,

/// Where part models are stored
EditorRigblocks = 0x40606000,
Expand All @@ -199,7 +200,7 @@ namespace GroupIDs

/// Contains the palette files loaded by Palettes::PaletteMain
Palettes = 0x406B6A00,
PaletteDefinitions = 0x406B6A00,
PaletteDefinitions = Palettes,

/// Where adventure props are stored
PaletteItems = 0xD87454E6,
Expand Down Expand Up @@ -237,11 +238,37 @@ namespace GroupIDs
VehicleModels = 0x40646200,
/// Where vehicle .ufo files are stored
UfoModels = 0x40656200,
UFOModels = 0x40656200,
UFOModels = UfoModels,
/// Where flora .flr files are stored
FloraModels = 0x40666200,
// Where palette assemblies are stored
PaletteModels = 0x406B6200,
/// Where city music .cmp files are stored
CityMusic = 0x40C0C200,
/// Where adventure .adv files are stored
Adventures = 0x408A0000,

CellImages = CellModels + 1,
CreatureImages = CreatureModels + 1,
BuildingImages = BuildingModels + 1,
VehicleImages = VehicleModels + 1,
UfoImages = UfoModels + 1,
UFOImages = UfoImages,
FloraImages = FloraModels + 1,

AdventuresLargeCardImage1 = Adventures + 1,
AdventuresLargeCardImage2 = Adventures + 2,
AdventuresLargeCardImage3 = Adventures + 3,
AdventuresLargeCardImage4 = Adventures + 4,

CellModelsConfig = 0x4061E500,
CreatureModelsConfig = 0x4062E500,
BuildingModelsConfig = 0x4063E500,
VehicleModelsConfig = 0x4064E500,
UfoModelsConfig = 0x4065E500,
UFOModelsConfig = UfoModelsConfig,
FloraModelsConfig = 0x4066E500,
PaletteModelsConfig = 0x406BE500,

CivicObjects = 0x9430ADD7,

Expand All @@ -250,16 +277,16 @@ namespace GroupIDs

/// This folder contains popups used in Space stage that can be used with UIEventLog. The hash is FNV of 'Data/Events/Space'.
SpacePopups = 0x131A9F54,
SpaceEvents = 0x131A9F54,
SpaceEvents = SpacePopups,
/// This folder contains popups used in Civilization stage that can be used with UIEventLog. The hash is FNV of 'Data/Events/CityCiv'.
CivPopups = 0xAA9A8ED7,
CivEvents = 0xAA9A8ED7,
CivEvents = CivPopups,
/// This folder contains popups used in Tribe stage that can be used with UIEventLog. The hash is FNV of 'Data/Events/Tribe'.
TribePopups = 0x182CD6CE,
TribeEvents = 0x182CD6CE,
TribeEvents = TribePopups,

CivicThumbs = 0x65928944,
PlannerThumbnails = 0x65928944,
PlannerThumbnails = CivicThumbs,

AssetBrowserData = 0x851D4139,
AssetBrowserConfig = 0x9A74416B,
Expand Down
2 changes: 1 addition & 1 deletion Spore ModAPI/Spore/Editors/BakeManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ namespace Editors
/* 40h */ virtual void func40h();
/* 44h */ virtual void func44h();
/* 48h */ virtual void func48h();
/* 4Ch */ virtual void func4Ch(const ResourceKey& nameKey, const BakeParameters& params); // bake?
/* 4Ch */ virtual void Bake(const ResourceKey& nameKey, const BakeParameters& params);

// 60h returns IModelWorld

Expand Down
2 changes: 1 addition & 1 deletion Spore ModAPI/Spore/Simulator/SerializationTypes.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ namespace Simulator
if (count > 0) {
*dst = eastl::string16(count, ' ');
for (size_t i = 0; i < count; ++i) {
IO::ReadInt16(s, (int16_t*)(*dst)[i], 1, IO::Endian::Little);
IO::ReadInt16(s, (int16_t*)(dst->c_str() + i), 1, IO::Endian::Little);
}
}
return true;
Expand Down
6 changes: 3 additions & 3 deletions Spore ModAPI/Spore/Simulator/cTribe.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ namespace Simulator
/* 2A8h */ eastl::vector<int> field_2A8;
/* 2BCh */ int field_2BC;
/* 2C0h */ float mEggPenFoodValue;
/* 2C4h */ float mInitialRelationship;
/* 2C4h */ float mInitialRelationship; // does not seem to change from 0
/* 2C8h */ float mChieftainRespawnTimer;
/* 2CCh */ float mGiftRelationshipDecayTimer;
/* 2D0h */ ObjectPtr field_2D0;
Expand All @@ -129,7 +129,7 @@ namespace Simulator
/* 310h */ float mClosestWaterDistance;
/* 314h */ eastl::vector<Vector3> mClosestForests;
/* 328h */ int field_328; // not initialized
/* 32Ch */ int mUpgradeLevel;
/* 32Ch */ int mUpgradeLevel; // may be a uint32 or have errors?
/* 330h */ float mZoningRadius; // 30.0
/* 334h */ bool mbRoboTribe;
/* 338h */ int mRoboPopulationCount;
Expand All @@ -151,7 +151,7 @@ namespace Simulator
/* 550h */ int mTribeArchetype; //TODO
/* 554h */ bool field_554;
/* 555h */ bool field_555;
/* 556h */ bool mbMembersFlee; // if true, creatures run away in fear
/* 556h */ bool mbDefeated; // if true, creatures run away in fear then die.
/* 557h */ bool mGoodyPopped;
/* 558h */ char _padding_558[0x1310];
/* 1868h */ int field_1868;
Expand Down
5 changes: 4 additions & 1 deletion Spore ModAPI/Spore/UI/EditorNamePanel.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,11 @@ namespace UI
EditorNamePanel();
~EditorNamePanel();

/// Creates a functional renaming UI for a nameable entity (eg Tribes and Cities)
/// allowRename when set to false will gray-out the name field
/// randomNameType when set to 0x0 will hide the randomization button
void Initialize(Editors::INameableEntity* pEntity, UTFWin::IWindow* pContainer, uint32_t layoutID,
bool, uint32_t randomNameType);
bool allowRename = true, uint32_t randomNameType = 0x0);
void Dispose();

virtual void SetExtended(bool extended);
Expand Down

0 comments on commit 2f0e7e9

Please sign in to comment.