• If you have a mod, tool or prefab, please use the Resources section. Click Mods at the top of the forums.

Why not a mod to make spears stackable like arrows?

Kilroy5150

New member
I don't mean make a mod to go crazy with like 50 but maybe 5-10 per slot and, when picked up, they go back into that slot until they fill up and then go to the next available slot. But, when in hand, and being throw, the countdown from 10 to 0 and finally empty out.

I've just seen it done on other games and it sorta makes sense to do it here. It takes up less belt slots and you don't have to switch to another slot to throw another spear.

 
^ that.

If we removed the quality levels, then they could stack but higher tier wouldn't mean they get better.

 
You CAN make them stackable but then you'd have to pay attention to not stack your high QL spear onto a low QL one and it would always dupe all installed mods.

 
I suggest to instead do it on the bone knife or hunting knife (remove quality, make em stackable, throwable and stickable).

This would give the agility skill a very nice weapon diversity !

 
Stacking would also mess up the durability of such items.

Everything that is not a pure "type" but an "instance" (has own individual values only regarding THIS instance of the item) can not be stacked, as a stack afaik is "X amount items of type Y", instead of a list of individual items (instances). That means all items in one stack need to have all attributes to have the same value.

 
I'm glad this question led to a spark of conversation. Has anyone, since the original post, come up with anything "modded" to make them stackable and able to fall back into the place they were when grabbed?

 
I am modding spears to make two types of spears .... one for thrusting and one for throwing so that you can have power attacks on spears.  

I have separated them but I cannot make the throwing speras stack because I cannot remove the quality level ... how do you make an item NOT have a quality level anymore? 

 
This is what the Throwing spear looks like : it works and can ONLY be thrown but they do not stack.

<item name="rangedWpnSpearT0StoneSpear" tiered="false">
    <property name="Tags" value="ammo,grunting,weapon,attPerception,perkJavelinMaster,noMods"/>
    <property name="DisplayType" value="meleeSpear"/>
    <property name="HoldType" value="59"/>
    <property name="Meshfile" value="#Other/Items?Weapons/Melee/Spear/spear_stone_Prefab.prefab"/>
    <property name="Material" value="Mstone"/>
    <property name="StickyMaterial" value="#Other/Items?Weapons/Melee/Spear/Materials/spear_sticky.mat"/>
    <property name="SoundDestroy" value="wooddestroy1"/>
    <property name="CustomIcon" value="meleeWpnSpearT0StoneSpear" />
    <property name="CustomIconTint" value="FD9095" />
    <property name="Stacknumber" value="10"/>
    <property name="FuelValue" value="75"/>
    <property name="EconomicValue" value="175"/>    
    <property name="SellableToTrader" value="false"/>
    <property name="IsSticky" value="true"/>
    <property name="StickyOffset" value=".7"/>
    <property name="StickyColliderUp" value="1"/>
    <property name="StickyColliderRadius" value=".1"/>
    <property name="StickyColliderLength" value="2"/>
    <property name="StickyForwardDirection" value="0,0,1"/>
    <property name="Group" value="Ammo/Weapons,Basics"/>
    <property name="NavObject" value="spear"/>
    <property class="Action0">
        <requirement name="StatCompareCurrent" stat="Stamina" operation="GTE" value="20.1"/>
        <property name="Class" value="ThrownWeapon"/>
        <property name="Hitmask_override" value="Bullet"/>
        <property name="Delay" value="1.2"/>
        <property name="Throw_strength_default" value="6"/>
        <property name="Throw_strength_max" value="18"/>
        <property name="Max_strain_time" value="1"/>
        <property name="Sound_start" value="spear_throw"/>
        <property name="Explosion.ParticleIndex" value="0"/> <!-- no expl. -->
        <property name="FlyTime" value="0"/>
        <property name="Gravity" value="-7.5"/> <!-- default is -9.81 -->
        <property name="LifeTime" value="60"/>
        <property class="HitSounds">
            <property name="Override0" value="organic" param1="metalstaborganic"/>
        </property>
    </property>

    <effect_group name="rangedWpnSpearT0StoneSpear" tiered="false">
        <passive_effect name="EntityDamage" operation="base_set" value="10.3" tags="perkJavelinMaster"/> <!-- meleeWpnSpearT0StoneSpear -->
        <passive_effect name="TargetArmor" operation="perc_add" value="-.2" tags="perkJavelinMaster"/><display_value name="dTargetArmor" value="-.2"/>
        <passive_effect name="BlockDamage" operation="base_set" value="5" tags="perkJavelinMaster"/>
        <passive_effect name="StaminaLoss" operation="base_set" value="18.5" tags="primary"/>
        <passive_effect name="MaxRange" operation="base_set" value="4" tags="perkJavelinMaster"/>
        <passive_effect name="BlockRange" operation="base_set" value="3.5" tags="perkJavelinMaster"/>
        <passive_effect name="DamageModifier" operation="perc_add" value="-.8" tags="wood"/>
        <passive_effect name="DamageModifier" operation="perc_add" value="-.9" tags="stone"/>
        <passive_effect name="DamageModifier" operation="perc_add" value="-.9" tags="metal"/>
        <passive_effect name="ModSlots" operation="base_set" value="0"/>
        <passive_effect name="HarvestCount" operation="base_add" value="-.75" tags="allHarvest"/>
        <passive_effect name="HarvestCount" operation="base_add" value="-.75" tags="allToolsHarvest"/>
        <passive_effect name="HarvestCount" operation="base_add" value="-.75" tags="oreWoodHarvest"/>
    </effect_group>

    <effect_group name="Throw">
        <passive_effect name="EntityDamage" operation="perc_add" value="2.85" tags="secondary"/>
        <passive_effect name="BlockDamage" operation="perc_add" value="2.85" tags="secondary"/>
        <passive_effect name="StaminaLoss" operation="base_set" value="36.9" tags="secondary"/>
    </effect_group>
</item>

 
Well I figured it out completely ... and now I have:

1) Thrusting Spears with power Attack option.

2) Throwing Javelins that stack.

I had to tweak the max strain time on the javelins to make them less cheezy .... the strain time goes up as you move to steel javelins

I now just need to put in recipes ... 

This is what they look like now ... the biggest mystery was putting tiered="false" next to the "Throw" effect group .... that was the secret.  If you do not put that they won't stack.  

<item name="ThrowingSpear">
    <property name="Tags" value="ammo,grunting,weapon,attPerception,perkJavelinMaster,noMods"/>
    <property name="DisplayType" value="meleeTorch"/>
    <property name="Class" value="ItemClassTorch"/>
    <property name="HoldType" value="59"/>
    <property name="Meshfile" value="#Other/Items?Weapons/Melee/Spear/spear_stone_Prefab.prefab"/>
    <property name="StickyMaterial" value="#Other/Items?Weapons/Melee/Spear/Materials/spear_sticky.mat"/><property name="DropScale" value=".6"/>
    <property name="Material" value="Mstone"/>
    <property name="SoundDestroy" value="wooddestroy1"/>
    <property name="Stacknumber" value="10"/> <!-- STK torch -->
    <property name="FuelValue" value="25"/>
    <property name="EconomicValue" value="10"/>    
    <property name="CustomIcon" value="meleeWpnSpearT0StoneSpear"/>
    <property name="CustomIconTint" value="FD5895"/>
    <property name="IsSticky" value="true"/>
    <property name="StickyOffset" value=".7"/>
    <property name="StickyColliderUp" value="1"/>
    <property name="StickyColliderRadius" value=".1"/>
    <property name="StickyColliderLength" value="2"/>
    <property name="StickyForwardDirection" value="0,0,1"/>
    <property name="NavObject" value="spear"/>
    
        <requirement name="StatCompareCurrent" stat="Stamina" operation="GTE" value="20.1"/>
        <property name="Class" value="ThrownWeapon"/>
        <property name="Hitmask_override" value="Bullet"/>
        <property name="Delay" value="1.2"/>
        <property name="Throw_strength_default" value="6"/>
        <property name="Throw_strength_max" value="18"/>
        <property name="Max_strain_time" value="2.0"/>
        <property name="Sound_start" value="spear_throw"/>
        <property name="Explosion.ParticleIndex" value="0"/> <!-- no expl. -->
        <property name="FlyTime" value="0"/>
        <property name="Gravity" value="-7.5"/> <!-- default is -9.81 -->
        <property name="LifeTime" value="60"/>
        <property class="HitSounds">
            <property name="Override0" value="organic" param1="metalstaborganic"/>
        </property>
    </property>
    <property name="Group" value="Basics,Ammo/Weapons"/>
    

    <effect_group name="ThrowingSpear" tiered="false">
        <passive_effect name="MaxRange" operation="base_set" value="4" tags="perkJavelinMaster"/>
        <passive_effect name="BlockRange" operation="base_set" value="3.5" tags="perkJavelinMaster"/>
        <passive_effect name="TargetArmor" operation="perc_add" value="-.2" tags="perkJavelinMaster"/><display_value name="dTargetArmor" value="-.2"/>
        <passive_effect name="EntityDamage" operation="base_set" value="10" tags="perkJavelinMaster"/> <!-- meleeToolTorch -->
        <passive_effect name="BlockDamage" operation="base_set" value="5" tags="perkJavelinMaster"/>
        <passive_effect name="DamageModifier" operation="perc_add" value="-.5" tags="earth"/>
        <passive_effect name="DamageModifier" operation="perc_add" value="-.5" tags="stone"/>
        <passive_effect name="DamageModifier" operation="perc_add" value="-.5" tags="metal"/>
        <passive_effect name="AttacksPerMinute" operation="base_set" value="50"/>
        <passive_effect name="HarvestCount" operation="base_add" value="-.75" tags="allHarvest"/>
        <passive_effect name="HarvestCount" operation="base_add" value="-.75" tags="allToolsHarvest"/>
        <passive_effect name="HarvestCount" operation="base_add" value="-.75" tags="oreWoodHarvest"/>
        <passive_effect name="StaminaLoss" operation="base_set" value="25" tags="primary"/>
        <passive_effect name="ModSlots" operation="base_set" value="0"/>
    </effect_group>    
    
    <effect_group name="Throw"  tiered="false">
        <passive_effect name="EntityDamage" operation="perc_add" value="2.85" tags="secondary"/>
        <passive_effect name="BlockDamage" operation="perc_add" value="2.85" tags="secondary"/>
        <passive_effect name="StaminaLoss" operation="base_set" value="36.9" tags="secondary"/>
    </effect_group>
    

</item>

 
Back
Top