Quick Reply
Search this Thread
Field Researcher
Original Poster
#1 Old 22nd Sep 2024 at 7:13 AM
Default Is it possible to make custom spawners or add new critters to existing ones?
I've been toying with the idea of a mod, but it occurred to me I don't think I've seen custom spawners, which made me curious if there was a reason for it.
In particular, I wanted to expand the options for mini pets (like the snakes, lizards, small rodents etc). Is it possible to add them into existing spawners, or would it be better to make them purchasable elsewhere?
Advertisement
Forum Resident
#2 Old 23rd Sep 2024 at 2:43 AM
A custom spawner is likely possible, but like any brand new function would need to be scripted- which is the most common limiting factor when it comes to mods, as the experience required is quite steep.

The MinorPets list can definitely be edited with just XML / S3PE knowledge, the only con is being incompatible with mods that edit the same file. New pets can be added to the list and to the contents of the spawners in this file- they'll also automatically be valid for the RockGemMetal spawner, which checks for type instead of specific species (this is likely to allow minor pets to appear in worlds that predated the expansion).
There's also the pet register from the TS3 Store- I believe the script is patched into the base game, so you may be able to work with that even if you don't have the original object.

When there aren't pre-existing examples or tutorials for working with a type of collectible/spawnable item, resources about custom plants and food are your friend
They cover a lot of the same topics in terms of what is going on in the XML, how to generate IDs that are attached to names, so on that are reused in all similar files.
Field Researcher
Original Poster
#3 Old 23rd Sep 2024 at 3:20 AM
Quote: Originally posted by CardinalSims
A custom spawner is likely possible, but like any brand new function would need to be scripted- which is the most common limiting factor when it comes to mods, as the experience required is quite steep.

The MinorPets list can definitely be edited with just XML / S3PE knowledge, the only con is being incompatible with mods that edit the same file. New pets can be added to the list and to the contents of the spawners in this file- they'll also automatically be valid for the RockGemMetal spawner, which checks for type instead of specific species (this is likely to allow minor pets to appear in worlds that predated the expansion).
There's also the pet register from the TS3 Store- I believe the script is patched into the base game, so you may be able to work with that even if you don't have the original object.

When there aren't pre-existing examples or tutorials for working with a type of collectible/spawnable item, resources about custom plants and food are your friend
They cover a lot of the same topics in terms of what is going on in the XML, how to generate IDs that are attached to names, so on that are reused in all similar files.

I hadn't even thought to use the plants as a good reference! I have a ton of mods that add new plants, and they spawn in the world the same as any other seed! Thank you! Would you happen to know of a good starting point for script mods?
Forum Resident
#4 Old 24th Sep 2024 at 2:17 AM
Buzzler's tutorials are usually the entry point for getting into script modding:
https://modthesims.info/wiki.php?ti...ripting_Modding

There is also Battery's alternative to Visual Studio (that can be a pain to get and set up these days), which can be used alongside a lot of the tips by Buzz:
https://modthesims.info/showthread.php?t=632267

The parts that are relevant for you specifically would be opening the .dlls extracted in the first link in a program like ILSpy or dnspy so that you can search for the existing spawners and see how they work.
You could also open the script from any CCLoader mod in the same way, for an idea of how they inject things into XML instead of overwriting.
And the object script tutorial:
https://simswiki.info/wiki.php?titl..._Object_Modding
Field Researcher
Original Poster
#5 Old 24th Sep 2024 at 7:35 AM
Quote: Originally posted by CardinalSims
Buzzler's tutorials are usually the entry point for getting into script modding:
https://modthesims.info/wiki.php?ti...ripting_Modding

There is also Battery's alternative to Visual Studio (that can be a pain to get and set up these days), which can be used alongside a lot of the tips by Buzz:
https://modthesims.info/showthread.php?t=632267

The parts that are relevant for you specifically would be opening the .dlls extracted in the first link in a program like ILSpy or dnspy so that you can search for the existing spawners and see how they work.
You could also open the script from any CCLoader mod in the same way, for an idea of how they inject things into XML instead of overwriting.
And the object script tutorial:
https://simswiki.info/wiki.php?titl..._Object_Modding


Thank you so much! This has been insanely helpful. I've done a lot of XML edits in my day but haven't done a from scratch. I will absolutely be looking into this!
Back to top