// Function from file: areas.dm public void burglaralert(Obj trigger = null) { ByTable cameras = null; dynamic RA = null; Obj_Machinery_Door_Airlock DOOR = null; Obj_Machinery_Camera C = null; Mob_Living_Silicon SILICON = null; if (this.always_unpowered) { return; } cameras = new ByTable(); foreach (dynamic _c in Lang13.Enumerate(this.related)) { RA = _c; ((Zone)RA).set_fire_alarm_effect(); foreach (dynamic _a in Lang13.Enumerate(RA, typeof(Obj_Machinery_Door_Airlock))) { DOOR = _a; Task13.Schedule(0, (Task13.Closure)(() => { DOOR.close(); if (DOOR.density) { DOOR.locked = true; DOOR.update_icon(); } return; })); } foreach (dynamic _b in Lang13.Enumerate(RA, typeof(Obj_Machinery_Camera))) { C = _b; cameras.Add(C); } } foreach (dynamic _d in Lang13.Enumerate(GlobalVars.player_list, typeof(Mob_Living_Silicon))) { SILICON = _d; if (SILICON.triggerAlarm("Burglar", this, cameras, trigger)) { Task13.Schedule(600, (Task13.Closure)(() => { SILICON.cancelAlarm("Burglar", this, trigger); return; })); } } return; }
// Function from file: camera.dm public void triggerCameraAlarm( ) { Mob_Living_Silicon S = null; this.alarm_on = true; foreach (dynamic _a in Lang13.Enumerate(GlobalVars.mob_list, typeof(Mob_Living_Silicon))) { S = _a; S.triggerAlarm("Camera", GlobalFuncs.get_area(this), new ByTable(new object [] { this }), this); } return; }
// Function from file: motion.dm public bool triggerAlarm( ) { Mob_Living_Silicon aiPlayer = null; if (!(this.detectTime != 0)) { return(false); } foreach (dynamic _a in Lang13.Enumerate(GlobalVars.player_list, typeof(Mob_Living_Silicon))) { aiPlayer = _a; if (this.status) { aiPlayer.triggerAlarm("Motion", GlobalFuncs.get_area(this), new ByTable(new object [] { this }), this); } } this.detectTime = -1; return(true); }
// Function from file: areas.dm public virtual void poweralert(bool state = false, Obj_Machinery_Power_Apc source = null) { ByTable cameras = null; Obj_Machinery_Camera C = null; Mob_Living_Silicon aiPlayer = null; Obj_Machinery_Computer_StationAlert a = null; Mob_Living_SimpleAnimal_Drone D = null; if (state != this.poweralm) { this.poweralm = state; if (source is Obj) { cameras = new ByTable(); foreach (dynamic _a in Lang13.Enumerate(this, typeof(Obj_Machinery_Camera))) { C = _a; cameras.Add(C); } foreach (dynamic _b in Lang13.Enumerate(GlobalVars.player_list, typeof(Mob_Living_Silicon))) { aiPlayer = _b; if (state) { aiPlayer.cancelAlarm("Power", this, source); } else { aiPlayer.triggerAlarm("Power", this, cameras, source); } } foreach (dynamic _c in Lang13.Enumerate(GlobalVars.machines, typeof(Obj_Machinery_Computer_StationAlert))) { a = _c; if (state) { a.cancelAlarm("Power", this, source); } else { a.triggerAlarm("Power", this, cameras, source); } } foreach (dynamic _d in Lang13.Enumerate(GlobalVars.mob_list, typeof(Mob_Living_SimpleAnimal_Drone))) { D = _d; if (state) { D.cancelAlarm("Power", this, source); } else { D.triggerAlarm("Power", this, cameras, source); } } } } return; }
// Function from file: areas.dm public bool atmosalert(int danger_level = 0, Obj source = null) { ByTable cameras = null; dynamic RA = null; Obj_Machinery_Camera C = null; Mob_Living_Silicon aiPlayer = null; Obj_Machinery_Computer_StationAlert a = null; Mob_Living_SimpleAnimal_Drone D = null; Mob_Living_Silicon aiPlayer2 = null; Obj_Machinery_Computer_StationAlert a2 = null; Mob_Living_SimpleAnimal_Drone D2 = null; if (danger_level != this.atmosalm) { if (danger_level == 2) { cameras = new ByTable(); foreach (dynamic _b in Lang13.Enumerate(this.related)) { RA = _b; foreach (dynamic _a in Lang13.Enumerate(RA, typeof(Obj_Machinery_Camera))) { C = _a; cameras.Add(C); } } foreach (dynamic _c in Lang13.Enumerate(GlobalVars.player_list, typeof(Mob_Living_Silicon))) { aiPlayer = _c; aiPlayer.triggerAlarm("Atmosphere", this, cameras, source); } foreach (dynamic _d in Lang13.Enumerate(GlobalVars.machines, typeof(Obj_Machinery_Computer_StationAlert))) { a = _d; a.triggerAlarm("Atmosphere", this, cameras, source); } foreach (dynamic _e in Lang13.Enumerate(GlobalVars.mob_list, typeof(Mob_Living_SimpleAnimal_Drone))) { D = _e; D.triggerAlarm("Atmosphere", this, cameras, source); } } else if (this.atmosalm == 2) { foreach (dynamic _f in Lang13.Enumerate(GlobalVars.player_list, typeof(Mob_Living_Silicon))) { aiPlayer2 = _f; aiPlayer2.cancelAlarm("Atmosphere", this, source); } foreach (dynamic _g in Lang13.Enumerate(GlobalVars.machines, typeof(Obj_Machinery_Computer_StationAlert))) { a2 = _g; a2.cancelAlarm("Atmosphere", this, source); } foreach (dynamic _h in Lang13.Enumerate(GlobalVars.mob_list, typeof(Mob_Living_SimpleAnimal_Drone))) { D2 = _h; D2.cancelAlarm("Atmosphere", this, source); } } this.atmosalm = danger_level; return(true); } return(false); }
// Function from file: areas.dm public void firealert(Obj_Machinery source = null) { ByTable cameras = null; dynamic RA = null; Obj_Machinery_Door_Firedoor D = null; Obj_Machinery_Firealarm F = null; Obj_Machinery_Camera C = null; Obj_Machinery_Computer_StationAlert a = null; Mob_Living_Silicon aiPlayer = null; Mob_Living_SimpleAnimal_Drone D2 = null; if (this.always_unpowered) { return; } cameras = new ByTable(); foreach (dynamic _d in Lang13.Enumerate(this.related)) { RA = _d; if (!RA.fire) { ((Zone)RA).set_fire_alarm_effect(); foreach (dynamic _a in Lang13.Enumerate(RA, typeof(Obj_Machinery_Door_Firedoor))) { D = _a; if (!D.blocked) { if (D.operating) { D.nextstate = GlobalVars.CLOSED; } else if (!D.density) { Task13.Schedule(0, (Task13.Closure)(() => { D.close(); return; })); } } } foreach (dynamic _b in Lang13.Enumerate(RA, typeof(Obj_Machinery_Firealarm))) { F = _b; F.update_icon(); } } foreach (dynamic _c in Lang13.Enumerate(RA, typeof(Obj_Machinery_Camera))) { C = _c; cameras.Add(C); } } foreach (dynamic _e in Lang13.Enumerate(GlobalVars.machines, typeof(Obj_Machinery_Computer_StationAlert))) { a = _e; a.triggerAlarm("Fire", this, cameras, source); } foreach (dynamic _f in Lang13.Enumerate(GlobalVars.player_list, typeof(Mob_Living_Silicon))) { aiPlayer = _f; aiPlayer.triggerAlarm("Fire", this, cameras, source); } foreach (dynamic _g in Lang13.Enumerate(GlobalVars.mob_list, typeof(Mob_Living_SimpleAnimal_Drone))) { D2 = _g; D2.triggerAlarm("Fire", this, cameras, source); } return; }