- Made facehugger ignore mobs disease.

- Added disease longevity
- Added magboots. They prevent slipping. In space or on wet floors. Found in EVA.
- Small meteor fixes.
- Some comments and general faggotry.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@364 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
panurgomatic
2010-11-02 06:44:11 +00:00
parent 2ca03bb86a
commit 18e52e6a09
16 changed files with 131 additions and 69 deletions
+6 -4
View File
@@ -29,10 +29,12 @@ obj/machinery/atmospherics/filter
var/filter_type = 0
/*
Filter types:
0: Carbon Molecules: Plasma Toxin, Carbon Dioxide, Oxygen Agent B
1: Oxygen: Oxygen ONLY
2: Nitrogen: Nitrogen and Sleeping Agent
3: Carbon Dioxide: Carbon Dioxide ONLY
-1: Nothing
0: Carbon Molecules: Plasma Toxin, Oxygen Agent B
1: Oxygen: Oxygen ONLY
2: Nitrogen: Nitrogen ONLY
3: Carbon Dioxide: Carbon Dioxide ONLY
4: Sleeping Agent (N2O)
*/
var/frequency = 0
+1 -1
View File
@@ -385,7 +385,7 @@
dat += "<BR><A href='?src=\ref[src];eject=1'>Eject beaker</A>[((R.total_volume&&R.reagent_list.len) ? "-- <A href='?src=\ref[src];empty_beaker=1'>Empty beaker</A>":"")]<BR>"
dat += "<A href='?src=\ref[user];mach_close=pandemic'>Close</A>"
user << browse("<TITLE>PanD.E.M.I.C 2200</TITLE><BR>[dat]", "window=pandemic;size=575x400")
user << browse("<TITLE>[src.name]</TITLE><BR>[dat]", "window=pandemic;size=575x400")
onclose(user, "pandemic")
return
+19 -6
View File
@@ -24,8 +24,8 @@ to null does not delete the object itself. Thank you.
var/spread_type = AIRBORNE
var/contagious_period = 0//the disease stage when it can be spread
var/list/affected_species = list()
var/mob/affected_mob = null
var/holder = null
var/mob/affected_mob = null //the mob which is affected by disease.
var/holder = null //the atom containing the disease (mob or obj)
var/carrier = 0.0 //there will be a small chance that the person will be a carrier
var/curable = 1 //can this disease be cured? (By itself...)
var/list/strain_data = list() //This is passed on to infectees
@@ -34,6 +34,7 @@ to null does not delete the object itself. Thank you.
var/permeability_mod = 1//permeability modifier coefficient.
var/desc = null//description. Leave it null and this disease won't show in med records.
var/severity = null//severity descr
var/longevity = 250//time in "ticks" the virus stays in inanimate object (blood stains, corpses, etc). In syringes, bottles and beakers it stays infinitely.
/datum/disease/proc/stage_act()
var/cure_present = has_cure()
@@ -71,6 +72,8 @@ to null does not delete the object itself. Thank you.
/mob/proc/contract_disease(var/datum/disease/virus, var/skip_this = 0, var/force_species_check=1)
// world << "Contract_disease called by [src] with virus [virus]"
if(src.stat >=2) return
if(force_species_check)
var/fail = 1
@@ -98,6 +101,7 @@ to null does not delete the object itself. Thank you.
if(prob(99.9)) return
src.resistances.Remove(virus.type)//the resistance is futile
/*
var/list/clothing_areas = list()
var/list/covers = list(UPPER_TORSO,LOWER_TORSO,LEGS,FEET,ARMS,HANDS)
@@ -276,8 +280,17 @@ to null does not delete the object itself. Thank you.
if(!src.holder) return
if(prob(40))
src.spread(holder)
if(src.holder == src.affected_mob && affected_mob.stat < 2)
src.stage_act()
if(src.holder == src.affected_mob)
if(affected_mob.stat < 2) //he's alive
src.stage_act()
else //he's dead.
if(src.spread_type!=SPECIAL)
src.spread_type = CONTACT_GENERAL
src.affected_mob = null
if(!src.affected_mob) //the virus is in inanimate obj
// world << "[src] longevity = [src.longevity]"
if(--src.longevity<=0)
src.cure(0)
return
/datum/disease/proc/cure(var/resistance=1)//if resistance = 0, the mob won't develop resistance to disease
@@ -291,8 +304,8 @@ to null does not delete the object itself. Thank you.
return
/datum/disease/New(var/process=1)//adding the object to global list. List is processed by master controller.
if(process)
/datum/disease/New(var/process=1)//process = 1 - adding the object to global list. List is processed by master controller.
if(process) // Viruses in list are considered active.
active_diseases += src
/*
+4 -1
View File
@@ -440,12 +440,15 @@
name = "galoshes"
icon_state = "galoshes"
permeability_coefficient = 0.05
flags = NOSLIP
/obj/item/clothing/shoes/magboots
desc = "Magnetic boots, often used during extravehicular activity to ensure the user remains safely attached to the vehicle."
name = "magboots"
icon_state = "magboots"
icon_state = "magboots0"
protective_temperature = 800
heat_transfer_coefficient = 0.01
// flags = NOSLIP //disabled by default
/obj/item/clothing/shoes/clown_shoes
desc = "Damn, thems some big shoes."
+2
View File
@@ -265,12 +265,14 @@
D.strain_data["UI"] = H.dna.uni_identity
D.strain_data["SE"] = H.dna.struc_enzymes
D.carrier = 1
D.holder = H
D.affected_mob = H
H.virus = D
break
else
H.virus = new virus_type
H.virus.affected_mob = H
H.virus.holder = H
H.virus.carrier = 1
break
+38 -30
View File
@@ -24,41 +24,46 @@
/proc/spawn_meteor()
AGAIN
var/startside = pick(cardinal)
var/startx
var/starty
var/endx
var/endy
var/turf/pickedstart
var/turf/pickedgoal
var/max_i = 10//number of tries to spawn meteor.
switch(startside)
if(NORTH)
starty = world.maxy-1
startx = rand(1, world.maxx-1)
endy = 1
endx = rand(1, world.maxx-1)
if(EAST)
starty = rand(1,world.maxy-1)
startx = world.maxx-1
endy = rand(1, world.maxy-1)
endx = 1
if(SOUTH)
starty = 1
startx = rand(1, world.maxx-1)
endy = world.maxy-1
endx = rand(1, world.maxx-1)
if(WEST)
starty = rand(1, world.maxy-1)
startx = 1
endy = rand(1,world.maxy-1)
endx = world.maxx-1
var/turf/pickedstart = locate(startx, starty, 1)
var/turf/pickedgoal = locate(endx, endy, 1)
do
switch(startside)
if(NORTH)
starty = world.maxy-1
startx = rand(1, world.maxx-1)
endy = 1
endx = rand(1, world.maxx-1)
if(EAST)
starty = rand(1,world.maxy-1)
startx = world.maxx-1
endy = rand(1, world.maxy-1)
endx = 1
if(SOUTH)
starty = 1
startx = rand(1, world.maxx-1)
endy = world.maxy-1
endx = rand(1, world.maxx-1)
if(WEST)
starty = rand(1, world.maxy-1)
startx = 1
endy = rand(1,world.maxy-1)
endx = world.maxx-1
pickedstart = locate(startx, starty, 1)
pickedgoal = locate(endx, endy, 1)
max_i--
if(max_i<=0) return
while (!istype(pickedstart, /turf/space) || locate(/obj/shield in pickedstart) || pickedstart.loc.name != "Space" ) //FUUUCK, should never happen.
if (!istype(pickedstart, /turf/space) || locate(/obj/shield in pickedstart) || pickedstart.loc.name != "Space" ) //FUUUCK, should never happen.
goto AGAIN
var/obj/meteor/M
if(rand(50))
@@ -67,7 +72,10 @@
M = new /obj/meteor/small( pickedstart )
M.dest = pickedgoal
walk_towards(M, M.dest, 1)
spawn(0)
walk_towards(M, M.dest, 1)
return
/obj/meteor
name = "meteor"
@@ -91,7 +99,7 @@
/obj/meteor/Bump(atom/A)
spawn(0)
for(var/mob/M in view(A, null))
for(var/mob/M in range(10, src))
if(!M.stat && !istype(M, /mob/living/silicon/ai)) //bad idea to shake an ai's view
shake_camera(M, 3, 1)
if (A)
@@ -99,7 +107,7 @@
playsound(src.loc, 'meteorimpact.ogg', 40, 1)
if (--src.hits <= 0)
if(prob(15) && !istype(A, /obj/grille))
explosion(loc, 0, 1, 2, 3)
explosion(src.loc, 0, 1, 2, 3)
playsound(src.loc, "explosion", 50, 1)
del(src)
return
+2
View File
@@ -247,6 +247,8 @@
target.alien_egg_flag = 1
var/mob/trg = target
src.death()
if(trg.virus)
trg.virus.cure(0)
trg.contract_disease(new /datum/disease/alien_embryo(0))
return
else
+1 -1
View File
@@ -1477,7 +1477,7 @@ Code:
/obj/item/device/pda/clown/HasEntered(AM as mob|obj) //Clown PDA is slippery.
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if ((istype(M, /mob/living/carbon/human) && istype(M:shoes, /obj/item/clothing/shoes/galoshes)) || M.m_intent == "walk")
if ((istype(M, /mob/living/carbon/human) && (istype(M:shoes, /obj/item/clothing/shoes) && M:shoes.flags&NOSLIP)) || M.m_intent == "walk")
return
if ((istype(M, /mob/living/carbon/human) && (M.real_name != src.owner) && (istype(src.cartridge, /obj/item/weapon/cartridge/clown))))
+1 -1
View File
@@ -681,7 +681,7 @@ steam.start() -- spawns the effect
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if ((istype(M, /mob/living/carbon/human) && istype(M:shoes, /obj/item/clothing/shoes/galoshes)))
if (istype(M, /mob/living/carbon/human) && (istype(M:shoes, /obj/item/clothing/shoes) && M:shoes.flags&NOSLIP))
return
M.pulling = null
+19 -1
View File
@@ -306,4 +306,22 @@ DEATH COMMANDO GAS MASK
/obj/item/clothing/under/color/orange/mode = 3
/obj/item/clothing/under/color/orange/attack_self(mob/user as mob)
user << "There are no controls for the sensing equipment woven into the fabric."
user << "There are no controls for the sensing equipment woven into the fabric."
/obj/item/clothing/shoes/magboots/attack_self(mob/user as mob)
if(src.flags&NOSLIP)
src.flags &= ~NOSLIP
icon_state = "magboots0"
user << "You disable the mag-pulse traction system."
else
src.flags |= NOSLIP
icon_state = "magboots1"
user << "You enable the mag-pulse traction system."
/obj/item/clothing/shoes/magboots/examine()
..()
var/state = "disabled"
if(src.flags&NOSLIP)
state = "enabled"
usr << "Its mag-pulse traction system appears to be [state]."
@@ -21,7 +21,7 @@ BIKE HORN
/obj/item/weapon/bananapeel/HasEntered(AM as mob|obj)
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if ((istype(M, /mob/living/carbon/human) && istype(M:shoes, /obj/item/clothing/shoes/galoshes)))
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP))
return
M.pulling = null
+31 -19
View File
@@ -152,7 +152,7 @@
switch (src.wet)
if(1)
if (istype(M, /mob/living/carbon/human)) // Added check since monkeys don't have shoes
if ((M.m_intent == "run") && (!istype(M:shoes, /obj/item/clothing/shoes/galoshes)))
if ((M.m_intent == "run") && !(istype(M:shoes, /obj/item/clothing/shoes) && M:shoes.flags&NOSLIP))
M.pulling = null
step(M, M.dir)
M << "\blue You slipped on the wet floor!"
@@ -718,32 +718,44 @@ turf/simulated/floor/proc/update_icon()
// if (locate(/obj/movable, src))
// return 1
if ((istype(A, /mob/) && src.x > 2 && src.x < (world.maxx - 1)))
if ((istype(A, /mob/) && src.x > 2 && src.x < (world.maxx - 1) && src.y > 2 && src.y < (world.maxy-1)))
var/mob/M = A
if ((!( M.handcuffed) && M.canmove))
var/prob_slip = 5
var/mag_eq = 0
if(istype(M, /mob/living/carbon/human))
var/mob/living/carbon/human/H = M
if(istype(H.shoes, /obj/item/clothing/shoes/magboots) && H.shoes.flags&NOSLIP)
mag_eq = 1
if (locate(/obj/grille, oview(1, M)) || locate(/obj/lattice, oview(1, M)) )
if (!( M.l_hand ))
prob_slip -= 2
else if (M.l_hand.w_class <= 2)
prob_slip -= 1
if(mag_eq)
prob_slip = 0
else
if (!( M.l_hand ))
prob_slip -= 2
else if (M.l_hand.w_class <= 2)
prob_slip -= 1
if (!( M.r_hand ))
prob_slip -= 2
else if (M.r_hand.w_class <= 2)
prob_slip -= 1
if (!( M.r_hand ))
prob_slip -= 2
else if (M.r_hand.w_class <= 2)
prob_slip -= 1
else if (locate(/turf/unsimulated, oview(1, M)) || locate(/turf/simulated, oview(1, M)))
if (!( M.l_hand ))
prob_slip -= 1
else if (M.l_hand.w_class <= 2)
prob_slip -= 0.5
if(mag_eq)
prob_slip = 0
else
if (!( M.l_hand ))
prob_slip -= 1
else if (M.l_hand.w_class <= 2)
prob_slip -= 0.5
if (!( M.r_hand ))
prob_slip -= 1
else if (M.r_hand.w_class <= 2)
prob_slip -= 0.5
if (!( M.r_hand ))
prob_slip -= 1
else if (M.r_hand.w_class <= 2)
prob_slip -= 0.5
prob_slip = round(prob_slip)
if (prob_slip < 5) //next to something, but they might slip off
if (prob(prob_slip) )
M << "\blue <B>You slipped!</B>"
@@ -942,4 +954,4 @@ turf/simulated/floor/proc/update_icon()
A.y = 3
spawn (0)
if ((A && A.loc))
A.loc.Entered(A)
A.loc.Entered(A)
+2
View File
@@ -100,6 +100,8 @@
#define MASKCOVERSMOUTH 2048 // on other items, these are just for mask/head
#define HEADCOVERSMOUTH 2048
#define NOSLIP 1024 //prevents from slipping on wet floors, in space etc
#define OPENCONTAINER 4096 // is an open container for chemistry purposes
#define ONESIZEFITSALL 8192 // can be worn by fatties (or children? ugh)
Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

After

Width:  |  Height:  |  Size: 3.5 KiB

+4 -4
View File
@@ -512,7 +512,7 @@
"ajR" = (/obj/cable{icon_state = "2-8"; d1 = 2; d2 = 8},/turf/simulated/floor/plating,/area/maintenance/starboard)
"ajS" = (/obj/machinery/atmospherics/pipe/simple,/turf/simulated/floor/plating,/area/maintenance/starboard)
"ajT" = (/obj/machinery/light/small{dir = 4},/turf/simulated/floor/plating,/area/maintenance/starboard)
"ajU" = (/obj/item/weapon/screwdriver,/turf/simulated/floor/plating,/area/storage/tech)
"ajU" = (/obj/item/weapon/screwdriver,/obj/machinery/alarm{dir = 4; icon_state = "alarm0"; pixel_x = -22},/turf/simulated/floor/plating,/area/storage/tech)
"ajV" = (/turf/simulated/floor/plating,/area/storage/tech)
"ajW" = (/obj/item/clothing/glasses/meson,/obj/machinery/power/apc{dir = 4; name = "Tech. Storage APC"; pixel_x = 24; pixel_y = 0},/obj/cable{icon_state = "0-2"; d2 = 2},/turf/simulated/floor/plating,/area/storage/tech)
"ajX" = (/obj/machinery/light/small{dir = 8},/turf/simulated/floor/grid,/area/turret_protected/ai)
@@ -603,7 +603,7 @@
"alE" = (/obj/rack{dir = 4},/obj/item/weapon/tank/jetpack,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"alF" = (/obj/rack{dir = 8},/obj/item/clothing/suit/space,/obj/item/clothing/head/helmet/space,/obj/item/clothing/mask/medical,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"alG" = (/obj/rack{dir = 4},/obj/item/clothing/suit/space,/obj/item/clothing/head/helmet/space,/obj/item/clothing/mask/medical,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"alH" = (/obj/rack{dir = 8},/turf/simulated/floor,/area/ai_monitored/storage/eva)
"alH" = (/obj/rack{dir = 8},/obj/item/clothing/shoes/magboots,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"alI" = (/obj/machinery/light{tag = "icon-tube1 (EAST)"; icon_state = "tube1"; dir = 4},/turf/simulated/floor,/area/ai_monitored/storage/eva)
"alJ" = (/obj/machinery/atmospherics/pipe/simple{dir = 5; icon_state = "intact-f"; initialize_directions = 5; layer = 3},/turf/simulated/wall/r_wall,/area/ai_monitored/storage/eva)
"alK" = (/obj/machinery/atmospherics/pipe/simple{dir = 10; icon_state = "intact-f"; initialize_directions = 10; layer = 3},/turf/simulated/wall/r_wall,/area/ai_monitored/storage/eva)
@@ -670,7 +670,7 @@
"amT" = (/obj/closet/wardrobe/red,/obj/machinery/light{tag = "icon-tube1 (EAST)"; icon_state = "tube1"; dir = 4},/turf/simulated/floor,/area/security/main)
"amU" = (/obj/grille,/obj/window/reinforced/west,/obj/window/reinforced/east,/obj/window/reinforced/south,/turf/simulated/floor/plating,/area/security/main)
"amV" = (/obj/machinery/atmospherics/pipe/tank/air{dir = 1; initialize_directions = 0; level = 1},/turf/simulated/floor,/area/ai_monitored/storage/eva)
"amW" = (/obj/rack{dir = 4},/turf/simulated/floor,/area/ai_monitored/storage/eva)
"amW" = (/obj/rack{dir = 4},/obj/item/clothing/shoes/magboots,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"amX" = (/obj/rack{dir = 8},/obj/item/weapon/tank/jetpack,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"amY" = (/obj/machinery/alarm{pixel_y = 22},/obj/item/weapon/sheet/metal{amount = 50},/obj/item/weapon/crowbar,/turf/simulated/floor,/area/ai_monitored/storage/eva)
"amZ" = (/obj/table{icon_state = "tabledir"; dir = 9},/obj/item/weapon/sheet/metal{amount = 50},/turf/simulated/floor,/area/ai_monitored/storage/eva)
@@ -1775,7 +1775,7 @@
"aIg" = (/obj/disposalpipe/segment{dir = 8; icon_state = "pipe-c"},/turf/simulated/floor,/area/hallway/secondary/exit)
"aIh" = (/turf/simulated/floor,/area/hallway/secondary/exit)
"aIi" = (/obj/machinery/atmospherics/pipe/simple,/turf/simulated/floor,/area/hallway/secondary/exit)
"aIj" = (/obj/machinery/light{dir = 1},/turf/simulated/floor,/area/hallway/secondary/exit)
"aIj" = (/obj/machinery/light{dir = 1},/obj/machinery/alarm{pixel_y = 24},/turf/simulated/floor,/area/hallway/secondary/exit)
"aIk" = (/obj/cable{icon_state = "1-2"; d1 = 1; d2 = 2},/turf/simulated/floor,/area/hallway/secondary/exit)
"aIl" = (/obj/machinery/door/firedoor/border_only{dir = 8},/turf/simulated/floor,/area/hallway/secondary/exit)
"aIm" = (/obj/machinery/camera{c_tag = "Escape Shuttle Hallway Central"},/obj/machinery/power/apc{dir = 1; name = "Escape Hall APC"; pixel_y = 24},/obj/cable{icon_state = "0-2"; d2 = 2},/obj/cable,/turf/simulated/floor,/area/hallway/secondary/exit)