Yogstation 13 - Modules - TypesProc Details

Lavaland Artillery Mainframe

A machine used for Toxins scientists. Accepts tank transfer valves (TTVs), then shoots (and detonates) them at Lavaland Z-level GPS coordinates provided.

Five primary variables are used to operate the machine: lavaland - setup during Init(), defines Z-level of lavaland for GPS checks locked - Locks/Unlocks all interactions w/ LAM, except for loading a TTV into it. dest - Turf that is selected as a target for the TTV to be shot at. Does not change unless a new target is chosen. targetdest - Name of the GPS selected at the same time as var/dest. tcoords - X, Y, Z coordinates selected at the same time as var/dest. scibomb - Variable that stores the TTV.

Additional secondary variables: radio_freq - Restricts machine to only speak on Science radio channel. This allows Miners to hear the LAM announcements as well. countdown - Adjustable value used to determine the time until the TTV is deployed to Lavaland. stopcount - Variable affected by ui_act("launch"). Used during countdown() to maintain or break the loop. mincount - Value that restricts var/countdown from being less than it. tick - Value that uses var/countdown when starting the countdown() proc. target_delay - Variable used in reset_lam(), limits targetting/firing actions in short succession.

Procs

countdownStarts countdown sequence for firing the TTV
fire_ttvLaunches TTV from LAM to turf
reset_lamVisual proc, temporarily disables interacting

Proc Details

countdown

Starts countdown sequence for firing the TTV

Subtracts 1 from var/tick every second silently until reaching the last 5 seconds. Spawn(10) loops back to the beginning by triggering the proc again after 10 deciseconds.

fire_ttv

Launches TTV from LAM to turf

Triggered after being called in the last step of countdown(). Sends the loaded TTV to the Turf selected during ui_act("target"), triggers toggle_valve(), and last resets variables to initial state.

reset_lam

Visual proc, temporarily disables interacting

Triggered after the ui_act's "target" and "abort" to add a delay between selecting GPS coordinates and cancelling a TTV launch.