[Solved] Unstuffify Walls and doors

Started by Saularian, August 03, 2015, 06:18:06 PM

Previous topic - Next topic

Saularian

Hey guys, I'm currently looking into unstuffing stuff (yeah, that's probably not my best English....) by which I actually mean to build something that does not take on the colour of the stuff it was made of. It would seem a very simple thing to do, but somehow I'm lost in all the lines of code and not seeing which line I'd need to add (or remove, as I build on the vanilla codes mostly) as it seems to elude me.... Any help?

Saularian

Maybe this is a better way to show what I'm looking at....

The thing is, the security door and the halfwall constructed get the colour of the stuff it is made of, which I do not want.

<ThingDef ParentName="DoorBase">
<defName>Securitydoor</defName>
<label>Security door</label>
<description>A powered steel plated security door that allows people to move through the door without slowing down.</description>
<statBases>
<MaxHitPoints>1000</MaxHitPoints>
<WorkToMake>2000</WorkToMake>
</statBases>
<stuffCategories>
<li>Metallic</li>
<li>Stony</li>
</stuffCategories>
<costList>
<Steel>10</Steel>
</costList>
<costStuffCount>30</costStuffCount>
<graphicData>
<texPath>Things/Building/SCDoors/SecDoor_Mover</texPath>
<graphicClass>Graphic_Single</graphicClass>
</graphicData>
<uiIconPath>Things/Building/SCDoors/SecDoor_MenuIcon</uiIconPath>
<comps>
<li>
<compClass>CompPowerTrader</compClass>
<basePowerConsumption>50</basePowerConsumption>
<transmitsPower>true</transmitsPower>
</li>
</comps>
</ThingDef>

<!--========================= Fence =============================-->
<ThingDef ParentName="BuildingBase">
<defName>SecHalfWall</defName>
<label>Security half wall</label>
<thingClass>Building</thingClass>
<category>Building</category>
<graphicData>
<linkType>Basic</linkType>
<texPath>Things/Building/SecHalfWall</texPath>
<graphicClass>Graphic_Single</graphicClass>
<linkFlags>
<li>Wall</li>
</linkFlags>
</graphicData>
<uiIconPath>Things/Building/SecHalfWallIco</uiIconPath>
<AltitudeLayer>Waist</AltitudeLayer>
<statBases>
<MaxHitPoints>1000</MaxHitPoints>
<WorkToMake>100</WorkToMake>
<Flammability>0.0</Flammability>
</statBases>
<stuffCategories>
<li>Metallic</li>
<li>Stony</li>
</stuffCategories>
<Passability>Impassable</Passability>
<fillPercent>0.9</fillPercent>
<Description>A steel plated half wall to hide behind and shoot over.</Description>
<placingDraggableDimensions>1</placingDraggableDimensions>
<costList>
<Steel>5</Steel>
</costList>
<costStuffCount>15</costStuffCount>
<building>
</building>
<damageMultipliers>
<li>
<damageDef>Bomb</damageDef>
<multiplier>3</multiplier>
</li>
</damageMultipliers>
<rotatable>false</rotatable>
<holdsRoof>false</holdsRoof>
   <blockLight>false</blockLight>
<selectable>true</selectable>
<neverMultiSelect>true</neverMultiSelect>
<DesignationCategory>Structure</DesignationCategory>

</ThingDef>


The security wall on the other hand does not have that problem, but I can't seem to find out what's causing the problem...

<ThingDef ParentName="BuildingBase">
    <defName>SecurityWall</defName>
    <label>Security wall</label>
    <thingClass>Building</thingClass>
    <category>Building</category>
<Description>Steel plated security wall</Description>
<graphicData>
<shaderType>CutoutComplex</shaderType>
    <texPath>Things/Building/SecWall</texPath>
<graphicClass>Graphic_Single</graphicClass>
<linkType>Basic</linkType>
    <linkFlags>
      <li>Wall</li>
    </linkFlags>
</graphicData>
    <uiIconPath>Things/Building/SecWallIco</uiIconPath>
   <statBases>
      <MaxHitPoints>3000</MaxHitPoints>
      <WorkToMake>1000</WorkToMake>
      <Flammability>0.0</Flammability>
  <Beauty>12</Beauty>
    </statBases>
<stuffCategories>
<li>Metallic</li>
<li>Stony</li>
</stuffCategories>
<costList>
<Steel>10</Steel>
</costList>
<costStuffCount>25</costStuffCount>
    <AltitudeLayer>BuildingTall</AltitudeLayer>
    <Passability>Impassable</Passability>
    <castEdgeShadows>true</castEdgeShadows>
    <fillPercent>1</fillPercent>
    <coversFloor>true</coversFloor>
    <placingDraggableDimensions>1</placingDraggableDimensions>
    <tickerType>Rare</tickerType>
    <rotatable>false</rotatable>
    <selectable>true</selectable>
    <neverMultiSelect>true</neverMultiSelect>
    <terrainAffordanceNeeded>Heavy</terrainAffordanceNeeded>
    <holdsRoof>true</holdsRoof>
    <DesignationCategory>Structure</DesignationCategory>
    <staticSunShadowHeight>1.0</staticSunShadowHeight>
    <blockLight>true</blockLight>
   
    <building>
      <ignoreNeedsPower>true</ignoreNeedsPower>
    </building>
    <damageMultipliers>
      <li>
        <damageDef>Bomb</damageDef>
        <multiplier>3</multiplier>
      </li>
    </damageMultipliers>
    </Comps>

  </ThingDef>


Anyone out there that sees what I'm missing or what I need to add??

skullywag

Dont use stuffcategories if you dont want to use stuff. Just use the costlist. Or maybe set madefromstuff to false. Not near the code so cant get the exact text.
Skullywag modded to death.
I'd never met an iterator I liked....until Zhentar saved me.
Why Unity5, WHY do you forsake me?

Saularian

That's just it, I do want to use stuff, I just don't want the things to look like the stuff  ;)

mrofa

You need masks textures for that
All i do is clutter all around.

skullywag

Yeah check out the bed in the core art resource thread. It has red and green bits so when the shader is applied it colours the red bits with the stuff colour. So in your case make a big red mask that covers your image and make it use the right shader in the graphic section.
Skullywag modded to death.
I'd never met an iterator I liked....until Zhentar saved me.
Why Unity5, WHY do you forsake me?

Saularian

#6
Quote from: skullywag on August 05, 2015, 04:02:42 AM
Yeah check out the bed in the core art resource thread. It has red and green bits so when the shader is applied it colours the red bits with the stuff colour. So in your case make a big red mask that covers your image and make it use the right shader in the graphic section.

I'll have to find a masking plugin for paint.net but I 'll have a look at it, thanks.

Saularian

Thanks for the help guys, masking wasn't actually needed as I found out that <shadertype>CutOutComplex</shadertype> does what I needed.

Have a good weekend!

Cheers!