Jetpacks can now use any gas.

The /obj/item/weapon/tank/jetpack path is now an empty jetpack, and oxygen and carbon dioxide filled jetpacks are /obj/item/weapon/tank/jetpack/blue_jetpack and /obj/item/weapon/tank/jetpack/black_jetpack respectively.

Added a new kind of disposal, the deathsposal (it's not called that in game). It's the same as a normal disposal, except it has a red rim to indicate that it leads to space.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3150 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
petethegoat@gmail.com
2012-02-18 21:40:42 +00:00
parent bf458c6f36
commit afb645c764
5 changed files with 46 additions and 37 deletions
+37 -33
View File
@@ -1,8 +1,7 @@
/obj/item/weapon/tank/jetpack
name = "Jetpack (Oxygen)"
desc = "A tank of compressed oxygen for use as propulsion in zero-gravity areas. Use with caution."
icon_state = "jetpack0"
name = "Jetpack (Empty)"
desc = "A tank of compressed gas for use as propulsion in zero-gravity areas. Use with caution."
icon_state = "jetpack"
w_class = 4.0
item_state = "jetpack"
distribute_pressure = ONE_ATMOSPHERE*O2STANDARD
@@ -16,7 +15,6 @@
..()
src.ion_trail = new /datum/effect/effect/system/ion_trail_follow()
src.ion_trail.set_up(src)
src.air_contents.oxygen = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
@@ -40,42 +38,29 @@
verb/toggle()
set name = "Toggle Jetpack"
set category = "Object"
src.on = !( src.on )
if(src.type == /obj/item/weapon/tank/jetpack/void_jetpack) //Slight change added by me. i didn't make it an if-elseif because some of you might want to add other types of resprited packs :3 -Agouri
src.icon_state = text("voidjetpack[]", src.on)
else if(src.type == /obj/item/weapon/tank/jetpack/black_jetpack)
src.icon_state = text("black_jetpack[]", src.on)
on = !on
if(on)
icon_state = "[icon_state]-on"
ion_trail.start()
else
src.icon_state = text("jetpack[]", src.on)
if(src.on)
src.ion_trail.start()
else
src.ion_trail.stop()
icon_state = initial(icon_state)
ion_trail.stop()
return
proc/allow_thrust(num, mob/living/user as mob)
if (!( src.on ))
if(!(src.on))
return 0
if ((num < 0.005 || src.air_contents.total_moles() < num))
if((num < 0.005 || src.air_contents.total_moles() < num))
src.ion_trail.stop()
return 0
var/datum/gas_mixture/G = src.air_contents.remove(num)
if (G.oxygen >= 0.005)
var/allgases = G.carbon_dioxide + G.nitrogen + G.oxygen + G.toxins //fuck trace gases -Pete
if(allgases >= 0.005)
return 1
if (G.toxins > 0.001)
if (user)
var/d = G.toxins / 2
d = min(abs(user.health + 100), d, 25)
user.take_organ_damage(0,d)
return (G.oxygen >= 0.0025 ? 0.5 : 0)
else
if (G.oxygen >= 0.0025)
return 0.5
else
return 0
del(G)
return
@@ -83,12 +68,31 @@
/obj/item/weapon/tank/jetpack/void_jetpack
name = "Void Jetpack (Oxygen)"
desc = "It works well in a void."
icon_state = "voidjetpack0"
icon_state = "voidjetpack"
item_state = "jetpack-void"
/obj/item/weapon/tank/jetpack/blue_jetpack
name = "Jetpack (Oxygen)"
desc = "A tank of compressed oxygen for use as propulsion in zero-gravity areas. Use with caution."
icon_state = "jetpack"
item_state = "jetpack"
New()
..()
src.air_contents.oxygen = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return
/obj/item/weapon/tank/jetpack/black_jetpack
name = "Black Jetpack (Oxygen)"
desc = "A black model of jetpacks."
icon_state = "black_jetpack0"
name = "Jetpack (Carbon Dioxide)"
desc = "A tank of compressed carbon dioxide for use as propulsion in zero-gravity areas. Painted black to indicate that it should not be used as a source for internals."
icon_state = "black_jetpack"
item_state = "jetpack-black"
New()
..()
src.ion_trail = new /datum/effect/effect/system/ion_trail_follow()
src.ion_trail.set_up(src)
src.air_contents.oxygen = 0
src.air_contents.carbon_dioxide = (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
return