Need help with a production

Your forum for all discussions around Modding.
Harrison Fork
Posts: 20
Joined: Thu Dec 02, 2021 12:27 pm

Need help with a production

Post by Harrison Fork »

hi,

I get the warning "Unable to add source storage" when the xml of my production is loaded.

Furthermore the input goods I put into the production are shown in the UI with the right amount and I can activate the production line but no goods are consumed and the output goods filllevel stays at 0. But surprisingly the correct pallets are ejected from time to time.

Does anyone have an idea what the problem could be? I compared the xml several times with working production and can not figure out any difference or error in the xml.

Tanks in advance!

Peter
User avatar
Dogface
Posts: 1097
Joined: Mon Nov 28, 2016 3:02 pm
Location: PC ⛽ USA

Re: Need help with a production

Post by Dogface »

Is this a custom goods?
Is this a map or a placeable?
Harrison Fork
Posts: 20
Joined: Thu Dec 02, 2021 12:27 pm

Re: Need help with a production

Post by Harrison Fork »

Hi, I defined some custom filltypes and the production building is a placable. In another mod ("Potato Processing") I already worked with several custom product without a problem but I can not figure out the difference between the working production and this faulty one...
Steel_Horse
Posts: 157
Joined: Thu Jan 13, 2022 2:25 am

Re: Need help with a production

Post by Steel_Horse »

Harrison Fork wrote: Wed Sep 07, 2022 12:28 am Hi, I defined some custom filltypes and the production building is a placable. In another mod ("Potato Processing") I already worked with several custom product without a problem but I can not figure out the difference between the working production and this faulty one...
Hard to be sure without the xml but as the error isnt completely terminal, my best guess is you have a very minor typo in a filltype definition or in the use of a filltype. I would be looking at spacing or capitalisation of anything related to the inputs of that production
Harrison Fork
Posts: 20
Joined: Thu Dec 02, 2021 12:27 pm

Re: Need help with a production

Post by Harrison Fork »

Yeah for sure you need more information. Maybe you can see what I do not see ...

These are the fill types defined in my fillTypes.xml:

Code: Select all

	<fillType name="FISH_FEED" title="$l10n_fillType_fishFeed" showOnPriceTable="true">
            <physics massPerLiter="1" maxPhysicalSurfaceAngle="38" />
            <economy pricePerLiter="2.25">
                <factors>
                    <factor period="1"  value="1.20" />
                    <factor period="2"  value="1.10" />
                    <factor period="3"  value="1.10" />
                    <factor period="4"  value="1.10" />
                    <factor period="5"  value="1.10" />
                    <factor period="6"  value="1.10" />
                    <factor period="7"  value="1.10" />
                    <factor period="8"  value="1.20" />
                    <factor period="9"  value="1.20" />
                    <factor period="10" value="1.20" />
                    <factor period="11" value="1.20" />
                    <factor period="12" value="1.20" />
                </factors>
            </economy>
            <image      hud     ="textures/hud_filltypeIcon_fishFeed.dds" />
            <pallet     filename="pallets/fishFeedPallet.xml" />
        </fillType>
        
        <fillType name="BABY_CARP" title="$l10n_fillType_babyCarp" showOnPriceTable="true">
            <physics massPerLiter="0.75" maxPhysicalSurfaceAngle="38" />
            <economy pricePerLiter="0.37">
                <factors>
                    <factor period="1"  value="1.20" />
                    <factor period="2"  value="1.10" />
                    <factor period="3"  value="1.10" />
                    <factor period="4"  value="1.10" />
                    <factor period="5"  value="1.00" />
                    <factor period="6"  value="1.00" />
                    <factor period="7"  value="1.10" />
                    <factor period="8"  value="1.20" />
                    <factor period="9"  value="1.30" />
                    <factor period="10" value="1.30" />
                    <factor period="11" value="1.20" />
                    <factor period="12" value="1.20" />
                </factors>
            </economy>
            <image      hud     ="textures/hud_filltypeIcon_babyCarp.dds" />
            <pallet     filename="pallets/babyCarpPallet.xml" />
        </fillType>

        <fillType name="YOUNG_CARP" title="$l10n_fillType_youngCarp" showOnPriceTable="true">
            <physics massPerLiter="0.75" maxPhysicalSurfaceAngle="38" />
            <economy pricePerLiter="0.37">
                <factors>
                    <factor period="1"  value="1.20" />
                    <factor period="2"  value="1.10" />
                    <factor period="3"  value="1.10" />
                    <factor period="4"  value="1.10" />
                    <factor period="5"  value="1.00" />
                    <factor period="6"  value="1.00" />
                    <factor period="7"  value="1.10" />
                    <factor period="8"  value="1.20" />
                    <factor period="9"  value="1.30" />
                    <factor period="10" value="1.30" />
                    <factor period="11" value="1.20" />
                    <factor period="12" value="1.20" />
                </factors>
            </economy>
            <image      hud     ="textures/hud_filltypeIcon_youngCarp.dds" />
            <pallet     filename="pallets/youngCarpPallet.xml" />
        </fillType>

And this is the XML file of the production:

Code: Select all

<?xml version="1.0" encoding="utf-8" standalone="no" ?>

<placeable type="productionPoint" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../shared/xml/schema/placeable.xsd">

    <storeData>
        <name>$l10n_shopItem_carpBreedingPondRectangularSmall</name>

    <image>textures/store_carpBreedingPondRectangularSmall.dds</image>

	<functions>
        <function>$l10n_function_carpBreedingPond</function>
    </functions>
         
        <price>2000</price>
		<lifetime>1000</lifetime>
		<dailyUpkeep>0</dailyUpkeep>
        <rotation>0</rotation>
        <brand>NONE</brand>
        <species>placeable</species>
        <category>placeableMisc</category>
		<canBeSold>true</canBeSold>
        <showInStore>true</showInStore>
        
		<brush>
            <type>placeable</type>
            <category>production</category>
            <tab>factories</tab>
        </brush>
    </storeData>

    <base>
        <filename>carpBreedingPondRectangularSmall.i3d</filename>
		<canBeRenamed>true</canBeRenamed>
    </base>

    <placement useRandomYRotation="false" useManualYRotation="true">
	    <testAreas>
            <testArea startNode="testArea1Start" endNode="testArea1End" />
        </testAreas>
    </placement>
	
	<clearAreas/>
	
	<leveling requireLeveling="true" maxSmoothDistance="1" maxSlope="75" maxEdgeAngle="30">
        <levelAreas>
            <levelArea startNode="levelArea1Start" widthNode="levelArea1Width" heightNode="levelArea1Height"/>
        </levelAreas>
    </leveling>
	
	<indoorAreas/>
	
	<tipOcclusionUpdateAreas/>

    <ai>
        <updateAreas>
            <updateArea startNode="tipOcclusionUpdateArea1Start" endNode="tipOcclusionUpdateArea1End" />
        </updateAreas>
    </ai>

    <triggerMarkers>
        <triggerMarker node="warningStripes" />
        <triggerMarker node="playerTriggerMarker" filename="$data/shared/assets/marker/markerIcons.xml" id="WRENCH" adjustToGround="true" />
        <triggerMarker node="unloadTriggerMarker" filename="$data/shared/assets/marker/markerIcons.xml" id="UNLOAD"  adjustToGround="true" />
    </triggerMarkers>

    <productionPoint>
        <productions>
            
            <production id="carpBreedingPondRectangularSmall_youngCarps" name="$l10n_production_youngCarp" cyclesPerHour="100" costsPerActiveHour="0.1">
                <inputs>
                    <input fillType="FISH_FEED" amount="1" />
                    <input fillType="BABY_CARP" amount="1" />
                </inputs>
                <outputs>
                    <output fillType="YOUNG_CARP" amount="1" />
                </outputs>
            </production>

        </productions>

        <sellingStation node="storage" appearsOnStats="false" supportsExtension="false">
            <unloadTrigger exactFillRootNode="unloadTrigger" fillTypes="FISH_FEED BABY_CARP" aiNode="unloadTriggerAINode" />
        </sellingStation>

        <loadingStation/>

        <palletSpawner node="palletSpawner">
            <spawnPlaces>
                <spawnPlace startNode="spawnPlace1Start" />
            </spawnPlaces>
        </palletSpawner>

        <!-- <storage node="storage" isExtension="false" fillLevelSyncThreshold="15" fillTypes="FISH_FEED BABY_CARP YOUNG_CARP"> -->
        <storage isExtension="false" fillLevelSyncThreshold="50" fillTypes="FISH_FEED BABY_CARP YOUNG_CARP" node="storage">
            <capacity fillType="FISH_FEED"      capacity="2000" />
            <capacity fillType="BABY_CARP"      capacity="2000" />
            <capacity fillType="YOUNG_CARP"     capacity="4000" />
        </storage>

        <playerTrigger node="playerTrigger" />
    </productionPoint>
	
	<i3dMappings>
        <i3dMapping id="clearAreas" node="0>1" />
		<i3dMapping id="clearArea1Start" node="0>1|0" />
		<i3dMapping id="clearArea1Width" node="0>1|0|0" />
		<i3dMapping id="clearArea1Height" node="0>1|0|1" />
		<i3dMapping id="levelAreas" node="0>2" />
		<i3dMapping id="levelArea1Start" node="0>2|0" />
		<i3dMapping id="levelArea1Width" node="0>2|0|0" />
		<i3dMapping id="levelArea1Height" node="0>2|0|1" />
		<i3dMapping id="indoorAreas" node="0>3" />
		<i3dMapping id="indoorArea1Start" node="0>3|0" />
		<i3dMapping id="indoorArea1Width" node="0>3|0|0" />
		<i3dMapping id="indoorArea1Height" node="0>3|0|1" />
		<i3dMapping id="testAreas" node="0>4" />
		<i3dMapping id="testArea1Start" node="0>4|0" />
		<i3dMapping id="testArea1End" node="0>4|0|0" />
		<i3dMapping id="tipOcclusionUpdateAreas" node="0>5" />
		<i3dMapping id="tipOcclusionUpdateArea1Start" node="0>5|0" />
		<i3dMapping id="tipOcclusionUpdateArea1End" node="0>5|0|0" />
        <i3dMapping id="storage" node="0>6" />
        <i3dMapping id="teleportNode" node="0>6|0" />
        <i3dMapping id="unloadTrigger" node="0>6|0" />
        <i3dMapping id="unloadTriggerMarker" node="0>6|1" />
        <i3dMapping id="unloadTriggerAINode" node="0>6|2" />
        <i3dMapping id="palletSpawner" node="0>7" />
        <i3dMapping id="spawnPlace1Start" node="0>7|0" />
        <i3dMapping id="warningStripes" node="0>8" />
        <i3dMapping id="playerTrigger" node="0>9|0" />
        <i3dMapping id="playerTriggerMarker" node="0>9|0|0" />
        <!-- <i3dMapping id="infoTrigger" node="0>10" /> -->
    </i3dMappings>
	
</placeable>
Steel_Horse
Posts: 157
Joined: Thu Jan 13, 2022 2:25 am

Re: Need help with a production

Post by Steel_Horse »

Only thing that I can see is a bit of a long shot.
<capacity fillType="FISH_FEED" capacity="2000" />
<capacity fillType="BABY_CARP" capacity="2000" />
<capacity fillType="YOUNG_CARP" capacity="4000" />


You have a bunch of spaces in the capacity section of the Storage definition. I would delete them and see if it makes a difference. I have seen multiple spaces in an expression cause weird stuff before

eg change it to
<capacity fillType="FISH_FEED" capacity="2000" />
<capacity fillType="BABY_CARP" capacity="2000" />
<capacity fillType="YOUNG_CARP" capacity="4000" />
Harrison Fork
Posts: 20
Joined: Thu Dec 02, 2021 12:27 pm

Re: Need help with a production

Post by Harrison Fork »

Thanks for the tip. I tried this out but with no effect :-(
ivor01
Posts: 3
Joined: Tue Sep 20, 2022 7:21 pm

Re: Need help with a production

Post by ivor01 »

Potato processing is stopping player’s from joining server since the update
Post Reply