Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - Neurotoxin

I know you guys have been waiting for an update to the save editor for a while. I present to you the new and improved save editor!

Now, I need something from you guys, Try your damnedest to break a save.

What's different from the previous save editor?
Well, first backstories are now gender locked, although they may change your body type.
A massive refactoring has taken place (more like rewriting) so future updates should mostly only require updating the resource definitions.
The UI layout has changed somewhat and works much more smoothly and is less hackish in it's implementation.

Issues I know about:
Backup Manager isn't yet fully implemented, instead it will open your backup directory for you. Backups however DO work.
On clicking ok when prompted that there is an update it will take you to the old thread, fixed for the next release.

There shouldn't be any bugs that are directly caused by this software related to traits, thoughts(except one see above) or backstories however changing the above MAY have unintended side effects caused by what the game expects and what is actually there. Those same side effects could be had from editing your save by hand.

Wiki - Still needs some love
Virus Scan

I will also attach the download to this thread until it is too large to attach. Can't attach it right now for some reason :/
I'll pretty up this thread later on as well.

Enjoy and looking forward to your bug reports.

Rolling changelog (these are changes as I make them, which you can expect in the next releases):

*Confused Gandalf* Tooltips?
Fixed application's potential to remove traits from pawn that aren't found in defs without the user choosing to do so.
Changing between genders of pawns no longer causes the application to lag out. From 3 seconds per change on my computer to under 1/4 second to update.
Swapped location of childhood and adulthood backstory selection boxes to be more intuitive.
Some internal cleanup of hard-coded Def mappings, now using deserialization.
Externalized hard-coded def mappings to facilitate a simplified update process and mod compatibility, see note after the rolling changelog.
Updated forum URL for new update found.

Ok, some info on the externalized hard mappings of save data. On first run the application will create a folder structure, inside of whatever directory you placed it in, and extract it's packaged data into some folders. Example:

Rimworld Save editor-

The file names don't matter, the application will attempt to load any definition files it locates in the folders so I, other users, or mod authors can provide definition files for compatibility with the save editor. Below is an example of the layout of the traits file, the layout and node structure is what is important here:

<?xml version="1.0"?>
<ArrayOfTrait xmlns:xsd="" xmlns:xsi="">

I will create some more documentation on this on the Bitbucket wiki page (which I haven't created just yet) around the time this version gets released. There's 2 gotchas with this though. First, obviously, without a definition the application can't add modded traits/thoughts/backstories. Second, adding a modded trait/thought/backstory(further known as items) on an umodded save (i.e. You haven't installed the mod who's definitions you're using) WILL cause crashing, you can easily fix that by removing the modded item or restoring a backed up save.
Mods / Git for dummies by a (relative) dummy
August 20, 2014, 03:33:45 AM
Git for dummies by a (realtive) dummy

A desire to learn and to contribute to open source projects
Windows(Specifically for this guide though you can probably follow along on other OS's too)
A Github account
Git Extensions (I'm using this because I'm familiar with it, you can use a different Git interface but setting it up is on you Or you can use the command-line but knowing commands is also on you and if you already know them, you probably don't need this guide)
Git Ex install guide
or, and I suggest using this guide:
[Setting up Git, Git Extensions and GitHub account

I'd like to note, GitEx may or may not actually include some of the options you see in the screenshots during install. I already had a Git program installed and wasn't asked about MsysGit or KDiff and had to install them manually (They are easy, google and setup with default settings). On to the guide:

Do you already know Git? Go Away! Just kidding, feel free to stick around and drop some pointers. This article is aimed at people completely new to Git. For our purposes I'm assuming you meet the prerequisites and have setup GitExtensions with your Github account (see: Setting up Git, Git Extensions and GitHub account).

So, how do I use this exactly? Well, let's say you have your own project. You are the sole maintainer and want to make changes (substantial or not so substantial) without breaking your already working code. You've already pushed your repo to git... oh, you haven't yet because the guide didn't tell you how to make your Project folder a repo? Alright, so open up GitExtensions, if it's open already, close and reopen so we're all on the same page and at the start screen. You'll see this (please excuse my jittery circling job):

Before we clone the Github Repo, we need to have one. So head over to Github and Create a Repository with the same name as your project. When you're done with that, come back to GitEx and click Clone Github Repository. If you have everything setup right, you should see something like this:

Ok, before continuing, go back up your project. Then set the destination directory to your Projects directory (aka if you have Visual Studio/Project/MyProject point it at Visual Studio/Projects) Basically you want the parent directory of your project. Alright, now select the repo you made (with the same name as your Project's Folder), make sure the Create Directory is you project's directory and hit clone. Oh? You had an error, the directory exists and isn't empty? That's why we made a backup, Delete it, Clone it, then put your files back in.

After you put your files back in, you'll have to commit your changes so that Github has the right files, so click that orange Commit button up top.Before we commit our existing files, let's make sure we're only including the necessary ones. Click Edit .gitignore. on the right side you'll see Add default ignores, which is good enough for our purposes so click that and save. Now, go ahead and hit that orange commit button at the top.

On the left side is the staging area, files that have changed will be in the top, files you're commiting will be in the bottom. before we do anything here Click Working Dir Changes at the very top and select edit ignored files. If you were to commit now, all those excess files the IDE creates would be included and they're not needed. For our purposes the default ignores are good enough, almost too much but we'll just use those for now (or you can google .gitignore syntax and customize it here). So hit add default ignores (or customize the list) and save.

Ok, the double arrow button on the right side will stage all changed files to be committed and being this is the initial commit, click it. The text field on the bottom allows you to keep a changelog of sorts. It's usually good practice to commit a single change at a time, so if you mess up somewhere, you can easily roll back that single change. Be verbose with your changes so you know exactly what you did, when you did it and why. Since this is our first commit adding everything to the repo just put in Initial Commit or something of the sorts (Hello World, Hello Kitty, Bananarama FilppityShooBop - Just kidding, try to keep it professionalish - nobody is making you but it will be easier for yourself in the future unless they are code phrases you have mapped out to something somewhere *Suspicious look*).

The Commit button will store your changes as a checkpoint on your local machine only. Commit and push Will store changes and update your remote branch's (github) copy. Let's get that code into the clouds and hit Commit and push. If you added a password to your SSH key you may be asked for it. Viola, your code is now safe (or as safe as it can be) in the cloud.

But why did we go through that effort when I could have just stashed the code in my zip file?

Accessibility and control:
You can make branches from here for making changes, keeping your main code sterile and in a working state while you develop new features or add/remove things that may break everything. If you get everything in your new branch working right, it's a single press of a button to merge into the Master branch and make that the new base for your next Branch.

Anyone with a github account can make their own fork of your code, modify it and push it into their fork. Say Modder C#Master creates an awesome new feature. He can push a button to submit his code to you. If you like the feature you can press a single button and everything is up to date. Then you can pull the changes to your local machine, compile and release, just like that. Say Modder C#Noob has an awesome feature but it may be buggy, they can also submit a pull request which you can pull into your own sterile fork for testing. You don't have to accept pull requests, you can always close them as well.

A scenario:
You write a mod. ModderB makes a feature but it has a few bugs that he can't figure out. He submits a pull request anyway. You make a new fork of your master code and pull his changes into it. You can now modify what he's done, fix it up and push it back into your development branch. If all goes well, it's a single button press from there to update the Master branch with the new code.

Scenario 2:
You're sitting back, enjoying you first Coffee after a successful release of your mod. Here come the bug reports. "Well, I can fix that, just remove this line, change that line, ok everything should work. Build, quick test... seems fine, let's release the fix" More reports, now something that WAS working perfectly doesn't work at all. "Where did I go wrong, what line did I remove again?" Unless you keep local backups of your source at each revision and release, now you have to crawl through every single one of your classes or your miles of code to find that ONE line you changed. Git (paired with KDiff) shows you exactly what changed at each commit so you can easily find that thing you broke and fix it or, if it's completely unclear, roll back  to your last working state and go from there. Change example:

I hope this helps someone out there get into open source collaboration.

Post 2 to be reserved for "Forking like an Animal".
Bugs / [W|0.6.532] Colonist not regaining total health
August 15, 2014, 06:53:41 AM
Let me preface this with I no longer have the save and forgot to take screenshots and cannot, currently, reproduce it.

I had a colonist get wounded in battle. He went to a medical bed where he was treated poorly for his crushed (left if that matters) eye. After he recovered from treatment I went long enough that the wound became old and he was consistently stuck at exactly 50% health. After some time he got wounded again and after that he fully recovered his health.

I know this isn't the best bug report but I know sometimes the simplest mention of something can give you an, "AHA! I know what that is" moment so I figured I'd post it, if it happens again I'll be sure to save the relevant save files/screenshots and try to figure out a way to reproduce it.

Cross Compatibility:
As I'm not using any OS specific code, and I'm targeting the 4.0 Mono Framework this program should be cross compatible with Linux and Mac. I've personally tested on linux.
What you need to make it work:
First, you need the Mono Runtime (MRE)
Some distros of linux come with it installed, to find out, open a terminal and type "mono" without quotes. If it's a valid command you already have it.
Once you take care of getting mono/determining if you already have it open a terminal and enter "mono path/to/RimWorldSaveEditor.exe" without the quotes (or add quotes to the path if it contains spaces). Viola!


NRE fix when manipulating traits
Fixed traits not populating in lists until a colonist is selected
Minor code cleanup
Fix for mods that modify pawn class or KindDef, should probably not have any more issues detecting pawns
Built against Mono framework to (hopefully) address some cross-compatibility issues
Merged a pull request adding a splash screen (still a bit of a WiP, need to fade/default select tab on save load)
Removed "Change Rimworld Dir" button as it no longer has a use.
Valid thoughts, Traits and Backstories now loaded on form load rather than on save load.
A few other minor fixes that I can't remember but I know are there, problem with rushing a release while going out the door.

Pre-release of trait editor. This MAY still have unforseen bugs so keep that backup button checked
No longer requires rimworld Directory, all necessary files have been re-parsed and inline at compile time.
Since this is a pre-release I will not be incrementing the version checker.
Older changes can be located at:

Newest version will be attached to this post and available on Github.


This program is licensed under the MIT license
Full license:
TLDR version:

About the update checker:
This program makes NO connections to the internet without you choosing to do so. When it does, it connects only to a text file with a string representing the current publicly available version number. The only connection it will make is to the following url

Below is the relevant code so you don't have to dig through the source on github:

string releaseThreadUrl = "";
string versionCheckUrl = "";

        public void CheckUpdate()
            using (var WebClient = new WebClient())
                string updateVersion = WebClient.DownloadString(versionCheckUrl);
                updateChecked = true;
                if (CompareVersions(updateVersion) == 1)
                    if (MessageBox.Show("New version available, Goto release thread?", "Open Thread?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
                    else { return; }
                else { return; }

        public int CompareVersions(string stringFromNet)
            string[] asmStyleParse = stringFromNet.Split('.');
            string[] currentVerParse = currentVersion.Split('.');

            for(int i = 0; i < asmStyleParse.Count(); i++)
                if (Convert.ToInt32(asmStyleParse[i]) > Convert.ToInt32(currentVerParse[i]))
                    return 1;
            return 0;

I included the CompareVersions method because a call is made to it. I'm including this section about the update checker for the security conscious users. If the checkbox for checking updates is not ticked, no outside connections will be made. The update checker is disabled by default, I only included it for you, the user's, convenience.

I've seen update checkers on mods/external tools for games get a lot of backlash specifically for not being forthcoming with details on it's operation, use and, implementation and/or for being opt-out rather than opt-in thus why I see fit for this block of text. If you have ANY privacy/security concerns I'll be more than happy to address them. This software is licensed under the MIT license so you ARE allowed to decompile it and see for yourself (If I'm wrong about that, I hereby grant you permission to decompile the binaries distributed with this software).

If you wish to avoid the update all-together I have left the old version ( for A6 and for A5) available to download.

Thank you everyone for your bug reports, many of the issues are things I didn't forsee or in general errors on my part. I appreciate everyone's help and your support to stick with me during these initial phases. This project started as, "I want to edit these skills but, I hate parsing XML manually, Maybe I can write software to do it" and evolved into what it is today. If it wasn't for you guys It never would have expanded beyond what it started as. Keep those bug reports rolling in (or, well, I hope you don't have to, but if you hit one, point it out). Trust me, I'm a nice guy and I won't bite your head off for posting a stacktrace. All comments, suggestions and reports are appreciated and considered. There's on thing I request, and it probably won't be seen by as many as I'd like because I'm not bulleting it, When you post a bug report/stacktrace/unwanted behavior please to make it easier on both of us, post what version you're using and the save you're having issues with or be prepared to do soo on request. Don't worry, I don't care about your colony name, or the female raider you have hostage and keep naked (for whatever reason), I don't even look, I'm only looking for the relevant sections to this software.

v0.9.6.7 is a pre-release. The trait editor SEEMS to be working as desired but I have a feeling I missed something.
I need testers for it, if you have ANY errors using the trait editor please be verbose with your reports and attach/upload the save you were working on as well as the stack trace (either in text or a screenshot). As always, be sure to make backups, once manually (for saftey) and allow the application to make it's own, THIS IS FOR YOUR SAVE'S SAFETY!. Also, being a pre-release, this has not yet been merged into the Master branch on Github, for v0.9.6.7 source see the InDev branch

[attachment deleted by admin: too old]
Like the title says, I'm wondering if mood affects tactical bonuses at all to simulate morale.

If it does already, cool. If not, suggestion:
Give tactical bonus to pawns with mood higher than target's mood by a set amount (% per n over target mood).
Off-Topic / Peter Molyneaux - your opinions?
August 08, 2014, 02:33:23 PM
I recently played the Godus Early Access and I have to say I wasn't too impressed. I could see myself having fun with it in the right mood of course but, like a lot of reviews say, it seems more like a tech demo than a game. Molyneaux has a reputation for not living up to his promises and I'm interested to hear your guys' take on it.

I don't think he straight up lies about the games, I feel like he has all these really good ideas that he REALLY wants to put into whatever game it is and then fails at the technical aspect. I feel like he's a good idea man but a so-so developer, by so-so I mean he can make a working game. As for the failed promises, you can see the effort to try and implement them in some of his games, the Fable series for instance. There's a lot that wasn't implemented or only half-way but there is still a decent game at the core. When you strip away what you were told the game was going to be, and the bugs (Oh god the bugs, I had to restart Fable 3, 5 TIMES, because of progression breaking bugs like being stuck in an area that I couldn't leave because a story trigger broke, or because my internet was shut off so I couldn't log into xbox live) there's still a decent game there. Although I had to restart Fable 3 5 times, I did, and I finished it because I genuinely had fun playing. And speaking of the bugs, that sorta solidifies my thought that he's a good idea man but a very so-so developer, It wouldn't have been hard to add a fail safe, a quick travel back to the overworld, or make the story trigger able to trigger more than that ONE time that you accidentally walked around it as long as some flag value (hasDoneThisTrigger) wasn't set.

I'm not defending him, I'm sick of failed promises, especially on his front, but I think he's too ambitious. He wants to implement so many ideas into his games, and in the attempt to do so, sometimes the game itself falls short because the features that are already there, or half-way there, don't get the work they need because he's busy trying to put in all this other stuff. I think he needs to make 0 promises on his games until there's a working prototype either in the game or working in a standalone instance (Kinda like Tynan's prototype games).

That being said, I don't like Molyneaux referring to himself as an Indie developer. His reputation brings everyone down.  It's like saying just because Steven Spielberg made a movie without a studio, it's an indie film. (Not that Molyneaux is the spielberg of gaming). He's been Making games since 1984, is constantly in gaming Media, and just about every gamer knows his name. I guess by definition, not working under a publisher, he IS an indie developer but his own fame makes it feel unfair to call him that.

Anyway, what is everyone else's thoughts on him? I'm interested in your guys' opinions. Try to keep the thread civil please, I've seen other threads about him blow up into flame wars (not on this forum but elsewhere).
Unfinished / [API] Update Check Framework
August 07, 2014, 05:06:02 AM
Started work today on a simple update checker.

All that's needed to plug in is an xml file.

<Your Mod>/Update/Data.xml
Path and file name are required.

Data.xml Example


Currently only working on HTTP protocol (not https)

I am posting now for people who may want to plug in, what would you like to see? Currently, as proof of concept, it compares version strings rather than values. I can easily add support for Major.Minor.Revision.Build for version checking thus only notifying of update if one of the values is greater than the current. Is there any other versioning system you want supported?

I intend for this to be a very simple way for mod makers to add an update checking functionality to their mods.

Are there any security concerns with parsing a version String that people are worried about? This mod sends no data besides obviously an IP to whatever server it's connecting to (in my example pastebin) relative to the user. It's no worse than browsing to the page yourself.

Does anyone want to help getting HTTPS to work? Let me know here or via PM. I'll get it eventually.

TODO before release:
Implement HTTPS (Specifically for github but also for any other necessary reason)
Implement actual version checking rather than if(!string1.Equals(String2)) - PoC method
Maintain Use simplicity.   
Gather all updated mods on thread close rather than logging to present all at once via GUI window (Might need help with GUI, I suck at those).

Source will be released with the mod itself.

Sorry for my broken train of thought here, kinda fried after a long day... think of this a my bullet points, in no specific order.

Anyway, I'll straighten this thread out tomorrow. Any thoughts, comments, suggestions?
Are you sick of feeding unwanted guests? Are your "guests" stopping by your prison and executing your valuable prisoners? Just don't like outsiders? This is the mod for you.

This mod adds a metal and wood door called a Colonist Only Door. Only colonists, as the name suggests, can pass. Your colonists still need their key to enter of course so don't lose it.

Screenshot: I'd love to demonstrate the doors working but the visitors just cluster at a random point outside the base rather than at the door because they can't use it.


    Fixed wood doors acting like powered doors
    Seperated 2 versions, 1 with standalone doors, 1 replace vanilla doors

    Seperated wood doors added by this mod from the vanilla wood doors (Oops, oversight on my part)
    Added power transmission to Colonist only wood doors
    Now with 100% more awesome thanks to MonkeyWithAWrench's textures.

    Hotfix for NRE caused by animals path-checking through doors

    Update for alpha 6
    Fixed issue with visitors opening and closing doors constantly

    Decided on a license.
    Added License to download archive.
    Made source available

    Added lockable doors. Click a door, hit the UI button (Pending replacement, Borrowed from mrofa) and nobody can go through (without breaking it down).
    Added wooden Variant.
    Started work on power safety doors.

    Open doors no longer allow everybody through. I can't fix both bugs and it's better the non-colonists don't come in.
    ^There's 2 methods for allowing people in doors, BlocksPawn(Pawn) which can be overridden (And that's what I'm using) and WillOpenFor(Pawn) which can't be overridden.
    ^^ I could theoretically use a NEW method to hide WillOpenFor but for some reason it doesn't want to work out.

    Fixed open doors not allowing everybody through.

    Initial Release

Known Issues:

Activating mod then loading into game can cause some texture glitches
to get around this activate then restart the game. This is on me, I need to assign the textures outside of the assembly.
I'm now not sure this CAN be fixed but stay tuned, might work something out.


Textures to differentiate doors at a glance.
Create a door to work in conjunction with power switch. Powered = closed and unopenable, unpowered = open. (Think prison saftey cell doors).
Reorganize this thread.

The current version can always be found attached to this post. If you'd prefer a mirror I will provide Github links as well which also provides me a way to keep old versions available and easily maintained for me.

Source Code:

This modification is license under the MIT license.
Full license:
TLDR license:

Things to note for ModPackers:
If you intend to use this mod in a modpack, Supporting any version besides the current version is YOUR job and your job only.
That said, try to keep up to date. I would refrain from adding this in for the next couple days as the updates will be frequent. Goal of this weekend (soft) for full release.

It's also not REQUIRED but I would appreciate you notifying me that you intend to use my mod in a modpack. No real reason, just metrics/ would love to kno.w

Big thanks to MonkeyWithAWrench for offering up some textures. It's greatly appreciated.

Hope you guys enjoy the mod. Any comments, questions, concerns can be addressed in this thread.

Pick the ColonistOnlyDoors-v#.#.#-Replacer if you want regular doors to be replaced by colonist only doors. (This is not compatible with other mods that modify the base vanilla door)

[attachment deleted by admin: too old]
Help / Adding job to right click menu for colonist?
August 03, 2014, 02:00:36 AM
I wrote a new JobDriver and want to add the job to the right click context menu for a colonist. How can I do this in the assembly as I want to check certain conditions before it actually appears kind of like how "Rescue" is only available on an incapacitated colonist.
Ideas / Desensitization
August 02, 2014, 08:14:24 PM
So here's my thought, I was actually planning on modding it in but I can't figure out exactly how I might hook it in. Basically, a instance variable on each Pawn, that counts how many times a specific thought has been had (eg. Saw a dead body, Saw a stranger die) and after a certain number (maybe x % 10 = 0) it lowers the mood penalty/benefit by a small percentage.

If I see a body, yeah it would probably cause some freak-outishness but after I've seen bodies 100 times, it likely wouldn't faze me as much, if at all. Certain thoughts shouldn't be affected, you'll always be sad when a fellow colonist dies for example, but maybe the time the thought lasts could be reduced. Once things like entertainment and other available mood boosts come around, they should be affected as well. Watching TV for 48 hours won't make you linearly happier than watching it for 3 hours and then doing something else entertaining (such as playing a game).

Overall I suppose I'm asking for diminishing returns on mood affecting thoughts, of course for balance issues they'd have to have a minimum they can drop to.

On that note, if anyone has a suggestion for how to hook into the pawn + thought system I'll gladly make the mod.

Finally, sorry if this has been posted before, I DID check the common requests thread and the other stickies and also google and didn't see anything here.