mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 15:17:01 +01:00
[MIRROR] Converts all A && A.B into A?.B (#1292)
* Converts A && A.B into A?.B (#54342) Implements the ?. operator, replacing code like A && A.B with A?.B BYOND Ref: When reading A?.B, it's equivalent to A && A.B except that A is only evaluated once, even if it's a complex expression like a proc call. * Converts all A && A.B into A?.B Co-authored-by: ZeWaka <zewakagamer@gmail.com>
This commit is contained in:
@@ -96,9 +96,9 @@
|
||||
|
||||
///Attempts to unlock the vault doors
|
||||
/obj/machinery/computer/vaultcontroller/proc/unlock_vault()
|
||||
if(door1 && door1.density)
|
||||
if(door1?.density)
|
||||
cycle_open(door1)
|
||||
if(door2 && door2.density)
|
||||
if(door2?.density)
|
||||
cycle_open(door2)
|
||||
if(!door1.density && door1.locked && !door2.density && door2.locked)
|
||||
locked = FALSE
|
||||
|
||||
Reference in New Issue
Block a user