mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
- Cell charger: Now calls battery emp_act() as well. - Security Barrier: Now has a chance to toggle the lock. - Flasher (portable and wall mounted machines, not the item): Now has a chance to flash. - Wall-Mounted Sparker: Creates sparks. - Light switch: Toggles the lights when emp'd (not that it'll matter since the lights will probably all have gone out anyway.) - Weapon Recharger: Calls the energy gun's battery's emp_act() for guns and in the case of stun batons, it sets their charges to 0. - Cyborg Recharge Station: Cyborgs now get ejected, then emp'd. There would probably be issues with emping the cyborg inside the machine, like being trapped forever or something. - Sleeper: Eject's the patient. I kind of wish I could make it inject random chems, but it wants a usr and I'm not inclined to start mucking with sleeper code just for this. - Space Heater: Calls the emp_act() for the battery inside the heater. - Status Display: Causes the blue screen of death. - Portable Atmos Pumps: Randomly changes the pressure, has a chance to flip the direction and turn the machine on/off. - Portable Atmos Scrubber: Has a chance to toggle the machine on/off. - Arcade Machine: Spits out some random prizes. - Medical record computer: Runs through the medical records and has a chance to scramble the name, age, sex, blood type, physical or mental state of patients as well as a small chance to delete entries entirely. - Security record computer: Runs through the security records and has a chance to scramble the name, age, sex, criminal status, physical or mental state of entries as well as a small chance to delete entries entirely. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5237 316c924e-a436-60f5-8080-3fe189b3f50e
42 lines
1.2 KiB
Plaintext
42 lines
1.2 KiB
Plaintext
//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:31
|
|
|
|
/obj/machinery/mass_driver
|
|
name = "mass driver"
|
|
desc = "Shoots things into space."
|
|
icon = 'icons/obj/stationobjs.dmi'
|
|
icon_state = "mass_driver"
|
|
anchored = 1.0
|
|
use_power = 1
|
|
idle_power_usage = 2
|
|
active_power_usage = 50
|
|
|
|
var/power = 1.0
|
|
var/code = 1.0
|
|
var/id = 1.0
|
|
var/drive_range = 50 //this is mostly irrelevant since current mass drivers throw into space, but you could make a lower-range mass driver for interstation transport or something I guess.
|
|
|
|
|
|
proc/drive(amount)
|
|
if(stat & (BROKEN|NOPOWER))
|
|
return
|
|
use_power(500)
|
|
var/O_limit
|
|
var/atom/target = get_edge_target_turf(src, dir)
|
|
for(var/atom/movable/O in loc)
|
|
if(!O.anchored||istype(O, /obj/mecha))//Mechs need their launch platforms.
|
|
O_limit++
|
|
if(O_limit >= 20)
|
|
for(var/mob/M in hearers(src, null))
|
|
M << "\blue The mass driver lets out a screech, it mustn't be able to handle any more items."
|
|
break
|
|
use_power(500)
|
|
spawn( 0 )
|
|
O.throw_at(target, drive_range * power, power)
|
|
flick("mass_driver1", src)
|
|
return
|
|
|
|
emp_act(severity)
|
|
if(stat & (BROKEN|NOPOWER))
|
|
return
|
|
drive()
|
|
..(severity) |