PDA

View Full Version : tried to make engines an assembled object



Orphen
08-06-2016, 09:19 PM
So I altered small engines an assembled item and everything seemed to be fine. I could make the parts and assemble a small engine. The problem is with small engine drops and using them in a minibike. Everytime one drops from salvaging a car or from a work crate it appears without a durability and gives an error whenever you select it. When a found one is used in a minibike it cannot be moved or filled with gas. If I spawn one of the working small engines I can build from parts and use it in the minibike it crashes hard. After I reload the server the minibike cannot be moved or destroyed. It becomes a blight on the landscape. Is someone able to explain what I need to change to make it work right?

These are the changes I made to the small engine
<append xpath="/items/item[@name='smallEngine']">
<property name="HandMeshfile" value="Items/Misc/sackPrefab" />
<property class="Parts">
<property name="Stock" value="partsEngine_parts" />
<property name="Receiver" value="partsCaberator" />
<property name="Pump" value="partsPistons" />
<property name="Barrel" value="partsBlock" />
</property>
</append>

<item id="" name="CZEngineBook">
<property name="Extends" value="schematicMaster" />
<property class="Action1">
<property name="Recipes_to_learn" value="smallEngine,partsEngine_parts,partsCaberator,parts Pistons,partsBlock" />
<property name="Skills_to_gain" value="Machining" />
</property>
<property name="CraftingSkillGroup" value="Machining" />
<property name="CustomIcon" value="gpmm" />
</item>

<item id="" name="partsEngine_parts">
<property name="Extends" value="partsMaster" />
<property name="CustomIcon" value="partsAuger_parts" />
<property name="DescriptionKey" value="enginePartsDesc" />
<property name="PartType" value="Stock" />
<property name="Weight" value="10" />
<property class="Attributes">
<property name="DegradationMax" value="700,4000" />
</property>
<property name="CraftingSkillGroup" value="Machining" />
</item>

<item id="" name="partsCarberator">
<property name="Extends" value="partsMaster" />
<property name="DescriptionKey" value="enginePartsDesc" />
<property name="PartType" value="Receiver" />
<property name="Weight" value="20" />
<property class="Attributes">
<property name="DegradationMax" value="700,4000" />
</property>
<property name="CraftingSkillGroup" value="Machining" />
</item>

<item id="" name="partsPistons">
<property name="Extends" value="partsMaster" />
<property name="DescriptionKey" value="enginePartsDesc" />
<property name="PartType" value="Pump" />
<property name="Weight" value="10" />
<property class="Attributes">
<property name="DegradationMax" value="700,4000" />
</property>
<property name="CraftingSkillGroup" value="Machining" />
</item>

<item id="" name="partsBlock">
<property name="Extends" value="partsMaster" />
<property name="DescriptionKey" value="enginePartsDesc" />
<property name="PartType" value="Barrel" />
<property name="Weight" value="10" />
<property class="Attributes">
<property name="DegradationMax" value="700,4000" />
</property>
<property name="CraftingSkillGroup" value="Machining" />
</item>

<recipe name="smallEngine" count="1" scrapable="False" craft_area="assembly">
<ingredient name="partsEngine_parts" count="1" />
<ingredient name="partsCaberator" count="1" />
<ingredient name="partsPistons" count="1" />
<ingredient name="partsBlock" count="1" />
</recipe>
These are the specific errors I get when using randomly found ones without a durability and ones I build or generate in.
This is the error I get when trying to select a randomly found small engine in my inventory

NullReferenceException: Object reference not set to an instance of an object
at XUiM_ItemStack.GetItemStats (.ItemStack itemStack) [0x00000] in <filename unknown>:0
at XUiC_ItemInfoWindow.VEI (.ItemStack , .XUiController , ItemActionListTypes ) [0x00000] in <filename unknown>:0
at XUiC_ItemInfoWindow.SetItemStack (.XUiC_ItemStack stack) [0x00000] in <filename unknown>:0
at XUiC_ItemInfoWindow.SetItemInfo (.XUiC_ItemStack stack) [0x00000] in <filename unknown>:0
at XUiC_ItemStack.HandleItemInspect () [0x00000] in <filename unknown>:0
at XUiC_ItemStack.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUi.Update () [0x00000] in <filename unknown>:0



This is the error it gives when I place a found small engine into a minibike

NullReferenceException: Object reference not set to an instance of an object
at AttributeBase.GetVal[AttributeVehicleMaxSpeed] (.ItemValue _itemValue, Single _default) [0x00000] in <filename unknown>:0
at VPEngine.SetItemValue (.ItemValue _itemValue) [0x00000] in <filename unknown>:0
at Vehicle.SetPartInSlot (System.String _tag, .ItemValue _itemValue) [0x00000] in <filename unknown>:0
at XUiM_Vehicle.SetPart (System.String vehicleSlotName, .ItemStack stack, .ItemStack& resultStack) [0x00000] in <filename unknown>:0
at XUiC_ItemStack.HandleMoveToPreferredLocation () [0x00000] in <filename unknown>:0
at XUiC_ItemStack.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUiController.Update (Single _dt) [0x00000] in <filename unknown>:0
at XUi.Update () [0x00000] in <filename unknown>:0



This is an error that brings the server to a halt when you hop on a minibike

NullReferenceException: Object reference not set to an instance of an object
at AttributeBase.GetVal[AttributeVehicleIdleSecondsPerLiter] (.ItemValue _itemValue, Single _default) [0x00000] in <filename unknown>:0
at VPEngine.Update (Single _dt) [0x00000] in <filename unknown>:0
at Vehicle.Update (Single _dt) [0x00000] in <filename unknown>:0
at EntityVehicle.Update () [0x00000] in <filename unknown>:0