Page 1 of 1

Constructing industries during game play

Posted: 07 Feb 2024 03:19
by starcraftguy1
I want to be able to build the printing works during game play.
Is there any line in the .xml that needs to edited?
This also applies to other industries as well.

Re: Constructing industries during game play

Posted: 08 Feb 2024 01:05
by Zakos
For industries, bit_10 is what controls whether you can build it during gameplay. Change it to 1 and you should see it in the build window.

This has been a godsend for me. There are some knowledge gaps, but almost every variable you'll ever need to know is detailed on this list.

Re: Constructing industries during game play

Posted: 08 Feb 2024 03:03
by starcraftguy1
Zakos wrote: 08 Feb 2024 01:05 For industries, bit_10 is what controls whether you can build it during gameplay. Change it to 1 and you should see it in the build window.

This has been a godsend for me. There are some knowledge gaps, but almost every variable you'll ever need to know is detailed on this list.
I only found "bit_8" and "bit_9" which were set to 1.
I changed the "9" to a 10 and nothing happened.....

Re: Constructing industries during game play

Posted: 08 Feb 2024 08:57
by Auge
Hello

Only for clarification. Do you ask for the function in Locomotion? I ask, because you are posting in the Locomotion section and Zakos seems to assume, your question is about OpenTTD, if I assume that he deliberately linked the TT-wiki.

Tschö, Auge

Re: Constructing industries during game play

Posted: 08 Feb 2024 13:45
by starcraftguy1
Auge wrote: 08 Feb 2024 08:57 Hello

Only for clarification. Do you ask for the function in Locomotion? I ask, because you are posting in the Locomotion section and Zakos seems to assume, your question is about OpenTTD, if I assume that he deliberately linked the TT-wiki.

Tschö, Auge
Yes.
Is the TT-wiki not for Locomotion???

Re: Constructing industries during game play

Posted: 08 Feb 2024 14:43
by Auge
Hello
starcraftguy1 wrote: 08 Feb 2024 13:45
Auge wrote: 08 Feb 2024 08:57 Only for clarification. Do you ask for the function in Locomotion? I ask, because you are posting in the Locomotion section and Zakos seems to assume, your question is about OpenTTD, if I assume that he deliberately linked the TT-wiki.
Yes.
Is the TT-wiki not for Locomotion???
As far as I know, no it's not.

Tschö, Auge

Re: Constructing industries during game play

Posted: 08 Feb 2024 21:30
by Walter1940
@Auge Zakos has already posted the correct list. There is a section for Locomotion in the tt-wiki. --> https://www.tt-wiki.net/wiki/Loco:Main_Page

Re: Constructing industries during game play

Posted: 09 Feb 2024 07:33
by Auge
Hello
Walter1940 wrote: 08 Feb 2024 21:30 @Auge Zakos has already posted the correct list. There is a section for Locomotion in the tt-wiki. --> https://www.tt-wiki.net/wiki/Loco:Main_Page
Oh, I wasn't aware of that. The URL contains no reference to Locomotion. I had expected a division into one namespace per game and thus a reference in the URL. I apologise for having caused unnecessary unrest.

Tschö, Auge

Re: Constructing industries during game play

Posted: 09 Feb 2024 16:38
by Zakos
starcraftguy1 wrote: 08 Feb 2024 03:03I only found "bit_8" and "bit_9" which were set to 1.
I changed the "9" to a 10 and nothing happened.....
You should change it back to the way you found it. bit_8 and bit_9 do completely different things from bit_10, and changing one into the other will either do nothing or mess up the file. Bit is short for binary digit, and it's a variable that is always either 0 (no) or 1 (yes). In order to change one of them, you should only change the value of the 0 or 1 in between >these< brackets. For example:

Code: Select all

<bit name="bit_10">0</bit>
Change the 0 to a 1 and:

Code: Select all

<bit name="bit_10">1</bit>
I looked in PRINTWRK.dat though and you're right, there's no bit_10 at all. Does anyone else know if we should just add another line of code in the bit section? If so, you could probably add <bit name="bit_10">1</bit> on the line below bit_9 and get the desired result.

Another option is to just download OpenLoco, where if you enable sandbox mode you'll be able to create and destroy industries freely. Doing both still costs a lot of money.

Re: Constructing industries during game play

Posted: 10 Feb 2024 04:03
by starcraftguy1
Zakos wrote: 09 Feb 2024 16:38
starcraftguy1 wrote: 08 Feb 2024 03:03I only found "bit_8" and "bit_9" which were set to 1.
I changed the "9" to a 10 and nothing happened.....
You should change it back to the way you found it. bit_8 and bit_9 do completely different things from bit_10, and changing one into the other will either do nothing or mess up the file. Bit is short for binary digit, and it's a variable that is always either 0 (no) or 1 (yes). In order to change one of them, you should only change the value of the 0 or 1 in between >these< brackets. For example:

Code: Select all

<bit name="bit_10">0</bit>
Change the 0 to a 1 and:

Code: Select all

<bit name="bit_10">1</bit>
I looked in PRINTWRK.dat though and you're right, there's no bit_10 at all. Does anyone else know if we should just add another line of code in the bit section? If so, you could probably add <bit name="bit_10">1</bit> on the line below bit_9 and get the desired result.

Another option is to just download OpenLoco, where if you enable sandbox mode you'll be able to create and destroy industries freely. Doing both still costs a lot of money.
I figured it out myself, so I added a new line and it worked. Sort of a trial and error process... :idea:

Re: Constructing industries during game play

Posted: 12 Feb 2024 22:38
by lsbc
this should do it..... save yours just in case.... works on mine... locotool with YOUR pngs...

<?xml version="1.0" encoding="ISO-8859-1"?>
<object class="0x9E" subclass="0x118E9B" name="PRINTWRK"><chunk compression="1">
<variable name="numaux01" size="1">2</variable>
<variable name="numaux4ent" size="1">2</variable>
<unknown name="field_20[156]" size="1">4</unknown>
<variable name="numaux5" size="1">7</variable>
<unknown name="field_BE[4]" size="1">4</unknown>
<unknown name="field_BE[8]" size="1">3</unknown>
<variable name="firstyear" size="2">0</variable>
<variable name="lastyear" size="2">65535</variable>
<unknown name="field_CE" size="1">2</unknown>
<variable name="costind" size="1">1</variable>
<variable name="costfactor1" size="2">288</variable>
<unknown name="field_D2[0]" size="1">240</unknown>
<unknown name="field_D2[2]" size="1">1</unknown>
<unknown name="field_D2[3]" size="1">16</unknown>
<unknown name="field_D2[17]" size="1">2</unknown>
<bitmask name="flags" size="4">
<bit name="bit_2">1</bit>
<bit name="bit_9">1</bit>
<bit name="bit_10">1</bit>
<bit name="needall">0</bit>
<bit name="canincreaseproduction">0</bit>
<bit name="candecreaseproduction">0</bit>
</bitmask>
<unknown name="field_E8[0]" size="1">1</unknown>
<unknown name="field_E8[1]" size="1">1</unknown>
<unknown name="field_E8[11]" size="1">1</unknown>
<description num="0" language="0">Printing Works</description>
<description num="0" language="1">Printing Works</description>
<description num="0" language="2">Imprimerie</description>
<description num="0" language="3">Druckerei</description>
<description num="0" language="4">Imprenta</description>
<description num="0" language="5">Stamperia</description>
<description num="0" language="9">ÿÀÎÿ¼â ÿ°øÿÀå</description>
<description num="0" language="11">ÿ¦Cÿ¦Lÿ¼t</description>
<description num="1" language="0">„@  Printing Works</description>
<description num="1" language="1">„@  Printing Works</description>
<description num="1" language="2">„@  Imprimerie</description>
<description num="1" language="3">„@  Druckerei</description>
<description num="1" language="4">„@  imprenta</description>
<description num="1" language="5">Stamperia di „@ </description>
<description num="1" language="9">„@  ÿÀÎÿ¼â ÿ°øÿÀå</description>
<description num="1" language="11">„@ ÿ¦Cÿ¦Lÿ¼t</description>
<description num="2" language="0">Printing Works </description>
<description num="2" language="1">Printing Works </description>
<description num="2" language="2">Imprimerie </description>
<description num="2" language="3">Druckerei </description>
<description num="2" language="4">Imprenta </description>
<description num="2" language="5">Stamperia </description>
<description num="2" language="9">ÿÀÎÿ¼â ÿ°øÿÀå</description>
<description num="2" language="11">ÿ¦Cÿ¦Lÿ¼t</description>
<description num="3" language="0">ƒ is closing down!</description>
<description num="3" language="1">ƒ is closing down!</description>
<description num="3" language="2">ƒ ferme !</description>
<description num="3" language="3">ƒ wird geschlossen!</description>
<description num="3" language="4">ƒ : cierra</description>
<description num="3" language="5">La ƒ sta chiudendo!</description>
<description num="3" language="9">ƒÿÀÌ(ÿ°¡) ÿÆóÿ¼âÿÁßÿÀÔÿ´Ïÿ´Ù!</description>
<description num="3" language="11">ƒÿ§Yÿ±NÿÃöÿ³¬!</description>
<description num="4" language="0">ƒ production up!</description>
<description num="4" language="1">ƒ production up!</description>
<description num="4" language="2">ƒ voit sa production augmenter !</description>
<description num="4" language="3">ƒ mit Produktionssteigerung!</description>
<description num="4" language="4">ƒ : sube la producción</description>
<description num="4" language="5">ƒ - la produzione aumenta!</description>
<description num="4" language="9">ƒ ÿ»ýÿ»êÿ·üÿÀÌ ÿÇâÿ»óÿµÇÿ¾úÿ½Àÿ´Ïÿ´Ù!</description>
<description num="4" language="11">ƒÿ²£ÿ¶qÿ¤Wÿ¤É!</description>
<description num="5" language="0">ƒ production down!</description>
<description num="5" language="1">ƒ production down!</description>
<description num="5" language="2">ƒ voit sa production diminuer !</description>
<description num="5" language="3">ƒ mit Produktionsrückgang!</description>
<description num="5" language="4">ƒ : baja la producción</description>
<description num="5" language="5">ƒ - la produzione diminuisce!</description>
<description num="5" language="9">ƒ ÿ»ýÿ»êÿ·üÿÀÌ ÿÀúÿÇÏÿµÇÿ¾úÿ½Àÿ´Ïÿ´Ù!</description>
<description num="5" language="11">ƒÿ²£ÿ¶qÿ¤Uÿ­°!</description>
<description num="6" language="0"> printing works</description>
<description num="6" language="1"> printing works</description>
<description num="6" language="2"> imprimerie</description>
<description num="6" language="3"> Druckerei</description>
<description num="6" language="4"> imprenta</description>
<description num="6" language="5"> stamperia</description>
<description num="6" language="9"> ÿÀÎÿ¼â ÿ°øÿÀå</description>
<description num="6" language="11">ÿ¦Cÿ¦Lÿ¼t</description>
<description num="7" language="0"> printing works</description>
<description num="7" language="1"> printing works</description>
<description num="7" language="2"> imprimeries</description>
<description num="7" language="3"> Druckereien</description>
<description num="7" language="4"> imprentas</description>
<description num="7" language="5"> stamperie</description>
<description num="7" language="9"> ÿÀÎÿ¼â ÿ°øÿÀå</description>
<description num="7" language="11">ÿ¦Cÿ¦Lÿ¼t</description>
<auxdata name="aux_0" size="1" num="2" type="0">
<unknown name="field_0[0]" size="1">86</unknown>
<unknown name="field_0[1]" size="1">60</unknown>
</auxdata>
<auxdata name="aux_1" size="2" num="2" type="0">
<unknown name="field_0[0]" size="2">1</unknown>
<unknown name="field_0[1]" size="2">1</unknown>
</auxdata>
<auxdata name="aux_2[0]" size="1" num="0" type="0">
</auxdata>
<auxdata name="aux_2[1]" size="1" num="0" type="0">
</auxdata>
<auxdata name="aux_2[2]" size="1" num="0" type="0">
</auxdata>
<auxdata name="aux_2[3]" size="1" num="0" type="0">
</auxdata>
<auxdata name="aux_3" size="2" num="0" type="1">
</auxdata>
<auxdata name="aux_4[0]" size="1" num="1" type="1">
</auxdata>
<auxdata name="aux_4[1]" size="1" num="1" type="1">
<unknown name="field_0" size="1">1</unknown>
</auxdata>
<auxdata name="aux_5" size="1" num="7" type="0">
<unknown name="field_0[1]" size="1">1</unknown>
<unknown name="field_0[3]" size="1">1</unknown>
<unknown name="field_0[6]" size="1">1</unknown>
</auxdata>
<useobject desc="produces[0]" class="8">GOODS </useobject>
<useobject desc="produces[1]" class="255">
</useobject>
<useobject desc="accepts[0]" class="8">PAPER </useobject>
<useobject desc="accepts[1]" class="255">
</useobject>
<useobject desc="accepts[2]" class="255">
</useobject>
<useobject desc="fence[0]" class="255">
</useobject>
<useobject desc="fence[1]" class="255">
</useobject>
<useobject desc="fence[2]" class="255">
</useobject>
<useobject desc="fence[3]" class="255">
</useobject>
<useobject desc="fence[4]" class="255">
</useobject>
<useobject desc="fence[5]" class="255">
</useobject>
<sprite id="0" xofs="-64" yofs="-101">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\000.png</pngfile>
</sprite>
<sprite id="1" xofs="-64" yofs="-101">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\001.png</pngfile>
</sprite>
<sprite id="2" xofs="-64" yofs="-101">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\002.png</pngfile>
</sprite>
<sprite id="3" xofs="-64" yofs="-101">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\003.png</pngfile>
</sprite>
<sprite id="4" xofs="-64" yofs="-77">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\004.png</pngfile>
</sprite>
<sprite id="5" xofs="-64" yofs="-76">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\005.png</pngfile>
</sprite>
<sprite id="6" xofs="-64" yofs="-64">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\006.png</pngfile>
</sprite>
<sprite id="7" xofs="-64" yofs="-64">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\007.png</pngfile>
</sprite>
<sprite id="8" xofs="-32" yofs="0">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\008.png</pngfile>
</sprite>
<sprite id="9" xofs="-32" yofs="-1">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\009.png</pngfile>
</sprite>
<sprite id="10" xofs="-32" yofs="0">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\010.png</pngfile>
</sprite>
<sprite id="11" xofs="-32" yofs="-1">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\011.png</pngfile>
</sprite>
<sprite id="12" xofs="-32" yofs="-1">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\012.png</pngfile>
</sprite>
<sprite id="13" xofs="-32" yofs="-1">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\013.png</pngfile>
</sprite>
<sprite id="14" xofs="-30" yofs="-1">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\014.png</pngfile>
</sprite>
<sprite id="15" xofs="-32" yofs="-1">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\015.png</pngfile>
</sprite>
<sprite id="16" xofs="-32" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\016.png</pngfile>
</sprite>
<sprite id="17" xofs="-32" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\017.png</pngfile>
</sprite>
<sprite id="18" xofs="-32" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\018.png</pngfile>
</sprite>
<sprite id="19" xofs="-32" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\019.png</pngfile>
</sprite>
<sprite id="20" xofs="-32" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\020.png</pngfile>
</sprite>
<sprite id="21" xofs="-32" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\021.png</pngfile>
</sprite>
<sprite id="22" xofs="-31" yofs="-16">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\022.png</pngfile>
</sprite>
<sprite id="23" xofs="-32" yofs="-32">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\023.png</pngfile>
</sprite>
<sprite id="24" xofs="0" yofs="0">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<stub>0</stub>
</sprite>
<sprite id="25" xofs="-32" yofs="-17">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\025.png</pngfile>
</sprite>
<sprite id="26" xofs="-31" yofs="-17">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<pngfile>I:\\New folder\\PRINTWRK\\026.png</pngfile>
</sprite>
<sprite id="27" xofs="31" yofs="14">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<stub>0</stub>
</sprite>
<sprite id="28" xofs="31" yofs="14">
<bit name="hasdata">1</bit>
<bit name="chunked">0</bit>
<bit name="copy">0</bit>
<stub>0</stub>
</sprite>
</chunk></object>