Merge remote-tracking branch 'upstream/dev-freeze' into dev

Conflicts:
	code/setup.dm
	icons/mob/items_righthand.dmi
	maps/exodus-1.dmm
	maps/exodus-5.dmm
This commit is contained in:
PsiOmega
2015-03-13 09:23:26 +01:00
69 changed files with 3159 additions and 2935 deletions
@@ -149,9 +149,6 @@
else
healths.icon_state = "health7"
if(pullin)
pullin.icon_state = "pull[pulling ? 1 : 0]"
if (client)
client.screen.Remove(global_hud.blurry,global_hud.druggy,global_hud.vimpaired)
@@ -225,7 +225,6 @@
else
healths.icon_state = "health7"
if(pullin) pullin.icon_state = "pull[pulling ? 1 : 0]"
if (client)
client.screen.Remove(global_hud.blurry,global_hud.druggy,global_hud.vimpaired)
@@ -451,7 +451,6 @@
msg += "\n[t_He] is [pose]"
user << msg
..()
//Helper procedure. Called by /mob/living/carbon/human/examine() and /mob/living/carbon/human/Topic() to determine HUD access to security and medical records.
/proc/hasHUD(mob/M as mob, hudtype)
@@ -1250,9 +1250,6 @@
if(pressure)
pressure.icon_state = "pressure[pressure_alert]"
if(pullin)
if(pulling) pullin.icon_state = "pull1"
else pullin.icon_state = "pull0"
// if(rest) //Not used with new UI
// if(resting || lying || sleeping) rest.icon_state = "rest1"
// else rest.icon_state = "rest0"
@@ -439,9 +439,6 @@
if(pressure)
pressure.icon_state = "pressure[pressure_alert]"
if(pullin) pullin.icon_state = "pull[pulling ? 1 : 0]"
if (toxin) toxin.icon_state = "tox[phoron_alert ? 1 : 0]"
if (oxygen) oxygen.icon_state = "oxy[oxygen_alert ? 1 : 0]"
if (fire) fire.icon_state = "fire[fire_alert ? 2 : 0]"
@@ -75,8 +75,9 @@
for(var/camera in cameras)
var/obj/machinery/camera/c = camera
if(!c)
if(!istype(c))
cameras -= c
continue
if(!c.can_use())
continue
@@ -54,8 +54,6 @@
/mob/living/silicon/robot/drone/init()
laws = new /datum/ai_laws/drone()
connected_ai = null
aiCamera = new/obj/item/device/camera/siliconcam/drone_camera(src)
playsound(src.loc, 'sound/machines/twobeep.ogg', 50, 0)
@@ -226,9 +226,7 @@
if(tra.current)
var/I = image('icons/mob/mob.dmi', loc = tra.current, icon_state = "traitor")
src.client.images += I
if(src.connected_ai)
src.connected_ai.connected_robots -= src
src.connected_ai = null
src.disconnect_from_ai()
if(src.mind)
if(!src.mind.special_role)
src.mind.special_role = "traitor"
@@ -264,8 +262,6 @@
else
src.bodytemp.icon_state = "temp-2"
if(src.pullin) src.pullin.icon_state = "pull[src.pulling ? 1 : 0]"
//Oxygen and fire does nothing yet!!
// if (src.oxygen) src.oxygen.icon_state = "oxy[src.oxygen_alert ? 1 : 0]"
// if (src.fire) src.fire.icon_state = "fire[src.fire_alert ? 1 : 0]"
+29 -16
View File
@@ -165,11 +165,10 @@ var/list/robot_verbs_default = list(
aiCamera = new/obj/item/device/camera/siliconcam/robot_camera(src)
laws = new /datum/ai_laws/nanotrasen()
additional_law_channels += "Binary"
connected_ai = select_active_ai_with_fewest_borgs()
if(connected_ai)
connected_ai.connected_robots += src
var/new_ai = select_active_ai_with_fewest_borgs()
if(new_ai)
lawupdate = 1
sync()
connect_to_ai(new_ai)
else
lawupdate = 0
@@ -366,7 +365,7 @@ var/list/robot_verbs_default = list(
choose_icon(6,module_sprites)
radio.config(module.channels)
notify_ai(2)
notify_ai(ROBOT_NOTIFICATION_NEW_MODULE, module.name)
/mob/living/silicon/robot/proc/updatename(var/prefix as text)
if(prefix)
@@ -386,7 +385,7 @@ var/list/robot_verbs_default = list(
else
changed_name = "[modtype] [braintype]-[num2text(ident)]"
notify_ai(3, real_name, changed_name)
notify_ai(ROBOT_NOTIFICATION_NEW_NAME, real_name, changed_name)
real_name = changed_name
name = real_name
@@ -803,7 +802,7 @@ var/list/robot_verbs_default = list(
if(prob(50))
emagged = 1
lawupdate = 0
connected_ai = null
disconnect_from_ai()
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.")
@@ -1135,8 +1134,7 @@ var/list/robot_verbs_default = list(
return
/mob/living/silicon/robot/proc/UnlinkSelf()
if (src.connected_ai)
src.connected_ai = null
disconnect_from_ai()
lawupdate = 0
lockcharge = 0
canmove = 1
@@ -1246,14 +1244,29 @@ var/list/robot_verbs_default = list(
return 1
return 0
/mob/living/silicon/robot/proc/notify_ai(var/notifytype, var/oldname, var/newname)
/mob/living/silicon/robot/proc/notify_ai(var/notifytype, var/first_arg, var/second_arg)
if(!connected_ai)
return
switch(notifytype)
if(1) //New Robot
if(ROBOT_NOTIFICATION_NEW_UNIT) //New Robot
connected_ai << "<br><br><span class='notice'>NOTICE - New [lowertext(braintype)] connection detected: <a href='byond://?src=\ref[connected_ai];track2=\ref[connected_ai];track=\ref[src]'>[name]</a></span><br>"
if(2) //New Module
connected_ai << "<br><br><span class='notice'>NOTICE - [braintype] module change detected: [name] has loaded the [module.name].</span><br>"
if(3) //New Name
if(oldname != newname)
connected_ai << "<br><br><span class='notice'>NOTICE - [braintype] reclassification detected: [oldname] is now designated as [newname].</span><br>"
if(ROBOT_NOTIFICATION_NEW_MODULE) //New Module
connected_ai << "<br><br><span class='notice'>NOTICE - [braintype] module change detected: [name] has loaded the [first_arg].</span><br>"
if(ROBOT_NOTIFICATION_MODULE_RESET)
connected_ai << "<br><br><span class='notice'>NOTICE - [braintype] module reset detected: [name] has unladed the [first_arg].</span><br>"
if(ROBOT_NOTIFICATION_NEW_NAME) //New Name
if(first_arg != second_arg)
connected_ai << "<br><br><span class='notice'>NOTICE - [braintype] reclassification detected: [first_arg] is now designated as [second_arg].</span><br>"
/mob/living/silicon/robot/proc/disconnect_from_ai()
if(connected_ai)
connected_ai.connected_robots -= src
connected_ai = null
/mob/living/silicon/robot/proc/connect_to_ai(var/mob/living/silicon/ai/AI)
if(AI && AI != connected_ai)
disconnect_from_ai()
connected_ai = AI
connected_ai.connected_robots |= src
notify_ai(ROBOT_NOTIFICATION_NEW_UNIT)
sync()
@@ -239,7 +239,7 @@
if (!(status_flags & CANPUSH))
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M, M, src )
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab(M, src)
M.put_in_active_hand(G)
@@ -375,4 +375,4 @@
/mob/living/simple_animal/put_in_hands(var/obj/item/W) // No hands.
W.loc = get_turf(src)
return 1
return 1
+6 -1
View File
@@ -228,7 +228,7 @@ var/list/slot_equipment_priority = list( \
if((is_blind(src) || usr.stat) && !isobserver(src))
src << "<span class='notice'>Something is there but you can't see it.</span>"
return
return 1
face_atom(A)
A.examine(src)
@@ -616,6 +616,8 @@ var/list/slot_equipment_priority = list( \
if(pulling)
pulling.pulledby = null
pulling = null
if(pullin)
pullin.icon_state = "pull1"
/mob/proc/start_pulling(var/atom/movable/AM)
if ( !AM || !usr || src==AM || !isturf(src.loc) ) //if there's no person pulling OR the person is pulling themself OR the object being pulled is inside something: abort!
@@ -642,6 +644,9 @@ var/list/slot_equipment_priority = list( \
src.pulling = AM
AM.pulledby = src
if(pullin)
pullin.icon_state = "pull0"
if(ishuman(AM))
var/mob/living/carbon/human/H = AM
if(H.pull_damage())
+12 -17
View File
@@ -453,23 +453,18 @@
if(istype(turf,/turf/space))
continue
if(istype(src,/mob/living/carbon/human/)) // Only humans can wear magboots, so we give them a chance to.
var/mob/living/carbon/human/H = src
if((istype(turf,/turf/simulated/floor)) && (src.lastarea.has_gravity == 0) && !(istype(H.shoes, /obj/item/clothing/shoes/magboots) && (H.shoes.flags & NOSLIP)))
continue
else
if((istype(turf,/turf/simulated/floor)) && (src.lastarea.has_gravity == 0)) // No one else gets a chance.
continue
/*
if(istype(turf,/turf/simulated/floor) && (src.flags & NOGRAV))
continue
*/
if(istype(turf,/turf/simulated/floor)) // Floors don't count if they don't have gravity
var/area/A = turf.loc
if(istype(A) && A.has_gravity == 0)
var/can_walk = 0
if(ishuman(src)) // Only humans can wear magboots, so we give them a chance to.
var/mob/living/carbon/human/H = src
if(istype(H.shoes, /obj/item/clothing/shoes/magboots) && (H.shoes.flags & NOSLIP))
can_walk = 1
if(!can_walk)
continue
dense_object++
break
-1
View File
@@ -168,7 +168,6 @@
O.mmi.transfer_identity(src)
callHook("borgify", list(O))
O.notify_ai(1)
O.Namepick()
spawn(0)//To prevent the proc from returning null.