Page MenuHomeFeedback Tracker

Batteries Attached to Appliances in cfgspawnabletypes.xml file ignore types.xml quantmin and quantmax
Closed, ResolvedPublic

Description

Batteries Attached to appliances in cfgspawnabletypes.xml ignore the <quantmin>30</quantmin> <quantmax>100</quantmax> in the types.xml file

<!-- Other -->

        <type name="KobraOptic">
		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="PSO11Optic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="PSO1Optic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="Megaphone">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="NVGoggles">=

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="KazuarOptic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="StarlightOptic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="FNP45_MRDSOptic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="Rangefinder">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="ReflexOptic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="KashtanOptic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="M4_T3NRDSOptic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="M68Optic">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>
<type name="TLRLight">

		<attachments chance="0.15">
			<item name="Battery9V" chance="1.00" />
		</attachments>

</type>

Battery in types file:

<type name="Battery9V">

    <nominal>100</nominal>
    <lifetime>14400</lifetime>
    <restock>1800</restock>
    <min>80</min>
    <quantmin>30</quantmin>
    <quantmax>100</quantmax>
    <cost>100</cost>
    <flags count_in_cargo="0" count_in_hoarder="0" count_in_map="1" count_in_player="0" crafted="0" deloot="0"/>
    <category name="tools"/>
    <tag name="shelves"/>
    <usage name="Industrial"/>
    <usage name="Village"/>
</type>

Any battery found in an optic or appliances will always be full, never random.

Details

Severity
Minor
Resolution
Open
Reproducibility
Always
Operating System
Windows 7
Category
Config
Steps To Reproduce

Attach a battery to any item that can use a battery in the cfgspawnabletypes.xml file

Find a item that can use a battery and see that the battery is full

Additional Information

Some items have a random quality. But items I listed will always have a full battery.

Event Timeline

Geez changed the task status from New to Awaiting internal Testing.Mar 29 2023, 10:00 AM
Geez changed the task status from Awaiting internal Testing to Confirmed Internally.
Geez added subscribers: etwas, sileed.
Geez closed this task as Resolved.Oct 25 2023, 10:12 AM
Geez claimed this task.
Geez added a subscriber: Geez.

Resolved in stable 1.23.