Files
2025-02-05 06:19:18 +00:00

25 lines
14 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><base href="../../"><link rel="stylesheet" href="dmdoc.css"><title>/datum/component/two_handed - /tg/ Station 13</title></head><body><header><a href="index.html">/tg/ Station 13</a> - <a href="index.html#modules">Modules</a> - <a href="index.html#types">Types</a><a href="datum/component/two_handed.html#var">Var Details</a> - <a href="datum/component/two_handed.html#proc">Proc Details</a></header><main><h1>two_handed <aside>/<a href="datum.html">datum</a>/<a href="datum/component.html">component</a>/<a href="datum/component/two_handed.html">two_handed</a></aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L7"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 7"></a></h1><p>Two Handed Component</p>
<p>When applied to an item it will make it two handed</p><table class="summary" cellspacing="0"><tr><td colspan="2"><h2>Vars</h2></td></tr><tr><th><a href="datum/component/two_handed.html#var/attacksound">attacksound</a></th><td>Play sound when unwielded</td></tr><tr><th><a href="datum/component/two_handed.html#var/force_multiplier">force_multiplier</a></th><td>Are we holding the two handed item properly</td></tr><tr><th><a href="datum/component/two_handed.html#var/force_unwielded">force_unwielded</a></th><td>The force of the item when weilded</td></tr><tr><th><a href="datum/component/two_handed.html#var/force_wielded">force_wielded</a></th><td>The multiplier applied to force when wielded, does not work with force_wielded, and force_unwielded</td></tr><tr><th><a href="datum/component/two_handed.html#var/icon_wielded">icon_wielded</a></th><td>Does it have to be held in both hands</td></tr><tr><th><a href="datum/component/two_handed.html#var/offhand_item">offhand_item</a></th><td>The icon that will be used when wielded</td></tr><tr><th><a href="datum/component/two_handed.html#var/require_twohands">require_twohands</a></th><td>Play sound on attack when wielded</td></tr><tr><th><a href="datum/component/two_handed.html#var/sharpened_increase">sharpened_increase</a></th><td>Reference to the offhand created for the item</td></tr><tr><th><a href="datum/component/two_handed.html#var/unwieldsound">unwieldsound</a></th><td>Play sound when wielded</td></tr><tr><th><a href="datum/component/two_handed.html#var/wieldsound">wieldsound</a></th><td>The force of the item when unweilded</td></tr><tr><td colspan="2"><h2>Procs</h2></td></tr><tr><th><a href="datum/component/two_handed.html#proc/Initialize">Initialize</a></th><td>The amount of increase recived from sharpening the item
Two Handed component</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_attack">on_attack</a></th><td>on_attack triggers on attack with the parent item</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_attack_self">on_attack_self</a></th><td>Triggered on attack self of the item containing the component</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_drop">on_drop</a></th><td>Triggered on drop of item containing the component</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_equip">on_equip</a></th><td>Triggered on equip of the item containing the component</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_moved">on_moved</a></th><td>on_moved Triggers on item moved</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_sharpen">on_sharpen</a></th><td>on_sharpen Triggers on usage of a sharpening stone on the item</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_swap_hands">on_swap_hands</a></th><td>on_swap_hands Triggers on swapping hands, blocks swap if the other hand is busy</td></tr><tr><th><a href="datum/component/two_handed.html#proc/on_update_icon">on_update_icon</a></th><td>on_update_icon triggers on call to update parent items icon</td></tr><tr><th><a href="datum/component/two_handed.html#proc/unwield">unwield</a></th><td>Unwield the two handed item</td></tr><tr><th><a href="datum/component/two_handed.html#proc/wield">wield</a></th><td>Wield the two handed item in both hands</td></tr></table><h2 id="var">Var Details</h2><h3 id="var/attacksound"><aside class="declaration">var </aside>attacksound <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L15"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 15"></a></h3><p>Play sound when unwielded</p><h3 id="var/force_multiplier"><aside class="declaration">var </aside>force_multiplier <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L10"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 10"></a></h3><p>Are we holding the two handed item properly</p><h3 id="var/force_unwielded"><aside class="declaration">var </aside>force_unwielded <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L12"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 12"></a></h3><p>The force of the item when weilded</p><h3 id="var/force_wielded"><aside class="declaration">var </aside>force_wielded <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L11"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 11"></a></h3><p>The multiplier applied to force when wielded, does not work with force_wielded, and force_unwielded</p><h3 id="var/icon_wielded"><aside class="declaration">var </aside>icon_wielded <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L17"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 17"></a></h3><p>Does it have to be held in both hands</p><h3 id="var/offhand_item"><aside class="declaration">var </aside>offhand_item <aside> /<a href="obj.html">obj</a>/<a href="obj/item.html">item</a>/offhand</aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L18"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 18"></a></h3><p>The icon that will be used when wielded</p><h3 id="var/require_twohands"><aside class="declaration">var </aside>require_twohands <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L16"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 16"></a></h3><p>Play sound on attack when wielded</p><h3 id="var/sharpened_increase"><aside class="declaration">var </aside>sharpened_increase <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L19"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 19"></a></h3><p>Reference to the offhand created for the item</p><h3 id="var/unwieldsound"><aside class="declaration">var </aside>unwieldsound <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L14"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 14"></a></h3><p>Play sound when wielded</p><h3 id="var/wieldsound"><aside class="declaration">var </aside>wieldsound <aside> </aside> <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L13"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 13"></a></h3><p>The force of the item when unweilded</p><h2 id="proc">Proc Details</h2><h3 id="proc/Initialize"><aside class="parent"><a title="/datum/component" href="datum/component.html#proc/Initialize"></a></aside>Initialize<aside>(require_twohands, wieldsound, unwieldsound, attacksound, force_multiplier, force_wielded, force_unwielded, icon_wielded) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L34"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 34"></a></aside></h3><p>The amount of increase recived from sharpening the item
Two Handed component</p>
<p>vars:</p>
<ul>
<li>require_twohands (optional) Does the item need both hands to be carried</li>
<li>wieldsound (optional) The sound to play when wielded</li>
<li>unwieldsound (optional) The sound to play when unwielded</li>
<li>attacksound (optional) The sound to play when wielded and attacking</li>
<li>force_multiplier (optional) The force multiplier when wielded, do not use with force_wielded, and force_unwielded</li>
<li>force_wielded (optional) The force setting when the item is wielded, do not use with force_multiplier</li>
<li>force_unwielded (optional) The force setting when the item is unwielded, do not use with force_multiplier</li>
<li>icon_wielded (optional) The icon to be used when wielded</li>
</ul><h3 id="proc/on_attack"><aside class="declaration">proc </aside>on_attack<aside>(/<a href="obj.html">obj</a>/<a href="obj/item.html">item</a>/source, /<a href="mob.html">mob</a>/<a href="mob/living.html">living</a>/target, /<a href="mob.html">mob</a>/<a href="mob/living.html">living</a>/user) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L240"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 240"></a></aside></h3><p>on_attack triggers on attack with the parent item</p><h3 id="proc/on_attack_self"><aside class="declaration">proc </aside>on_attack_self<aside>(/<a href="datum.html">datum</a>/source, /<a href="mob.html">mob</a>/user) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L107"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 107"></a></aside></h3><p>Triggered on attack self of the item containing the component</p><h3 id="proc/on_drop"><aside class="declaration">proc </aside>on_drop<aside>(/<a href="datum.html">datum</a>/source, /<a href="mob.html">mob</a>/user) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L98"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 98"></a></aside></h3><p>Triggered on drop of item containing the component</p><h3 id="proc/on_equip"><aside class="declaration">proc </aside>on_equip<aside>(/<a href="datum.html">datum</a>/source, /<a href="mob.html">mob</a>/user, slot) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L91"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 91"></a></aside></h3><p>Triggered on equip of the item containing the component</p><h3 id="proc/on_moved"><aside class="declaration">proc </aside>on_moved<aside>(/<a href="datum.html">datum</a>/source, /<a href="mob.html">mob</a>/user, dir) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L260"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 260"></a></aside></h3><p>on_moved Triggers on item moved</p><h3 id="proc/on_sharpen"><aside class="declaration">proc </aside>on_sharpen<aside>(/<a href="obj.html">obj</a>/<a href="obj/item.html">item</a>/item, amount, max_amount) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L275"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 275"></a></aside></h3><p>on_sharpen Triggers on usage of a sharpening stone on the item</p><h3 id="proc/on_swap_hands"><aside class="declaration">proc </aside>on_swap_hands<aside>(/<a href="mob.html">mob</a>/user, /<a href="obj.html">obj</a>/<a href="obj/item.html">item</a>/held_item) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L266"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 266"></a></aside></h3><p>on_swap_hands Triggers on swapping hands, blocks swap if the other hand is busy</p><h3 id="proc/on_update_icon"><aside class="declaration">proc </aside>on_update_icon<aside>(/<a href="datum.html">datum</a>/source) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L250"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 250"></a></aside></h3><p>on_update_icon triggers on call to update parent items icon</p>
<p>Updates the icon using icon_wielded if set</p><h3 id="proc/unwield"><aside class="declaration">proc </aside>unwield<aside>(/<a href="mob.html">mob</a>/<a href="mob/living.html">living</a>/<a href="mob/living/carbon.html">carbon</a>/user, show_message) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L181"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 181"></a></aside></h3><p>Unwield the two handed item</p>
<p>vars:</p>
<ul>
<li>user The mob/living/carbon that is unwielding the item</li>
<li>show_message (option) show a message to chat on unwield</li>
</ul><h3 id="proc/wield"><aside class="declaration">proc </aside>wield<aside>(/<a href="mob.html">mob</a>/<a href="mob/living.html">living</a>/<a href="mob/living/carbon.html">carbon</a>/user) <a href="https://github.com/evilew/GS13-Citadel/blob/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e/code/datums/components/twohanded.dm#L121"><img src="git.png" width="16" height="16" title="code/datums/components/twohanded.dm 121"></a></aside></h3><p>Wield the two handed item in both hands</p>
<p>vars:</p>
<ul>
<li>user The mob/living/carbon that is wielding the item</li>
</ul></main><footer>tgstation.dme <a href="https://github.com/evilew/GS13-Citadel/tree/e8e0068531dd988f9e65b33ae7866d4fbf1fdd9e">e8e0068</a> (master) — <a href="https://github.com/SpaceManiac/SpacemanDMM/blob/master/crates/dmdoc/README.md">dmdoc 1.9.0</a></footer></body></html>