2 problems but 1 simple mod

Started by confusedwings, April 17, 2014, 05:04:36 PM

Previous topic - Next topic

confusedwings

Quote from: iame6162013 on April 18, 2014, 05:32:55 PM
NO don't give up do u have  a research def?
this is map layout
TestPlant
     |-> About (About.xml)
     |-> Assemblies (researchablePlant.dll) (downloaded from you)
     |-> Defs
          |-> ResearchProjectDefs (ResearchProject_TestPlant.xml)
          |-> ThingsDefs (TestPlant.xml; resources.xml)
     |-> Textures
          |-> Plant (TestPlant.png)

this code is my ResearchProject_TestPlant.xml
<?xml version="1.0" encoding="utf-8" ?>
<ResearchProjectDefs>

<ResearchProjectDef>
<defName>TestPlant</defName>
<label>Alien Test Plant</label>
<description>Research of a new plant. When finished this could will lead you to be able to grow silver plant... Yes sir really!!!</description>
<descriptionDiscovered>At last now you can grow silver stop trading for it and start growing it

NOTE: Don't eat this plant!</descriptionDiscovered>
<totalCost>40000</totalCost>
</ResearchProjectDef>

</ResearchProjectDefs>


I know i make little changes to my text... it's just i'm looking for the answer for it :p

Vendan

there's your problem, your research projects defname is just TestPlant, you are looking for ResearchProject_TestPlant. 

Quote from: iame6162013 on April 18, 2014, 05:36:32 PM
Quote from: Vendan on April 18, 2014, 05:34:31 PM
I notice that your first post had ResearchProjects_TestPlant, and you've changed it to ResearchProject_TestPlant.  Did you change the defName in the researchProjectDef as well?  And no, you shouldn't need to change anything in the dll, but I will get the source code up soon.  In the mean time, if anyone is interested in the source, ILSpy works fine :)

IlSpy? never heard about this one :)

it's a real handy .net decompiler, can pretty much open it up, drag and drop a .net assembly into it and see all the codes.  ALL THE CODES!

confusedwings

Quote from: Vendan on April 18, 2014, 05:50:31 PM
there's your problem, your research projects defname is just TestPlant, you are looking for ResearchProject_TestPlant. 

Quote from: iame6162013 on April 18, 2014, 05:36:32 PM
Quote from: Vendan on April 18, 2014, 05:34:31 PM
I notice that your first post had ResearchProjects_TestPlant, and you've changed it to ResearchProject_TestPlant.  Did you change the defName in the researchProjectDef as well?  And no, you shouldn't need to change anything in the dll, but I will get the source code up soon.  In the mean time, if anyone is interested in the source, ILSpy works fine :)

IlSpy? never heard about this one :)

it's a real handy .net decompiler, can pretty much open it up, drag and drop a .net assembly into it and see all the codes.  ALL THE CODES!

i won't start on those file... first this part :p ^^

Vendan

The first sentence was for you, confusedwings

Here's  what you shouold change the research project xml to
<?xml version="1.0" encoding="utf-8" ?>
<ResearchProjectDefs>

<ResearchProjectDef>
<defName>ResearchProject_TestPlant</defName>
<label>Alien Test Plant</label>
<description>Research of a new plant. When finished this could will lead you to be able to grow silver plant... Yes sir really!!!</description>
<descriptionDiscovered>At last now you can grow silver stop trading for it and start growing it

NOTE: Don't eat this plant!</descriptionDiscovered>
<totalCost>40000</totalCost>
</ResearchProjectDef>

</ResearchProjectDefs>


confusedwings

ok... i feel so stupid right now...

i found out the problem... at the end of 'researchproject_testpalnt.xml'
it ended with "</ResearchProjectDefs"
and it has to be "</ResearchProjectDefs>"

i forgot a ">"
But everybody's help helped me learn a lot... really thx