2021-09-24 12:00:38 +02:00
<?xml version="1.0" encoding="utf-8"?>
2021-10-11 19:05:02 +02:00
{% if config['slug'] != "Sunken Tapes" %}<!-- This mod is based on Sunken Tapes. See https://git.kompot.si/jaka/barotrauma - sunken - tapes and https://steamcommunity.com/sharedfiles/filedetails/?id=2616577901 for the source material and code generator. --> {% else %}<!-- Code licensed under GPLv3 and generated with a script available at https://git.kompot.si/jaka/barotrauma - sunken - tapes --> {% endif %}
2021-09-24 12:00:38 +02:00
<Items >
<Item name= "Boombox" cargocontaineridentifier= "metalcrate" identifier= "boombox" category= "Equipment" Tags= "mediumitem,boombox" scale= "0.5" description= "" price= "850" impactsoundtag= "impact_metal_light" isshootable= "true" >
<PreferredContainer primary= "abandonedcrewcab" spawnprobability= "0.1" />
<PreferredContainer primary= "outpostcrewcabinet" spawnprobability= "0.1" />
<Price baseprice= "500" soldeverywhere= "false" >
<Price locationtype= "outpost" multiplier= "1" minavailable= "1" />
<Price locationtype= "city" multiplier= "0.7" minavailable= "1" />
<Price locationtype= "research" multiplier= "1.5" sold= "false" />
<Price locationtype= "military" multiplier= "1.5" sold= "false" />
<Price locationtype= "mine" multiplier= "1.5" sold= "false" />
</Price>
<Upgrade gameversion= "0.9.2.0" scale= "0.5" />
2021-10-11 19:05:02 +02:00
<InventoryIcon texture= "Mods/{{ config['slug'] }}/icons.png" sourcerect= "0,0,64,64" origin= "0.5,0.5" />
<Sprite texture= "Mods/{{ config['slug'] }}/boombox.png" sourcerect= "0,0,100,60" depth= "0.55" origin= "0.5,0.5" />
2021-09-24 12:00:38 +02:00
<Body width= "100" height= "60" />
<LightComponent LightColor= "0.78,0.04,0.235,0.59" range= "10" powerconsumption= "0" blinkfrequency= "1" IsOn= "false" canbeselected= "false" >
</LightComponent>
<CustomInterface canbeselected= "true" drawhudwhenequipped= "true" allowuioverlap= "true" >
<GuiFrame relativesize= "0.10,0.07" anchor= "CenterLeft" pivot= "BottomLeft" relativeoffset= "0.006,-0.05" style= "ItemUI" />
<TickBox text= "Play" >
<StatusEffect type= "OnUse" targettype= "This" IsOn= "true" >
<Conditional IsOn= "false" />
2021-10-11 19:05:02 +02:00
<sound file= "Mods/{{ config['slug'] }}/sound_effects/boombox_play_cassette.ogg" type= "OnUse" range= "500" volume= "1.0" />
2021-09-24 12:00:38 +02:00
</StatusEffect>
<!-- StatusEffect type="OnUse" targettype="Contained" comparison="And">
<Conditional condition= "lte 50.0" />
<Conditional condition= "gt 25.0" />
<RequiredItem items= "cassette" type= "Contained" />
<sound file= "Content/Sounds/FireSmall.ogg" type= "OnUse" range= "1000" loop= "true" volume= "1.0" />
</StatusEffect>
<StatusEffect type= "OnUse" targettype= "Contained" comparison= "And" >
<Conditional condition= "lte 25.0" />
<Conditional condition= "gt 10.0" />
<RequiredItem items= "cassette" type= "Contained" />
<sound file= "Content/Sounds/FireSmall.ogg" type= "OnUse" range= "1000" loop= "true" volume= "1.0" />
</StatusEffect>
<StatusEffect type= "OnUse" targettype= "Contained" >
<Conditional condition= "lte 10.0" />
<RequiredItem items= "cassette" type= "Contained" />
<sound file= "Content/Sounds/FireSmall.ogg" type= "OnUse" range= "1000" loop= "true" volume= "1.0" />
</StatusEffect-->
{% for tape in tapes %}
<StatusEffect type= "OnUse" targettype= "Contained" condition= "-{{ condition_delta[loop.index0] }}" >
<RequiredItem items= "cassette-{{ tape.identifier }}" type= "Contained" />
<SpawnItem identifiers= "song-{{ tape.identifier }}" spawnposition= "ContainedInventory" />
</StatusEffect> {% endfor %}
<StatusEffect type= "OnSecondaryUse" targettype= "This" IsOn= "false" >
<Conditional IsOn= "true" />
2021-10-11 19:05:02 +02:00
<sound file= "Mods/{{ config['slug'] }}/sound_effects/boombox_play_cassette.ogg" type= "OnUse" range= "500" volume= "1.0" />
2021-09-24 12:00:38 +02:00
<Use />
</StatusEffect>
</TickBox>
</CustomInterface>
<Holdable slots= "RightHand,LeftHand" selectkey= "Use" pickkey= "Select" attachable= "false" aimable= "false" holdpos= "5,-65" holdangle= "0" aimpos= "5,30" handle1= "0,30" handle2= "0,30" swingamount= "20,5" swingspeed= "0.5" swingwhenusing= "true" msg= "ItemMsgPickUpUse" >
</Holdable>
<ItemContainer hideitems= "true" drawinventory= "true" capacity= "1" maxstacksize= "1" slotsperrow= "6" itempos= "0,0" iteminterval= "0,0" itemrotation= "0" canbeselected= "false" containedspritedepth= "0.79" >
<StatusEffect type= "OnUse" targettype= "Contained" >
<Use />
</StatusEffect>
<Containable items= "cassette" >
</Containable>
</ItemContainer>
</Item>
<!-- tape box -->
<Item name= "Cassette Tape Box" identifier= "cassette-tape-box" category= "Equipment" tags= "smallitem,mobilecontainer,tool" cargocontaineridentifier= "" showcontentsintooltip= "true" Scale= "0.5" fireproof= "true" description= "" impactsoundtag= "impact_metal_heavy" >
<PreferredContainer secondary= "wreckstoragecab" spawnprobability= "0.06" />
<PreferredContainer primary= "outpostcrewcabinet" minamount= "0" maxamount= "1" spawnprobability= "0.2" />
<Deconstruct time= "10" >
<Item identifier= "steel" />
</Deconstruct>
<Fabricate suitablefabricators= "fabricator" requiredtime= "20" >
<RequiredSkill identifier= "mechanical" level= "20" />
<Item identifier= "steel" />
</Fabricate>
<Price baseprice= "75" >
<Price locationtype= "outpost" multiplier= "1" minavailable= "1" />
<Price locationtype= "city" multiplier= "0.9" minavailable= "1" />
<Price locationtype= "research" multiplier= "1.25" minavailable= "1" />
<Price locationtype= "military" multiplier= "1.25" minavailable= "1" />
<Price locationtype= "mine" multiplier= "1.25" minavailable= "1" />
</Price>
<InventoryIcon texture= "Content/Items/InventoryIconAtlas.png" sourcerect= "640,256,64,64" origin= "0.5,0.6" />
<Sprite texture= "Content/Items/Tools/tools.png" sourcerect= "314,1,94,74" origin= "0.5,0.5" />
<Body width= "90" height= "60" density= "20" />
<MeleeWeapon slots= "RightHand,LeftHand,Any" controlpose= "true" aimpos= "45,10" handle1= "0,10" handle2= "0,10" holdangle= "90" reload= "1" range= "50" combatpriority= "6" msg= "ItemMsgPickUpSelect" >
<Attack structuredamage= "10" itemdamage= "5" stun= "0.6" targetimpulse= "2" >
<Affliction identifier= "blunttrauma" strength= "2" />
<Sound file= "Content/Items/Weapons/Smack2.ogg" range= "800" />
</Attack>
</MeleeWeapon>
<ItemContainer capacity= "24" keepopenwhenequipped= "true" movableframe= "true" >
<Containable items= "cassette" />
</ItemContainer>
<aitarget sightrange= "1000" soundrange= "1000" fadeouttime= "2" />
<Upgrade gameversion= "0.10.0.0" scale= "0.5" />
</Item>
<!-- Cassette Tapes -->
{% for tape in tapes %}
<Item name= "Tape: {{ tape.name }}" identifier= "cassette-{{ tape.identifier }}" category= "Equipment" maxstacksize= "8" Tags= "smallitem,cassette" cargocontaineridentifier= "metalcrate" scale= "0.5" isshootable= "true" impacttolerance= "1.3" >
<PreferredContainer primary= "abandonedcrewcab" spawnprobability= "0.05" />
<PreferredContainer primary= "outpostcrewcabinet" minamount= "0" maxamount= "1" spawnprobability= "0.05" />
<Price baseprice= "{{ tape.price }}" soldeverywhere= "false" > {% for location in ["outpost", "city", "research", "military", "mine"] %}
<Price locationtype= "{{ location }}" multiplier= "{{ tape.multipliers[loop.index0] }}" sold= "{{ tape.sold[loop.index0] }}" minavailable= "1" /> {% endfor %}
</Price>
2021-10-11 19:05:02 +02:00
<InventoryIcon texture= "Mods/{{ config['slug'] }}/icons.png" sourcerect= "0,{{ loop.index0*41 + 64 }},64,41" origin= "0.5,0.5" />
<Sprite texture= "Mods/{{ config['slug'] }}/icons.png" sourcerect= "0,{{ loop.index0*41 + 64 }},64,41" depth= "0.6" origin= "0.5,0.5" />
2021-09-24 12:00:38 +02:00
<Body width= "48" height= "48" />
<Throwable slots= "Any,RightHand,LeftHand" holdpos= "0,0" handle1= "0,0" throwforce= "4.0" aimpos= "35,-10" msg= "ItemMsgPickUpSelect" >
<StatusEffect type= "OnImpact" target= "This" Condition= "-5.0" disabledeltatime= "true" >
2021-10-11 19:05:02 +02:00
<sound file= "Mods/{{ config['slug'] }}/sound_effects/cassette_drop.ogg" range= "500" volume= "1.0" />
2021-09-24 12:00:38 +02:00
</StatusEffect>
</Throwable>
<CustomInterface canbeselected= "false" drawhudwhenequipped= "true" allowuioverlap= "true" >
2021-10-11 19:05:02 +02:00
<GuiFrame relativesize= "{{ 512.0 / config['resolution_x'] }},{{ 328.0 / config['resolution_y'] }}" anchor= "CenterRight" pivot= "CenterRight" style= "{{ config['slug'] }}_cover_{{ tape.identifier }}" />
2021-09-24 12:00:38 +02:00
</CustomInterface>
<ItemContainer hideitems= "true" capacity= "1" drawinventory= "false" canbeselected= "false" canbecombined= "true" removecontaineditemsondeconstruct= "true" >
<StatusEffect type= "OnNotContained" targettype= "Contained" >
<Use />
</StatusEffect>
<StatusEffect type= "OnContained" targettype= "This" >
<Conditional hastag= "!eq boombox" targetcontainer= "true" />
<Use />
</StatusEffect>
<StatusEffect type= "OnUse" targettype= "Contained" >
<Use />
</StatusEffect>
<Containable items= "song" />
</ItemContainer>
<Holdable slots= "Any,RightHand,LeftHand" msg= "ItemMsgPickUpSelect" >
<StatusEffect type= "OnBroken" target= "This" >
<Remove />
</StatusEffect>
</Holdable>
</Item>
{% endfor %}
<!-- SONGS -->
{% for tape, delta in zip(tapes, affliction_delta) %}
<Item name= "Song: {{ tape.name }}" identifier= "song-{{ tape.identifier }}" Tags= "song" category= "Misc" >
<Sprite texture= "Content/Items/Electricity/signalcomp.png" depth= "0.8" sourcerect= "0,160,4,4" origin= "0.5,0.5" />
<Body width= "48" height= "48" />
<InventoryIcon texture= "Content/Items/Electricity/signalcomp.png" sourcerect= "0,160,4,4" origin= "0.5,0.5" />
<ItemComponent >
<StatusEffect type= "Always" target= "This" >
2021-10-11 19:05:02 +02:00
<sound file= "Mods/{{ config['slug'] }}/music/{{ tape.identifier }}.ogg" type= "OnUse" range= "1000" loop= "true" volume= "1.0" />
2021-09-24 12:00:38 +02:00
</StatusEffect> {% if tape.buffs %}
<StatusEffect type= "Always" target= "NearbyCharacters" range= "1000" > {% for buff in tape.buffs %}
2021-10-11 00:57:36 +02:00
{% if buff == "psychosis" %}<Affliction identifier= "{{ buff }}" strength= "{{ '%0.4f' % (tape.buff_multiplier*(delta + 0.1)) }}" /> {% else %}<Affliction identifier= "{{ buff }}" strength= "{{ '%0.4f' % (tape.buff_multiplier*(delta*4 + 1)) }}" /> {% endif %}{% endfor %}
2021-09-24 12:00:38 +02:00
</StatusEffect> {% endif %}
<StatusEffect type= "OnNotContained" targettype= "This" >
<Remove />
</StatusEffect>
<StatusEffect type= "OnUse" targettype= "This" >
<Remove />
</StatusEffect>
</ItemComponent>
</Item>
{% endfor %}
</Items>