Files

1 line
13 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>/obj/structure/safe - Space Station 13</title></head><body><header><a href="index.html">Space Station 13</a> - <a href="index.html#modules">Modules</a> - <a href="index.html#types">Types</a><a href="obj/structure/safe.html#var">Var Details</a> - <a href="obj/structure/safe.html#proc">Proc Details</a></header><main><h1>Safe <aside>/<a href="obj.html">obj</a>/<a href="obj/structure.html">structure</a>/<a href="obj/structure/safe.html">safe</a></aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L20"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 20"></a></h1><p>A locked container that can only be opened by entering a combination through a dial.</p><table class="summary" cellspacing="0"><tr><td colspan="2"><h2>Vars</h2></td></tr><tr><th><a href="obj/structure/safe.html#var/current_tumbler_index">current_tumbler_index</a></th><td>The index in the tumblers list of the tumbler dial position that needs to be hit.</td></tr><tr><th><a href="obj/structure/safe.html#var/dial">dial</a></th><td>The position the dial is pointing to.</td></tr><tr><th><a href="obj/structure/safe.html#var/drill">drill</a></th><td>The currently placed thermal drill, if any.</td></tr><tr><th><a href="obj/structure/safe.html#var/drill_overlay">drill_overlay</a></th><td>The drill overlay image to display during the drilling process.</td></tr><tr><th><a href="obj/structure/safe.html#var/drill_start_time">drill_start_time</a></th><td>The world.time at which drilling started.</td></tr><tr><th><a href="obj/structure/safe.html#var/drill_timer">drill_timer</a></th><td>The <a href="global.html#proc/addtimer" title="/global">/proc/addtimer</a> handle for the current thermal drill.</td></tr><tr><th><a href="obj/structure/safe.html#var/drill_x_offset">drill_x_offset</a></th><td>The X pixel offset for the drilling progress bar.</td></tr><tr><th><a href="obj/structure/safe.html#var/drill_y_offset">drill_y_offset</a></th><td>The Y pixel offset for the drilling progress bar.</td></tr><tr><th><a href="obj/structure/safe.html#var/driller">driller</a></th><td>Who placed the drill on the safe. Used to trigger the status effect</td></tr><tr><th><a href="obj/structure/safe.html#var/known_by">known_by</a></th><td>Used by <a href="obj/item/paper.html" title="/obj/item/paper">/obj/item/paper/safe_code</a> to tell the codes through a paper spawned on map load.</td></tr><tr><th><a href="obj/structure/safe.html#var/locked">locked</a></th><td>Whether the safe is locked or not.</td></tr><tr><th><a href="obj/structure/safe.html#var/maxspace">maxspace</a></th><td>The maximum combined w_class of stuff in the safe.</td></tr><tr><th><a href="obj/structure/safe.html#var/number_of_tumblers">number_of_tumblers</a></th><td>The amount of tumblers that will be generated.</td></tr><tr><th><a href="obj/structure/safe.html#var/open">open</a></th><td>Whether the safe is open or not.</td></tr><tr><th><a href="obj/structure/safe.html#var/progress_bar">progress_bar</a></th><td>The progress bar image to display during the drilling process.</td></tr><tr><th><a href="obj/structure/safe.html#var/space">space</a></th><td>The combined w_class of everything in the safe.</td></tr><tr><th><a href="obj/structure/safe.html#var/time_to_drill">time_to_drill</a></th><td>Drill duration of the current thermal drill.</td></tr><tr><th><a href="obj/structure/safe.html#var/tumblers">tumblers</a></th><td>The list of tumbler dial positions that need to be hit.</td></tr><tr><td colspan="2"><h2>Procs</h2></td></tr><tr><th><a href="obj/structure/safe.html#proc/check_unlocked">check_unlocked</a></th><td>Called every dial turn to determine whether the safe should unlock or not.</td></tr><tr><th><a href="obj/structure/safe.html#proc/drill_open">drill_open</a></th><td>Called when the current thermal drill has finished drilling.</td></tr><tr><th><a href="obj/structure/safe.html#proc/get_combination">get_combination</a></th><td>Returns the combination to unlock the safe as text.</td></tr><tr><th><a href="obj/structure/safe.html#proc/notify_user">notify_user</a></th><td>Called every dial turn to provide feedback if possible.</td></tr></table><h2 id="var">Var Details</h2><h3 id="var/current_tumbler_index"><aside class="declaration">var </aside>current_tumbler_index <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L42"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 42"></a></h3><p>The index in the tumblers list of the tumbler dial position that needs to be hit.</p><h3 id="var/dial"><aside class="declaration">var </aside>dial <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L38"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 38"></a></h3><p>The position the dial is pointing to.</p><h3 id="var/drill"><aside class="declaration">var </aside>drill <aside> /<a href="obj.html">obj</a>/<a href="obj/item.html">item</a>/<a href="obj/item/thermal_drill.html">thermal_drill</a></aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L47"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 47"></a></h3><p>The currently placed thermal drill, if any.</p><h3 id="var/drill_overlay"><aside class="declaration">var </aside>drill_overlay <aside> /image</aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L55"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 55"></a></h3><p>The drill overlay image to display during the drilling process.</p><h3 id="var/drill_start_time"><aside class="declaration">var </aside>drill_start_time <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L53"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 53"></a></h3><p>The world.time at which drilling started.</p><h3 id="var/drill_timer"><aside class="declaration">var </aside>drill_timer <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L49"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 49"></a></h3><p>The <a href="global.html#proc/addtimer" title="/global">/proc/addtimer</a> handle for the current thermal drill.</p><h3 id="var/drill_x_offset"><aside class="declaration">var </aside>drill_x_offset <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L59"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 59"></a></h3><p>The X pixel offset for the drilling progress bar.</p><h3 id="var/drill_y_offset"><aside class="declaration">var </aside>drill_y_offset <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L61"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 61"></a></h3><p>The Y pixel offset for the drilling progress bar.</p><h3 id="var/driller"><aside class="declaration">var </aside>driller <aside> /<a href="mob.html">mob</a>/<a href="mob/living.html">living</a>/<a href="mob/living/carbon.html">carbon</a>/<a href="mob/living/carbon/human.html">human</a></aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L65"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 65"></a></h3><p>Who placed the drill on the safe. Used to trigger the status effect</p><h3 id="var/known_by"><aside class="declaration">var </aside>known_by <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L63"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 63"></a></h3><p>Used by <a href="obj/item/paper.html" title="/obj/item/paper">/obj/item/paper/safe_code</a> to tell the codes through a paper spawned on map load.</p><h3 id="var/locked"><aside class="declaration">var </aside>locked <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L36"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 36"></a></h3><p>Whether the safe is locked or not.</p><h3 id="var/maxspace"><aside class="declaration">var </aside>maxspace <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L29"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 29"></a></h3><p>The maximum combined w_class of stuff in the safe.</p><h3 id="var/number_of_tumblers"><aside class="declaration">var </aside>number_of_tumblers <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L31"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 31"></a></h3><p>The amount of tumblers that will be generated.</p><h3 id="var/open"><aside class="declaration">var </aside>open <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L34"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 34"></a></h3><p>Whether the safe is open or not.</p><h3 id="var/progress_bar"><aside class="declaration">var </aside>progress_bar <aside> /image</aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L57"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 57"></a></h3><p>The progress bar image to display during the drilling process.</p><h3 id="var/space"><aside class="declaration">var </aside>space <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L44"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 44"></a></h3><p>The combined w_class of everything in the safe.</p><h3 id="var/time_to_drill"><aside class="declaration">var </aside>time_to_drill <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L51"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 51"></a></h3><p>Drill duration of the current thermal drill.</p><h3 id="var/tumblers"><aside class="declaration">var </aside>tumblers <aside> /list</aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L40"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 40"></a></h3><p>The list of tumbler dial positions that need to be hit.</p><h2 id="proc">Proc Details</h2><h3 id="proc/check_unlocked"><aside class="declaration">proc </aside>check_unlocked<aside>() <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L389"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 389"></a></aside></h3><p>Called every dial turn to determine whether the safe should unlock or not.</p><h3 id="proc/drill_open"><aside class="declaration">proc </aside>drill_open<aside>() <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L418"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 418"></a></aside></h3><p>Called when the current thermal drill has finished drilling.</p><h3 id="proc/get_combination"><aside class="declaration">proc </aside>get_combination<aside>() <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L412"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 412"></a></aside></h3><p>Returns the combination to unlock the safe as text.</p><h3 id="proc/notify_user"><aside class="declaration">proc </aside>notify_user<aside>(user, canhear, sounds, total_ticks, current_tick, correct_sound) <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/game/objects/structures/safe.dm#L400"><img src="git.png" width="16" height="16" title="code/game/objects/structures/safe.dm 400"></a></aside></h3><p>Called every dial turn to provide feedback if possible.</p></main><footer>paradise.dme <a href="https://github.com/ParadiseSS13/Paradise/tree/8a8a00a2a9bec485351e5f219982b7315d3504fa">8a8a00a</a> (master) — <a href="https://github.com/SpaceManiac/SpacemanDMM/blob/master/crates/dmdoc/README.md">dmdoc 1.11.0</a></footer></body></html>