mob living silicon

This commit is contained in:
deathride58
2018-01-04 01:06:25 -05:00
parent 4957aa3cb0
commit 66f0a9c2b7
9 changed files with 104 additions and 87 deletions
+24 -24
View File
@@ -1,26 +1,26 @@
/mob/living/silicon/ai/examine(mob/user)
/mob/living/silicon/ai/examine(mob/user)
var/msg = "<span class='info'>*---------*\nThis is [icon2html(src, user)] <EM>[src]</EM>!\n"
if (stat == DEAD)
msg += "<span class='deadsay'>It appears to be powered-down.</span>\n"
else
msg += "<span class='warning'>"
if (getBruteLoss())
if (getBruteLoss() < 30)
msg += "It looks slightly dented.\n"
else
msg += "<B>It looks severely dented!</B>\n"
if (getFireLoss())
if (getFireLoss() < 30)
msg += "It looks slightly charred.\n"
else
msg += "<B>Its casing is melted and heat-warped!</B>\n"
msg += "</span>"
if(deployed_shell)
msg += "The wireless networking light is blinking.\n"
else if (!shunted && !client)
msg += "[src]Core.exe has stopped responding! NTOS is searching for a solution to the problem...\n"
msg += "*---------*</span>"
to_chat(user, msg)
if (stat == DEAD)
msg += "<span class='deadsay'>It appears to be powered-down.</span>\n"
else
msg += "<span class='warning'>"
if (getBruteLoss())
if (getBruteLoss() < 30)
msg += "It looks slightly dented.\n"
else
msg += "<B>It looks severely dented!</B>\n"
if (getFireLoss())
if (getFireLoss() < 30)
msg += "It looks slightly charred.\n"
else
msg += "<B>Its casing is melted and heat-warped!</B>\n"
msg += "</span>"
if(deployed_shell)
msg += "The wireless networking light is blinking.\n"
else if (!shunted && !client)
msg += "[src]Core.exe has stopped responding! NTOS is searching for a solution to the problem...\n"
msg += "*---------*</span>"
to_chat(user, msg)
..()
@@ -173,4 +173,4 @@
obscured += t.obscured
#undef UPDATE_BUFFER
#undef CHUNK_SIZE
#undef CHUNK_SIZE
@@ -16,7 +16,6 @@
// It will also stream the chunk that the new loc is in.
/mob/camera/aiEye/proc/setLoc(T)
if(ai)
if(!isturf(ai.loc))
return
@@ -34,6 +33,8 @@
if(istype(ai.current, /obj/machinery/holopad))
var/obj/machinery/holopad/H = ai.current
H.move_hologram(ai, T)
if(ai.camera_light_on)
ai.light_cameras()
/mob/camera/aiEye/Move()
return 0
@@ -85,11 +86,6 @@
if(!user.tracking)
user.cameraFollow = null
//user.unset_machine() //Uncomment this if it causes problems.
//user.lightNearbyCamera()
if(user.camera_light_on)
user.light_cameras()
// Return to the Core.
/mob/living/silicon/ai/proc/view_core()
+11 -11
View File
@@ -1,13 +1,13 @@
/mob/living/silicon/spawn_gibs()
/mob/living/silicon/spawn_gibs()
new /obj/effect/gibspawner/robot(get_turf(src))
/mob/living/silicon/spawn_dust()
new /obj/effect/decal/remains/robot(loc)
/mob/living/silicon/death(gibbed)
if(!gibbed)
emote("deathgasp")
diag_hud_set_status()
diag_hud_set_health()
update_health_hud()
/mob/living/silicon/spawn_dust()
new /obj/effect/decal/remains/robot(loc)
/mob/living/silicon/death(gibbed)
if(!gibbed)
emote("deathgasp")
diag_hud_set_status()
diag_hud_set_health()
update_health_hud()
. = ..()
+2 -2
View File
@@ -52,7 +52,7 @@
var/obj/machinery/door/hackdoor // The airlock being hacked
var/hackprogress = 0 // Possible values: 0 - 100, >= 100 means the hack is complete and will be reset upon next check
var/obj/item/radio/integrated/signal/sradio // AI's signaller
var/obj/item/integrated_signaler/signaler // AI's signaller
var/holoform = FALSE
var/canholo = TRUE
@@ -105,7 +105,7 @@
P.setPersonality(src)
forceMove(P)
card = P
sradio = new(src)
signaler = new(src)
if(!radio)
radio = new /obj/item/device/radio(src)
+10 -13
View File
@@ -169,23 +169,20 @@
if("signaller")
if(href_list["send"])
sradio.send_signal("ACTIVATE")
signaler.send_activation()
audible_message("[icon2html(src, world)] *beep* *beep*")
if(href_list["freq"])
var/new_frequency = (sradio.frequency + text2num(href_list["freq"]))
if(new_frequency < 1200 || new_frequency > 1600)
var/new_frequency = (signaler.frequency + text2num(href_list["freq"]))
if(new_frequency < MIN_FREE_FREQ || new_frequency > MAX_FREE_FREQ)
new_frequency = sanitize_frequency(new_frequency)
sradio.set_frequency(new_frequency)
signaler.set_frequency(new_frequency)
if(href_list["code"])
sradio.code += text2num(href_list["code"])
sradio.code = round(sradio.code)
sradio.code = min(100, sradio.code)
sradio.code = max(1, sradio.code)
signaler.code += text2num(href_list["code"])
signaler.code = round(signaler.code)
signaler.code = min(100, signaler.code)
signaler.code = max(1, signaler.code)
@@ -397,14 +394,14 @@
Frequency:
<A href='byond://?src=[REF(src)];software=signaller;freq=-10;'>-</A>
<A href='byond://?src=[REF(src)];software=signaller;freq=-2'>-</A>
[format_frequency(sradio.frequency)]
[format_frequency(signaler.frequency)]
<A href='byond://?src=[REF(src)];software=signaller;freq=2'>+</A>
<A href='byond://?src=[REF(src)];software=signaller;freq=10'>+</A><BR>
Code:
<A href='byond://?src=[REF(src)];software=signaller;code=-5'>-</A>
<A href='byond://?src=[REF(src)];software=signaller;code=-1'>-</A>
[sradio.code]
[signaler.code]
<A href='byond://?src=[REF(src)];software=signaller;code=1'>+</A>
<A href='byond://?src=[REF(src)];software=signaller;code=5'>+</A><BR>
@@ -1,3 +1,4 @@
/mob/living/silicon/robot/Login()
..()
regenerate_icons()
+20 -17
View File
@@ -5,8 +5,6 @@
icon_state = "robot"
maxHealth = 100
health = 100
macro_default = "robot-default"
macro_hotkeys = "robot-hotkeys"
bubble_icon = "robot"
designation = "Default" //used for displaying the prefix & getting the current module of cyborg
has_limbs = 1
@@ -247,17 +245,6 @@
return //won't work if dead
robot_alerts()
//for borg hotkeys, here module refers to borg inv slot, not core module
/mob/living/silicon/robot/verb/cmd_toggle_module(module as num)
set name = "Toggle Module"
set hidden = 1
toggle_module(module)
/mob/living/silicon/robot/verb/cmd_unequip_module()
set name = "Unequip Module"
set hidden = 1
uneq_active()
/mob/living/silicon/robot/proc/robot_alerts()
var/dat = ""
for (var/cat in alarms)
@@ -536,6 +523,19 @@
toner = tonermax
qdel(W)
to_chat(user, "<span class='notice'>You fill the toner level of [src] to its max capacity.</span>")
else if(istype(W, /obj/item/device/flashlight))
if(!opened)
to_chat(user, "<span class='warning'>You need to open the panel to repair the headlamp!</span>")
if(lamp_cooldown <= world.time)
to_chat(user, "<span class='warning'>The headlamp is already functional!</span>")
else
if(!user.temporarilyRemoveItemFromInventory(W))
to_chat(user, "<span class='warning'>[W] seems to be stuck to your hand. You'll have to find a different light.</span>")
return
lamp_cooldown = 0
qdel(W)
to_chat(user, "<span class='notice'>You replace the headlamp bulbs.</span>")
else
return ..()
@@ -812,6 +812,9 @@
/mob/living/silicon/robot/modules/security
set_module = /obj/item/robot_module/security
/mob/living/silicon/robot/modules/clown
set_module = /obj/item/robot_module/clown
/mob/living/silicon/robot/modules/peacekeeper
set_module = /obj/item/robot_module/peacekeeper
@@ -829,7 +832,7 @@
lawupdate = FALSE
scrambledcodes = TRUE // These are rogue borgs.
ionpulse = TRUE
var/playstyle_string = "<span class='userdanger'>You are a Syndicate assault cyborg!</span><br>\
var/playstyle_string = "<span class='big bold'>You are a Syndicate assault cyborg!</span><br>\
<b>You are armed with powerful offensive tools to aid you in your mission: help the operatives secure the nuclear authentication disk. \
Your cyborg LMG will slowly produce ammunition from your power supply, and your operative pinpointer will find and locate fellow nuclear operatives. \
<i>Help the operatives secure the disk at all costs!</i></b>"
@@ -851,7 +854,7 @@
/mob/living/silicon/robot/modules/syndicate/medical
icon_state = "syndi-medi"
playstyle_string = "<span class='userdanger'>You are a Syndicate medical cyborg!</span><br>\
playstyle_string = "<span class='big bold'>You are a Syndicate medical cyborg!</span><br>\
<b>You are armed with powerful medical tools to aid you in your mission: help the operatives secure the nuclear authentication disk. \
Your hypospray will produce Restorative Nanites, a wonder-drug that will heal most types of bodily damages, including clone and brain damage. It also produces morphine for offense. \
Your defibrillator paddles can revive operatives through their hardsuits, or can be used on harm intent to shock enemies! \
@@ -1015,9 +1018,9 @@
status_flags &= ~CANPUSH
if(module.clean_on_move)
flags_1 |= CLEAN_ON_MOVE_1
AddComponent(/datum/component/cleaning)
else
flags_1 &= ~CLEAN_ON_MOVE_1
qdel(GetComponent(/datum/component/cleaning))
hat_offset = module.hat_offset
@@ -33,8 +33,8 @@
var/ride_allow_incapacitated = FALSE
var/allow_riding = TRUE
/obj/item/robot_module/New()
..()
/obj/item/robot_module/Initialize()
. = ..()
for(var/i in basic_modules)
var/obj/item/I = new i(src)
basic_modules += I
@@ -336,17 +336,6 @@
can_be_pushed = FALSE
hat_offset = 3
/obj/item/robot_module/security/respawn_consumable(mob/living/silicon/robot/R, coeff = 1)
..()
var/obj/item/gun/energy/e_gun/advtaser/cyborg/T = locate(/obj/item/gun/energy/e_gun/advtaser/cyborg) in basic_modules
if(T)
if(T.cell.charge < T.cell.maxcharge)
var/obj/item/ammo_casing/energy/S = T.ammo_type[T.select]
T.cell.give(S.e_cost * coeff)
T.update_icon()
else
T.charge_tick = 0
/obj/item/robot_module/security/do_transform_animation()
..()
to_chat(loc, "<span class='userdanger'>While you have picked the security module, you still have to follow your laws, NOT Space Law. \
@@ -435,6 +424,37 @@
if(CL)
CL.reagents.add_reagent("lube", 2 * coeff)
/obj/item/robot_module/clown
name = "Clown"
basic_modules = list(
/obj/item/device/assembly/flash/cyborg,
/obj/item/toy/crayon/rainbow,
/obj/item/device/instrument/bikehorn,
/obj/item/stamp/clown,
/obj/item/bikehorn,
/obj/item/bikehorn/airhorn,
/obj/item/paint/anycolor,
/obj/item/soap/nanotrasen,
/obj/item/pneumatic_cannon/pie/selfcharge/cyborg,
/obj/item/razor, //killbait material
/obj/item/lipstick/purple,
/obj/item/reagent_containers/spray/waterflower/cyborg,
/obj/item/borg/cyborghug/peacekeeper,
/obj/item/borg/lollipop/clown,
/obj/item/picket_sign/cyborg,
/obj/item/reagent_containers/borghypo/clown,
/obj/item/extinguisher/mini)
emag_modules = list(
/obj/item/reagent_containers/borghypo/clown/hacked,
/obj/item/reagent_containers/spray/waterflower/cyborg/hacked)
ratvar_modules = list(
/obj/item/clockwork/slab/cyborg,
/obj/item/clockwork/weapon/ratvarian_spear,
/obj/item/clockwork/replica_fabricator/cyborg)
moduleselect_icon = "service"
cyborg_base_icon = "clown"
hat_offset = -2
/obj/item/robot_module/butler
name = "Service"
basic_modules = list(