Merge pull request #175 from alex-gh/fixes_and_cherrypicks

Fixes, cherrypicks and improvements
This commit is contained in:
ZomgPonies
2014-03-24 08:31:51 -04:00
13 changed files with 117 additions and 29 deletions
+7 -2
View File
@@ -414,7 +414,7 @@ datum/mind
if(!def_value)//If it's a custom objective, it will be an empty string.
def_value = "custom"
var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "blood", "debrain", "protect", "prevent", "harm", "brig", "hijack", "escape", "survive", "steal", "download", "nuclear", "capture", "absorb", "custom")
var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "blood", "debrain", "protect", "prevent", "harm", "speciesist", "brig", "hijack", "escape", "survive", "steal", "download", "nuclear", "capture", "absorb", "custom")
if (!new_obj_type) return
var/datum/objective/new_objective = null
@@ -452,6 +452,11 @@ datum/mind
//Will display as special role if the target is set as MODE. Ninjas/commandos/nuke ops.
new_objective.explanation_text = "[objective_type] [new_target:real_name], the [new_target:mind:assigned_role=="MODE" ? (new_target:mind:special_role) : (new_target:mind:assigned_role)]."
if ("speciesist")
new_objective = new /datum/objective/speciesist
new_objective.owner = src
new_objective.find_target()
if ("prevent")
new_objective = new /datum/objective/block
new_objective.owner = src
@@ -581,7 +586,7 @@ datum/mind
log_admin("[key_name_admin(usr)] has de-traitor'ed [current].")
else if (href_list["revolution"])
current.hud_updateflag |= (1 << SPECIALROLE_HUD)
current.hud_updateflag |= (1 << SPECIALROLE_HUD)
switch(href_list["revolution"])
if("clear")
+2 -2
View File
@@ -175,10 +175,10 @@ var/list/blob_nodes = list()
return
if (1)
command_alert("Confirmed outbreak of level 7 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert")
command_alert("NanoTrasen has issued a directive 7-10 for [station_name()]. The station is to be considered quarantined.", "Biohazard Alert")
for(var/mob/M in player_list)
if(!istype(M,/mob/new_player))
M << sound('sound/AI/outbreak7.ogg')
M << sound('sound/AI/blob_confirmed.ogg')
return
if (2)
+1 -1
View File
@@ -32,7 +32,7 @@
intercepttext += "Message ends."
for (var/mob/living/silicon/ai/aiPlayer in player_list)
if (aiPlayer.client)
var/law = "The station is under quarantine, prevent biological entities from leaving the station at all costs while minimizing collateral damage. The nuclear failsafe must be activated at any cost, the code is: [get_nuke_code()]."
var/law = "The station is under quarantine, prevent biological entities from leaving the station at all costs. The nuclear failsafe must be activated at any cost, the code is: [get_nuke_code()]."
aiPlayer.set_zeroth_law(law)
aiPlayer << "\red <b>You have detected a change in your laws information:</b>"
aiPlayer << "Laws Updated: [law]"
+1 -1
View File
@@ -4,7 +4,7 @@
icon_state = "blob_idle"
desc = "Some blob creature thingy"
health = 60
brute_resist = 1
brute_resist = 4
fire_resist = 2
+4 -2
View File
@@ -2,7 +2,7 @@
/obj/effect/blob
name = "blob"
icon = 'icons/mob/blob.dmi'
luminosity = 3
luminosity = 0
desc = "Some blob creature thingy"
density = 0
opacity = 0
@@ -47,6 +47,8 @@
update_icon()
proc/Life()
for(var/atom/A in src.loc)//Hit everything in the turf
A.blob_act()
return
@@ -57,7 +59,7 @@
if(run_action())//If we can do something here then we dont need to pulse more
return
if(pulse > 30)
if(pulse > 20)
return//Inf loop check
//Looking for another blob to pulse
+32 -2
View File
@@ -5,7 +5,8 @@ var/list/potential_theft_objectives=typesof(/datum/theft_objective) \
- /datum/theft_objective \
- /datum/theft_objective/special \
- /datum/theft_objective/number \
- /datum/theft_objective/number/special
- /datum/theft_objective/number/special \
- /datum/theft_objective/number/coins
datum/objective
var/datum/mind/owner = null //Who owns the objective.
@@ -266,7 +267,6 @@ datum/objective/protect//The opposite of killing a dude.
explanation_text = "Free Objective"
return target
find_target_by_role(role, role_type=0)
..(role, role_type)
if(target && target.current)
@@ -305,6 +305,36 @@ datum/objective/hijack
return 0
return 1
datum/objective/speciesist
var/datum/species/speciesist_target = null
find_target()
var/list/possible_targets = list()
var/mob/living/carbon/human/O = owner.current
for(var/datum/mind/possible_target in ticker.minds)
if(ishuman(possible_target.current))
var/mob/living/carbon/human/M = possible_target.current
if (M.species != O.species)
possible_targets += M.species
if(possible_targets.len > 0)
speciesist_target = pick(possible_targets)
explanation_text = "Do not allow any [speciesist_target.name]s to escape on the shuttle."
else
explanation_text = "Free Objective"
return speciesist_target
check_completion()
if(emergency_shuttle.location<2)
return 0
var/area/shuttle = locate(/area/shuttle/escape/centcom)
for(var/mob/living/carbon/human/player in player_list)
if (player.mind)
if (player.species == speciesist_target)
if(player.stat != DEAD) //they're not dead!
if(get_turf(player) in shuttle)
return 0
return 1
datum/objective/block
explanation_text = "Do not allow any organic lifeforms to escape on the shuttle alive."
+18 -10
View File
@@ -96,16 +96,23 @@
else
switch(rand(1,100))
if(1 to 33)
if(1 to 25)
var/datum/objective/assassinate/kill_objective = new
kill_objective.owner = traitor
kill_objective.find_target()
traitor.objectives += kill_objective
if(34 to 50)
var/datum/objective/brig/brig_objective = new
brig_objective.owner = traitor
brig_objective.find_target()
traitor.objectives += brig_objective
if(26 to 40)
var/datum/objective/debrain/debrain_objective = new
debrain_objective.owner = traitor
debrain_objective.find_target()
traitor.objectives += debrain_objective
if(41 to 50)
var/datum/objective/protect/protect_objective = new
protect_objective.owner = traitor
protect_objective.find_target_by_role("Traitor",0) //Protect your fellow traitor
if (!protect_objective.target)
protect_objective.find_target() //We could not find any traitors, protect somebody
traitor.objectives += protect_objective
if(51 to 66)
var/datum/objective/harm/harm_objective = new
harm_objective.owner = traitor
@@ -151,10 +158,11 @@
hijack_objective.owner = traitor
traitor.objectives += hijack_objective
else // Honk
if (!(locate(/datum/objective/minimize_casualties) in traitor.objectives))
var/datum/objective/minimize_casualties/escape_objective = new
escape_objective.owner = traitor
traitor.objectives += escape_objective
if (!(locate(/datum/objective/speciesist) in traitor.objectives))
var/datum/objective/speciesist/speciesist_objective = new
speciesist_objective.owner = traitor
speciesist_objective.find_target()
traitor.objectives += speciesist_objective
return
+2 -1
View File
@@ -966,6 +966,8 @@ About the new airlock wires panel:
var/obj/item/weapon/airlock_electronics/ae
if(!electronics)
ae = new/obj/item/weapon/airlock_electronics( src.loc )
if(!src.req_access)
src.check_access()
if(src.req_access.len)
ae.conf_access = src.req_access
else if (src.req_one_access.len)
@@ -1162,4 +1164,3 @@ About the new airlock wires panel:
return
else
return
+12 -1
View File
@@ -131,6 +131,8 @@
var/obj/item/weapon/airlock_electronics/ae
if(!electronics)
ae = new/obj/item/weapon/airlock_electronics( src.loc )
if(!src.req_access)
src.check_access()
if(src.req_access.len)
ae.conf_access = src.req_access
else if (src.req_one_access.len)
@@ -187,6 +189,14 @@
/obj/machinery/door/window/attack_hand(mob/user as mob)
return src.attackby(user, user)
/obj/machinery/door/window/attack_animal(mob/user as mob)
if(!isanimal(user)) return
var/mob/living/simple_animal/M = user
if(M.melee_damage_upper <= 0) return
playsound(src.loc, 'sound/effects/Glasshit.ogg', 75, 1)
visible_message("\red <B>[user] smashes against the [src.name].</B>", 1)
take_damage(M.melee_damage_upper)
/obj/machinery/door/window/attackby(obj/item/weapon/I as obj, mob/user as mob)
//If it's in the process of opening/closing, ignore the click
@@ -230,6 +240,8 @@
var/obj/item/weapon/airlock_electronics/ae
if(!electronics)
ae = new/obj/item/weapon/airlock_electronics( src.loc )
if(!src.req_access)
src.check_access()
if(src.req_access.len)
ae.conf_access = src.req_access
else if (src.req_one_access.len)
@@ -346,4 +358,3 @@
dir = SOUTH
icon_state = "rightsecure"
base_state = "rightsecure"
+3 -2
View File
@@ -102,7 +102,8 @@
/turf/simulated/wall/Destroy()
var/temploc = src.loc
//This proc performs really badly with qdel relativewall gets called a over ten thousand times. Commenting it out until I get to figure out what exactly goes wrong here. uc
/* var/temploc = src.loc
spawn(10)
for(var/turf/simulated/wall/W in range(temploc,1))
@@ -110,7 +111,7 @@
for(var/obj/structure/falsewall/W in range(temploc,1))
W.relativewall()
*/
for(var/direction in cardinal)
for(var/obj/effect/glowshroom/shroom in get_step(src,direction))
if(!shroom.floor) //shrooms drop to the floor
+4 -4
View File
@@ -44,9 +44,9 @@ var/global/list/possibleEvents = list()
//see:
// Code/WorkInProgress/Cael_Aislinn/Economy/Economy_Events.dm
// Code/WorkInProgress/Cael_Aislinn/Economy/Economy_Events_Mundane.dm
possibleEvents[/datum/event/economic_event] = 200
possibleEvents[/datum/event/trivial_news] = 300
possibleEvents[/datum/event/mundane_news] = 200
possibleEvents[/datum/event/economic_event] = 150
possibleEvents[/datum/event/trivial_news] = 200
possibleEvents[/datum/event/mundane_news] = 150
possibleEvents[/datum/event/mass_hallucination] = 200
possibleEvents[/datum/event/falsealarm] = 300
@@ -88,7 +88,7 @@ var/global/list/possibleEvents = list()
possibleEvents[/datum/event/anomaly/anomaly_bluespace] = 50 + 25 * active_with_role["Engineer"]
possibleEvents[/datum/event/anomaly/anomaly_flux] = 50 + 50 * active_with_role["Engineer"]
possibleEvents[/datum/event/viral_infection] = 25 + active_with_role["Medical"] * 100
possibleEvents[/datum/event/viral_infection] = 25 + active_with_role["Medical"] * 50
if(active_with_role["Medical"] > 0)
possibleEvents[/datum/event/radiation_storm] = active_with_role["Medical"] * 50
possibleEvents[/datum/event/spontaneous_appendicitis] = active_with_role["Medical"] * 150
@@ -274,6 +274,8 @@
for(var/atom/A in T)
if(!A.Adjacent(src))
continue
if(istype(A, /obj/structure/window) || istype(A, /obj/structure/closet) || istype(A, /obj/structure/table) || istype(A, /obj/structure/grille) || istype(A, /obj/structure/rack))
if(istype(A, /obj/structure/window) || istype(A, /obj/structure/closet) || \
istype(A, /obj/structure/table) || istype(A, /obj/structure/grille) || \
istype(A, /obj/structure/rack) || istype(A, /obj/machinery/door/window))
A.attack_animal(src)
return
@@ -2016,6 +2016,34 @@ datum
if( (prob(10) && method==TOUCH) || method==INGEST)
M.contract_disease(new /datum/disease/xeno_transformation(0),1)
spore
name = "Blob Spores"
id = "spore"
description = "Spores of some blob creature thingy."
reagent_state = LIQUID
color = "#CE760A" // rgb: 206, 118, 10
var/client/blob_client = null
var/blob_point_rate = 3
on_mob_life(var/mob/living/M)
if(!M) M = holder.my_atom
if (holder.has_reagent("plantbgone",45))
holder.del_reagent("spore")
if (prob(1))
M << "\red Your mouth tastes funny."
if (prob(1) && prob(25))
if(iscarbon(M))
var/mob/living/carbon/C = M
if(directory[ckey(C.key)])
blob_client = directory[ckey(C.key)]
C.gib()
if(blob_client)
var/obj/effect/blob/core/core = new(get_turf(C), 200, blob_client, blob_point_rate)
if(core.overmind && core.overmind.mind)
core.overmind.mind.name = C.name
return
//foam precursor
fluorosurfactant