Menu

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

Messages - Jamestec

#1
Releases / Re: Rock5s [B18] mods
December 07, 2017, 09:15:42 AM
Quote from: Rock5 on December 06, 2017, 11:48:14 AM
One problem I had is not being able to find the text controls name. I don't know unity but the part that seems to make the search bar controls is
            searchTerm = Widgets.TextField(searchBarRect, searchTerm);

I'm not sure I understand it but searchTerm is a string, not some control.

The "Widgets.TextField(...)" part is what creates the text box GUI in that line; that method uses GUI.TextField (https://docs.unity3d.com/ScriptReference/GUI.TextField.html) to do so. Yes, searchTerm is just a string that gets the text box's value.


Try changing your code to:

GUI.SetNextControlName("TaggingSearchTerm");
searchTerm = Widgets.TextField(searchBarRect, searchTerm);
GUI.FocusControl("TaggingSearchTerm");

And see if the text box gets focus.
#2
Releases / Re: Rock5s [B18] mods
December 06, 2017, 09:20:38 AM
If you haven't found a solution to auto focusing keyboard, look at:

https://docs.unity3d.com/ScriptReference/GUI.FocusControl.html

I used it in JTMoreAreas, Dialog_RenameArea_JT, line 89.
#3
Updated JTSavagePrisoners and JTWeRAnimals to A17.


Quote from: LiteEmUp on July 30, 2017, 02:12:09 AM
so is the savage prisoners and weranimals gonna get an a17 update???

Sure thingo.


Quote from: SpaceDorf on July 30, 2017, 03:31:42 PM
Is the ZoneManager able to copy&paste Zones ? This would be awesome to set up slightly different Zones.

It used to, but with the A17 update my method of displaying gizmos (fake thingdef) for the buttons wouldn't work without spamming errors, so I disabled it when I updated JTMoreAreas to A17. I've tried other methods like fake areas or zones, but they all have problems; I think I'll just settle with adding a new designator category that you can hopefully disable using mod settings. Still working on it though.
#4
You're suppose to override it with another class of your own for that apparel.

Look at the Rimworld.ShieldBelt class and maybe it's XML. Edit: yea, you need a <thingClass> tag to point it to the right class.

How I easily get an example to learn from, without knowing SheildBelt displays gizmos in-game:
In ILSpy, go to Pawn_ApparelTracker.GetGizmos() like you have, right click the thing you're interested in (in this case, where does this.wornApparel[//i].GetWornGizmos() get it's gizmos from? So right click GetWornGizmos()), click Analyze and expand Overriden By in the Analyzer box that appears at the bottom.
There you can see that ShieldBelt overrides GetWornGizmos, so just copy that behaviour and create a class for your apparel and override GetWornGizmos.

Edit: another thing that you may or may not know that helped me is that the modifier, virtual, allows the method to be overridden, so by design, what you want to look at isn't the virtual method.
#5
Updated JTHomemadeBionics to A17.
#6
Updated JTBetterCrashedShips, JTBetterhauling, JTDrill5Eva, JTExport, JTMoreAreas, JTMoreHydroponicOptions, JTZoneButtons.


Quote from: Ichimatsu on June 14, 2017, 09:48:36 AM
JTReplaceWalls sounds awesome! I'll wait here patiently for an update :D

Someone's already updated it here: http://steamcommunity.com/sharedfiles/filedetails/?id=936562361
Probably better to just start using that, there are no reports of it bugging out in the comments. I only plan on updating it myself when all my other mods are updated and I can do mod settings correctly for it (gonna try to allow users to add compatibility themselves).


Quote from: coldcell on June 14, 2017, 08:47:41 AM
What? Where? Thread is still A15/A16 with conversion in progress still.

OneDrive: https://onedrive.live.com/?authkey=%21AOJkr-l_lBwwAJw&id=D3374FA891C72E6%212308&cid=0D3374FA891C72E6
Steam A17 Collection: https://steamcommunity.com/workshop/filedetails/?id=939624099
#7
Do you mean removing the options on the left when you select a stockpile, to toggle whether to let them in the stockpile?



If you do mean those entries, you would have to do some C# stuff. You can't easily remove them from just dumping stockpiles, since in the C# code, dumping stockpiles are actually normal stockpiles but with different initial values.

Edit: nevermind, A16 is similar to A15.

You can find the code in C# at Verse.ThingFilterUI.DoThingFilterConfigWindow( ... ), the actual ticks and crosses entries (under Clear all and Allow all buttons) begin at the line:
listing_TreeThingFilter.DoCategoryChildren(node, 0, openMask, true);

To get started, you would have to get Zone_Stockpile to save whether it's a dumping or not (save as a variable or make a new class for dumping stockpiles).
You would then have to detour RimWorld.ITab_Storage.FillTab() to pass an additional argument to Verse.ThingFilterUI.DoThingFilterConfigWindow( ... ) whether it's a dumping or not.
If it's a dumping stockpile, you can either:
Edit: 1) Change the last two arguments (the null, null) of
ThingFilterUI.DoThingFilterConfigWindow(rect2, ref this.scrollPosition, settings.filter, parentFilter, 8, null, null);
to give these:
http://pastebin.com/GPQqVN3Q
To get the ThingDef from a string, use DefDatabase<ThingDef>.GetNamedSilentFail("name of def"), or get all and check if it has _Corpse.

2) Pass Verse.Listing_TreeThingFilter.DoCategoryChildren( ... ) a different TreeNode_ThingCategory node

3) Implement a different version of DoCategoryChildren which skips over Corpses.

Edit: found another way, still have to save whether it's a dumping stockpile, then detour RimWorld.Zone_Stockpile.GetParentStoreSettings() to return the a ThingFilter with the following values if it's a dumping stockpile:
http://pastebin.com/PFTxr9RF
#8
I think your mod load order can be extracted from that log, line starting at 365.

Otherwise it's listed at (... is your PC username):
C:\Users\ ... \AppData\LocalLow\Ludeon Studios\RimWorld by Ludeon Studios\Config\ModsConfig.xml
but gives unfriendly names for steam workshop mods.

You can extract a more friendly list using a save file. Save files are located at (for A16):
C:\Users\ ... \AppData\LocalLow\Ludeon Studios\RimWorld by Ludeon Studios\Saves
Open the save with your favourite text editor and the list should be near the beginning under <modNames> (which is after <modIds>).

With the error itself, I had a similar error when I was playing A15, however it was not 100% reproducible: it would only sometimes appear even when I kept loading the same save. I would just ignore this error.

You do have an error with Stats_Pawns_WorkMedical.xml at line 337:
Exception reading Stats_Pawns_WorkMedical.xml as XML: System.Xml.XmlException: 'li' is expected  Line 112, position 8.
#9
Mod bugs / Re: Help please . .
January 24, 2017, 10:13:34 PM
The error is from TraderKinds_Visitor_Outlander.xml. Either that file in core (base game) or one of the mods replacing it was edited incorrectly.

If you haven't modified core, try redownload the mods. Otherwise search for TraderKinds_Visitor_Outlander.xml in the mods and try to correct it yourself, the error gives you a hint: 'stockGenerators' is expected  Line 89, position 10. The closing tag </stockGenerators> was probably missed.
#10
Mod bugs / Re: Save game loading fails
January 24, 2017, 10:00:46 PM
Attached is a working version of the save file you uploaded.

I think what happened is that Lamia updated and changed Bodies_Lamia.xml to have fewer body parts (currently 56, so 0-55), but in your save game a dead Lamia (Mardi Gras - Lamia25509) had entries for missing parts 56 to 63 causing the Argument is out of range error. I deleted the entries that had partIndex of 55.

[attachment deleted by admin due to age]
#11
Mod bugs / Re: Save game loading fails
January 24, 2017, 12:12:12 AM
Has to do with hediffs and body parts. Since I don't think the mods in your log do anything with body parts or hediffs, this might be a vanilla bug.

Use the attached mod, it will probably allow you to load and give you info on which pawn was the cause etc.
Still backup the current save even if it loads since the mod is just a quick patch up and might have unforeseen consequences.
Maybe post your game log and save file if it successfully loads and someone else can determine why this happened.

[attachment deleted by admin due to age]
#12
Your Psychology mod install seems to be missing it's assembly file(s).

There's also an error loading HorseRIDE.xml (from HorseMod?).

You don't have to activate the mods one by one, you can extract the mods you used for a save from that save file.
When you open the save file with a text editor, the mods are under the <modIds> tag in order, copy the list over to (while RimWorld is not running) (for Windows):
C:\Users\ ... \AppData\LocalLow\Ludeon Studios\RimWorld by Ludeon Studios\Config\ModsConfig.xml
And paste it under the <activeMods> tag.
Bear in mind that this won't download the mods for you, this assumes that you have the mods, but RimWorld decided to untick all your mods.
#13
Help / Re: Trying to do a few things
January 19, 2017, 09:11:28 AM
Use this version of ILSpy: https://github.com/Zhentar/ILSpy/releases/
Extract and run ILSpy.exe

I also use Notepad++ with it's "Folder as Workspace" function to search through the XML or through saved decompiled C#.
#14
Here's a slimmed down version of the output log (truncated lines 266 and 340):
http://pastebin.com/enM6Hw12

I believe the JTReplaceWalls and concrete walls error messages are as follows (lines 127-139):
JTReplaceWalls: detected ConcreteWall
JTReplaceWalls: detected ConcreteEmbrasure
JTReplaceWalls: detected WallScrapMetal
JTReplaceWalls: detected ConcreteAutodoor
These just say JTReplaceWalls knows about these additional walls. If you saw a different error, please try to replicated and post that output log.

Lines 143-184 show a HugsLib error with SexualitySpectrum (RomanceDiversified?), unable to detour some methods that are already detoured.

Line 200 and 204, looks like HugsLib has complaints about Fluffy_BirdsAndBees' detouring.

Your first load starts at line 234, it says there's an error loading HorseRIDE (HorseMod?) but it seems to be an apparel associated with the MercenaryGunner, Yoshiko Vongrimm, from Faction_13. That's the thing that's causing the problem.

Edit: try loading this save (deleted lines 277480-27786, references to HorseRIDE):
https://1drv.ms/u/s!AuZyHIn6dDMNlW_iZK_pf5QcMACc
Will delete the file from my onedrive in like a week or something.
#15
That's all I've updated at the moment (JTZoneButtons just now, so that makes 3), I don't play RimWorld anymore so there's not much motivation to do so. It's Christmas and I work in retail so I've also been busy.

Updated JTZoneButtons: Increment targetVersion to Alpha16 in About.xml, no code changes, this version still works with Alpha15.