Prisoner Management Update:

* New Implant: Chem. Insert up to 10 units of chemicals into implant with a syringe (while still in implant case) and then can use a prisoner management console to trigger 1, 5, or 10 units of the chemical to be injected into the implanted subject. Once all the chemicals are used up, the implant disables itself.
* Prisoner Management Console can now detect the approximate location of prisoners with tracking implants in them. It gives slightly more useful information then the tracker but isn't portable.
* AI cannot access Prisoner Management Console (unless malf/XISC).
* Prisoner Management Console re-added to Armory (It no longer can trigger explosive implants). Play nice or else you'll get your toys taken away from you.

BORK BORK update:
* Re-did ChemMaster. Now it allows you transfer reagents in and out of a buffer. You can then turn the contents of the buffer into either a pill or a bottle. When removing reagents from the buffer, you can either delete them entirely or return them to the beaker. However, removing the beaker clears the contents of the buffer (so no mixing inside the ChemMaster!). CondiMaster Neo is almost identical to the ChemMaster except it only makes condiment bottles (no pills).
* Milk now being handled like the other reagents (as intended). Remember: 5 units of milk = 1 cup.
* Soymilk interchangable with regular milk in microwave recipes. (again, 5 units = 1 cup)
* Xenomeatbread! 3 xeno meat, 3 cheese, 3 flour. Extra Heretical!
* Monkey related food items renamed to generic meat (since I'm adding animals, I really don't want to add a new food items for every single new animal).
* Cola removed from fridge. Thematically appropriate but it just clutters it up (especially since there are vending machines all over the damn place).
* Faggots removed from meat locker. Instead, a small amount of meat spawns in there.
* Carp processes modified. Code is a littles cleaner (lawl) and the random pathing a a little cleaner as well.

Badmin Update:
* By request, Admins can now trigger radiation event.
* Confirmation warning on admin-triggered carp event.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@660 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
morikou@gmail.com
2010-12-18 18:18:14 +00:00
parent 3eda991cc0
commit cac1fdb477
17 changed files with 3418 additions and 3148 deletions
+31 -42
View File
@@ -13,59 +13,48 @@
/obj/secure_closet/meat/New()
..()
sleep(2)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/kitchen/egg_box(src)
new /obj/item/kitchen/egg_box(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
new /obj/item/weapon/kitchenknife(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/reagent_containers/food/snacks/flour(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/weapon/tray(src)
new /obj/item/kitchen/egg_box(src)
new /obj/item/kitchen/egg_box(src)
if(rand(20))
new /obj/item/weapon/reagent_containers/food/snacks/faggot(src)
new /obj/item/weapon/reagent_containers/food/snacks/faggot(src)
new /obj/item/weapon/reagent_containers/food/snacks/faggot(src)
new /obj/item/weapon/reagent_containers/food/snacks/faggot(src)
if(prob(80))
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
else
new /obj/item/weapon/reagent_containers/food/snacks/monkeyburger(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeyburger(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeyburger(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeyburger(src)
new /obj/item/weapon/reagent_containers/food/snacks/xenomeat(src)
new /obj/item/weapon/reagent_containers/food/snacks/xenomeat(src)
/obj/secure_closet/fridge/New()
..()
sleep(2)
new /obj/item/weapon/reagent_containers/food/drinks/cola(src)
new /obj/item/weapon/reagent_containers/food/drinks/cola(src)
new /obj/item/weapon/reagent_containers/food/drinks/cola(src)
new /obj/item/weapon/reagent_containers/food/drinks/cola(src)
new /obj/item/weapon/reagent_containers/food/drinks/cola(src)
new /obj/item/weapon/reagent_containers/food/drinks/cola(src)
new /obj/item/weapon/reagent_containers/food/drinks/milk(src)
new /obj/item/weapon/reagent_containers/food/drinks/milk(src)
new /obj/item/weapon/reagent_containers/food/drinks/milk(src)
new /obj/item/weapon/reagent_containers/food/drinks/milk(src)
new /obj/item/weapon/reagent_containers/food/drinks/milk(src)
new /obj/item/weapon/reagent_containers/food/drinks/milk(src)
new /obj/item/weapon/reagent_containers/food/drinks/soymilk(src)
new /obj/item/weapon/reagent_containers/food/drinks/soymilk(src)
new /obj/item/weapon/reagent_containers/food/drinks/soymilk(src)
new /obj/item/weapon/reagent_containers/food/drinks/soymilk(src)
new /obj/item/weapon/reagent_containers/food/drinks/soymilk(src)
+54 -18
View File
@@ -27,25 +27,31 @@ IMPLANTER
src.name = text("Glass Case- '[]'", t)
else
src.name = "Glass Case"
else
if (!( istype(I, /obj/item/weapon/implanter) ))
return
if (I:imp)
if ((src.imp || I:imp.implanted))
return
I:imp.loc = src
src.imp = I:imp
I:imp = null
src.update()
I:update()
else
if (src.imp)
if (I:imp)
else if(istype(I, /obj/item/weapon/reagent_containers/syringe))
if(src.imp.reagents.total_volume >= 10)
user << "\red [src] is full."
else
spawn(5)
I.reagents.trans_to(src.imp, 5)
user << "\blue You inject 5 units of the solution. The syringe now contains [I.reagents.total_volume] units."
else if (istype(I, /obj/item/weapon/implanter))
if (I:imp)
if ((src.imp || I:imp.implanted))
return
src.imp.loc = I
I:imp = src.imp
src.imp = null
update()
I:imp.loc = src
src.imp = I:imp
I:imp = null
src.update()
I:update()
else
if (src.imp)
if (I:imp)
return
src.imp.loc = I
I:imp = src.imp
src.imp = null
update()
I:update()
return
@@ -61,6 +67,18 @@ IMPLANTER
..()
return
/obj/item/weapon/implant/chem/New()
..()
var/datum/reagents/R = new/datum/reagents(10)
reagents = R
R.my_atom = src
/obj/item/weapon/implantcase/chem/New()
src.imp = new /obj/item/weapon/implant/chem( src )
..()
return
/obj/item/weapon/implantpad/proc/update()
if (src.case)
@@ -174,6 +192,24 @@ No Implant Specifics"}
<i>Direct-Interface</i>- You can use the prisoner management system to transmit short messages directly into the brain of the implanted subject.<BR>
<i>Safe-break</i>- Can be safely deactivated remotely.<BR>
<b>Integrity:</b> Implant will occasionally be degraded by the body's immune system and thus will occasionally malfunction."}
else if (istype(src.case.imp, /obj/item/weapon/implant/chem))
dat += {"
<b>Implant Specifications:</b><BR>
<b>Name:</b> Robust Corp MJ-420 Prisoner Management Implant<BR>
<b>Zone:</b> Abdominal Cavity>Abdominal Aorta<BR>
<b>Power Source:</b> Techno-organtic Metabolization System<BR>
<b>Life:</b> Deactivates upon death but remains within the body.<BR>
<b>Important Notes: Due to the system functioning off of nutrients in the implanted subject's body, the subject<BR>
will suffer from an increased appetite.</B><BR>
<HR>
<b>Implant Details:</b><BR>
<b>Function:</b> Contains a small capsule that can contain various chemicals. Upon receiving a specially encoded signal<BR>
the implant releases the chemicals directly into the blood stream.<BR>
<b>Special Features:</b><BR>
<i>Micro-Capsule</i>- Can be loaded with any sort of chemical agent via the common syringe and can hold 25 units.<BR>
Can only be loaded while still in it's original case.<BR>
<b>Integrity:</b> Implant will last so long as the subject is alive. However, if the subject suffers from malnutrition,<BR>
the implant may become unstable and either pre-maturely inject the subject or simply break."}
else
dat += "Implant ID not in database"
else
+74 -67
View File
@@ -1,72 +1,79 @@
/obj/kitchenspike/attack_paw(mob/user as mob)
return src.attack_hand(usr)
//////Kitchen Spike
/obj/kitchenspike/attackby(obj/item/weapon/grab/G as obj, mob/user as mob)
if(!istype(G, /obj/item/weapon/grab))
return
if(istype(G.affecting, /mob/living/carbon/monkey))
if(src.occupied == 0)
src.icon_state = "spikebloody"
src.occupied = 1
src.meat = 5
src.meattype = 1
var/mob/dead/observer/newmob
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [user] has forced [G.affecting] onto the spike, killing them instantly!"))
if (G.affecting.client)
newmob = new/mob/dead/observer(G.affecting)
G.affecting:client:mob = newmob
newmob:client:eye = newmob
del(G.affecting)
del(G)
/obj/kitchenspike
attack_paw(mob/user as mob)
return src.attack_hand(usr)
attackby(obj/item/weapon/grab/G as obj, mob/user as mob)
if(!istype(G, /obj/item/weapon/grab))
return
if(istype(G.affecting, /mob/living/carbon/monkey))
if(src.occupied == 0)
src.icon_state = "spikebloody"
src.occupied = 1
src.meat = 5
src.meattype = 1
var/mob/dead/observer/newmob
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [user] has forced [G.affecting] onto the spike, killing them instantly!"))
if (G.affecting.client)
newmob = new/mob/dead/observer(G.affecting)
G.affecting:client:mob = newmob
newmob:client:eye = newmob
del(G.affecting)
del(G)
else
user << "\red The spike already has something on it, finish collecting its meat first!"
else if(istype(G.affecting, /mob/living/carbon/alien) && !istype(G.affecting, /mob/living/carbon/alien/larva/metroid))
if(src.occupied == 0)
src.icon_state = "spikebloodygreen"
src.occupied = 1
src.meat = 5
src.meattype = 2
var/mob/dead/observer/newmob
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [user] has forced [G.affecting] onto the spike, killing them instantly!"))
if (G.affecting.client)
newmob = new/mob/dead/observer(G.affecting)
G.affecting:client:mob = newmob
newmob:client:eye = newmob
del(G.affecting)
del(G)
else
user << "\red The spike already has something on it, finish collecting its meat first!"
else
user << "\red The spike already has something on it, finish collecting its meat first!"
else if(istype(G.affecting, /mob/living/carbon/alien) && !istype(G.affecting, /mob/living/carbon/alien/larva/metroid))
if(src.occupied == 0)
src.icon_state = "spikebloodygreen"
src.occupied = 1
src.meat = 5
src.meattype = 2
var/mob/dead/observer/newmob
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [user] has forced [G.affecting] onto the spike, killing them instantly!"))
if (G.affecting.client)
newmob = new/mob/dead/observer(G.affecting)
G.affecting:client:mob = newmob
newmob:client:eye = newmob
del(G.affecting)
del(G)
else
user << "\red The spike already has something on it, finish collecting its meat first!"
else
user << "\red They are too big for the spike, try something smaller!"
return
user << "\red They are too big for the spike, try something smaller!"
return
// MouseDrop_T(var/atom/movable/C, mob/user)
// if(istype(C, /obj/mob/carbon/monkey)
// else if(istype(C, /obj/mob/carbon/alien) && !istype(C, /mob/living/carbon/alien/larva/metroid))
// else if(istype(C, /obj/livestock/spesscarp
/obj/kitchenspike/attack_hand(mob/user as mob)
if(..())
return
if(src.occupied)
if(src.meattype == 1)
if(src.meat > 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat( src.loc )
usr << "You remove some meat from the monkey."
else if(src.meat == 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src.loc)
usr << "You remove the last piece of meat from the monkey!"
src.icon_state = "spike"
src.occupied = 0
else if(src.meattype == 2)
if(src.meat > 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/xenomeat( src.loc )
usr << "You remove some meat from the alien."
else if(src.meat == 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/xenomeat(src.loc)
usr << "You remove the last piece of meat from the alien!"
src.icon_state = "spike"
src.occupied = 0
attack_hand(mob/user as mob)
if(..())
return
if(src.occupied)
if(src.meattype == 1)
if(src.meat > 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat( src.loc )
usr << "You remove some meat from the monkey."
else if(src.meat == 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src.loc)
usr << "You remove the last piece of meat from the monkey!"
src.icon_state = "spike"
src.occupied = 0
else if(src.meattype == 2)
if(src.meat > 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/xenomeat( src.loc )
usr << "You remove some meat from the alien."
else if(src.meat == 1)
src.meat--
new /obj/item/weapon/reagent_containers/food/snacks/xenomeat(src.loc)
usr << "You remove the last piece of meat from the alien!"
src.icon_state = "spike"
src.occupied = 0
+110 -18
View File
@@ -30,7 +30,6 @@
var/view_range = 7 //How far it can see.
var/obj/item/weapon/card/id/anicard //By default, animals can open doors but not any with access restrictions.
var/intelligence = null // the intelligence var allows for additional access (by job).
var/hardness = 0 // determines the prob of a stun
New() //Initializes the livestock's AI and access
..()
@@ -74,18 +73,27 @@
..()
bullet_act(flag, A as obj)
if (flag == PROJECTILE_BULLET)
src.health -= 20
else if (flag == PROJECTILE_WEAKBULLET)
src.health -= 4
else if (flag == PROJECTILE_LASER)
src.health -= 10
switch(flag)
if(PROJECTILE_BULLET)
src.health -= 15
if(PROJECTILE_TASER)
src.health -= 5
if(PROJECTILE_WEAKBULLET)
src.health -= 8
if(PROJECTILE_LASER)
src.health -= 10
if(PROJECTILE_PULSE)
src.health -= 25
if(prob(30))
src.ex_act(1)
if(PROJECTILE_BOLT)
src.health -= 5
healthcheck()
ex_act(severity)
switch(severity)
if(1.0)
src.death()
src.death(1)
if(2.0)
src.health -= 15
healthcheck()
@@ -141,6 +149,24 @@
trg_idle = null
frustration = 0
proc/special_extra() //Placeholder for animal specific effects such as cow milk or spess carp breathing.
proc/special_attack() //Placeholder for extra effects from the attack such as the carp's stun.
proc/special_target() //Placeholder for extra targeting protocol
proc/random_movement() //Unlike pick(cardinal), it has a bias towards continuing on in it's
var/temp_move = null // original direction.
switch(roll(1,20)) //50% => Foreward, 20% turn left, 20% turn right, 10% don't move.
if(1 to 10)
temp_move = src.dir
if(11 to 14)
temp_move = turn(src.dir, -90)
if(15 to 18)
temp_move = turn(src.dir, 90)
if(!isnull(temp_move))
step(src,temp_move)
proc/process() //Master AI proc.
set background = 1
if (!alive) //If it isn't alive, it shouldn't be doing anything.
@@ -178,8 +204,7 @@
for(var/mob/O in viewers(world.view,src))
O.show_message("\red <B>[src.target] has been attacked by [src.name]!</B>", 1, "\red You hear someone fall.", 2)
target:bruteloss += strength
if (prob(hardness))
target:stunned = max(target:stunned, (strength / 2))
special_attack()
src.loc = target.loc
set_null() //Break off the attack for a sec.
step_towards(src,get_step_towards2(src , target)) // Move towards the target.
@@ -213,13 +238,14 @@
if(state != 2 || !alive || target) return //If you arne't idling, aren't alive, or have a target, you shouldn't be here.
if(prob(5) && health < maxhealth) //5% chance of healing every cycle.
health++
special_extra()
if(isnull(trg_idle)) //No one to follow? Find one.
for(var/mob/living/O in viewers(world.view,src))
if(O.mutations == (0 || 16)) //Hates mutants and fatties.
trg_idle = O
break
if(isnull(trg_idle)) //Still no one to follow? Step in a random direction.
step(src,pick(cardinal))
random_movement()
else if(!path_idle.len) //Has a target but no path?
if(can_see(src,trg_idle,view_range)) //Can see it? Then move towards it.
step_towards(src,get_step_towards2(src , trg_idle))
@@ -227,7 +253,7 @@
path_idle(trg_idle) //Can't see it? Find a path.
if(!path_idle.len) //Still no path? Stop trying to follow it.
trg_idle = null
step(src,pick(cardinal))
random_movement()
else
if(can_see(src,trg_idle,view_range)) //Has a path and can see the target?
if(get_dist(src, trg_idle) >= 2) //If 2 or more squares away, re-find path and move towards it.
@@ -253,14 +279,17 @@
path_target = AStar(src.loc, trg.loc, /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 250, anicard, null)
path_target = reverselist(path_target)
proc/death()
proc/death(var/messy = 0)
if(!alive) return
src.alive = 0
density = 0
icon_state = "[initial(icon_state)]_d"
set_null()
for(var/mob/O in hearers(src, null))
O.show_message("\red <B>[src]'s eyes glass over!</B>", 1)
if(!messy)
for(var/mob/O in hearers(src, null))
O.show_message("\red <B>[src]'s eyes glass over!</B>", 1)
else
del(src)
proc/healthcheck()
if (src.health <= 0)
@@ -275,6 +304,18 @@
strength = 5
cycle_pause = 15
patience = 25
var/obj/item/weapon/reagent_containers/food/snacks/egg_holder
special_extra()
if(prob(5))
for(var/mob/O in hearers(src, null))
O << "\green Chick: Cluck."
src.egg_holder = new /obj/item/weapon/reagent_containers/food/snacks/egg(src)
src.egg_holder.loc = src.loc
src.egg_holder = null
for(var/mob/living/carbon/human/V in viewers(world.view,src))
if(V.mind.special_role == "wizard")
for(var/mob/H in hearers(src, null))
H << "\green Chick clucks in an angry manner at [V.name]."
/obj/livestock/spesscarp
name = "Spess Carp"
@@ -287,12 +328,63 @@
cycle_pause = 10
patience = 25
view_range = 8
hardness = 20
var/stun_chance = 20 // determines the prob of a stun
special_attack()
if (prob(stun_chance))
target:stunned = max(target:stunned, (strength / 2))
/obj/livestock/spesscarp/elite
desc = "Oh shit, you're really fucked now. It has an evil gleam in it's eye."
health = 50
maxhealth = 50
view_range = 14
hardness = 100
intelligence = "Assistant"
stun_chance = 100
intelligence = "Assistant"
/obj/livestock/cow
name = "Pigmy Cow"
desc = "That's not my cow!"
icon_state = "cow"
health = 100
maxhealth = 100
strength = 20
cycle_pause = 20
patience = 50
view_range = 10
special_extra()
if(prob(20))
for(var/mob/O in hearers(src, null))
O << "\green Cow: Moo."
src.reagents.add_reagent("milk", 1)
if(src.reagents.get_reagent_amount("milk") >= 100)
gib()
examine()
..()
switch(src.reagents.get_reagent_amount("milk"))
if(0 to 10)
usr << text("\red The cow looks content.")
if(11 to 80)
usr << text("\red The cow looks uncomfortable.")
if(81 to INFINITY)
usr << text("\red The cow looks as if it could burst at any minute!")
proc/gib() //Will move this to a generic livestock proc once I get some gib animations for the others -- Darem.
var/atom/movable/overlay/animation = null
src.icon = null
src.invisibility = 101
animation = new(src.loc)
animation.icon = 'livestock.dmi'
animation.icon_state = "blank"
animation.master = src
flick("cow_g", animation)
new /obj/decal/cleanable/blood(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
new /obj/item/weapon/reagent_containers/food/snacks/monkeymeat(src)
for (var/obj/I in src) //Not the best way to do this but it allows for pinata style animals as well.
I.loc = src.loc
sleep(11)
src.death(1)
del(animation)
return
+6 -6
View File
@@ -80,13 +80,13 @@
..()
return
/obj/item/weapon/storage/explosiveimp_kit/New()
/obj/item/weapon/storage/chemimp_kit/New()
new /obj/item/weapon/implantcase/explosive( src )
new /obj/item/weapon/implantcase/explosive( src )
new /obj/item/weapon/implantcase/explosive( src )
new /obj/item/weapon/implantcase/explosive( src )
new /obj/item/weapon/implantcase/explosive( src )
new /obj/item/weapon/implantcase/chem( src )
new /obj/item/weapon/implantcase/chem( src )
new /obj/item/weapon/implantcase/chem( src )
new /obj/item/weapon/implantcase/chem( src )
new /obj/item/weapon/implantcase/chem( src )
new /obj/item/weapon/implanter( src )
new /obj/item/weapon/implantpad( src )
..()