Ludeon Forums

Ludeon Forums

  • April 26, 2019, 12:32:22 PM
  • Welcome, Guest
Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Duplicate defName Conflict  (Read 2814 times)

RedTheHusky

  • Muffalo
  • *
  • Posts: 6
  • Refugee
    • View Profile
Duplicate defName Conflict
« on: February 07, 2015, 12:57:48 PM »

Dont know if this was done. If it was, please can you send me the link.
I got anoyed when a mod overrides a WorkGiverDef, so I made this application that finds duplicated defNames.
The first button makes an list of all XML files.
https://www.dropbox.com/s/tcihpi7zmxegwoe/2-7-2015%207-24-30%20PM.png?dl=0
The second button reads the XML list and makes a defNameList
https://www.dropbox.com/s/sesbbq5hp1ibk77/2-7-2015%207-24-39%20PM.png?dl=0
And the last one checks if defNames duplicate
https://www.dropbox.com/s/objw6w642cwcde0/2-7-2015%207-24-50%20PM.png?dl=0

Of course i could have made it in just one button , but what if you wanted to see all the defNames, not just the duplicated ones.
Dosent check folder "texture", "assemblies", "languages" and "about".
Also dosent check folder "core" but i will (maybe) add an option to check it.
To use it, you need to put it in your game folder.
I added a bit funny error messages  :P
Quote
Empty! Hmmm. Thats bad.
Are you sure you put int in the right folder?
Try again?"

I have a question. If a defName x exist in ThingDefs and in ResearchProjectDefs, will one override the another or that only happens if both are the same type(ThingDefs ThingDefs ) ?

[attachment deleted due to age]
« Last Edit: February 07, 2015, 03:52:26 PM by RedTheHusky »
Logged

yokai

  • Muffalo
  • *
  • Posts: 18
  • Newbie at modding
    • View Profile
Re: Duplicate defName Conflict
« Reply #1 on: February 16, 2015, 04:49:18 AM »

Very nice work. So looking for problems why the mod dont run will be easier ;D
Logged

1000101

  • Super Modder
  • Planetologist
  • ***
  • Posts: 1344
  • RimFortress Builder
    • View Profile
Re: Duplicate defName Conflict
« Reply #2 on: April 30, 2015, 03:21:43 PM »

I have a question. If a defName x exist in ThingDefs and in ResearchProjectDefs, will one override the another or that only happens if both are the same type(ThingDefs ThingDefs ) ?

defNames have to be unique in a class, but each class could have a def of the same name.  The core DesignationDefs and their associated DesignatorDefs tend to use the same defName.  Note, the DesignatorDefs for the core Designations are "hidden" in code. They do exist but don't have an xml representation (look in Assembly-CSharp).
Logged
(2*b)||!(2*b) - That is the question.
There are 10 kinds of people in this world - those that understand binary and those that don't.

Powered By

Adamiks

  • Transcendent
  • *****
  • Posts: 2609
  • W O K E
    • View Profile
Re: Duplicate defName Conflict
« Reply #3 on: April 30, 2015, 04:07:45 PM »

Don't working for me (i can't even run this). I have windows 7 and i put this into Rimworld785 folder.
Logged

mora145

  • Muffalo
  • *
  • Posts: 17
  • Refugee
    • View Profile
Re: Duplicate defName Conflict
« Reply #4 on: May 15, 2017, 04:49:04 PM »

Is the software available?
Logged