Skip to content

Sims 3 desktop executable utility tool that recategorizes pattern custom content and extracts icons.

License

Notifications You must be signed in to change notification settings

yauyenching/sims-3-pattern-recategorizer

Repository files navigation

Sims 3 Pattern Recategorizer

Executable file that can recategorize Sims 3 Pattern Custom Content (CC) binary files and extract icons for better CC organization purposes. On 2nd October 2022, this tool was released for public use within the Sims 3 Tumblr community. See the community response here.

💡 Motivation

This tool is really mostly for my own purposes. I wanted my pattern CC to adhere to more consistent categories. For example, one creator may categorize a floral pattern as 'Fabric', while another creator may categorize a different floral pattern as 'Theme'. To have all floral patterns be the same category in-game, one would have to manually edit the files.

Recategorizing manually for tons of files was soul-sucking. So, I set out to automate the task. Sims 3 .package files are not readable by normal means, so this work would not have been possible without Peter L Jone's s3pi .NET library.

✨ Preview

🔗 Download the executable here!

⭐ Features

  • Decodes pattern XML and change category at appropriate place
  • Extract icon file and save it in same root folder as file
  • Executable file
    • Drag-and-drop capabilities as a mean of loading your files
    • Prompt user to input new pattern category
  • Simple GUI
    • Set load and save directory file path
    • Set new pattern category
    • Option to toggle saving icon file

Upon a test user's request (DEVELOPMENT HALTED UNTIL FURTHER NOTICE):

  • Change pattern in another internal XML resource to be more consistent
  • Recategorizes .sims3pack pattern files as well (and not just .package files)
    • Successfully extracted .package from .sims3pack and recategorized that
    • Next step: repackaging into .sims3pack without loss of information
  • Advanced options
    • Able to change surface material
    • Able to change pattern description

🛠️ Implementation

This project was coded using pythonnet to utilize .NET libraries in Python, CustomTkinter to create a GUI with a modern interface, and PyInstaller to create the executable file.

🧰 Dependencies

Microsoft's .NET Framework 4 and the following python packages:

  • pythonnet
  • beautifulsoup4
  • lxml
  • customtkinter

The versions used can be found in requirements.txt.

⚙️ Building this Project

Install Python on your system if you have yet to do so. Then, run pip install -r requirements.txt to install all dependencies.

Then, in the cloned repo, run python ProgramGUI.py.

📖 Documentation

PatternRecategorizer

Class that extracts and modifies resources in .package file and calls on the ResourceChanger class to change pattern category based on user settings.

ResourceChanger

Class that rewrites specific resources within xml type files.

ProgramGUI

Class that forms the main GUI for the program. Produces error messages in the case of invalid run options and then uses a loop to run through each file in the chosen directory.

Package

Wrapper to handle .package files.

Sims3Pack

Handler for .sims3pack files. (Unfinished)

🤝🏻 How to Contribute

Fork this repository, implement a feature, and open a pull request!

Contributions are very much welcome! There are several features that have been requested by users.

📝 License

This project is licensed under the GNU GPLv3 License - see the LICENSE file for details.

🙌🏻 Acknowledgements

This tool was something I built primarily for my own incredibly niche uses. I found lots of satisfaction in being able to build a standalone desktop application. This project would not have been possible without our forefathers in Sims 3 tool modding:

Finally, I want to thank the following creators of the assets I used:

And I got the Sims Plumbob asset from here.

About

Sims 3 desktop executable utility tool that recategorizes pattern custom content and extracts icons.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages