Code Question for v0.8
Posted: Wed Sep 02, 2020 4:28 am
Once I decided to make great mod for Barotrauma v0.8 and once I did it, but once I saw version newer then 0.8 and decided to make magazine system too.
I hope what someone know "secrets" of code. So...if you know, then I almost made this system, but I can't make bullet output. I made first and last try with this code, because I don't know any mechanics of spawning items by items.
Code of magazine:
Code of weapon:
It shoots, but without bullets and any damage. Remember, 0.8, not newer version.
I hope what someone know "secrets" of code. So...if you know, then I almost made this system, but I can't make bullet output. I made first and last try with this code, because I don't know any mechanics of spawning items by items.
Code of magazine:
Code: Select all
<ItemContainer capacity="1" hideitems="true">
<Containable name="10mm Round"/>
<StatusEffect type="OnUse" target="This" condition="-5.0" disabledeltatime="true">
<SpawnItem name="10mm Round" spawnposition="Inventory" />
</StatusEffect>
</ItemContainer>
Code: Select all
<ItemContainer capacity="2" hideitems="true">
<Containable name="test Magazine"/>
<StatusEffect type="OnUse" target="This" disabledeltatime="true">
<SpawnItem identifiers="10mm Round" spawnposition="Container" />
</StatusEffect>
</ItemContainer>
It shoots, but without bullets and any damage. Remember, 0.8, not newer version.
Spoiler