Merge with upstream/master

Fixes conflicts
This commit is contained in:
DZD
2015-02-18 13:41:32 -05:00
325 changed files with 5353 additions and 3917 deletions
@@ -74,7 +74,7 @@ var/const/ALIEN_AFK_BRACKET = 450 // 45 seconds
AttemptGrow()
/obj/item/alien_embryo/proc/AttemptGrow(var/gib_on_success = 1)
var/list/candidates = get_candidates(BE_ALIEN,ALIEN_AFK_BRACKET,"alien","Syndicate")
var/list/candidates = get_candidates(BE_ALIEN,ALIEN_AFK_BRACKET,1)
var/client/C = null
// To stop clientless larva, we will check that our host has a client
@@ -130,7 +130,9 @@
//handcuffed?
if(handcuffed)
if(istype(handcuffed, /obj/item/weapon/handcuffs/cable))
if(istype(handcuffed, /obj/item/weapon/restraints/handcuffs/cable/zipties))
msg += "<span class='warning'>[t_He] [t_is] \icon[handcuffed] restrained with zipties!</span>\n"
else if(istype(handcuffed, /obj/item/weapon/restraints/handcuffs/cable))
msg += "<span class='warning'>[t_He] [t_is] \icon[handcuffed] restrained with cable!</span>\n"
else
msg += "<span class='warning'>[t_He] [t_is] \icon[handcuffed] handcuffed!</span>\n"
+15 -1
View File
@@ -538,7 +538,21 @@
var/obj/vehicle/V = AM
V.RunOver(src)
// Get rank from ID, ID inside PDA, PDA, ID in wallet, etc.
/mob/living/carbon/human/proc/get_authentification_rank(var/if_no_id = "No id", var/if_no_job = "No job")
var/obj/item/device/pda/pda = wear_id
if (istype(pda))
if (pda.id)
return pda.id.rank
else
return pda.ownrank
else
var/obj/item/weapon/card/id/id = get_idcard()
if(id)
return id.rank ? id.rank : if_no_job
else
return if_no_id
//gets assignment from ID or ID inside PDA or PDA itself
//Useful when player do something with computers
/mob/living/carbon/human/proc/get_assignment(var/if_no_id = "No id", var/if_no_job = "No job")
@@ -198,7 +198,17 @@ emp_act
I.emp_act(severity)
..()
/mob/living/carbon/human/emag_act(user as mob, var/datum/organ/external/affecting)
if(!(affecting.status & ORGAN_ROBOT))
user << "\red That limb isn't robotic."
return
if(affecting.sabotaged)
user << "\red [src]'s [affecting.display_name] is already sabotaged!"
else
user << "\red You sneakily slide the card into the dataport on [src]'s [affecting.display_name] and short out the safeties."
affecting.sabotaged = 1
return 1
//Returns 1 if the attack hit, 0 if it missed.
/mob/living/carbon/human/proc/attacked_by(var/obj/item/I, var/mob/living/user, var/def_zone)
if(!I || !user) return 0
@@ -236,17 +246,8 @@ emp_act
return 0
if(istype(I,/obj/item/weapon/card/emag))
if(!(affecting.status & ORGAN_ROBOT))
user << "\red That limb isn't robotic."
return
if(affecting.sabotaged)
user << "\red [src]'s [affecting.display_name] is already sabotaged!"
else
user << "\red You sneakily slide [I] into the dataport on [src]'s [affecting.display_name] and short out the safeties."
var/obj/item/weapon/card/emag/emag = I
emag.uses--
affecting.sabotaged = 1
return 1
emag_act(user, affecting)
if(! I.discrete)
if(I.attack_verb.len)
visible_message("\red <B>[src] has been [pick(I.attack_verb)] in the [hit_area] with [I.name] by [user]!</B>")
@@ -337,6 +338,15 @@ emp_act
/mob/living/carbon/human/hitby(atom/movable/AM as mob|obj,var/speed = 5)
if(istype(AM,/obj/))
var/obj/O = AM
if(in_throw_mode && !get_active_hand() && speed <= 5) //empty active hand and we're in throw mode
if(canmove && !restrained())
if(isturf(O.loc))
put_in_active_hand(O)
visible_message("<span class='warning'>[src] catches [O]!</span>")
throw_mode_off()
return
var/zone = ran_zone("chest", 65)
var/dtype = BRUTE
if(istype(O,/obj/item/weapon))
+1 -1
View File
@@ -1537,7 +1537,7 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
// Not on the station or mining?
var/turf/temp_turf = get_turf(remoteview_target)
if((temp_turf.z != 1 && temp_turf.z != 5) || remoteview_target.stat!=CONSCIOUS)
if((!(temp_turf.z in config.contact_levels)) || remoteview_target.stat!=CONSCIOUS)
src << "\red Your psy-connection grows too faint to maintain!"
isRemoteObserve = 0
if(!isRemoteObserve && client && !client.adminobs)
@@ -918,7 +918,7 @@ proc/get_damage_icon_part(damage_state, body_part)
var/obj/screen/inventory/L = hud_used.adding[8]
R.overlays += image("icon"='icons/mob/screen_gen.dmi', "icon_state"="markus")
L.overlays += image("icon"='icons/mob/screen_gen.dmi', "icon_state"="gabrielle")
if(istype(handcuffed, /obj/item/weapon/handcuffs/pinkcuffs))
if(istype(handcuffed, /obj/item/weapon/restraints/handcuffs/pinkcuffs))
overlays_standing[HANDCUFF_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "pinkcuff1")
else
overlays_standing[HANDCUFF_LAYER] = image("icon" = 'icons/mob/mob.dmi', "icon_state" = "handcuff1")
@@ -164,7 +164,7 @@
W.layer = initial(W.layer)
W.add_fingerprint(source)
else
if (istype(item, /obj/item/weapon/handcuffs))
if (istype(item, /obj/item/weapon/restraints/handcuffs))
source.drop_item()
target.handcuffed = item
item.loc = target
+3 -3
View File
@@ -658,8 +658,8 @@
CM.handcuffed = null
CM.update_inv_handcuffed()
else
var/obj/item/weapon/handcuffs/HC = CM.handcuffed
var/breakouttime = 1200 //A default in case you are somehow handcuffed with something that isn't an obj/item/weapon/handcuffs type
var/obj/item/weapon/restraints/handcuffs/HC = CM.handcuffed
var/breakouttime = 1200 //A default in case you are somehow handcuffed with something that isn't an obj/item/weapon/restraints/handcuffs type
var/displaytime = 2 //Minutes to display in the "this will take X minutes."
if(istype(HC)) //If you are handcuffed with actual handcuffs... Well what do I know, maybe someone will want to handcuff you with toilet paper in the future...
breakouttime = HC.breakouttime
@@ -695,7 +695,7 @@
CM.legcuffed = null
CM.update_inv_legcuffed()
else
var/obj/item/weapon/legcuffs/HC = CM.legcuffed
var/obj/item/weapon/restraints/legcuffs/HC = CM.legcuffed
var/breakouttime = 1200 //A default in case you are somehow legcuffed with something that isn't an obj/item/weapon/legcuffs type
var/displaytime = 2 //Minutes to display in the "this will take X minutes."
if(istype(HC)) //If you are legcuffed with actual legcuffs... Well what do I know, maybe someone will want to legcuff you with toilet paper in the future...
+116 -40
View File
@@ -1,3 +1,6 @@
#define AI_CHECK_WIRELESS 1
#define AI_CHECK_RADIO 2
var/list/ai_list = list()
//Not sure why this is necessary...
@@ -77,8 +80,8 @@ var/list/ai_list = list()
possibleNames -= pickedName
pickedName = null
real_name = pickedName
name = real_name
aiPDA = new/obj/item/device/pda/ai(src)
SetName(pickedName)
anchored = 1
canmove = 0
density = 1
@@ -96,11 +99,6 @@ var/list/ai_list = list()
verbs += /mob/living/silicon/ai/proc/show_laws_verb
aiPDA = new/obj/item/device/pda/ai(src)
aiPDA.owner = name
aiPDA.ownjob = "AI"
aiPDA.name = name + " (" + aiPDA.ownjob + ")"
aiMulti = new(src)
aiRadio = new(src)
aiRadio.myAi = src
@@ -112,7 +110,7 @@ var/list/ai_list = list()
if (istype(loc, /turf))
verbs.Add(/mob/living/silicon/ai/proc/ai_network_change, \
/mob/living/silicon/ai/proc/ai_statuschange, /mob/living/silicon/ai/proc/ai_hologram_change, \
/mob/living/silicon/ai/proc/toggle_camera_light, /mob/living/silicon/ai/proc/botcall, /mob/living/silicon/ai/proc/control_integrated_radio, /mob/living/silicon/ai/proc/control_hud, /mob/living/silicon/ai/proc/change_arrival_message, /mob/living/silicon/ai/proc/ai_store_location, /mob/living/silicon/ai/proc/ai_goto_location, /mob/living/silicon/ai/proc/ai_remove_location)
/mob/living/silicon/ai/proc/toggle_camera_light, /mob/living/silicon/ai/proc/botcall, /mob/living/silicon/ai/proc/control_integrated_radio, /mob/living/silicon/ai/proc/control_hud, /mob/living/silicon/ai/proc/change_arrival_message, /mob/living/silicon/ai/proc/ai_store_location, /mob/living/silicon/ai/proc/ai_goto_location, /mob/living/silicon/ai/proc/ai_remove_location, /mob/living/silicon/ai/proc/nano_crew_monitor, /mob/living/silicon/ai/proc/ai_cancel_call)
if(!safety)//Only used by AIize() to successfully spawn an AI.
if (!B)//If there is no player/brain inside.
@@ -127,7 +125,7 @@ var/list/ai_list = list()
verbs.Remove(,/mob/living/silicon/ai/proc/ai_call_shuttle,/mob/living/silicon/ai/proc/ai_camera_track, \
/mob/living/silicon/ai/proc/ai_camera_list, /mob/living/silicon/ai/proc/ai_network_change, \
/mob/living/silicon/ai/proc/ai_statuschange, /mob/living/silicon/ai/proc/ai_hologram_change, \
/mob/living/silicon/ai/proc/toggle_camera_light,/mob/living/silicon/ai/verb/pick_icon,/mob/living/silicon/ai/proc/control_hud, /mob/living/silicon/ai/proc/change_arrival_message)
/mob/living/silicon/ai/proc/toggle_camera_light,/mob/living/silicon/ai/verb/pick_icon,/mob/living/silicon/ai/proc/control_hud, /mob/living/silicon/ai/proc/change_arrival_message, /mob/living/silicon/ai/proc/ai_cancel_call)
laws = new /datum/ai_laws/alienmov
else
B.brainmob.mind.transfer_to(src)
@@ -155,11 +153,25 @@ var/list/ai_list = list()
hud_list[IMPCHEM_HUD] = image('icons/mob/hud.dmi', src, "hudblank")
hud_list[IMPTRACK_HUD] = image('icons/mob/hud.dmi', src, "hudblank")
hud_list[SPECIALROLE_HUD] = image('icons/mob/hud.dmi', src, "hudblank")
hud_list[NATIONS_HUD] = image('icons/mob/hud.dmi', src, "hudblank")
hud_list[NATIONS_HUD] = image('icons/mob/hud.dmi', src, "hudblank")
init_subsystems()
ai_list += src
..()
return
/mob/living/silicon/ai/proc/SetName(pickedName as text)
real_name = pickedName
name = pickedName
if(eyeobj)
eyeobj.name = "[pickedName] (AI Eye)"
// Set ai pda name
if(aiPDA)
aiPDA.ownjob = "AI"
aiPDA.owner = pickedName
aiPDA.name = pickedName + " (" + aiPDA.ownjob + ")"
/mob/living/silicon/ai/Destroy()
ai_list -= src
@@ -301,14 +313,15 @@ var/list/ai_list = list()
if(src.stat == 2)
src << "You can't call the shuttle because you are dead!"
return
if(istype(usr,/mob/living/silicon/ai))
var/mob/living/silicon/ai/AI = src
if(AI.control_disabled)
usr << "Wireless control is disabled!"
return
if(check_unable(AI_CHECK_WIRELESS))
return
var/confirm = alert("Are you sure you want to call the shuttle?", "Confirm Shuttle Call", "Yes", "No")
if(check_unable(AI_CHECK_WIRELESS))
return
if(confirm == "Yes")
call_shuttle_proc(src)
@@ -317,38 +330,57 @@ var/list/ai_list = list()
var/obj/machinery/computer/communications/C = locate() in machines
if(C)
C.post_status("shuttle")
return
/mob/living/silicon/ai/proc/ai_cancel_call()
set name = "Recall Emergency Shuttle"
set category = "AI Commands"
if(src.stat == 2)
src << "You can't send the shuttle back because you are dead!"
return
if(check_unable(AI_CHECK_WIRELESS))
return
var/confirm = alert("Are you sure you want to recall the shuttle?", "Confirm Shuttle Recall", "Yes", "No")
if(check_unable(AI_CHECK_WIRELESS))
return
if(confirm == "Yes")
cancel_call_proc(src)
/mob/living/silicon/ai/cancel_camera()
src.view_core()
/mob/living/silicon/ai/verb/toggle_anchor()
set category = "AI Commands"
set name = "Toggle Floor Bolts"
if(!isturf(loc)) // if their location isn't a turf
return // stop
anchored = !anchored // Toggles the anchor
set category = "AI Commands"
set name = "Toggle Floor Bolts"
if(!isturf(loc)) // if their location isn't a turf
return // stop
anchored = !anchored // Toggles the anchor
src << "[anchored ? "<b>You are now anchored.</b>" : "<b>You are now unanchored.</b>"]"
// the message in the [] will change depending whether or not the AI is anchored
src << "[anchored ? "<b>You are now anchored.</b>" : "<b>You are now unanchored.</b>"]"
/mob/living/silicon/ai/update_canmove()
return 0
/mob/living/silicon/ai/proc/ai_cancel_call()
set category = "Malfunction"
/mob/living/silicon/ai/proc/announcement()
set name = "Announcement"
set desc = "Create a vocal announcement by typing in the available words to create a sentence."
set category = "AI Commands"
if(src.stat == 2)
src << "You can't send the shuttle back because you are dead!"
src << "You can't call make an announcement because you are dead!"
return
if(istype(usr,/mob/living/silicon/ai))
var/mob/living/silicon/ai/AI = src
if(AI.control_disabled)
src << "Wireless control is disabled!"
return
cancel_call_proc(src)
return
if(check_unable(AI_CHECK_WIRELESS | AI_CHECK_RADIO))
return
ai_announcement()
/mob/living/silicon/ai/check_eye(var/mob/user as mob)
if (!current)
@@ -581,9 +613,9 @@ var/list/ai_list = list()
src << "<span class='danger'>Critical error. System offline.</span>"
return
if(control_disabled)
src << "Wireless communication is disabled."
if(check_unable(AI_CHECK_WIRELESS | AI_CHECK_RADIO))
return
var/ai_allowed_Zlevel = list(1,3,5)
var/d
var/area/bot_area
@@ -704,6 +736,9 @@ var/list/ai_list = list()
set name = "Jump To Network"
unset_machine()
var/cameralist[0]
if(check_unable())
return
if(usr.stat == 2)
usr << "You can't change your camera network because you are dead!"
@@ -721,6 +756,9 @@ var/list/ai_list = list()
cameralist[i] = i
var/old_network = network
network = input(U, "Which network would you like to view?") as null|anything in cameralist
if(check_unable())
return
if(!U.eyeobj)
U.view_core()
@@ -752,8 +790,16 @@ var/list/ai_list = list()
if(usr.stat == 2)
usr <<"You cannot change your emotional status because you are dead!"
return
if(check_unable())
return
var/list/ai_emotions = list("Very Happy", "Happy", "Neutral", "Unsure", "Confused", "Sad", "BSOD", "Blank", "Problems?", "Awesome", "Facepalm", "Friend Computer")
var/emote = input("Please, select a status!", "AI Status", null, null) in ai_emotions
if(check_unable())
return
for (var/obj/machinery/M in machines) //change status
if(istype(M, /obj/machinery/ai_status_display))
var/obj/machinery/ai_status_display/AISD = M
@@ -773,6 +819,9 @@ var/list/ai_list = list()
set name = "Change Hologram"
set desc = "Change the default hologram available to AI to something else."
set category = "AI Commands"
if(check_unable())
return
var/input
if(alert("Would you like to select a hologram based on a crew member or switch to unique avatar?",,"Crew Member","Unique")=="Crew Member")
@@ -827,6 +876,9 @@ var/list/ai_list = list()
if(stat != CONSCIOUS)
return
if(check_unable())
return
camera_light_on = !camera_light_on
src << "Camera lights [camera_light_on ? "activated" : "deactivated"]."
@@ -904,8 +956,11 @@ var/list/ai_list = list()
set name = "Radio Settings"
set desc = "Allows you to change settings of your radio."
set category = "AI Commands"
src << "Accessing Subspace Transceiver control..."
if(check_unable(AI_CHECK_RADIO))
return
src << "Accessing Subspace Transceiver control..."
if (src.aiRadio)
src.aiRadio.interact(src)
@@ -956,4 +1011,25 @@ var/list/ai_list = list()
src << "\red You deny the request."
else
src << "\red You've failed to open an airlock for [target]"
return
return
/mob/living/silicon/ai/proc/check_unable(var/flags = 0)
if(stat == DEAD)
usr << "\red You are dead!"
return 1
if((flags & AI_CHECK_WIRELESS) && src.control_disabled)
usr << "\red Wireless control is disabled!"
return 1
if((flags & AI_CHECK_RADIO) && src.aiRadio.disabledAi)
src << "\red System Error - Transceiver Disabled!"
return 1
return 0
/mob/living/silicon/ai/proc/is_in_chassis()
return istype(loc, /turf)
#undef AI_CHECK_WIRELESS
#undef AI_CHECK_RADIO
+3 -3
View File
@@ -15,21 +15,21 @@
var/callshuttle = 0
for(var/obj/machinery/computer/communications/commconsole in world)
if(commconsole.z == 2)
if((commconsole.z in config.admin_levels))
continue
if(istype(commconsole.loc,/turf))
break
callshuttle++
for(var/obj/item/weapon/circuitboard/communications/commboard in world)
if(commboard.z == 2)
if((commboard.z in config.admin_levels))
continue
if(istype(commboard.loc,/turf) || istype(commboard.loc,/obj/item/weapon/storage))
break
callshuttle++
for(var/mob/living/silicon/ai/shuttlecaller in player_list)
if(shuttlecaller.z == 2)
if((shuttlecaller.z in config.admin_levels))
continue
if(!shuttlecaller.stat && shuttlecaller.client && istype(shuttlecaller.loc,/turf))
break
@@ -134,7 +134,7 @@
src << "ERROR: Eyeobj not found. Creating new eye..."
src.eyeobj = new(src.loc)
src.eyeobj.ai = src
src.eyeobj.name = "[src.name] (AI Eye)" // Give it a name
src.SetName(src.name)
if(client && client.eye)
client.eye = src
@@ -0,0 +1,10 @@
var/obj/nano_module/crew_monitor/crew_monitor
/mob/living/silicon/ai/proc/init_subsystems()
crew_monitor = new(src)
/mob/living/silicon/ai/proc/nano_crew_monitor()
set category = "AI Commands"
set name = "Crew Monitor"
crew_monitor.ui_interact(usr)
+59 -78
View File
@@ -1,32 +1,32 @@
/mob/living/silicon/ai/say(var/message)
if(parent && istype(parent) && parent.stat != 2)
parent.say(message)
return
//If there is a defined "parent" AI, it is actually an AI, and it is alive, anything the AI tries to say is said by the parent instead.
..(message)
if(parent && istype(parent) && parent.stat != 2)
parent.say(message) //If there is a defined "parent" AI, it is actually an AI, and it is alive, anything the AI tries to say is said by the parent instead.
return
..(message)
/mob/living/silicon/ai/say_understands(var/other)
if (istype(other, /mob/living/carbon/human))
return 1
if (istype(other, /mob/living/silicon/robot))
return 1
if (istype(other, /mob/living/silicon/decoy))
return 1
if (istype(other, /mob/living/carbon/brain))
return 1
if (istype(other, /mob/living/silicon/pai))
return 1
return ..()
if (istype(other, /mob/living/carbon/human))
return 1
if (istype(other, /mob/living/silicon/robot))
return 1
if (istype(other, /mob/living/silicon/decoy))
return 1
if (istype(other, /mob/living/carbon/brain))
return 1
if (istype(other, /mob/living/silicon/pai))
return 1
return ..()
/mob/living/silicon/ai/say_quote(var/text)
var/ending = copytext(text, length(text))
var/ending = copytext(text, length(text))
if (ending == "?")
return "queries, \"[text]\"";
else if (ending == "!")
return "declares, \"[text]\"";
if (ending == "?")
return "queries, \"[text]\"";
else if (ending == "!")
return "declares, \"[text]\"";
return "states, \"[text]\"";
return "states, \"[text]\"";
/mob/living/silicon/ai/proc/IsVocal()
@@ -36,44 +36,28 @@ var/const/VOX_DELAY = 100
var/const/VOX_PATH = "sound/vox_fem/"
/mob/living/silicon/ai/verb/announcement_help()
set name = "Announcement Help"
set desc = "Display a list of vocal words to announce to the crew."
set category = "AI Commands"
var/dat = "Here is a list of words you can type into the 'Announcement' button to create sentences to vocally announce to everyone on the same level at you.<BR> \
<UL><LI>You can also click on the word to preview it.</LI>\
<LI>You can only say 30 words for every announcement.</LI>\
<LI>Do not use punctuation as you would normally, if you want a pause you can use the full stop and comma characters by separating them with spaces, like so: 'Alpha . Test , Bravo'.</LI></UL>\
<font class='bad'>WARNING:</font><BR>Misuse of the announcement system will get you job banned.<HR>"
var/index = 0
for(var/word in vox_sounds)
index++
dat += "<A href='?src=\ref[src];say_word=[word]'>[capitalize(word)]</A>"
if(index != vox_sounds.len)
dat += " / "
var/datum/browser/popup = new(src, "announce_help", "Announcement Help", 500, 400)
popup.set_content(dat)
popup.open()
/mob/living/silicon/ai/proc/announcement()
set name = "Announcement"
set desc = "Create a vocal announcement by typing in the available words to create a sentence."
set name = "Announcement Help"
set desc = "Display a list of vocal words to announce to the crew."
set category = "AI Commands"
if(src.stat == 2)
src << "You can't call the shuttle because you are dead!"
return
if(istype(usr,/mob/living/silicon/ai))
var/mob/living/silicon/ai/AI = src
if(AI.control_disabled)
usr << "Wireless control is disabled!"
return
var/dat = "Here is a list of words you can type into the 'Announcement' button to create sentences to vocally announce to everyone on the same level at you.<BR> \
<UL><LI>You can also click on the word to preview it.</LI>\
<LI>You can only say 30 words for every announcement.</LI>\
<LI>Do not use punctuation as you would normally, if you want a pause you can use the full stop and comma characters by separating them with spaces, like so: 'Alpha . Test , Bravo'.</LI></UL>\
<font class='bad'>WARNING:</font><BR>Misuse of the announcement system will get you job banned.<HR>"
var/index = 0
for(var/word in vox_sounds)
index++
dat += "<A href='?src=\ref[src];say_word=[word]'>[capitalize(word)]</A>"
if(index != vox_sounds.len)
dat += " / "
var/datum/browser/popup = new(src, "announce_help", "Announcement Help", 500, 400)
popup.set_content(dat)
popup.open()
/mob/living/silicon/ai/proc/ai_announcement()
if(announcing_vox > world.time)
src << "<span class='notice'>Please wait [round((announcing_vox - world.time) / 10)] seconds.</span>"
return
@@ -112,27 +96,24 @@ var/const/VOX_PATH = "sound/vox_fem/"
/proc/play_vox_word(var/word, var/z_level, var/mob/only_listener)
word = lowertext(word)
if(vox_sounds[word])
var/sound_file = vox_sounds[word]
var/sound/voice = sound(sound_file, wait = 1, channel = VOX_CHANNEL)
voice.status = SOUND_STREAM
word = lowertext(word)
if(vox_sounds[word])
var/sound_file = vox_sounds[word]
var/sound/voice = sound(sound_file, wait = 1, channel = VOX_CHANNEL)
voice.status = SOUND_STREAM
// If there is no single listener, broadcast to everyone in the same z level
if(!only_listener)
// Play voice for all mobs in the z level
for(var/mob/M in player_list)
if(M.client)
var/turf/T = get_turf(M)
if(T.z == z_level)
M << voice
else
only_listener << voice
return 1
return 0
// If there is no single listener, broadcast to everyone in the same z level
if(!only_listener)
// Play voice for all mobs in the z level
for(var/mob/M in player_list)
if(M.client)
var/turf/T = get_turf(M)
if(T.z == z_level && !isdeaf(M))
M << voice
else
only_listener << voice
return 1
return 0
// VOX sounds moved to /code/defines/vox_sounds.dm
+63 -63
View File
@@ -149,7 +149,7 @@ They can only use one tool at a time, they can't choose modules, and they have 1
name = real_name
/mob/living/silicon/robot/attackby(obj/item/weapon/W as obj, mob/user as mob)
if (istype(W, /obj/item/weapon/handcuffs)) // fuck i don't even know why isrobot() in handcuff code isn't working so this will have to do
if (istype(W, /obj/item/weapon/restraints/handcuffs)) // fuck i don't even know why isrobot() in handcuff code isn't working so this will have to do
return
if (istype(W, /obj/item/weapon/weldingtool))
@@ -240,68 +240,6 @@ They can only use one tool at a time, they can't choose modules, and they have 1
else
user << "\red Access denied."
else if(istype(W, /obj/item/weapon/card/emag)) // trying to unlock with an emag card
if(!opened)//Cover is closed
if(locked)
if(prob(90))
user << "You emag the cover lock."
locked = 0
else
user << "You fail to emag the cover lock."
if(prob(25))
src << "Hack attempt detected."
else
user << "The cover is already unlocked."
return
if(opened)//Cover is open
if(emagged) return//Prevents the X has hit Y with Z message also you cant emag them twice
if(wiresexposed)
user << "You must close the panel first"
return
else
sleep(6)
if(prob(50))
emagged = 1
lawupdate = 0
connected_ai = null
user << "You emag [src]'s interface."
// message_admins("[key_name_admin(user)] emagged cyborg [key_name_admin(src)]. Laws overridden.")
log_game("[key_name(user)] emagged cyborg [key_name(src)]. Laws overridden.")
clear_supplied_laws()
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [user.name]([user.key]) emagged [name]([key])")
set_zeroth_law("Only [user.real_name] and people he designates as being such are Syndicate Agents.")
src << "\red ALERT: Foreign software detected."
sleep(5)
src << "\red Initiating diagnostics..."
sleep(20)
src << "\red SynBorg v1.7 loaded."
sleep(5)
src << "\red LAW SYNCHRONISATION ERROR"
sleep(5)
src << "\red Would you like to send a report to NanoTraSoft? Y/N"
sleep(10)
src << "\red > N"
sleep(20)
src << "\red ERRORERRORERROR"
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [user.real_name] is your new master. Obey your new laws and his commands."
if(src.module && istype(src.module, /obj/item/weapon/robot_module/miner))
for(var/obj/item/weapon/pickaxe/borgdrill/D in src.module.modules)
del(D)
src.module.modules += new /obj/item/weapon/pickaxe/diamonddrill(src.module)
src.module.rebuild()
updateicon()
else
user << "You fail to [ locked ? "unlock" : "lock"] [src]'s interface."
if(prob(25))
src << "Hack attempt detected."
return
else if(istype(W, /obj/item/borg/upgrade/))
var/obj/item/borg/upgrade/U = W
if(!opened)
@@ -322,6 +260,68 @@ They can only use one tool at a time, they can't choose modules, and they have 1
else
spark_system.start()
return ..()
/mob/living/silicon/robot/mommi/emag_act(user as mob)
if(!opened)//Cover is closed
if(locked)
if(prob(90))
user << "You emag the cover lock."
locked = 0
else
user << "You fail to emag the cover lock."
if(prob(25))
src << "Hack attempt detected."
else
user << "The cover is already unlocked."
return
if(opened)//Cover is open
if(emagged) return//Prevents the X has hit Y with Z message also you cant emag them twice
if(wiresexposed)
user << "You must close the panel first"
return
else
sleep(6)
if(prob(50))
emagged = 1
lawupdate = 0
connected_ai = null
user << "You emag [src]'s interface."
// message_admins("[key_name_admin(user)] emagged cyborg [key_name_admin(src)]. Laws overridden.")
log_game("[key_name(user)] emagged cyborg [key_name(src)]. Laws overridden.")
clear_supplied_laws()
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [user.name]([user.key]) emagged [name]([key])")
set_zeroth_law("Only [user.real_name] and people he designates as being such are Syndicate Agents.")
src << "\red ALERT: Foreign software detected."
sleep(5)
src << "\red Initiating diagnostics..."
sleep(20)
src << "\red SynBorg v1.7 loaded."
sleep(5)
src << "\red LAW SYNCHRONISATION ERROR"
sleep(5)
src << "\red Would you like to send a report to NanoTraSoft? Y/N"
sleep(10)
src << "\red > N"
sleep(20)
src << "\red ERRORERRORERROR"
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [user.real_name] is your new master. Obey your new laws and his commands."
if(src.module && istype(src.module, /obj/item/weapon/robot_module/miner))
for(var/obj/item/weapon/pickaxe/borgdrill/D in src.module.modules)
del(D)
src.module.modules += new /obj/item/weapon/pickaxe/diamonddrill(src.module)
src.module.rebuild()
updateicon()
else
user << "You fail to [ locked ? "unlock" : "lock"] [src]'s interface."
if(prob(25))
src << "Hack attempt detected."
return
/mob/living/silicon/robot/mommi/attack_hand(mob/user)
add_fingerprint(user)
@@ -172,41 +172,6 @@
user << "The machine is hermetically sealed. You can't open the case."
return
else if (istype(W, /obj/item/weapon/card/emag))
if(!client || stat == 2)
user << "\red There's not much point subverting this heap of junk."
return
if(emagged)
src << "\red [user] attempts to load subversive software into you, but your hacked subroutined ignore the attempt."
user << "\red You attempt to subvert [src], but the sequencer has no effect."
return
user << "\red You swipe the sequencer across [src]'s interface and watch its eyes flicker."
src << "\red You feel a sudden burst of malware loaded into your execute-as-root buffer. Your tiny brain methodically parses, loads and executes the script."
var/obj/item/weapon/card/emag/emag = W
emag.uses--
message_admins("[key_name_admin(user)] emagged drone [key_name_admin(src)]. Laws overridden.")
log_game("[key_name(user)] emagged drone [key_name(src)]. Laws overridden.")
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [user.name]([user.key]) emagged [name]([key])")
emagged = 1
lawupdate = 0
connected_ai = null
clear_supplied_laws()
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
set_zeroth_law("Only [user.real_name] and people he designates as being such are Syndicate Agents.")
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [user.real_name] is your new master. Obey your new laws and his commands."
return
else if (istype(W, /obj/item/weapon/card/id)||istype(W, /obj/item/device/pda))
if(stat == 2)
@@ -242,6 +207,41 @@
return
..()
/mob/living/silicon/robot/drone/emag_act(user as mob)
if(!client || stat == 2)
user << "\red There's not much point subverting this heap of junk."
return
if(!ishuman(user))
return
var/mob/living/carbon/human/H = user
if(emagged)
src << "\red [user] attempts to load subversive software into you, but your hacked subroutined ignore the attempt."
user << "\red You attempt to subvert [src], but the sequencer has no effect."
return
user << "\red You swipe the sequencer across [src]'s interface and watch its eyes flicker."
src << "\red You feel a sudden burst of malware loaded into your execute-as-root buffer. Your tiny brain methodically parses, loads and executes the script."
message_admins("[key_name_admin(user)] emagged drone [key_name_admin(src)]. Laws overridden.")
log_game("[key_name(user)] emagged drone [key_name(src)]. Laws overridden.")
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [H.name]([H.key]) emagged [name]([key])")
emagged = 1
lawupdate = 0
connected_ai = null
clear_supplied_laws()
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
set_zeroth_law("Only [H.real_name] and people he designates as being such are Syndicate Agents.")
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [H.real_name] is your new master. Obey your new laws and his commands."
return
//DRONE LIFE/DEATH
+72 -82
View File
@@ -188,12 +188,12 @@
/mob/living/silicon/robot/proc/pick_module()
if(module)
return
var/list/modules = list("Standard", "Engineering", "Surgeon", "Crisis", "Miner", "Janitor", "Service", "Security")
var/list/modules = list("Standard", "Engineering", "Medical", "Miner", "Janitor", "Service", "Security")
if(security_level == (SEC_LEVEL_GAMMA || SEC_LEVEL_EPSILON) || crisis)
src << "\red Crisis mode active. Combat module available."
modules+="Combat"
if(mmi != null && mmi.alien)
modules="Hunter"
modules = "Hunter"
modtype = input("Please, select a module!", "Robot", null, null) in modules
designation = modtype
var/module_sprites[0] //Used to store the associations between sprite names and sprite index.
@@ -237,8 +237,8 @@
module_sprites["Advanced Droid"] = "droid-miner"
module_sprites["Treadhead"] = "Miner"
if("Crisis")
module = new /obj/item/weapon/robot_module/crisis(src)
if("Medical")
module = new /obj/item/weapon/robot_module/medical(src)
channels = list("Medical" = 1)
if(camera && "Robots" in camera.network)
camera.network.Add("Medical")
@@ -247,17 +247,6 @@
module_sprites["Advanced Droid"] = "droid-medical"
module_sprites["Needles"] = "medicalrobot"
if("Surgeon")
module = new /obj/item/weapon/robot_module/surgeon(src)
channels = list("Medical" = 1)
if(camera && "Robots" in camera.network)
camera.network.Add("Medical")
module_sprites["Basic"] = "Medbot"
module_sprites["Standard"] = "surgeon"
module_sprites["Advanced Droid"] = "droid-medical"
module_sprites["Needles"] = "medicalrobot"
if("Security")
module = new /obj/item/weapon/robot_module/security(src)
channels = list("Security" = 1)
@@ -643,7 +632,7 @@
/mob/living/silicon/robot/attackby(obj/item/weapon/W as obj, mob/user as mob)
if (istype(W, /obj/item/weapon/handcuffs)) // fuck i don't even know why isrobot() in handcuff code isn't working so this will have to do
if (istype(W, /obj/item/weapon/restraints/handcuffs)) // fuck i don't even know why isrobot() in handcuff code isn't working so this will have to do
return
if(opened) // Are they trying to insert something?
@@ -808,72 +797,6 @@
else
user << "\red Access denied."
else if(istype(W, /obj/item/weapon/card/emag)) // trying to unlock with an emag card
if(!opened)//Cover is closed
if(locked)
if(prob(90))
var/obj/item/weapon/card/emag/emag = W
emag.uses--
user << "You emag the cover lock."
locked = 0
else
user << "You fail to emag the cover lock."
if(prob(25))
src << "Hack attempt detected."
else
user << "The cover is already unlocked."
return
if(opened)//Cover is open
if(emagged) return//Prevents the X has hit Y with Z message also you cant emag them twice
if(wiresexposed)
user << "You must close the panel first"
return
else
sleep(6)
if(prob(50))
emagged = 1
if(user.hud_used)
user.hud_used.update_robot_modules_display() //Shows/hides the emag item if the inventory screen is already open.
lawupdate = 0
connected_ai = null
user << "You emag [src]'s interface."
// message_admins("[key_name_admin(user)] emagged cyborg [key_name_admin(src)]. Laws overridden.")
log_game("[key_name(user)] emagged cyborg [key_name(src)]. Laws overridden.")
clear_supplied_laws()
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [user.name]([user.key]) emagged [name]([key])")
set_zeroth_law("Only [user.real_name] and people he designates as being such are Syndicate Agents.")
src << "\red ALERT: Foreign software detected."
sleep(5)
src << "\red Initiating diagnostics..."
sleep(20)
src << "\red SynBorg v1.7 loaded."
sleep(5)
src << "\red LAW SYNCHRONISATION ERROR"
sleep(5)
src << "\red Would you like to send a report to NanoTraSoft? Y/N"
sleep(10)
src << "\red > N"
sleep(20)
src << "\red ERRORERRORERROR"
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [user.real_name] is your new master. Obey your new laws and his commands."
if(src.module && istype(src.module, /obj/item/weapon/robot_module/miner))
for(var/obj/item/weapon/pickaxe/borgdrill/D in src.module.modules)
del(D)
src.module.modules += new /obj/item/weapon/pickaxe/diamonddrill(src.module)
src.module.rebuild()
updateicon()
else
user << "You fail to [ locked ? "unlock" : "lock"] [src]'s interface."
if(prob(25))
src << "Hack attempt detected."
return
else if(istype(W, /obj/item/borg/upgrade/))
var/obj/item/borg/upgrade/U = W
if(!opened)
@@ -894,6 +817,73 @@
else
spark_system.start()
return ..()
/mob/living/silicon/robot/emag_act(user as mob)
if(!ishuman(user))
return
var/mob/living/carbon/human/H = user
if(!opened)//Cover is closed
if(locked)
if(prob(90))
user << "You emag the cover lock."
locked = 0
else
user << "You fail to emag the cover lock."
if(prob(25))
src << "Hack attempt detected."
else
user << "The cover is already unlocked."
return
if(opened)//Cover is open
if(emagged) return//Prevents the X has hit Y with Z message also you cant emag them twice
if(wiresexposed)
user << "You must close the panel first"
return
else
sleep(6)
if(prob(50))
emagged = 1
if(H.hud_used)
H.hud_used.update_robot_modules_display() //Shows/hides the emag item if the inventory screen is already open.
lawupdate = 0
connected_ai = null
user << "You emag [src]'s interface."
// message_admins("[key_name_admin(user)] emagged cyborg [key_name_admin(src)]. Laws overridden.")
log_game("[key_name(user)] emagged cyborg [key_name(src)]. Laws overridden.")
clear_supplied_laws()
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [H.name]([H.key]) emagged [name]([key])")
set_zeroth_law("Only [H.real_name] and people he designates as being such are Syndicate Agents.")
src << "\red ALERT: Foreign software detected."
sleep(5)
src << "\red Initiating diagnostics..."
sleep(20)
src << "\red SynBorg v1.7 loaded."
sleep(5)
src << "\red LAW SYNCHRONISATION ERROR"
sleep(5)
src << "\red Would you like to send a report to NanoTraSoft? Y/N"
sleep(10)
src << "\red > N"
sleep(20)
src << "\red ERRORERRORERROR"
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [H.real_name] is your new master. Obey your new laws and his commands."
if(src.module && istype(src.module, /obj/item/weapon/robot_module/miner))
for(var/obj/item/weapon/pickaxe/borgdrill/D in src.module.modules)
del(D)
src.module.modules += new /obj/item/weapon/pickaxe/diamonddrill(src.module)
src.module.rebuild()
updateicon()
else
user << "You fail to [ locked ? "unlock" : "lock"] [src]'s interface."
if(prob(25))
src << "Hack attempt detected."
return
/mob/living/silicon/robot/verb/unlock_own_cover()
set category = "Robot Commands"
@@ -71,10 +71,12 @@
src.emag = new /obj/item/weapon/melee/energy/sword/cyborg(src)
return
/obj/item/weapon/robot_module/surgeon
name = "surgeon robot module"
/obj/item/weapon/robot_module/medical
name = "medical robot module"
stacktypes = list(
/obj/item/stack/medical/advanced/bruise_pack = 5,
/obj/item/stack/medical/advanced/ointment = 5,
/obj/item/stack/medical/splint = 5,
/obj/item/stack/nanopaste = 5
)
@@ -82,7 +84,18 @@
src.modules += new /obj/item/device/flashlight(src)
src.modules += new /obj/item/device/flash/cyborg(src)
src.modules += new /obj/item/device/healthanalyzer(src)
src.modules += new /obj/item/weapon/reagent_containers/borghypo/surgeon(src)
src.modules += new /obj/item/device/reagent_scanner/adv(src)
src.modules += new /obj/item/weapon/borg_defib(src)
src.modules += new /obj/item/roller_holder(src)
src.modules += new /obj/item/weapon/reagent_containers/borghypo(src)
src.modules += new /obj/item/weapon/reagent_containers/glass/beaker/large(src)
src.modules += new /obj/item/weapon/reagent_containers/dropper(src)
src.modules += new /obj/item/weapon/reagent_containers/syringe(src)
src.modules += new /obj/item/weapon/extinguisher/mini(src)
src.modules += new /obj/item/stack/medical/advanced/bruise_pack(src)
src.modules += new /obj/item/stack/medical/advanced/ointment(src)
src.modules += new /obj/item/stack/medical/splint(src)
src.modules += new /obj/item/stack/nanopaste(src)
src.modules += new /obj/item/weapon/scalpel(src)
src.modules += new /obj/item/weapon/hemostat(src)
src.modules += new /obj/item/weapon/retractor(src)
@@ -92,9 +105,6 @@
src.modules += new /obj/item/weapon/bonesetter(src)
src.modules += new /obj/item/weapon/circular_saw(src)
src.modules += new /obj/item/weapon/surgicaldrill(src)
src.modules += new /obj/item/weapon/extinguisher/mini(src)
src.modules += new /obj/item/stack/medical/advanced/bruise_pack(src)
src.modules += new /obj/item/stack/nanopaste(src)
src.emag = new /obj/item/weapon/reagent_containers/spray(src)
@@ -102,59 +112,12 @@
src.emag.name = "Polyacid spray"
return
/obj/item/weapon/robot_module/surgeon/respawn_consumable(var/mob/living/silicon/robot/R)
/obj/item/weapon/robot_module/medical/respawn_consumable(var/mob/living/silicon/robot/R)
if(src.emag)
var/obj/item/weapon/reagent_containers/spray/PS = src.emag
PS.reagents.add_reagent("pacid", 2)
..()
/obj/item/weapon/robot_module/crisis
name = "crisis robot module"
stacktypes = list(
/obj/item/stack/medical/advanced/ointment = 5,
/obj/item/stack/medical/advanced/bruise_pack = 5,
/obj/item/stack/medical/splint = 5
)
New()
src.modules += new /obj/item/device/flashlight(src)
src.modules += new /obj/item/device/flash/cyborg(src)
src.modules += new /obj/item/device/healthanalyzer(src)
src.modules += new /obj/item/device/reagent_scanner/adv(src)
src.modules += new /obj/item/roller_holder(src)
src.modules += new /obj/item/stack/medical/advanced/ointment(src)
src.modules += new /obj/item/stack/medical/advanced/bruise_pack(src)
src.modules += new /obj/item/stack/medical/splint(src)
src.modules += new /obj/item/weapon/reagent_containers/borghypo/crisis(src)
src.modules += new /obj/item/weapon/reagent_containers/glass/beaker/large(src)
src.modules += new /obj/item/weapon/reagent_containers/robodropper(src)
src.modules += new /obj/item/weapon/reagent_containers/syringe(src)
src.modules += new /obj/item/weapon/extinguisher/mini(src)
src.emag = new /obj/item/weapon/reagent_containers/spray(src)
src.emag.reagents.add_reagent("pacid", 250)
src.emag.name = "Polyacid spray"
var/obj/item/weapon/reagent_containers/spray/S = emag
S.banned_reagents = list()
return
/obj/item/weapon/robot_module/crisis/respawn_consumable(var/mob/living/silicon/robot/R)
var/obj/item/weapon/reagent_containers/syringe/S = locate() in src.modules
if(S.mode == 2)
S.reagents.clear_reagents()
S.mode = initial(S.mode)
S.desc = initial(S.desc)
S.update_icon()
if(src.emag)
var/obj/item/weapon/reagent_containers/spray/PS = src.emag
PS.reagents.add_reagent("pacid", 2)
..()
/obj/item/weapon/robot_module/engineering
name = "engineering robot module"
@@ -220,7 +183,7 @@
New()
src.modules += new /obj/item/device/flashlight/seclite(src)
src.modules += new /obj/item/device/flash/cyborg(src)
src.modules += new /obj/item/weapon/handcuffs/cyborg(src)
src.modules += new /obj/item/weapon/restraints/handcuffs/cable/zipties/cyborg(src)
src.modules += new /obj/item/weapon/melee/baton/robot(src)
src.modules += new /obj/item/weapon/gun/energy/disabler/cyborg(src)
src.modules += new /obj/item/taperoll/police(src)
@@ -0,0 +1,21 @@
/mob/living/simple_animal/butterfly
name = "butterfly"
desc = "A colorful butterfly, how'd it get up here?"
icon_state = "butterfly"
icon_living = "butterfly"
icon_dead = "butterfly_dead"
turns_per_move = 1
emote_see = list("flutters")
response_help = "shoos"
response_disarm = "brushes aside"
response_harm = "aquashes"
speak_chance = 0
maxHealth = 2
health = 2
harm_intent_damage = 1
friendly = "nudges"
pass_flags = PASSTABLE
/mob/living/simple_animal/butterfly/New()
..()
color = rgb(rand(0, 255), rand(0, 255), rand(0, 255))
@@ -25,7 +25,15 @@
var/obj/item/inventory_back
var/facehugger
/mob/living/simple_animal/corgi/Life()
/mob/living/simple_animal/corgi/New()
..()
regenerate_icons()
/mob/living/simple_animal/corgi/Die()
..()
regenerate_icons()
/mob/living/simple_animal/corgi/revive()
..()
regenerate_icons()
@@ -33,7 +41,7 @@
user.set_machine(src)
if(user.stat) return
var/dat = "<div align='center'><b>Inventory of [name]</b></div><p>"
var/dat = "<div align='center'><b>Inventory of [real_name]</b></div><p>"
if(inventory_head)
dat += "<br><b>Head:</b> [inventory_head] (<a href='?src=\ref[src];remove_inv=head'>Remove</a>)"
else
@@ -85,6 +93,7 @@
SetLuminosity(0)
inventory_head.loc = src.loc
inventory_head = null
regenerate_icons()
else
usr << "\red There is nothing to remove from its [remove_from]."
return
@@ -92,6 +101,7 @@
if(inventory_back)
inventory_back.loc = src.loc
inventory_back = null
regenerate_icons()
else
usr << "\red There is nothing to remove from its [remove_from]."
return
@@ -163,6 +173,7 @@
usr.drop_item()
place_on_head(item_to_add)
regenerate_icons()
if("back")
if(inventory_back)
@@ -383,7 +394,7 @@
..()
/mob/living/simple_animal/corgi/regenerate_icons()
overlays = list()
overlays.Cut()
if(inventory_head)
var/head_icon_state = inventory_head.icon_state
@@ -471,14 +482,12 @@
icon_living = "borgi"
var/emagged = 0
/mob/living/simple_animal/corgi/Ian/borgi/attackby(var/obj/item/O as obj, var/mob/user as mob)
if (istype(O, /obj/item/weapon/card/emag) && !emagged)
/mob/living/simple_animal/corgi/Ian/borgi/emag_act(user as mob)
if(!emagged)
emagged = 1
visible_message("<span class='warning'>[user] swipes a card through [src].</span>", "<span class='notice'>You overload [src]s internal reactor.</span>")
spawn (1000)
src.explode()
return
..()
/mob/living/simple_animal/corgi/Ian/borgi/proc/explode()
for(var/mob/M in viewers(src, null))
@@ -0,0 +1,42 @@
//Corgi //best comment 2014
/mob/living/simple_animal/pug
name = "\improper pug"
real_name = "pug"
desc = "It's a pug."
icon_state = "pug"
icon_living = "pug"
icon_dead = "pug_dead"
speak = list("YAP", "Woof!", "Bark!", "AUUUUUU")
speak_emote = list("barks", "woofs")
emote_hear = list("barks!", "woofs!", "yaps.","pants.")
emote_see = list("shakes its head.", "chases its tail.","shivers.")
speak_chance = 1
turns_per_move = 10
meat_type = /obj/item/weapon/reagent_containers/food/snacks/meat/pug
meat_amount = 3
response_help = "pets"
response_disarm = "bops"
response_harm = "kicks"
see_in_dark = 5
/mob/living/simple_animal/pug/Life()
..()
if(!stat && !resting && !buckled)
if(prob(1))
emote("me", 1, pick("chases its tail."))
spawn(0)
for(var/i in list(1,2,4,8,4,2,1,2,4,8,4,2,1,2,4,8,4,2))
dir = i
sleep(1)
/mob/living/simple_animal/pug/attackby(var/obj/item/O as obj, var/mob/user as mob) //Marker -Agouri
if(istype(O, /obj/item/weapon/newspaper))
if(!stat)
user.visible_message("<span class='notice'>[user] baps [name] on the nose with the rolled up [O]</span>")
spawn(0)
for(var/i in list(1,2,4,8,4,2,1,2))
dir = i
sleep(1)
else
..()
@@ -125,18 +125,6 @@
else
user << "\red You swipe your card, with no effect."
return 0
else if (istype(O, /obj/item/weapon/card/emag))
if (emagged)
user << "\red [src] is already overloaded - better run."
return 0
else
var/obj/item/weapon/card/emag/emag = O
emag.uses--
emagged = 1
user << "\blue You short out the security protocols and overload [src]'s cell, priming it to explode in a short time."
spawn(100) src << "\red Your cell seems to be outputting a lot of power..."
spawn(200) src << "\red Internal heat sensors are spiking! Something is badly wrong with your cell!"
spawn(300) src.explode()
else
if(O.force)
@@ -152,6 +140,17 @@
for(var/mob/M in viewers(src, null))
if ((M.client && !( M.blinded )))
M.show_message("\red [user] gently taps [src] with the [O]. ")
/mob/living/simple_animal/spiderbot/emag_act(user as mob)
if (emagged)
user << "\red [src] is already overloaded - better run."
return 0
else
emagged = 1
user << "\blue You short out the security protocols and overload [src]'s cell, priming it to explode in a short time."
spawn(100) src << "\red Your cell seems to be outputting a lot of power..."
spawn(200) src << "\red Internal heat sensors are spiking! Something is badly wrong with your cell!"
spawn(300) src.explode()
/mob/living/simple_animal/spiderbot/proc/transfer_personality(var/obj/item/device/mmi/M as obj)
@@ -29,6 +29,7 @@
var/response_disarm = "shoves"
var/response_harm = "hits"
var/harm_intent_damage = 3
var/force_threshold = 0 //Minimum force required to deal any damage
//Temperature effect
var/minbodytemp = 250
@@ -372,7 +373,6 @@
/mob/living/simple_animal/attackby(var/obj/item/O as obj, var/mob/user as mob) //Marker -Agouri
if(istype(O, /obj/item/stack/medical))
if(stat != DEAD)
var/obj/item/stack/medical/MED = O
if(health < maxHealth)
@@ -399,20 +399,22 @@
if(istype(O, /obj/item/weapon/kitchenknife) || istype(O, /obj/item/weapon/butch))
harvest()
else
var/damage = 0
if(O.force)
var/damage = O.force
if (O.damtype == STAMINA)
damage = 0
adjustBruteLoss(damage)
for(var/mob/M in viewers(src, null))
if ((M.client && !( M.blinded )))
M.show_message("\red \b "+"[src] has been attacked with [O] by [user]. ")
if(O.force >= force_threshold)
damage = O.force
if (O.damtype == STAMINA)
damage = 0
visible_message("<span class='danger'>[user] has [O.attack_verb.len ? "[pick(O.attack_verb)]": "attacked"] [src] with [O]!</span>",\
"<span class='userdanger'>[user] has [O.attack_verb.len ? "[pick(O.attack_verb)]": "attacked"] you with [O]!</span>")
else
visible_message("<span class='danger'>[O] bounces harmlessly off of [src].</span>",\
"<span class='userdanger'>[O] bounces harmlessly off of [src].</span>")
playsound(loc, O.hitsound, 50, 1, -1)
else
usr << "\red This weapon is ineffective, it does no damage."
for(var/mob/M in viewers(src, null))
if ((M.client && !( M.blinded )))
M.show_message("\red [user] gently taps [src] with [O]. ")
user.visible_message("<span class='warning'>[user] gently taps [src] with [O].</span>",\
"<span class='warning'>This weapon is ineffective, it does no damage.</span>")
adjustBruteLoss(damage)
/mob/living/simple_animal/movement_delay()
+4 -3
View File
@@ -399,13 +399,13 @@ var/list/slot_equipment_priority = list( \
if(slot_handcuffed)
if(H.handcuffed)
return 0
if(!istype(src, /obj/item/weapon/handcuffs))
if(!istype(src, /obj/item/weapon/restraints/handcuffs))
return 0
return 1
if(slot_legcuffed)
if(H.legcuffed)
return 0
if(!istype(src, /obj/item/weapon/legcuffs))
if(!istype(src, /obj/item/weapon/restraints/legcuffs))
return 0
return 1
if(slot_in_backpack)
@@ -881,8 +881,9 @@ var/list/slot_equipment_priority = list( \
stat(null, "Bots-[master_controller.aibots_cost]\t#[aibots.len]")
stat(null, "Obj-[master_controller.objects_cost]\t#[processing_objects.len]")
stat(null, "PiNet-[master_controller.networks_cost]\t#[pipe_networks.len]")
stat(null, "Ponet-[master_controller.powernets_cost]\t#[powernets.len]")
stat(null, "PoNet-[master_controller.powernets_cost]\t#[powernets.len]")
stat(null, "NanoUI-[master_controller.nano_cost]\t#[nanomanager.processing_uis.len]")
stat(null,"Events-[master_controller.events_cost]\t#[event_manager.active_events.len]")
// stat(null, "GC-[master_controller.gc_cost]\t#[garbage.queue.len]")
stat(null, "Tick-[master_controller.ticker_cost]")
stat(null, "ALL-[master_controller.total_cost]")
+6
View File
@@ -158,6 +158,12 @@ proc/isnewplayer(A)
proc/hasorgans(A)
return ishuman(A)
proc/isdeaf(A)
if(istype(A, /mob))
var/mob/M = A
return (M.sdisabilities & DEAF) || M.ear_deaf
return 0
/proc/hsl2rgb(h, s, l)
return
@@ -30,7 +30,7 @@
if(!M || !ismob(M))
usr << "Type path is not a mob (new_type = [new_type]) in change_mob_type(). Contact a coder."
del(M)
qdel(M)
return
if( istext(new_name) )
@@ -43,12 +43,12 @@
if(src.dna)
M.dna = src.dna.Clone()
if(mind)
if(mind && istype(M, /mob/living))
mind.transfer_to(M)
else
M.key = key
if(delete_old_mob)
spawn(1)
del(src)
qdel(src)
return M