nuclearbomb
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 6](git.png)
Vars | |
auth | The nuke disk currently inserted into the nuke |
---|---|
core | The nuke core within the nuke, created in initialize |
countdown | A reference to the countdown that goes up over the nuke |
deconstruction_state | The current state of deconstructing / opening up the nuke to access the core |
detonation_timer | world time tracker for when we're going to explode |
exploded | Whether we've actually fully exploded |
exploding | Whether the timer has elapsed and we're currently exploding |
interior | Overlay - shows the interior of the nuke |
lights | Overlay - flashing lights over the nuke |
maximum_timer_set | What the max value the timer can be, in seconds |
minimum_timer_set | What the min value the timer can be, in seconds |
numeric_input | The current input of the numpad on the bomb |
previous_level | The alert level that was set before the nuke started, so we can revert to the correct level after |
proper_bomb | if TRUE, this nuke is actually a real nuke, and not a prank or toy |
r_code | The code we need to detonate this nuke. Starts as "admin", purposefully un-enterable |
safety | Whether the nuke safety is on, can't explode if it is |
timer_set | What the timer is set to, in seconds |
timing | Whether we're currently timing an explosive and counting down |
ui_mode | What mode the UI currently is in |
yes_code | If TRUE, the correct code has been entered and we can start the nuke |
Procs | |
arm_nuke | Arms the nuke, making it active and triggering all pinpointers to start counting down (+delta alert) |
disarm_nuke | Disarms the nuke, reverting all pinpointers and the security level |
disk_check | Checks if the disk inserted is a real nuke disk or not. |
explode | Begins the process of exploding the nuke. [proc/explode] -> [proc/actually_explode] -> [proc/really_actually_explode]) |
get_cinematic_type | Gets what type of cinematic this nuke showcases depending on where we detonated. |
get_nuke_state | Gets the current state of the nuke. |
get_time_left | If the nuke is active, gets how much time is left until it detonates, in seconds. If the nuke is not active, gets how much time the nuke is set for, in seconds. |
nuke_effects | Cause nuke effects to the passed z-levels. |
set_anchor | Anchors the nuke, duh. Can only be done if the disk is inside. |
toggle_nuke_armed | Arms the nuke, or disarms it if it's already active. |
toggle_nuke_safety | Toggles the safety of the nuke. |
update_ui_mode | Changes what mode the UI is depending on the state of the nuke. |
Var Details
auth
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 41](git.png)
The nuke disk currently inserted into the nuke
core
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 45](git.png)
The nuke core within the nuke, created in initialize
countdown
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 57](git.png)
A reference to the countdown that goes up over the nuke
deconstruction_state
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 47](git.png)
The current state of deconstructing / opening up the nuke to access the core
detonation_timer
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 33](git.png)
world time tracker for when we're going to explode
exploded
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 31](git.png)
Whether we've actually fully exploded
exploding
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 29](git.png)
Whether the timer has elapsed and we're currently exploding
interior
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 51](git.png)
Overlay - shows the interior of the nuke
lights
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 49](git.png)
Overlay - flashing lights over the nuke
maximum_timer_set
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 21](git.png)
What the max value the timer can be, in seconds
minimum_timer_set
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 19](git.png)
What the min value the timer can be, in seconds
numeric_input
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 23](git.png)
The current input of the numpad on the bomb
previous_level
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 43](git.png)
The alert level that was set before the nuke started, so we can revert to the correct level after
proper_bomb
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 53](git.png)
if TRUE, this nuke is actually a real nuke, and not a prank or toy
r_code
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 35](git.png)
The code we need to detonate this nuke. Starts as "admin", purposefully un-enterable
safety
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 39](git.png)
Whether the nuke safety is on, can't explode if it is
timer_set
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 17](git.png)
What the timer is set to, in seconds
timing
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 27](git.png)
Whether we're currently timing an explosive and counting down
ui_mode
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 25](git.png)
What mode the UI currently is in
yes_code
![code/modules/antagonists/nukeop/equipment/nuclear_bomb/_nuclear_bomb.dm 37](git.png)
If TRUE, the correct code has been entered and we can start the nuke
Proc Details
arm_nuke
Arms the nuke, making it active and triggering all pinpointers to start counting down (+delta alert)
disarm_nuke
Disarms the nuke, reverting all pinpointers and the security level
disk_check
Checks if the disk inserted is a real nuke disk or not.
explode
Begins the process of exploding the nuke. [proc/explode] -> [proc/actually_explode] -> [proc/really_actually_explode])
Goes through a few timers and plays a cinematic.
get_cinematic_type
Gets what type of cinematic this nuke showcases depending on where we detonated.
get_nuke_state
Gets the current state of the nuke.
get_time_left
If the nuke is active, gets how much time is left until it detonates, in seconds. If the nuke is not active, gets how much time the nuke is set for, in seconds.
nuke_effects
Cause nuke effects to the passed z-levels.
set_anchor
Anchors the nuke, duh. Can only be done if the disk is inside.
toggle_nuke_armed
Arms the nuke, or disarms it if it's already active.
toggle_nuke_safety
Toggles the safety of the nuke.
update_ui_mode
Changes what mode the UI is depending on the state of the nuke.