mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2025-12-25 09:31:13 +00:00
@@ -123,21 +123,22 @@
|
||||
laws.add_inherent_law(M.newFreeFormLaw)
|
||||
usr << "Added a freeform law."
|
||||
|
||||
if(istype(P, /obj/item/device/mmi) || istype(P, /obj/item/device/mmi/posibrain))
|
||||
if(!P:brainmob)
|
||||
if(istype(P, /obj/item/device/mmi))
|
||||
var/obj/item/device/mmi/M = P
|
||||
if(!M.brainmob)
|
||||
user << "\red Sticking an empty [P] into the frame would sort of defeat the purpose."
|
||||
return
|
||||
if(P:brainmob.stat == 2)
|
||||
if(M.brainmob.stat == 2)
|
||||
user << "\red Sticking a dead [P] into the frame would sort of defeat the purpose."
|
||||
return
|
||||
|
||||
if(jobban_isbanned(P:brainmob, "AI"))
|
||||
if(jobban_isbanned(M.brainmob, "AI"))
|
||||
user << "\red This [P] does not seem to fit."
|
||||
return
|
||||
|
||||
if(P:brainmob.mind)
|
||||
ticker.mode.remove_cultist(P:brainmob.mind, 1)
|
||||
ticker.mode.remove_revolutionary(P:brainmob.mind, 1)
|
||||
if(M.brainmob.mind)
|
||||
ticker.mode.remove_cultist(M.brainmob.mind, 1)
|
||||
ticker.mode.remove_revolutionary(M.brainmob.mind, 1)
|
||||
|
||||
user.drop_item()
|
||||
P.loc = src
|
||||
|
||||
@@ -636,7 +636,7 @@
|
||||
/obj/mecha/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
|
||||
|
||||
if(istype(W, /obj/item/device/mmi) || istype(W, /obj/item/device/mmi/posibrain))
|
||||
if(istype(W, /obj/item/device/mmi))
|
||||
if(mmi_move_inside(W,user))
|
||||
user << "[src]-MMI interface initialized successfuly"
|
||||
else
|
||||
@@ -1153,7 +1153,7 @@
|
||||
src.occupant.client.perspective = MOB_PERSPECTIVE
|
||||
*/
|
||||
src.occupant << browse(null, "window=exosuit")
|
||||
if(istype(mob_container, /obj/item/device/mmi) || istype(mob_container, /obj/item/device/mmi/posibrain))
|
||||
if(istype(mob_container, /obj/item/device/mmi))
|
||||
var/obj/item/device/mmi/mmi = mob_container
|
||||
if(mmi.brainmob)
|
||||
occupant.loc = mmi
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
return 1
|
||||
|
||||
// Okay, it wasn't a terminal being touched, check for all the simple insertions.
|
||||
if(input_device.type in list(/obj/item/device/paicard, /obj/item/device/mmi, /obj/item/device/mmi/posibrain))
|
||||
if(input_device.type in list(/obj/item/device/paicard, /obj/item/device/mmi, /obj/item/device/mmi/digital/posibrain))
|
||||
integrate_ai(input_device,user)
|
||||
return 1
|
||||
|
||||
|
||||
@@ -1,5 +1,22 @@
|
||||
//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:32
|
||||
|
||||
/obj/item/device/mmi/digital/New()
|
||||
src.brainmob = new(src)
|
||||
src.brainmob.add_language("Binary")
|
||||
src.brainmob.loc = src
|
||||
src.brainmob.container = src
|
||||
src.brainmob.stat = 0
|
||||
src.brainmob.silent = 0
|
||||
dead_mob_list -= src.brainmob
|
||||
|
||||
/obj/item/device/mmi/digital/transfer_identity(var/mob/living/carbon/H)
|
||||
brainmob.dna = H.dna
|
||||
brainmob.timeofhostdeath = H.timeofdeath
|
||||
brainmob.stat = 0
|
||||
if(H.mind)
|
||||
H.mind.transfer_to(brainmob)
|
||||
return
|
||||
|
||||
/obj/item/device/mmi
|
||||
name = "Man-Machine Interface"
|
||||
desc = "The Warrior's bland acronym, MMI, obscures the true horror of this monstrosity."
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/device/mmi/posibrain
|
||||
/obj/item/device/mmi/digital/posibrain
|
||||
name = "positronic brain"
|
||||
desc = "A cube of shining metal, four inches to a side and covered in shallow grooves."
|
||||
icon = 'icons/obj/assemblies.dmi'
|
||||
@@ -15,7 +15,7 @@
|
||||
mecha = null//This does not appear to be used outside of reference in mecha.dm.
|
||||
|
||||
|
||||
/obj/item/device/mmi/posibrain/attack_self(mob/user as mob)
|
||||
/obj/item/device/mmi/digital/posibrain/attack_self(mob/user as mob)
|
||||
if(brainmob && !brainmob.key && searching == 0)
|
||||
//Start the process of searching for a new user.
|
||||
user << "\blue You carefully locate the manual activation switch and start the positronic brain's boot process."
|
||||
@@ -24,7 +24,7 @@
|
||||
src.request_player()
|
||||
spawn(600) reset_search()
|
||||
|
||||
/obj/item/device/mmi/posibrain/proc/request_player()
|
||||
/obj/item/device/mmi/digital/posibrain/proc/request_player()
|
||||
for(var/mob/dead/observer/O in player_list)
|
||||
if(O.has_enabled_antagHUD == 1 && config.antag_hud_restricted)
|
||||
continue
|
||||
@@ -34,7 +34,7 @@
|
||||
if(O.client.prefs.be_special & BE_AI)
|
||||
question(O.client)
|
||||
|
||||
/obj/item/device/mmi/posibrain/proc/question(var/client/C)
|
||||
/obj/item/device/mmi/digital/posibrain/proc/question(var/client/C)
|
||||
spawn(0)
|
||||
if(!C) return
|
||||
var/response = alert(C, "Someone is requesting a personality for a positronic brain. Would you like to play as one?", "Positronic brain request", "Yes", "No", "Never for this round")
|
||||
@@ -47,26 +47,15 @@
|
||||
C.prefs.be_special ^= BE_AI
|
||||
|
||||
|
||||
/obj/item/device/mmi/posibrain/transfer_identity(var/mob/living/carbon/H)
|
||||
/*
|
||||
Positronic brains should have posibrain-like name, instead of human-MMIlike names. -- ATL
|
||||
|
||||
name = "positronic brain ([H])"
|
||||
brainmob.name = H.real_name
|
||||
brainmob.real_name = H.real_name
|
||||
*/
|
||||
brainmob.dna = H.dna
|
||||
brainmob.timeofhostdeath = H.timeofdeath
|
||||
brainmob.stat = 0
|
||||
/obj/item/device/mmi/digital/posibrain/transfer_identity(var/mob/living/carbon/H)
|
||||
..()
|
||||
if(brainmob.mind)
|
||||
brainmob.mind.assigned_role = "Positronic Brain"
|
||||
if(H.mind)
|
||||
H.mind.transfer_to(brainmob)
|
||||
brainmob << "\blue You feel slightly disoriented. That's normal when you're just a metal cube."
|
||||
brainmob << "<span class='notify'>You feel slightly disoriented. That's normal when you're just a metal cube.</span>"
|
||||
icon_state = "posibrain-occupied"
|
||||
return
|
||||
|
||||
/obj/item/device/mmi/posibrain/proc/transfer_personality(var/mob/candidate)
|
||||
/obj/item/device/mmi/digital/posibrain/proc/transfer_personality(var/mob/candidate)
|
||||
announce_ghost_joinleave(candidate, 0, "They are occupying a positronic brain now.")
|
||||
src.searching = 0
|
||||
src.brainmob.mind = candidate.mind
|
||||
@@ -83,7 +72,7 @@
|
||||
M.show_message("\blue The positronic brain chimes quietly.")
|
||||
icon_state = "posibrain-occupied"
|
||||
|
||||
/obj/item/device/mmi/posibrain/proc/reset_search() //We give the players sixty seconds to decide, then reset the timer.
|
||||
/obj/item/device/mmi/digital/posibrain/proc/reset_search() //We give the players sixty seconds to decide, then reset the timer.
|
||||
|
||||
if(src.brainmob && src.brainmob.key) return
|
||||
|
||||
@@ -94,10 +83,10 @@
|
||||
for (var/mob/M in viewers(T))
|
||||
M.show_message("\blue The positronic brain buzzes quietly, and the golden lights fade away. Perhaps you could try again?")
|
||||
|
||||
/obj/item/device/mmi/posibrain/examine(mob/user)
|
||||
/obj/item/device/mmi/digital/posibrain/examine(mob/user)
|
||||
if(!..(user))
|
||||
return
|
||||
|
||||
|
||||
var/msg = "<span class='info'>*---------*\nThis is \icon[src] \a <EM>[src]</EM>!\n[desc]\n"
|
||||
msg += "<span class='warning'>"
|
||||
|
||||
@@ -113,7 +102,7 @@
|
||||
user << msg
|
||||
return
|
||||
|
||||
/obj/item/device/mmi/posibrain/emp_act(severity)
|
||||
/obj/item/device/mmi/digital/posibrain/emp_act(severity)
|
||||
if(!src.brainmob)
|
||||
return
|
||||
else
|
||||
@@ -126,16 +115,7 @@
|
||||
src.brainmob.emp_damage += rand(0,10)
|
||||
..()
|
||||
|
||||
/obj/item/device/mmi/posibrain/New()
|
||||
|
||||
src.brainmob = new(src)
|
||||
src.brainmob.add_language("Binary")
|
||||
/obj/item/device/mmi/digital/posibrain/New()
|
||||
..()
|
||||
src.brainmob.name = "[pick(list("PBU","HIU","SINA","ARMA","OSI"))]-[rand(100, 999)]"
|
||||
src.brainmob.real_name = src.brainmob.name
|
||||
src.brainmob.loc = src
|
||||
src.brainmob.container = src
|
||||
src.brainmob.stat = 0
|
||||
src.brainmob.silent = 0
|
||||
dead_mob_list -= src.brainmob
|
||||
|
||||
..()
|
||||
|
||||
19
code/modules/mob/living/carbon/brain/robot.dm
Normal file
19
code/modules/mob/living/carbon/brain/robot.dm
Normal file
@@ -0,0 +1,19 @@
|
||||
/obj/item/device/mmi/digital/robot
|
||||
name = "robotic intelligence circuit"
|
||||
desc = "The pinnacle of artifical intelligence which can be achieved using classical computer science."
|
||||
icon = 'icons/obj/module.dmi'
|
||||
icon_state = "mainboard"
|
||||
w_class = 3
|
||||
origin_tech = "engineering=4;materials=3;programming=4"
|
||||
|
||||
/obj/item/device/mmi/digital/robot/New()
|
||||
..()
|
||||
src.brainmob.name = "[pick(list("ADA","DOS","GNU","MAC","WIN"))]-[rand(1000, 9999)]"
|
||||
src.brainmob.real_name = src.brainmob.name
|
||||
|
||||
/obj/item/device/mmi/digital/robot/transfer_identity(var/mob/living/carbon/H)
|
||||
..()
|
||||
if(brainmob.mind)
|
||||
brainmob.mind.assigned_role = "Robotic Intelligence"
|
||||
brainmob << "<span class='notify'>You feel slightly disoriented. That's normal when you're little more than a complex circuit.</span>"
|
||||
return
|
||||
@@ -3,7 +3,7 @@
|
||||
if (silent)
|
||||
return
|
||||
|
||||
if(!(container && (istype(container, /obj/item/device/mmi) || istype(container, /obj/item/device/mmi/posibrain))))
|
||||
if(!(container && istype(container, /obj/item/device/mmi)))
|
||||
return //No MMI, can't speak, bucko./N
|
||||
else
|
||||
if(prob(emp_damage*4))
|
||||
|
||||
@@ -339,13 +339,14 @@ var/list/robot_verbs_default = list(
|
||||
/mob/living/silicon/robot/proc/updatename(var/prefix as text)
|
||||
if(prefix)
|
||||
modtype = prefix
|
||||
if(mmi)
|
||||
if(istype(mmi, /obj/item/device/mmi/posibrain))
|
||||
braintype = "Android"
|
||||
else
|
||||
braintype = "Cyborg"
|
||||
else
|
||||
|
||||
if(istype(mmi, /obj/item/device/mmi/digital/posibrain))
|
||||
braintype = "Android"
|
||||
else if(istype(mmi, /obj/item/device/mmi/digital/robot))
|
||||
braintype = "Robot"
|
||||
else
|
||||
braintype = "Cyborg"
|
||||
|
||||
|
||||
var/changed_name = ""
|
||||
if(custom_name)
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
|
||||
/mob/living/simple_animal/spiderbot/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
|
||||
if(istype(O, /obj/item/device/mmi) || istype(O, /obj/item/device/mmi/posibrain))
|
||||
if(istype(O, /obj/item/device/mmi))
|
||||
var/obj/item/device/mmi/B = O
|
||||
if(src.mmi) //There's already a brain in it.
|
||||
user << "\red There's already a brain in [src]!"
|
||||
@@ -164,14 +164,12 @@
|
||||
death()
|
||||
|
||||
/mob/living/simple_animal/spiderbot/proc/update_icon()
|
||||
if(mmi)
|
||||
if(istype(mmi,/obj/item/device/mmi))
|
||||
icon_state = "spiderbot-chassis-mmi"
|
||||
icon_living = "spiderbot-chassis-mmi"
|
||||
if(istype(mmi, /obj/item/device/mmi/posibrain))
|
||||
icon_state = "spiderbot-chassis-posi"
|
||||
icon_living = "spiderbot-chassis-posi"
|
||||
|
||||
if(istype(mmi, /obj/item/device/mmi/digital/posibrain))
|
||||
icon_state = "spiderbot-chassis-posi"
|
||||
icon_living = "spiderbot-chassis-posi"
|
||||
else if(istype(mmi,/obj/item/device/mmi))
|
||||
icon_state = "spiderbot-chassis-mmi"
|
||||
icon_living = "spiderbot-chassis-mmi"
|
||||
else
|
||||
icon_state = "spiderbot-chassis"
|
||||
icon_living = "spiderbot-chassis"
|
||||
|
||||
@@ -158,14 +158,13 @@
|
||||
O.job = "Cyborg"
|
||||
if(O.mind.assigned_role == "Cyborg")
|
||||
if(O.mind.role_alt_title == "Android")
|
||||
O.mmi = new /obj/item/device/mmi/posibrain(O)
|
||||
O.mmi = new /obj/item/device/mmi/digital/posibrain(O)
|
||||
else if(O.mind.role_alt_title == "Robot")
|
||||
O.mmi = null //Robots do not have removable brains.
|
||||
O.mmi = new /obj/item/device/mmi/digital/robot(O)
|
||||
else
|
||||
O.mmi = new /obj/item/device/mmi(O)
|
||||
|
||||
if(O.mmi)
|
||||
O.mmi.transfer_identity(src)
|
||||
O.mmi.transfer_identity(src)
|
||||
|
||||
callHook("borgify", list(O))
|
||||
O.notify_ai(1)
|
||||
|
||||
@@ -1168,7 +1168,7 @@ obj/item/weapon/organ/head/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
|
||||
//TODO: ORGAN REMOVAL UPDATE.
|
||||
if(istype(src,/obj/item/weapon/organ/head/posi))
|
||||
var/obj/item/device/mmi/posibrain/B = new(loc)
|
||||
var/obj/item/device/mmi/digital/posibrain/B = new(loc)
|
||||
B.transfer_identity(brainmob)
|
||||
else
|
||||
var/obj/item/organ/brain/B = new(loc)
|
||||
|
||||
@@ -604,7 +604,7 @@ datum/design/posibrain
|
||||
|
||||
build_type = PROTOLATHE
|
||||
materials = list("$metal" = 2000, "$glass" = 1000, "$silver" = 1000, "$gold" = 500, "$phoron" = 500, "$diamond" = 100)
|
||||
build_path = /obj/item/device/mmi/posibrain
|
||||
build_path = /obj/item/device/mmi/digital/posibrain
|
||||
|
||||
///////////////////////////////////
|
||||
//////////Mecha Module Disks///////
|
||||
|
||||
Reference in New Issue
Block a user