A Sneak Peek of My Tuning Editor
🕑 Added 2021-10-30 19:18:11 +0000 UTCHey everyone! I haven't posted any updates in a while, so I figured it was time to do so, even if it may not be super exciting to everyone.
As mentioned in the past, I'm taking a little time off from modding to work on some modding tools for my fellow creators. I've already shared about the string table tools I've made, but haven't shared any details about the main project I am working on, so, this post will give you some insight of what you can expect from it.
Please note that I haven't committed to a name yet, so I'll be vaguely referring to it as "this program" or "my program" throughout this post. I have some ideas, but I'm not set on any of them yet.
What is it?
I'm working on a desktop application that can edit tuning, SimDatas, and String Tables (support for other file types will be considered at a later time). It is similar in concept to Sims 4 Studio, but is specialized for the most common file types used when creating gameplay mods, and offers a more IDE-like development experience for them.
It is in no way, shape, or form meant to be a replacement for S4S, but rather a complement to it. S4S is still required for creating/editing any file types that are not tuning, SimData, or String Tables (e.g. DST images and most files required to make CC), and you may find S4S easier or more convenient to work with for smaller mods – this program is really meant for organizing larger modding projects.
So... it's like S4S, but does less?
If you're looking at it from a purely quantitative view, then sure. However, the reduced quantity of supported file types allows me to focus on the quality of the program itself, the editing experience of the most-used file types, and some additional tools to assist with common tasks.
But again, I want to stress that this is not a replacement for S4S. They will be completely compatible with one another, so that you can use whichever one you need to for certain tasks. For example, the program supports tuning, SimData, and String Tables, which should be enough to complete just about any gameplay mod. One notable exclusion is DST images, which are required for adding icons to buffs, traits, interactions, etc. If you need to add a DST image, simply add it with S4S.
(I may add support for DST images later, but they are not a priority at this time.)
What exactly does it do, then?
The two main objectives of this program are to create an easy-to-use, familiar development environment, and to offer powerful tools that boost code-writing productivity. Now, without all the buzz words, here's what I mean:
The Environment
- Organize your files in an actual file system, rather than one big list. This program is capable of editing both packages and raw files, which allows you to organize your projects in whatever way you see fit. This also means that you can use Git with your modding projects if you wish.
- When editing a package rather than raw files, the program can group tunings by type (in subfolders), and display them in alphabetical order. SimDatas can also be linked to their corresponding tuning, so they are always next to one another.
- You can have multiple files open at once, with your scrolling position saved in each one. This makes it easy to go back and forth between files that you're editing at the same time.
- The program has a modern user interface inspired by VS Code and Atom, featuring both light and dark modes with customizable color schemes. It also allows you to collapse the file explorer so that you can have more screen space dedicated to your code. Check out the header of this post for a sneak-peek of what the program currently looks like, but keep in mind that it is not yet complete and the UI is a work-in-progress!
The Productivity
- Tuning files currently feature autocomplete for XML syntax, and I am looking into autocomplete for tuning references and string hashes that are in your open project. I also plan on adding code suggestions from the TDESCs, but this is not guaranteed and may not be in the initial release.
- When creating a new tuning file, you can select a template to base it off of. This saves you from writing tedious boilerplate code, and also from ye olde method of copy-pasting and replacing. Some templates will come pre-defined for you, but you can also create, save, and share ones of your own. Templates can also cover multiple files, such as when you want to create a trait with associated loots that give and remove it.
- When the tuning type you're working on has a SimData, you can choose to link the SimData and tuning together to auto-generate the SimData from your tuning. I already have a proof-of-concept for this feature, but it does require some manual input from me up front - so please note that SimData generation may not be available for every tuning type from the start.
- When you have to create a new string, you will be able to do so directly from tuning - just use a keyboard shortcut to signify that you are creating a new string, and the program will hash it, place it in a string table, and write out the hash code and comment for you automatically.
- If you ever have to create many similar files (such as dozens of buffs or traits), you can generate them with the generator tool. Please note that this has not been implemented in the program yet, but I do have my own Python library that does this exact thing, so it's just a matter of porting it over - it may not be in the initial release.
When will it be ready?
It'll be ready when it's ready. Since this is a program that will be used to write other programs, I have to be sure I get it right and test it extensively. As such, I cannot give an estimated release date at this time, because it can not be rushed. If I need more time, I need more time. Just know that I'm working on it in pretty much all of the free time that I have. I hope to have it done by the end of the year, but I will make no promises.
I'm a nerd, what tech stack are you using to make it?
I am using Electron, the same Node.js framework used to create VS Code, Discord, and many other cross-platform desktop applications. I am using TypeScript to interact with the Electron API, which forms the core of the application, and I'm using Svelte, SCSS, and TypeScript to build the front end. Right now, this is a closed project while I figure everything out, but I am considering making it open source once I get the foundation built.
And, that's all for now!
I just wanted to offer some transparency about what I've been up to, so hopefully this post clears things up. I know this may not be of particular interest to players, but hopefully those of you who create mods find it useful. I will keep you updated on the development as it continues, I'm excited to see where this goes!