Merge pull request #58 from TheDZD/pAI-Drone-Port

pAI drone port [DO NOT MERGE] [Testing Required]
This commit is contained in:
Fox-McCloud
2015-01-09 18:12:08 -05:00
5 changed files with 53 additions and 24 deletions
@@ -225,9 +225,17 @@
/obj/item/device/paicard/Topic(href, href_list)
var/mob/U = usr
if(!usr || usr.stat)
return
if(pai)
if(!in_range(src, U) || pai.canmove || pai.resting)
U << browse(null, "window=paicard")
usr.unset_machine()
return
if(href_list["setdna"])
if(pai.master_dna)
return
@@ -250,6 +258,10 @@
M << "<font color = #ff4d4d><h3>Byte by byte you lose your sense of self.</h3></font>"
M << "<font color = #ff8787><h4>Your mental faculties leave you.</h4></font>"
M << "<font color = #ffc4c4><h5>oblivion... </h5></font>"
var/mob/living/silicon/pai/P = M
if(istype(P))
if(P.resting || P.canmove)
P.close_up()
M.death(0)
removePersonality()
if(href_list["wires"])
@@ -302,3 +314,8 @@
M.emp_act(severity)
..()
/obj/item/device/paicard/ex_act(severity)
if(pai)
pai.ex_act(severity)
else
del(src)
+1 -1
View File
@@ -177,7 +177,7 @@
set name = "pAI Suicide"
var/answer = input("REALLY kill yourself? This action can't be undone.", "Suicide", "No") in list ("Yes", "No")
if(answer == "Yes")
if(canmove && !resting)
if(canmove || resting)
close_up()
var/obj/item/device/paicard/card = loc
card.removePersonality()
+11 -7
View File
@@ -1,13 +1,15 @@
/mob/living/silicon/pai/death(gibbed)
if(stat == DEAD) return
var/turf/T = get_turf_or_move(loc)
for (var/mob/M in viewers(T))
M.show_message("\red A shower of sparks spray from [src]'s inner workings.", 3, "\red You hear and smell the ozone hiss of electrical sparks being expelled violently.", 2)
var/obj/effect/decal/cleanable/deadpai = new /obj/effect/decal/cleanable/robot_debris(loc)
if(canmove || resting)
deadpai.icon = 'icons/mob/pai.dmi'
deadpai.icon_state = "[chassis]_dead"
del(src)
var/turf/T = get_turf_or_move(loc)
for (var/mob/M in viewers(T))
M.show_message("\red [src] emits a dull beep before it loses power and collapses.", 3, "\red You hear a dull beep followed by the sound of glass crunching.", 2)
name = "pAI debris"
desc = "The unfortunate remains of some poor personal AI device."
icon_state = "[chassis]_dead"
else
card.overlays.Cut()
card.overlays += "pai-off"
stat = DEAD
canmove = 0
if(blind) blind.layer = 0
@@ -23,3 +25,5 @@
if(mind) del(mind)
living_mob_list -= src
ghostize()
if(icon_state != "[chassis]_dead")
del(src)
+24 -16
View File
@@ -24,6 +24,7 @@
"Cat" = "cat",
"Mouse" = "mouse",
"Monkey" = "monkey",
"Corgi" = "corgi",
"Fox" = "fox"
)
@@ -80,7 +81,6 @@
if(!card.radio)
card.radio = new /obj/item/device/radio(src.card)
radio = card.radio
//Verbs for pAI mobile form, chassis and Say flavor text
verbs += /mob/living/silicon/pai/proc/choose_chassis
verbs += /mob/living/silicon/pai/proc/choose_verbs
@@ -174,16 +174,16 @@
switch(severity)
if(1.0)
if (src.stat != 2)
adjustBruteLoss(100)
adjustFireLoss(100)
if (src.stat != 2) //Let's not have two of these instantly kill you.
adjustBruteLoss(45)
adjustFireLoss(45)
if(2.0)
if (src.stat != 2)
adjustBruteLoss(60)
adjustFireLoss(60)
adjustBruteLoss(30)
adjustFireLoss(30)
if(3.0)
if (src.stat != 2)
adjustBruteLoss(30)
adjustBruteLoss(20)
src.updatehealth()
@@ -200,8 +200,6 @@
src.updatehealth()
return
//mob/living/silicon/pai/bullet_act(var/obj/item/projectile/Proj)
/mob/living/silicon/pai/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
@@ -236,8 +234,6 @@
O.show_message(text("\red <B>[] took a swipe at []!</B>", M, src), 1)
return
///mob/living/silicon/pai/attack_hand(mob/living/carbon/M as mob)
/mob/living/silicon/pai/proc/switchCamera(var/obj/machinery/camera/C)
usr:cameraFollow = null
if (!C)
@@ -412,19 +408,22 @@
src.updatehealth()
else
visible_message("<span class='warning'>[user.name] bonks [src] harmlessly with [W].</span>")
if(stat != 2) close_up()
spawn(1)
if(stat != 2)
close_up()
return
/mob/living/silicon/pai/attack_hand(mob/user as mob)
if(stat == 2) return
visible_message("<span class='danger'>[user.name] boops [src] on the head.</span>")
close_up()
spawn(1)
close_up()
//I'm not sure how much of this is necessary, but I would rather avoid issues.
/mob/living/silicon/pai/proc/close_up()
last_special = world.time + 200
resting = 0
if(src.loc == card)
return
@@ -443,10 +442,18 @@
canmove = 0
icon_state = "[chassis]"
/mob/living/silicon/pai/start_pulling(var/atom/movable/AM)
/mob/living/silicon/pai/Bump(atom/movable/AM as mob|obj, yes)
return
/mob/living/silicon/pai/Bumped(AM as mob|obj)
return
/mob/living/silicon/pai/start_pulling(var/atom/movable/AM)
if(stat || sleeping || paralysis || weakened)
return
if(istype(AM,/obj/item))
src << "<span class='warning'>You are far too small to pull anything!</span>"
return
/mob/living/silicon/pai/examine()
@@ -479,6 +486,7 @@
..(Proj)
updatehealth()
if (stat != 2)
close_up()
spawn(1)
close_up()
return 2
BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 24 KiB