Implants, Explosions, and Carps, Oh my!

- New Implant: Explosive. Implant it into a prisoner and you can detonate it remotely from a Prisoner Management console (located on the prison station and in the Armory). Armor access required to activate the explosives. A box of the implants is located on the prison station and another in the Armory. WARNING: Implantation of a subject who hasn't been convicted of a felony is a felony under the Space Code of Justice. Detonation of an individual may be considered murder as if they were killed by any other method.
- Wardens office rearranged so that it's easier to get around and you don't accidentally open the door so much.
- Spess Carp! OH SHIT. You can beat them up assuming they don't eat you first. Can be found wandering in space. Be careful: They're fast and smart.
- New Random Event: "Unknown biological entities have been detected on the station, Please Stand By."
- Chicks! Can't do anything with them yet but they're cute!
- Poppy and Corn sprites added (growing, full grown, harvested, wilted, seeds, etc). Red, Green, and Yellow gelatin (because jell=o is copyrighted) sprites also added.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@601 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
morikou@gmail.com
2010-12-13 04:26:17 +00:00
parent f87dc8e97f
commit 490dc13666
16 changed files with 7516 additions and 7007 deletions

View File

@@ -135,6 +135,10 @@
icon_state = "implant"
item_state = "syringe_kit"
/obj/item/weapon/storage/explosiveimp_kit
name = "Explosive Implant Kit"
icon_state = "implant"
item_state = "syringe_kit"
/obj/item/weapon/storage/toolbox
name = "toolbox"

View File

@@ -642,6 +642,7 @@
/obj/item/weapon/implant
name = "implant"
var/implanted = null
var/mob/imp_in = null
var/color = "b"
/obj/item/weapon/implant/freedom
@@ -655,6 +656,9 @@
var/frequency = 1451
var/id = 1.0
/obj/item/weapon/implant/explosive
name = "explosive"
/obj/item/weapon/implantcase
name = "Glass Case"
icon_state = "implantcase-0"
@@ -669,6 +673,11 @@
icon = 'items.dmi'
icon_state = "implantcase-b"
/obj/item/weapon/implantcase/explosive
name = "Glass Case- 'Explosive'"
icon = 'items.dmi'
icon_state = "implantcase-r"
/obj/item/weapon/implanter
name = "implanter"
icon = 'items.dmi'

View File

@@ -8,7 +8,7 @@
start_events()
/proc/event()
switch(rand(1,8))
switch(rand(1,9))
if(1)
event = 1
command_alert("Meteors have been detected on collision course with the station.", "Meteor Alert")
@@ -95,6 +95,9 @@
if(8)
event = 1
prison_break()
if(9)
event = 1
carp_migration()
/proc/dotheblobbaby()
if (blobevent)
@@ -311,5 +314,13 @@
sleep(150)
command_alert("Prison station VI is not accepting commands. Recommend station AI involvement.", "VI Alert")
/proc/carp_migration() // -- Darem
for(var/obj/landmark/C in world)
if(C.name == "carpspawn")
if(prob(95))
new /obj/livestock/spesscarp(C.loc)
else
new /obj/livestock/spesscarp/elite(C.loc)
sleep(100)
command_alert("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert")
world << sound('commandreport.ogg')

View File

@@ -99,6 +99,9 @@
/obj/item/weapon/circuitboard/swfdoor
name = "Circuit board (Magix)"
computertype = "/obj/machinery/computer/pod/old/swf"
/obj/item/weapon/circuitboard/explosive
name = "Circuit board (ExImplant)"
computertype = "/obj/machinery/computer/explosive"

View File

@@ -0,0 +1,131 @@
/obj/machinery/computer/explosive
name = "Prisoner Management"
icon = 'computer.dmi'
icon_state = "explosive"
req_access = list(access_captain, access_armory)
var/id = 0.0
var/temp = null
var/status = 0
var/timeleft = 60
var/stop = 0.0
var/screen = 0 // 0 - No Access Denied, 1 - Access allowed
/obj/machinery/computer/explosive/attackby(I as obj, user as mob)
if(istype(I, /obj/item/weapon/screwdriver))
playsound(src.loc, 'Screwdriver.ogg', 50, 1)
if(do_after(user, 20))
if (src.stat & BROKEN)
user << "\blue The broken glass falls out."
var/obj/computerframe/A = new /obj/computerframe( src.loc )
new /obj/item/weapon/shard( src.loc )
var/obj/item/weapon/circuitboard/explosive/M = new /obj/item/weapon/circuitboard/explosive( A )
for (var/obj/C in src)
C.loc = src.loc
M.id = src.id
A.circuit = M
A.state = 3
A.icon_state = "3"
A.anchored = 1
del(src)
else
user << "\blue You disconnect the monitor."
var/obj/computerframe/A = new /obj/computerframe( src.loc )
var/obj/item/weapon/circuitboard/explosive/M = new /obj/item/weapon/circuitboard/explosive( A )
for (var/obj/C in src)
C.loc = src.loc
M.id = src.id
A.circuit = M
A.state = 4
A.icon_state = "4"
A.anchored = 1
del(src)
//else
src.attack_hand(user)
return
/obj/machinery/computer/explosive/attack_ai(var/mob/user as mob)
return src.attack_hand(user)
/obj/machinery/computer/explosive/attack_paw(var/mob/user as mob)
return src.attack_hand(user)
return
/obj/machinery/computer/explosive/attack_hand(var/mob/user as mob)
if(..())
return
user.machine = src
var/dat
dat += "<B>Prisoner Implant Manager System</B><BR>"
if(screen == 0)
dat += "<HR><A href='?src=\ref[src];lock=1'>Unlock Console</A>"
else if(screen == 1)
for(var/obj/item/weapon/implant/explosive/E in world)
if(!E.implanted) continue
dat += "[E.imp_in.name] | "
dat += "<A href='?src=\ref[src];killimplant=\ref[E]'>(<font color=red><i>Detonate</i></font>)</A> | "
dat += "<A href='?src=\ref[src];disable=\ref[E]'>(<font color=red><i>Deactivate</i></font>)</A> | "
dat += "<A href='?src=\ref[src];warn=\ref[E]'>(<font color=red><i>Warn</i></font>)</A> |<BR>"
dat += "<HR><A href='?src=\ref[src];lock=1'>Lock Console</A>"
user << browse(dat, "window=computer;size=400x500")
onclose(user, "computer")
return
/obj/machinery/computer/engine/process()
if(stat & (NOPOWER|BROKEN))
return
use_power(500)
src.updateDialog()
return
/obj/machinery/computer/explosive/Topic(href, href_list)
if(..())
return
if ((usr.contents.Find(src) || (in_range(src, usr) && istype(src.loc, /turf))) || (istype(usr, /mob/living/silicon)))
usr.machine = src
if (href_list["killimplant"])
var/obj/item/weapon/implant/I = locate(href_list["killimplant"])
var/mob/living/carbon/R = I.imp_in
if(R)
var/choice = input("Are you certain you wish to detonate [R.name]?") in list("Confirm", "Abort")
if(choice == "Confirm")
R << "You hear quiet beep from the base of your skull."
message_admins("\blue [key_name_admin(usr)] gibbed [R.name]")
if(prob(95))
R.gib()
else
R << "\blue you hear a click as the implant fails to detonate and disintegrates."
else if (href_list["disable"])
var/choice = input("Are you certain you wish to deactivate the implant?") in list("Confirm", "Abort")
if(choice == "Confirm")
var/obj/item/weapon/implant/I = locate(href_list["disable"])
var/mob/living/carbon/R = I.imp_in
R << "You hear quiet beep from the base of your skull."
if(prob(1))
message_admins("\blue [key_name_admin(usr)] attempted to disarm [R.name]' implant but it glitched. Oops.")
R.gib()
else
R << "\blue you hear a click as the implant disintegrates."
del(I)
else if (href_list["lock"])
if(src.allowed(usr))
screen = !screen
else
usr << "Unauthorized Access."
else if (href_list["warn"])
var/warning = input(usr,"Message:","Enter your message here!","")
var/obj/item/weapon/implant/I = locate(href_list["warn"])
var/mob/living/carbon/R = I.imp_in
R << "\green You hear a voice in your head saying: '[warning]'"
src.add_fingerprint(usr)
src.updateUsrDialog()
return

View File

@@ -10,6 +10,11 @@
if(src.check_access(bot.botcard))
if(density)
open()
else if(istype(AM, /obj/livestock))
var/obj/livestock/ani =AM
if(src.check_access(ani.anicard))
if(density)
open()
else if(istype(AM, /obj/alien/facehugger))
if(src.check_access(null))
if(density)
@@ -240,6 +245,11 @@
if(src.check_access(bot.botcard))
if(density)
open()
else if(istype(AM, /obj/livestock))
var/obj/livestock/ani =AM
if(src.check_access(ani.anicard))
if(density)
open()
else if(istype(AM, /obj/alien/facehugger))
if(src.check_access(null))
if(density)

View File

@@ -1,6 +1,5 @@
// BLATANTLY ripped from the facehugger.dm alien code. -- TLE
#define cycle_pause 5 //min 1
#define viewrange 7 //min 2
// Returns the surrounding cardinal turfs with open links
@@ -32,6 +31,7 @@
var/alive = 1 //1 alive, 0 dead
var/health = 25
var/maxhealth = 25
var/cycle_pause = 5
flags = 258.0

View File

@@ -216,6 +216,7 @@
continue
if(C:stunned || C:paralysis || C:weakened)
target = C
break
if(C:health < last_health)
last_health = C:health

View File

@@ -55,6 +55,12 @@ IMPLANTER
..()
return
/obj/item/weapon/implantcase/explosive/New()
src.imp = new /obj/item/weapon/implant/explosive( src )
..()
return
/obj/item/weapon/implantpad/proc/update()
if (src.case)
@@ -135,8 +141,7 @@ ID (1-100):
<A href='byond://?src=\ref[src];id=-1'>-</A> [T.id]
<A href='byond://?src=\ref[src];id=1'>+</A>
<A href='byond://?src=\ref[src];id=10'>+</A><BR>"}
else
if (istype(src.case.imp, /obj/item/weapon/implant/freedom))
else if (istype(src.case.imp, /obj/item/weapon/implant/freedom))
dat += {"
<b>Implant Specifications:</b><BR>
<b>Name:</b> Freedom Beacon<BR>
@@ -154,6 +159,21 @@ mechanisms<BR>
<b>Integrity:</b> The battery is extremely weak and commonly after injection its
life can drive down to only 1 use.<HR>
No Implant Specifics"}
else if (istype(src.case.imp, /obj/item/weapon/implant/explosive))
dat += {"
<b>Implant Specifications:</b><BR>
<b>Name:</b> Robust Corp RX-78 Prisoner Management Implant<BR>
<b>Zone:</b> Spinal Column>Atlantis Vertebrae<BR>
<b>Power Source:</b> Nervous System Ion Withdrawl Gradient<BR>
<b>Life:</b> Deactivates upon death but remains within the body.<BR>
<b>Important Notes:</b><BR>
<HR>
<b>Implant Details:</b><BR>
<b>Function:</b> Contains a compact, electrically detonated explosive that detonates upon receiving a specially encoded signal.<BR>
<b>Special Features:</b><BR>
<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
dat += "Implant ID not in database"
else
@@ -238,14 +258,14 @@ No Implant Specifics"}
return
/obj/item/weapon/implanter/attack(mob/M as mob, mob/user as mob)
if (!istype(M, /mob))
if (!istype(M, /mob/living/carbon))
return
if (user && src.imp)
for (var/mob/O in viewers(M, null))
O.show_message("\red [M] has been implanted by [user].", 1)
src.imp.loc = M
src.imp.imp_in = M
src.imp.implanted = 1
src.imp.implanted(M)
src.imp = null

View File

@@ -0,0 +1,294 @@
//Blatently copy/pasted from facehugger code + a few changes.
/obj/livestock
name = "animal thing"
desc = "This doesn't seem so bad..."
icon = 'livestock.dmi'
layer = 5.0
density = 1
anchored = 0
var/state = 0 //0 = null, 1 = attack, 2 = idle
var/list/path = new/list()
var/frustration = 0 //How long it's gone without reaching it's target.
var/patience = 35 //The maximum time it'll chase a target.
var/mob/living/carbon/target //It's combat target.
var/list/path_target = new/list() //The path to the combat target.
var/turf/trg_idle //It's idle target, the one it's following but not attacking.
var/list/path_idle = new/list() //The path to the idle target.
var/alive = 1 //1 alive, 0 dead
var/maxhealth = 25
var/health = 25
var/aggressive = 0
flags = 258.0
var/strength = 10 //The damage done by the creature if it attacks something.
var/cycle_pause = 5
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).
New() //Initializes the livestock's AI and access
..()
anicard = new(src)
if(!isnull(src.intelligence))
anicard.access = get_access(intelligence)
else
anicard.access = null
src.process()
examine()
set src in view()
..()
if(!alive)
usr << text("\red <B>The animal is not moving</B>")
else if (src.health == src.health)
usr << text("\red <B>The animal looks healthy.</B>")
else
usr << text("\red <B>The animal looks beat up</B>")
if (aggressive && alive)
usr << text("\red <B>Looks fierce!</B>")
return
attack_hand(user as mob)
return
attackby(obj/item/weapon/W as obj, mob/user as mob)
switch(W.damtype)
if("fire")
src.health -= W.force * 0.75
if("brute")
src.health -= W.force * 0.5
else
if (src.health <= 0)
src.death()
else if (W.force)
if(src.aggressive && (ishuman(user) || ismonkey(user)))
src.target = user
src.state = 1
..()
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
healthcheck()
ex_act(severity)
switch(severity)
if(1.0)
src.death()
if(2.0)
src.health -= 15
healthcheck()
return
meteorhit()
src.death()
return
blob_act()
if(prob(50))
src.death()
return
Bumped(AM as mob|obj)
if(ismob(AM) && src.aggressive && (ishuman(AM) || ismonkey(AM)) )
src.target = AM
set_attack()
else if(ismob(AM))
spawn(0)
var/turf/T = get_turf(src)
AM:loc = T
Bump(atom/A)
if(ismob(A) && src.aggressive && (ishuman(A) || ismonkey(A)))
src.target = A
set_attack()
else if(ismob(A))
src.loc = A:loc
..()
temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
if(exposed_temperature > 300)
health -= 5
healthcheck()
proc/set_attack()
state = 1
if(path_idle.len) path_idle = new/list()
trg_idle = null
proc/set_idle()
state = 2
if (path_target.len) path_target = new/list()
target = null
frustration = 0
proc/set_null()
state = 0
if (path_target.len) path_target = new/list()
if (path_idle.len) path_idle = new/list()
target = null
trg_idle = null
frustration = 0
proc/process() //Master AI proc.
set background = 1
if (!alive) //If it isn't alive, it shouldn't be doing anything.
return
if (!target)
if (path_target.len) path_target = new/list() //No target but there's still path data? reset it.
var/last_health = INFINITY //Set as high as possible as an initial value.
var/view = view_range-2 //Actual sight slightly lower then it's total sight.
for (var/mob/living/carbon/C in range(view,src.loc)) //Checks all carbon creatures in range.
if (!aggressive) //Is this animal angry? If not, what the fuck are you doing?
break
if (C.stat == 2 || !can_see(src,C,view_range)) //Can it see it at all or is the target a ghost?
continue
if(C:stunned || C:paralysis || C:weakened) //An easy target, bwahaha!
target = C
break
if(C:health < last_health) //Selects the target but does NOT break the FOR loop.
last_health = C:health // As such, it'll keep going until it finds the one with the
target = C // lowest health.
if(target) //Does it have a target NOW?
if (aggressive) //Double checking if it is aggressive or not.
set_attack()
else if(state != 2) //If it doesn't have a target and it isn't idling already, idle.
set_idle()
idle()
else if(target) //It already has a target? YAY!
var/turf/distance = get_dist(src, target)
if (src.aggressive) //I probably don't need this check, but just in case.
set_attack()
else
set_idle()
idle()
if(can_see(src,target,view_range )) //Can I see it?
if(distance <= 1) //Am I close enough to attack it?
for(var/mob/O in viewers(world.view,src))
O.show_message("\red <B>[src.target] has been leapt on by [src.name]!</B>", 1, "\red You hear someone fall", 2)
target:bruteloss += strength
target:stunned = max(target:stunned, (strength / 2))
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.
else
if( !path_target.len ) //Don't have a path yet but do have a target?
path_attack(target) //Find a path!
if(!path_target.len) //Still no path?
set_null() //Fuck this shit.
if( path_target.len ) //Ok, I DO have a path
var/turf/next = path_target[1] //Select the next square to move to.
if(next in range(1,src)) //Is it next to it?
path_attack(target) //Re-find path.
if(!path_target.len) //If can't path to the target, it gets really angry.
src.frustration += 5
else
next = path_target[1] //If it CAN path to the target, select the next move point
path_target -= next
step_towards(src,next) //And move in that direction.
if (get_dist(src, src.target) >= distance) src.frustration++ //If it hasn't reached the target yet, get a little angry.
else src.frustration-- //It reached the target! Get less angry.
if(frustration >= patience) set_null() //If too angry? Fuck this shit.
if(target)
spawn(3)
src.process()
else
spawn(cycle_pause)
src.process()
proc/idle() //Idle proc for when it isn't in combat mode. Called by itself and process()
set background = 1
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++
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))
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))
else
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))
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.
step_towards(src,get_step_towards2(src , trg_idle))
if(path_idle.len) path_idle = new/list()
else
var/turf/next = path_idle[1] //Has a target and a path but can't see it?
if(!next in range(1,src)) //If end of path and not next to target, find new path.
path_idle(trg_idle)
if(path_idle.len) //If still some path left, move along path.
next = path_idle[1]
path_idle -= next
step_towards(src,next)
spawn(cycle_pause)
idle()
proc/path_idle(var/atom/trg)
path_idle = AStar(src.loc, get_turf(trg), /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 250, anicard, null)
path_idle = reverselist(path_idle)
proc/path_attack(var/atom/trg)
path_target = AStar(src.loc, trg.loc, /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 250, anicard, null)
path_target = reverselist(path_target)
proc/death()
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] curls up into a ball!</B>", 1)
proc/healthcheck()
if (src.health <= 0)
src.death()
/obj/livestock/chick
name = "Chick"
desc = "A harmless little baby chicken, it's so cute!"
icon_state = "chick"
health = 10
maxhealth = 10
strength = 5
cycle_pause = 15
patience = 25
/obj/livestock/spesscarp
name = "Spess Carp"
desc = "Oh shit, you're really fucked now."
icon_state = "spesscarp"
aggressive = 1
health = 40
maxhealth = 40
strength = 15
cycle_pause = 10
patience = 50
view_range = 10
/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
intelligence = "Assistant"

View File

@@ -80,6 +80,18 @@
..()
return
/obj/item/weapon/storage/explosiveimp_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/implanter( src )
new /obj/item/weapon/implantpad( src )
..()
return
/obj/item/weapon/storage/injectbox/New()
new /obj/item/weapon/dnainjector/h2m( src )

View File

@@ -1164,6 +1164,9 @@ var/showadminmessages = 1
if(aliens_allowed)
alien_infestation()
message_admins("[key_name_admin(usr)] has spawned aliens", 1)
if("carp")
message_admins("[key_name_admin(usr)] has spawned carp", 1)
carp_migration()
if("prison_break")
message_admins("[key_name_admin(usr)] has allowed a prison break", 1)
prison_break()
@@ -1629,6 +1632,7 @@ var/showadminmessages = 1
<A href='?src=\ref[src];secretsfun=timeanomalies'>Spawn wormholes (Untested)</A><BR>
<A href='?src=\ref[src];secretsfun=goblob'>Spawn magma(Untested)</A><BR>
<A href='?src=\ref[src];secretsfun=aliens'>Trigger an Alien infestation</A><BR>
<A href='?src=\ref[src];secretsfun=carp'>Trigger an Carp migration</A><BR>
<A href='?src=\ref[src];secretsfun=prison_break'>Trigger a Prison Break</A><BR>
<A href='?src=\ref[src];secretsfun=virus'>Trigger a Virus Outbreak</A><BR>
<A href='?src=\ref[src];secretsfun=flicklights'>Ghost Mode</A><BR>

View File

@@ -375,6 +375,7 @@
#include "code\game\machinery\computer\communications.dm"
#include "code\game\machinery\computer\computer.dm"
#include "code\game\machinery\computer\crew.dm"
#include "code\game\machinery\computer\explosive.dm"
#include "code\game\machinery\computer\hologram.dm"
#include "code\game\machinery\computer\medical.dm"
#include "code\game\machinery\computer\Operating.dm"
@@ -439,6 +440,7 @@
#include "code\game\objects\items.dm"
#include "code\game\objects\kitchen.dm"
#include "code\game\objects\lamarr.dm"
#include "code\game\objects\livestock.dm"
#include "code\game\objects\noticeboard.dm"
#include "code\game\objects\object_procs.dm"
#include "code\game\objects\portals.dm"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 22 KiB

File diff suppressed because it is too large Load Diff