Project: Save the Pets!
Protect your pets from yourself and give them a second chance at life!
Client or Server Side (Singleplayer counts as Server Side!). Unlike most mods, this mod will work on both without the other with some features missing on the client. If installed on the server, all clients will receive all server side features!
Forge and Fabric have the same features and configuration files and can work with each other (IE: Vanilla/Forge Server and Fabric/Vanilla Client).
Java Version: 17+
This mod should work with 1.18.x and future releases.
No older versions will be supported.
This mod protects your pets from various sources of damaged caused by you!
|Source||Server Side||Client Side||Configurable|
|Direct Attack||✔️ Yes||✔️ Yes||✔️ Yes|
|Sword Sweeping||✔️ Yes||❌ No||✔️ Yes|
|Projectiles||✔️ Yes||❌ No||✔️ Yes|
|Explosions||✔️ Yes||❌ No||✔️ Yes|
|Potions||✔️ Yes||❌ No||✔️ Yes|
Revival (Server Side Only)
When your pet dies, it drops a note. You can then use this note to revive the pet.
Right-clicking on a Copper Block (configurable) while holding the note, will respawn the pet and consume the block.
Untaming (Removing Ownership) (Server Side Only)
Don't want your pet or want to give it to someone else? You can remove ownership by crouching and using a shear (configurable)!
Harming your pets (Client Side only)
Holding down the Shift key (configurable in the Option's menu) while attacking will bypass the Client Side protection and harm the pet. I'm not sure why you want to do this but it's here, just in case.
Note: Feature is removed if Server has the mod installed.
The Configuration file is JSON. Below is an example file with comments.
// Used Interally
// Items used to remove onwership of a pet
// Allows the Minecraft and Modded Shears to remove ownership
// Blocks that can be used to revive a pet
// Are tamable entites protected?
// Are fox entites protected?
// Are horse based entites protected?
// Blacklist entities from protection and revival
// Entities that should drop the revival note
// Do mobs with custom names drop a revival note?
// Do we protect against projectiles?
// Do we protect against sword sweep?
// Do we protect against direct attack?
// Do we protect against explosions?
// Do we protect against harmful potions?
// Harmful effects to living entities.
// Harmful effects to undead entities.
APIs (For modders)
Most of the configurability lives in
dcp.mc.projectsavethepets.ProjectSaveThePets. This is used later on for both Fabric and Forge.
The following has been publicly exposed to easily add/remove singletons in a dynamic fashion:
For examples on how to use them (as well as how to make APIs for the mod), see
dcp.mc.projectsavethepets.ProjectSaveThePets#<cinit>() and classes in
The following Entry Points are for the following classes:
InterModEnqueueEvent to send instances of
It's done already! Have a look here
Go for it! You have my full permission to add the mod to your Mod Pack. No credits required!
Can I use this for my mod?
Sure thing! Same as above!
Hey! I saw your code and would like to take a snippet!
Sure, I don't mind! As long as it's not a blatant copy and paste of an entire file! ( accessors excluded). I do wish to be mentioned if possible.
Do I need Fabric API?
Yes you do as the mod needs it for the custom keybindings. But only if you are using the Fabric version of the mod!
Is this client or server sided?
It can run on the Client without the Server having it installed. But, some features will be missing if the Server doesn't have it installed! So if you have it installed, you can use it on a vanilla server.
However, if the server has it installed, no Players will need to install the mod on their client.
Does my client need this mod?
Only for servers that don't have this mod and for Singleplayer/LAN! See above for more information.
Does LAN Multiplayer work with this mod?
I believe so! Untested but I'll fix any problems that show up. You and all players should get all Server Side Features.
I got a question or a bug.
Feel free to comment below the question, however I would prefer if you left any bug reports in the GitLab Repository! Thanks!
Note: Doesn't include fixes and might be possibly missing a few features.
- Changed source code package to something shorter
- Added config
- Added Explosion protection
- Added Splash and Lingering Potion protection
- Added Revival and API associated to it
- Added ability to blacklist entities from protection
- Added Forge compatibility
- Added Client Side feature
- Added cross mod compatibility API
- Added Projectile protection
- Added Sword Sweep protection
- Allowed Foxes to be protected
- Change license to Apache-2.0
- Allowed Horse Based Entities to be protected
- Initial Release
- Allowed Tamable Entities to be protected