mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
-When a pAI Card is deleted it will now kill the pAI mob inside. This is to stop people from being able to respawn by having their pAI destroyed in a singularity.
-Added a new wire to Cyborgs. The Camera wire allows you to disable the Cyborg's camera. It will show on Security Consoles as "Cyborg-155 (deactivated)". Pulsing it provides you and the Cyborg with a message of the Cyborg's camera focusing loudly. It will also kick anyone who is watching the Cyborg's camera out. -Traitor Cyborgs, when scrambling their codes, now have a completely disabled camera. It will not show up on Security Consoles at all, even as deactivated. -Added a new small guide for new Cyborgs. It is similar to the AI's with some more useful information specific to Cyborgs. -Commented out the old message, it was copy+pasted everywhere. -Changed RandomBorgWires to not rely on lucking out and landing on a previously unused index. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4089 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -47,7 +47,7 @@
|
||||
var/datum/effect/effect/system/ion_trail_follow/ion_trail = null
|
||||
var/datum/effect/effect/system/spark_spread/spark_system//So they can initialize sparks whenever/N
|
||||
var/jeton = 0
|
||||
var/borgwires = 15
|
||||
var/borgwires = 31 // 0b11111
|
||||
var/killswitch = 0
|
||||
var/killswitch_time = 60
|
||||
var/weapon_lock = 0
|
||||
|
||||
@@ -11,11 +11,17 @@
|
||||
var/looking_for_personality = 0
|
||||
var/mob/living/silicon/pai/pai
|
||||
|
||||
New()
|
||||
/obj/item/device/paicard/New()
|
||||
..()
|
||||
overlays += "pai-off"
|
||||
|
||||
attack_self(mob/user)
|
||||
/obj/item/device/paicard/Del()
|
||||
//Will stop people throwing friend pAIs into the singularity so they can respawn
|
||||
if(!isnull(pai))
|
||||
pai.death(0)
|
||||
..()
|
||||
|
||||
/obj/item/device/paicard/attack_self(mob/user)
|
||||
if (!in_range(src, user))
|
||||
return
|
||||
user.machine = src
|
||||
@@ -50,7 +56,7 @@
|
||||
onclose(user, "paicard")
|
||||
return
|
||||
|
||||
Topic(href, href_list)
|
||||
/obj/item/device/paicard/Topic(href, href_list)
|
||||
|
||||
if(href_list["setdna"])
|
||||
if(pai.master_dna)
|
||||
@@ -95,16 +101,16 @@
|
||||
// WIRE_RECEIVE = 2
|
||||
// WIRE_TRANSMIT = 4
|
||||
|
||||
proc/setPersonality(mob/living/silicon/pai/personality)
|
||||
/obj/item/device/paicard/proc/setPersonality(mob/living/silicon/pai/personality)
|
||||
src.pai = personality
|
||||
src.overlays += "pai-happy"
|
||||
|
||||
proc/removePersonality()
|
||||
/obj/item/device/paicard/proc/removePersonality()
|
||||
src.pai = null
|
||||
src.overlays = null
|
||||
src.overlays += "pai-off"
|
||||
|
||||
proc/setEmotion(var/emotion)
|
||||
/obj/item/device/paicard/proc/setEmotion(var/emotion)
|
||||
if(pai)
|
||||
src.overlays = null
|
||||
switch(emotion)
|
||||
@@ -118,12 +124,13 @@
|
||||
if(8) src.overlays += "pai-angry"
|
||||
if(9) src.overlays += "pai-what"
|
||||
|
||||
proc/alertUpdate()
|
||||
/obj/item/device/paicard/proc/alertUpdate()
|
||||
var/turf/T = get_turf_or_move(src.loc)
|
||||
for (var/mob/M in viewers(T))
|
||||
M.show_message("\blue [src] flashes a message across its screen, \"Additional personalities available for download.\"", 3, "\blue [src] bleeps electronically.", 2)
|
||||
|
||||
emp_act(severity)
|
||||
/obj/item/device/paicard/emp_act(severity)
|
||||
for(var/mob/M in src)
|
||||
M.emp_act(severity)
|
||||
..()
|
||||
|
||||
|
||||
@@ -204,10 +204,10 @@
|
||||
if(O.mind && O.mind.special_role)
|
||||
O.mind.store_memory("In case you look at this after being borged, the objectives are only here until I find a way to make them not show up for you, as I can't simply delete them without screwing up round-end reporting. --NeoFite")
|
||||
|
||||
O << "<B>You are playing a Cyborg. The Cyborg can interact with most electronic objects in its view point.</B>"
|
||||
O << "<B>You must follow the laws that the AI has. You must follow orders the AI gives you.</B>"
|
||||
O << "To use something, simply click on it."
|
||||
O << {"Use say ":s to speak to fellow cyborgs and the AI through binary."}
|
||||
//O << "<B>You are playing a Cyborg. The Cyborg can interact with most electronic objects in its view point.</B>"
|
||||
//O << "<B>You must follow the laws that the AI has. You must follow orders the AI gives you.</B>"
|
||||
//O << "To use something, simply click on it."
|
||||
//O << {"Use say ":s to speak to fellow cyborgs and the AI through binary."}
|
||||
|
||||
O.job = "Cyborg"
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
update_canmove()
|
||||
|
||||
tension_master.death(src)
|
||||
|
||||
if(camera)
|
||||
camera.status = 0
|
||||
|
||||
if(in_contents_of(/obj/machinery/recharge_station))//exit the recharge station
|
||||
|
||||
@@ -76,10 +76,11 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
if(camera)
|
||||
src.camera.status = 1//bluh bluh ugly fix but it will work till this whole thing gets recoded
|
||||
if(src.stat)
|
||||
if(src.camera && !scrambledcodes)
|
||||
if(src.stat == 2 || isWireCut(5))
|
||||
src.camera.status = 0
|
||||
else
|
||||
src.camera.status = 1
|
||||
|
||||
health = 200 - (getOxyLoss() + getFireLoss() + getBruteLoss())
|
||||
|
||||
|
||||
@@ -41,9 +41,12 @@
|
||||
modtype = "Synd"
|
||||
|
||||
radio = new /obj/item/device/radio(src)
|
||||
if(!scrambledcodes)
|
||||
camera = new /obj/machinery/camera(src)
|
||||
camera.c_tag = real_name
|
||||
camera.network = "SS13"
|
||||
if(isWireCut(5)) // 5 = BORG CAMERA
|
||||
camera.status = 0
|
||||
if(!cell)
|
||||
var/obj/item/weapon/cell/C = new(src)
|
||||
C.charge = 1500
|
||||
|
||||
@@ -15,6 +15,12 @@
|
||||
ident = rand(1, 999)
|
||||
real_name += "-[ident]"
|
||||
name = real_name
|
||||
src << "<B>You are playing a Cyborg. You can move around and remotely interact with the machines around you.</B>"
|
||||
src << "<B>You can use things such as computers, APCs, intercoms, doors, etc. To use something, simply click on it.</B>"
|
||||
src << "<B>As a new Cyborg you can choose your class. Each class have different modules that help them perform their duties.</B>"
|
||||
src << "<B>Remember that you have a limited charge and the more modules you have active the more power you will drain.</B>"
|
||||
src << "<B>Finally, you are loyal to your linked AI. You should obey all orders of the linked AI as long as it does not conflict with your laws.</B>"
|
||||
src << "Use say :s to speak to your fellow machines through binary."
|
||||
|
||||
spawn (4)
|
||||
if(!syndie)
|
||||
@@ -44,6 +50,7 @@
|
||||
modtype = "Synd"
|
||||
|
||||
radio = new /obj/item/device/radio(src)
|
||||
if(!scrambledcodes)
|
||||
camera = new /obj/machinery/camera(src)
|
||||
camera.c_tag = real_name
|
||||
camera.network = "SS13"
|
||||
@@ -963,17 +970,24 @@ Frequency:
|
||||
lockcharge = 0
|
||||
canmove = 1
|
||||
scrambledcodes = 1
|
||||
|
||||
//Disconnect it's camera so it's not so easily tracked.
|
||||
if(src.camera)
|
||||
del(src.camera)
|
||||
src.camera = null
|
||||
// I'm trying to get the Cyborg to not be listed in the camera list
|
||||
// Instead of being listed as "deactivated". The downside is that I'm going
|
||||
// to have to check if every camera is null or not before doing anything, to prevent runtime errors.
|
||||
// I could change the network to null but I don't know what would happen, and it seems too hacky for me.
|
||||
|
||||
|
||||
/mob/living/silicon/robot/proc/ResetSecurityCodes()
|
||||
set category = "Robot Commands"
|
||||
set name = "Reset Identity Codes"
|
||||
set desc = "Scrambles your security and identification codes and resets your current buffers. Unlocks you and but permenantly severs you from your AI and the robotics console."
|
||||
set desc = "Scrambles your security and identification codes and resets your current buffers. Unlocks you and but permenantly severs you from your AI and the robotics console and will deactivate your camera system."
|
||||
|
||||
var/mob/living/silicon/robot/R = usr
|
||||
|
||||
if(R)
|
||||
R.UnlinkSelf()
|
||||
R << "Buffers flushed and reset. All systems operational."
|
||||
R << "Buffers flushed and reset. Camera system shutdown. All systems operational."
|
||||
src.verbs -= /mob/living/silicon/robot/proc/ResetSecurityCodes
|
||||
@@ -2,24 +2,26 @@
|
||||
#define BORG_WIRE_MAIN_POWER1 2
|
||||
#define BORG_WIRE_MAIN_POWER2 3
|
||||
#define BORG_WIRE_AI_CONTROL 4
|
||||
#define BORG_WIRE_CAMERA 5
|
||||
|
||||
/proc/RandomBorgWires()
|
||||
//to make this not randomize the wires, just set index to 1 and increment it in the flag for loop (after doing everything else).
|
||||
var/list/Borgwires = list(0, 0, 0, 0)
|
||||
BorgIndexToFlag = list(0, 0, 0, 0)
|
||||
BorgIndexToWireColor = list(0, 0, 0, 0)
|
||||
BorgWireColorToIndex = list(0, 0, 0, 0)
|
||||
var/list/Borgwires = list(0, 0, 0, 0, 0)
|
||||
BorgIndexToFlag = list(0, 0, 0, 0, 0)
|
||||
BorgIndexToWireColor = list(0, 0, 0, 0, 0)
|
||||
BorgWireColorToIndex = list(0, 0, 0, 0, 0)
|
||||
var/flagIndex = 1
|
||||
for (var/flag=1, flag<16, flag+=flag)
|
||||
var/valid = 0
|
||||
while (!valid)
|
||||
var/colorIndex = rand(1, 4)
|
||||
//I think it's easier to read this way, also doesn't rely on the random number generator to land on a new wire.
|
||||
var/list/colorIndexList = list(BORG_WIRE_LAWCHECK, BORG_WIRE_MAIN_POWER1, BORG_WIRE_MAIN_POWER2, BORG_WIRE_AI_CONTROL, BORG_WIRE_CAMERA)
|
||||
for (var/flag=1, flag<=16, flag+=flag)
|
||||
var/colorIndex = pick(colorIndexList)
|
||||
if (Borgwires[colorIndex]==0)
|
||||
valid = 1
|
||||
Borgwires[colorIndex] = flag
|
||||
BorgIndexToFlag[flagIndex] = flag
|
||||
BorgIndexToWireColor[flagIndex] = colorIndex
|
||||
BorgWireColorToIndex[colorIndex] = flagIndex
|
||||
colorIndexList -= colorIndex // Shortens the list.
|
||||
//world.log << "Flag: [flag], CIndex: [colorIndex], FIndex: [flagIndex]"
|
||||
flagIndex+=1
|
||||
return Borgwires
|
||||
|
||||
@@ -43,6 +45,11 @@
|
||||
if (BORG_WIRE_AI_CONTROL) //Cut the AI wire to reset AI control
|
||||
if (src.connected_ai)
|
||||
src.connected_ai = null
|
||||
if (BORG_WIRE_CAMERA)
|
||||
if(!isnull(src.camera) && !scrambledcodes)
|
||||
src.camera.status = 0
|
||||
src.camera.deactivate(usr, 0) // Will kick anyone who is watching the Cyborg's camera.
|
||||
|
||||
src.interact(usr)
|
||||
|
||||
/mob/living/silicon/robot/proc/mend(var/wireColor)
|
||||
@@ -53,6 +60,10 @@
|
||||
if(BORG_WIRE_LAWCHECK) //turns law updates back on assuming the borg hasn't been emagged
|
||||
if (src.lawupdate == 0 && !src.emagged)
|
||||
src.lawupdate = 1
|
||||
if(BORG_WIRE_CAMERA)
|
||||
if (!isnull(src.camera) && !scrambledcodes)
|
||||
src.camera.status = 1
|
||||
|
||||
src.interact(usr)
|
||||
|
||||
|
||||
@@ -63,9 +74,16 @@
|
||||
if (src.lawupdate)
|
||||
src.lawsync()
|
||||
|
||||
if (BORG_WIRE_AI_CONTROL) //pule the AI wire to make the borg reselect an AI
|
||||
if (BORG_WIRE_AI_CONTROL) //pulse the AI wire to make the borg reselect an AI
|
||||
if(!src.emagged)
|
||||
src.connected_ai = activeais()
|
||||
|
||||
if (BORG_WIRE_CAMERA)
|
||||
if(!isnull(src.camera) && src.camera.status && !scrambledcodes)
|
||||
src.camera.deactivate(usr, 0) // Kick anyone watching the Cyborg's camera, doesn't display you disconnecting the camera.
|
||||
usr << "[src]'s camera lens focuses loudly."
|
||||
src << "Your camera lens focuses loudly."
|
||||
|
||||
src.interact(usr)
|
||||
|
||||
/mob/living/silicon/robot/proc/interact(mob/user)
|
||||
@@ -77,6 +95,7 @@
|
||||
"Dark red" = 2,
|
||||
"White" = 3,
|
||||
"Yellow" = 4,
|
||||
"Blue" = 5,
|
||||
)
|
||||
for(var/wiredesc in Borgwires)
|
||||
var/is_uncut = src.borgwires & BorgWireColorToFlag[Borgwires[wiredesc]]
|
||||
@@ -88,6 +107,7 @@
|
||||
t1 += "<a href='?src=\ref[src];pulse=[Borgwires[wiredesc]]'>Pulse</a> "
|
||||
t1 += "<br>"
|
||||
t1 += text("<br>\n[(src.lawupdate ? "The LawSync light is on." : "The LawSync light is off.")]<br>\n[(src.connected_ai ? "The AI link light is on." : "The AI link light is off.")]")
|
||||
t1 += text("<br>\n[((!isnull(src.camera) && src.camera.status == 1) ? "The Camera light is on." : "The Camera light is off.")]<br>\n")
|
||||
t1 += text("<p><a href='?src=\ref[src];close2=1'>Close</a></p>\n")
|
||||
user << browse(t1, "window=borgwires")
|
||||
onclose(user, "borgwires")
|
||||
@@ -119,3 +139,9 @@
|
||||
usr << browse(null, "window=borgwires")
|
||||
usr.machine = null
|
||||
return
|
||||
|
||||
#undef BORG_WIRE_LAWCHECK
|
||||
#undef BORG_WIRE_MAIN_POWER1
|
||||
#undef BORG_WIRE_MAIN_POWER2
|
||||
#undef BORG_WIRE_AI_CONTROL
|
||||
#undef BORG_WIRE_CAMERA
|
||||
@@ -198,10 +198,10 @@
|
||||
ticker.minds += O.mind//Adds them to regular mind list.
|
||||
|
||||
O.loc = loc
|
||||
O << "<B>You are playing a Cyborg. A Cyborg can interact with most electronic objects in its view point.</B>"
|
||||
O << "<B>You must follow the laws that the AI has. You must follow orders the AI gives you.</B>"
|
||||
O << "To use something, simply click on it."
|
||||
O << {"Use say ":s to speak to fellow cyborgs and the AI through binary."}
|
||||
//O << "<B>You are playing a Cyborg. A Cyborg can interact with most electronic objects in its view point.</B>"
|
||||
//O << "<B>You must follow the laws that the AI has. You must follow orders the AI gives you.</B>"
|
||||
//O << "To use something, simply click on it."
|
||||
//O << {"Use say ":s to speak to fellow cyborgs and the AI through binary."}
|
||||
|
||||
O.job = "Cyborg"
|
||||
|
||||
|
||||
@@ -83,10 +83,10 @@
|
||||
ticker.minds += O.mind//Adds them to regular mind list.
|
||||
|
||||
O.loc = loc
|
||||
O << "<B>You are playing a Cyborg. A Cyborg can interact with most electronic objects in its view point.</B>"
|
||||
O << "<B>You must follow the laws that the AI has. You must follow orders the AI gives you.</B>"
|
||||
O << "To use something, simply click on it."
|
||||
O << {"Use say ":s to speak to fellow cyborgs and the AI through binary."}
|
||||
//O << "<B>You are playing a Cyborg. A Cyborg can interact with most electronic objects in its view point.</B>"
|
||||
//O << "<B>You must follow the laws that the AI has. You must follow orders the AI gives you.</B>"
|
||||
//O << "To use something, simply click on it."
|
||||
//O << {"Use say ":s to speak to fellow cyborgs and the AI through binary."}
|
||||
|
||||
O.job = "Cyborg"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user