mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-21 02:57:48 +01:00
Merge branch 'master' of https://github.com/ParadiseSS13/Paradise into lavaland_megafauna
# Conflicts: # code/modules/mob/living/carbon/human/species/station.dm # icons/mob/screen_alert.dmi
This commit is contained in:
@@ -226,6 +226,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
if(client.statpanel == "Status")
|
||||
show_stat_station_time()
|
||||
show_stat_emergency_shuttle_eta()
|
||||
stat(null, "Respawnability: [(src in respawnable_list) ? "Yes" : "No"]")
|
||||
|
||||
/mob/dead/observer/verb/reenter_corpse()
|
||||
set category = "Ghost"
|
||||
@@ -667,4 +668,4 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
mind.active = 1
|
||||
mind.transfer_to(new_char)
|
||||
else
|
||||
new_char.key = key
|
||||
new_char.key = key
|
||||
|
||||
@@ -34,12 +34,12 @@
|
||||
/mob/living/carbon/Move(NewLoc, direct)
|
||||
. = ..()
|
||||
if(.)
|
||||
if(src.nutrition && src.stat != 2)
|
||||
src.nutrition -= HUNGER_FACTOR/10
|
||||
if(src.m_intent == "run")
|
||||
src.nutrition -= HUNGER_FACTOR/10
|
||||
if((FAT in src.mutations) && src.m_intent == "run" && src.bodytemperature <= 360)
|
||||
src.bodytemperature += 2
|
||||
if(nutrition && stat != DEAD)
|
||||
nutrition -= HUNGER_FACTOR/10
|
||||
if(m_intent == "run")
|
||||
nutrition -= HUNGER_FACTOR/10
|
||||
if((FAT in mutations) && m_intent == "run" && bodytemperature <= 360)
|
||||
bodytemperature += 2
|
||||
|
||||
// Moving around increases germ_level faster
|
||||
if(germ_level < GERM_LEVEL_MOVE_CAP && prob(8))
|
||||
@@ -939,9 +939,10 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
|
||||
/mob/living/carbon/proc/eat(var/obj/item/weapon/reagent_containers/food/toEat, mob/user)
|
||||
if(!istype(toEat))
|
||||
return 0
|
||||
var/fullness = 0
|
||||
var/fullness = nutrition + 10
|
||||
if(istype(toEat, /obj/item/weapon/reagent_containers/food/snacks))
|
||||
fullness = nutrition + (reagents.get_reagent_amount("nutriment") * 20) + (reagents.get_reagent_amount("protein") * 25) + (reagents.get_reagent_amount("plantmatter") * 25)
|
||||
for(var/datum/reagent/consumable/C in reagents.reagent_list) //we add the nutrition value of what we're currently digesting
|
||||
fullness += C.nutriment_factor * C.volume / C.metabolization_rate
|
||||
if(user == src)
|
||||
if(istype(toEat, /obj/item/weapon/reagent_containers/food/drinks))
|
||||
if(!selfDrink(toEat))
|
||||
@@ -960,15 +961,18 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
|
||||
if(istype(toEat, /obj/item/weapon/reagent_containers/food/pill))
|
||||
to_chat(src, "<span class='notify'>You [toEat.apply_method] [toEat].</span>")
|
||||
else
|
||||
if(toEat.junkiness && satiety < -150 && nutrition > NUTRITION_LEVEL_STARVING + 50 )
|
||||
to_chat(src, "<span class='notice'>You don't feel like eating any more junk food at the moment.</span>")
|
||||
return 0
|
||||
if(fullness <= 50)
|
||||
to_chat(src, "<span class='warning'>You hungrily chew out a piece of [toEat] and gobble it!</span>")
|
||||
else if(fullness > 50 && fullness <= 150)
|
||||
else if(fullness > 50 && fullness < 150)
|
||||
to_chat(src, "<span class='notice'>You hungrily begin to eat [toEat].</span>")
|
||||
else if(fullness > 150 && fullness <= 350)
|
||||
else if(fullness > 150 && fullness < 500)
|
||||
to_chat(src, "<span class='notice'>You take a bite of [toEat].</span>")
|
||||
else if(fullness > 350 && fullness <= 550)
|
||||
else if(fullness > 500 && fullness < 600)
|
||||
to_chat(src, "<span class='notice'>You unwillingly chew a bit of [toEat].</span>")
|
||||
else if(fullness > (550 * (1 + overeatduration / 2000))) // The more you eat - the more you can eat
|
||||
else if(fullness > (600 * (1 + overeatduration / 2000))) // The more you eat - the more you can eat
|
||||
to_chat(src, "<span class='warning'>You cannot force any more of [toEat] to go down your throat.</span>")
|
||||
return 0
|
||||
return 1
|
||||
@@ -977,7 +981,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
|
||||
return 1
|
||||
|
||||
/mob/living/carbon/proc/forceFed(var/obj/item/weapon/reagent_containers/food/toEat, mob/user, fullness)
|
||||
if(fullness <= (550 * (1 + overeatduration / 1000)))
|
||||
if(fullness <= (600 * (1 + overeatduration / 1000)))
|
||||
if(!toEat.instant_application)
|
||||
visible_message("<span class='warning'>[user] attempts to force [src] to [toEat.apply_method] [toEat].</span>")
|
||||
else
|
||||
@@ -1005,15 +1009,14 @@ so that different stomachs can handle things in different ways VB*/
|
||||
/mob/living/carbon/proc/consume(var/obj/item/weapon/reagent_containers/food/toEat)
|
||||
if(!toEat.reagents)
|
||||
return
|
||||
if(satiety > -200)
|
||||
satiety -= toEat.junkiness
|
||||
if(toEat.consume_sound)
|
||||
playsound(loc, toEat.consume_sound, rand(10,50), 1)
|
||||
if(toEat.reagents.total_volume)
|
||||
toEat.reagents.reaction(src, toEat.apply_type)
|
||||
spawn(0)
|
||||
if(toEat.reagents.total_volume > toEat.bitesize)
|
||||
toEat.reagents.trans_to(src, toEat.bitesize*toEat.transfer_efficiency)
|
||||
else
|
||||
toEat.reagents.trans_to(src, toEat.reagents.total_volume*toEat.transfer_efficiency)
|
||||
var/fraction = min(toEat.bitesize/toEat.reagents.total_volume, 1)
|
||||
toEat.reagents.reaction(src, toEat.apply_type, fraction)
|
||||
toEat.reagents.trans_to(src, toEat.bitesize*toEat.transfer_efficiency)
|
||||
|
||||
/mob/living/carbon/get_access()
|
||||
. = ..()
|
||||
|
||||
@@ -253,10 +253,10 @@
|
||||
if(5)
|
||||
msg += "[t_He] looks absolutely soaked.\n"
|
||||
|
||||
if(nutrition < 100)
|
||||
if(nutrition < NUTRITION_LEVEL_STARVING - 50)
|
||||
msg += "[t_He] [t_is] severely malnourished.\n"
|
||||
else if(nutrition >= 500)
|
||||
if(user.nutrition < 100)
|
||||
else if(nutrition >= NUTRITION_LEVEL_FAT)
|
||||
if(user.nutrition < NUTRITION_LEVEL_STARVING - 50)
|
||||
msg += "[t_He] [t_is] plump and delicious looking - Like a fat little piggy. A tasty piggy.\n"
|
||||
else
|
||||
msg += "[t_He] [t_is] quite chubby.\n"
|
||||
@@ -516,7 +516,7 @@
|
||||
return istype(H.glasses, /obj/item/clothing/glasses/hud/health) || istype(H.glasses, /obj/item/clothing/glasses/hud/health/health_advanced) || istype(CIH,/obj/item/organ/internal/cyberimp/eyes/hud/medical)
|
||||
else
|
||||
return 0
|
||||
else if(istype(M, /mob/living/silicon))
|
||||
else if(isrobot(M) || isAI(M)) //Stand-in/Stopgap to prevent pAIs from freely altering records, pending a more advanced Records system
|
||||
switch(hudtype)
|
||||
if("security")
|
||||
return 1
|
||||
|
||||
@@ -351,9 +351,7 @@ emp_act
|
||||
if(ismob(I.thrower))
|
||||
var/mob/M = I.thrower
|
||||
if(M)
|
||||
src.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been hit with a [I], thrown by [key_name(M)]</font>")
|
||||
M.attack_log += text("\[[time_stamp()]\] <font color='red'>Hit [key_name(src)] with a thrown [I]</font>")
|
||||
msg_admin_attack("[key_name_admin(src)] was hit by a [I], thrown by [key_name_admin(M)]", print_attack_log = I.throwforce)
|
||||
add_logs(M, src, "hit", I, " (thrown)", print_attack_log = I.throwforce)
|
||||
|
||||
//thrown weapon embedded object code.
|
||||
if(dtype == BRUTE && istype(I))
|
||||
|
||||
@@ -442,7 +442,7 @@
|
||||
|
||||
var/static/list/customableTypes = list(/obj/item/weapon/reagent_containers/food/snacks/customizable,/obj/item/weapon/reagent_containers/food/snacks/breadslice,/obj/item/weapon/reagent_containers/food/snacks/bun,/obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough,/obj/item/weapon/reagent_containers/food/snacks/boiledspagetti,/obj/item/trash/plate,/obj/item/trash/bowl)
|
||||
|
||||
var/static/list/rawtypes = list(/obj/item/weapon/reagent_containers/food/snacks/grown, /obj/item/weapon/reagent_containers/food/snacks/rawcutlet, /obj/item/weapon/reagent_containers/food/snacks/rawmeatball, /obj/item/weapon/reagent_containers/food/snacks/rawsticks, /obj/item/weapon/reagent_containers/food/snacks/salmonmeat, /obj/item/weapon/reagent_containers/food/snacks/carpmeat, /obj/item/weapon/reagent_containers/food/snacks/catfishmeat, /obj/item/weapon/reagent_containers/food/snacks/spagetti, /obj/item/weapon/reagent_containers/food/snacks/dough_ball, /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/doughslice, /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/boiledrice, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/raw_bacon)
|
||||
var/static/list/rawtypes = list(/obj/item/weapon/reagent_containers/food/snacks/grown, /obj/item/weapon/reagent_containers/food/snacks/rawcutlet, /obj/item/weapon/reagent_containers/food/snacks/rawsticks, /obj/item/weapon/reagent_containers/food/snacks/salmonmeat, /obj/item/weapon/reagent_containers/food/snacks/carpmeat, /obj/item/weapon/reagent_containers/food/snacks/catfishmeat, /obj/item/weapon/reagent_containers/food/snacks/spagetti, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/doughslice, /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/boiledrice, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/raw_bacon)
|
||||
|
||||
try
|
||||
var/list/allContents = getAllContents()
|
||||
|
||||
@@ -506,17 +506,14 @@
|
||||
//END FIRE CODE
|
||||
|
||||
/mob/living/carbon/human/proc/stabilize_temperature_from_calories()
|
||||
var/body_temperature_difference = species.body_temperature - bodytemperature
|
||||
|
||||
if(bodytemperature <= species.cold_level_1) //260.15 is 310.15 - 50, the temperature where you start to feel effects.
|
||||
if(nutrition >= 2) //If we are very, very cold we'll use up quite a bit of nutriment to heat us up.
|
||||
nutrition -= 2
|
||||
var/body_temperature_difference = species.body_temperature - bodytemperature
|
||||
bodytemperature += max((body_temperature_difference / BODYTEMP_AUTORECOVERY_DIVISOR), BODYTEMP_AUTORECOVERY_MINIMUM)
|
||||
bodytemperature += max((body_temperature_difference * metabolism_efficiency / BODYTEMP_AUTORECOVERY_DIVISOR), BODYTEMP_AUTORECOVERY_MINIMUM)
|
||||
if(bodytemperature >= species.cold_level_1 && bodytemperature <= species.heat_level_1)
|
||||
var/body_temperature_difference = species.body_temperature - bodytemperature
|
||||
bodytemperature += body_temperature_difference / BODYTEMP_AUTORECOVERY_DIVISOR
|
||||
bodytemperature += body_temperature_difference * metabolism_efficiency / BODYTEMP_AUTORECOVERY_DIVISOR
|
||||
if(bodytemperature >= species.heat_level_1) //360.15 is 310.15 + 50, the temperature where you start to feel effects.
|
||||
//We totally need a sweat system cause it totally makes sense...~
|
||||
var/body_temperature_difference = species.body_temperature - bodytemperature
|
||||
bodytemperature += min((body_temperature_difference / BODYTEMP_AUTORECOVERY_DIVISOR), -BODYTEMP_AUTORECOVERY_MINIMUM) //We're dealing with negative numbers
|
||||
|
||||
|
||||
@@ -676,11 +673,20 @@
|
||||
becomeFat()
|
||||
|
||||
// nutrition decrease
|
||||
if(nutrition > 0 && stat != 2)
|
||||
nutrition = max (0, nutrition - HUNGER_FACTOR)
|
||||
if(nutrition > 0 && stat != DEAD)
|
||||
// THEY HUNGER
|
||||
var/hunger_rate = HUNGER_FACTOR
|
||||
if(satiety > 0)
|
||||
satiety--
|
||||
if(satiety < 0)
|
||||
satiety++
|
||||
if(prob(round(-satiety/40)))
|
||||
Jitter(5)
|
||||
hunger_rate = 3 * HUNGER_FACTOR
|
||||
nutrition = max(0, nutrition - hunger_rate)
|
||||
|
||||
if(nutrition > 450)
|
||||
if(overeatduration < 800) //capped so people don't take forever to unfat
|
||||
if(nutrition > NUTRITION_LEVEL_FULL)
|
||||
if(overeatduration < 600) //capped so people don't take forever to unfat
|
||||
overeatduration++
|
||||
|
||||
else
|
||||
@@ -690,6 +696,22 @@
|
||||
else
|
||||
overeatduration -= 2
|
||||
|
||||
//metabolism change
|
||||
if(nutrition > NUTRITION_LEVEL_FAT)
|
||||
metabolism_efficiency = 1
|
||||
else if(nutrition > NUTRITION_LEVEL_FED && satiety > 80)
|
||||
if(metabolism_efficiency != 1.25)
|
||||
to_chat(src, "<span class='notice'>You feel vigorous.</span>")
|
||||
metabolism_efficiency = 1.25
|
||||
else if(nutrition < NUTRITION_LEVEL_STARVING + 50)
|
||||
if(metabolism_efficiency != 0.8)
|
||||
to_chat(src, "<span class='notice'>You feel sluggish.</span>")
|
||||
metabolism_efficiency = 0.8
|
||||
else
|
||||
if(metabolism_efficiency == 1.25)
|
||||
to_chat(src, "<span class='notice'>You no longer feel vigorous.</span>")
|
||||
metabolism_efficiency = 1
|
||||
|
||||
if(drowsyness)
|
||||
AdjustDrowsy(-1)
|
||||
EyeBlurry(2)
|
||||
@@ -932,20 +954,8 @@
|
||||
if(getToxLoss() >= 45 && nutrition > 20)
|
||||
lastpuke ++
|
||||
if(lastpuke >= 25) // about 25 second delay I guess
|
||||
Stun(5)
|
||||
|
||||
visible_message("<span class='danger'>[src] throws up!</span>", \
|
||||
"<span class='userdanger'>[src] throws up!</span>")
|
||||
playsound(loc, 'sound/effects/splat.ogg', 50, 1)
|
||||
|
||||
var/turf/location = loc
|
||||
if(istype(location, /turf/simulated))
|
||||
location.add_vomit_floor(src, 1)
|
||||
|
||||
nutrition -= 20
|
||||
vomit(20, 0, 1, 0, 1)
|
||||
adjustToxLoss(-3)
|
||||
|
||||
// make it so you can only puke so fast
|
||||
lastpuke = 0
|
||||
|
||||
//0.1% chance of playing a scary sound to someone who's in complete darkness
|
||||
|
||||
@@ -559,8 +559,12 @@
|
||||
switch(H.nutrition)
|
||||
if(NUTRITION_LEVEL_FULL to INFINITY)
|
||||
H.throw_alert("nutrition", /obj/screen/alert/fat)
|
||||
if(NUTRITION_LEVEL_HUNGRY to NUTRITION_LEVEL_FULL)
|
||||
H.clear_alert("nutrition")
|
||||
if(NUTRITION_LEVEL_WELL_FED to NUTRITION_LEVEL_FULL)
|
||||
H.throw_alert("nutrition", /obj/screen/alert/full)
|
||||
if(NUTRITION_LEVEL_FED to NUTRITION_LEVEL_WELL_FED)
|
||||
H.throw_alert("nutrition", /obj/screen/alert/well_fed)
|
||||
if(NUTRITION_LEVEL_HUNGRY to NUTRITION_LEVEL_FED)
|
||||
H.throw_alert("nutrition", /obj/screen/alert/fed)
|
||||
if(NUTRITION_LEVEL_STARVING to NUTRITION_LEVEL_HUNGRY)
|
||||
H.throw_alert("nutrition", /obj/screen/alert/hungry)
|
||||
else
|
||||
|
||||
@@ -817,8 +817,8 @@
|
||||
H.nutrition += light_amount
|
||||
H.traumatic_shock -= light_amount
|
||||
|
||||
if(H.nutrition > 450)
|
||||
H.nutrition = 450
|
||||
if(H.nutrition > NUTRITION_LEVEL_WELL_FED)
|
||||
H.nutrition = NUTRITION_LEVEL_WELL_FED
|
||||
|
||||
if(light_amount > 0)
|
||||
H.clear_alert("nolight")
|
||||
|
||||
@@ -345,7 +345,7 @@
|
||||
SetDruggy(0)
|
||||
SetHallucinate(0)
|
||||
blinded = 0
|
||||
nutrition = 400
|
||||
nutrition = NUTRITION_LEVEL_FED + 50
|
||||
bodytemperature = 310
|
||||
CureBlind()
|
||||
CureNearsighted()
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
var/implanting = 0 //Used for the mind-slave implant
|
||||
var/floating = 0
|
||||
var/mob_size = MOB_SIZE_HUMAN
|
||||
var/metabolism_efficiency = 1 //more or less efficiency to metabolize helpful/harmful reagents and regulate body temperature..
|
||||
var/nightvision = 0
|
||||
|
||||
var/bloodcrawl = 0 //0 No blood crawling, 1 blood crawling, 2 blood crawling+mob devour
|
||||
|
||||
@@ -408,9 +408,22 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
return
|
||||
|
||||
var/atom/whisper_loc = get_whisper_loc()
|
||||
var/list/listening = hearers(message_range, whisper_loc)
|
||||
var/list/listening = hear(message_range, whisper_loc)
|
||||
listening |= src
|
||||
|
||||
var/list/hearturfs = list()
|
||||
|
||||
//Pass whispers on to anything inside the immediate listeners.
|
||||
// This comes before the ghosts do so that ghosts don't act as whisper relays
|
||||
for(var/atom/L in listening)
|
||||
if(ismob(L))
|
||||
for(var/mob/C in L.contents)
|
||||
if(isliving(C))
|
||||
listening += C
|
||||
hearturfs += get_turf(L)
|
||||
if(isobj(L))
|
||||
hearturfs += get_turf(L)
|
||||
|
||||
//ghosts
|
||||
for(var/mob/M in dead_mob_list) //does this include players who joined as observers as well?
|
||||
if(!M.client)
|
||||
@@ -418,11 +431,14 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
if(M.stat == DEAD && M.client && M.get_preference(CHAT_GHOSTEARS))
|
||||
listening |= M
|
||||
|
||||
//Pass whispers on to anything inside the immediate listeners.
|
||||
for(var/mob/L in listening)
|
||||
for(var/mob/C in L.contents)
|
||||
if(isliving(C))
|
||||
listening += C
|
||||
// This, in tandem with "hearturfs", lets nested mobs hear whispers that are in range
|
||||
// Grifted from saycode above.
|
||||
for(var/mob/M in player_list)
|
||||
if(!M.client || isnewplayer(M))
|
||||
continue //skip monkeys and leavers
|
||||
if(get_turf(M) in hearturfs)
|
||||
listening |= M
|
||||
|
||||
|
||||
//pass on the message to objects that can hear us.
|
||||
for(var/obj/O in view(message_range, whisper_loc))
|
||||
|
||||
@@ -24,6 +24,5 @@
|
||||
//Read as: I have no idea what I'm doing but asking for help got me nowhere so this is what you get. - Nodrak
|
||||
if(mind) qdel(mind)
|
||||
living_mob_list -= src
|
||||
ghostize()
|
||||
if(icon_state != "[chassis]_dead" || cleanWipe)
|
||||
qdel(src)
|
||||
|
||||
@@ -114,6 +114,11 @@
|
||||
C.toff = 1
|
||||
..()
|
||||
|
||||
/mob/living/silicon/pai/update_icons()
|
||||
if(stat == DEAD)
|
||||
icon_state = "[chassis]_dead"
|
||||
else
|
||||
icon_state = resting ? "[chassis]_rest" : "[chassis]"
|
||||
|
||||
// this function shows the information about being silenced as a pAI in the Status panel
|
||||
/mob/living/silicon/pai/proc/show_silenced()
|
||||
@@ -420,17 +425,17 @@
|
||||
set category = "IC"
|
||||
|
||||
// Pass lying down or getting up to our pet human, if we're in a rig.
|
||||
if(istype(src.loc,/obj/item/device/paicard))
|
||||
if(stat == CONSCIOUS && istype(src.loc,/obj/item/device/paicard))
|
||||
resting = 0
|
||||
var/obj/item/weapon/rig/rig = src.get_rig()
|
||||
if(istype(rig))
|
||||
rig.force_rest(src)
|
||||
else
|
||||
resting = !resting
|
||||
icon_state = resting ? "[chassis]_rest" : "[chassis]"
|
||||
to_chat(src, "<span class='notice'>You are now [resting ? "resting" : "getting up"]</span>")
|
||||
|
||||
canmove = !resting
|
||||
update_icons()
|
||||
update_canmove()
|
||||
|
||||
//Overriding this will stop a number of headaches down the track.
|
||||
/mob/living/silicon/pai/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
|
||||
|
||||
@@ -28,6 +28,9 @@ var/datum/paiController/paiController // Global handler for pAI candidates
|
||||
if("signup" in href_list)
|
||||
var/mob/dead/observer/O = locate(href_list["signup"])
|
||||
if(!O) return
|
||||
if(!(O in respawnable_list))
|
||||
to_chat(O, "You've given up your ability to respawn!")
|
||||
return
|
||||
if(!check_recruit(O)) return
|
||||
recruitWindow(O)
|
||||
return
|
||||
@@ -361,6 +364,8 @@ var/datum/paiController/paiController // Global handler for pAI candidates
|
||||
return 0
|
||||
if(O.has_enabled_antagHUD == 1 && config.antag_hud_restricted)
|
||||
return 0
|
||||
if(!(O in respawnable_list))
|
||||
return 0
|
||||
if(O.client)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
@@ -6,8 +6,11 @@
|
||||
|
||||
/mob/living/silicon/pai/get_whisper_loc()
|
||||
if(loc == card) // currently in its card?
|
||||
if(istype(card.loc, /mob/living))
|
||||
return card.loc // allow a pai being held or in pocket to whisper
|
||||
var/atom/movable/whisper_loc = card
|
||||
if(istype(card.loc, /obj/item/device/pda)) // Step up 1 level if in a PDA
|
||||
whisper_loc = card.loc
|
||||
if(istype(whisper_loc.loc, /mob/living))
|
||||
return whisper_loc.loc // allow a pai being held or in pocket to whisper
|
||||
else
|
||||
return card // allow a pai in its card to whisper
|
||||
return ..()
|
||||
return whisper_loc // allow a pai in its card to whisper
|
||||
return ..()
|
||||
|
||||
@@ -14,10 +14,6 @@
|
||||
return 0
|
||||
|
||||
O.mouse_opacity = 2
|
||||
if(istype(O,/obj/item/borg/sight))
|
||||
var/obj/item/borg/sight/S = O
|
||||
sight_mode &= ~S.sight_mode
|
||||
update_sight()
|
||||
|
||||
if(client)
|
||||
client.screen -= O
|
||||
@@ -53,7 +49,6 @@
|
||||
if((cell.charge * 100 / cell.maxcharge) < B.powerneeded)
|
||||
to_chat(src, "Not enough power to activate [B.name]!")
|
||||
return
|
||||
var/activated_thingy = null
|
||||
if(!module_state_1)
|
||||
O.mouse_opacity = initial(O.mouse_opacity)
|
||||
module_state_1 = O
|
||||
@@ -61,7 +56,6 @@
|
||||
O.plane = HUD_PLANE
|
||||
O.screen_loc = inv1.screen_loc
|
||||
contents += O
|
||||
activated_thingy = O
|
||||
else if(!module_state_2)
|
||||
O.mouse_opacity = initial(O.mouse_opacity)
|
||||
module_state_2 = O
|
||||
@@ -69,7 +63,6 @@
|
||||
O.plane = HUD_PLANE
|
||||
O.screen_loc = inv2.screen_loc
|
||||
contents += O
|
||||
activated_thingy = O
|
||||
else if(!module_state_3)
|
||||
O.mouse_opacity = initial(O.mouse_opacity)
|
||||
module_state_3 = O
|
||||
@@ -77,11 +70,8 @@
|
||||
O.plane = HUD_PLANE
|
||||
O.screen_loc = inv3.screen_loc
|
||||
contents += O
|
||||
activated_thingy = O
|
||||
else
|
||||
to_chat(src, "You need to disable a module first!")
|
||||
if(istype(activated_thingy,/obj/item/borg/sight))
|
||||
update_sight()
|
||||
update_icons()
|
||||
|
||||
/mob/living/silicon/robot/proc/uneq_active()
|
||||
|
||||
@@ -86,6 +86,7 @@ var/list/robot_verbs_default = list(
|
||||
var/datum/effect/system/ion_trail_follow/ion_trail // Ionpulse effect.
|
||||
|
||||
var/datum/action/item_action/toggle_research_scanner/scanner = null
|
||||
var/list/module_actions = list()
|
||||
|
||||
/mob/living/silicon/robot/New(loc,var/syndie = 0,var/unfinished = 0, var/alien = 0)
|
||||
spark_system = new /datum/effect/system/spark_spread()
|
||||
@@ -371,7 +372,7 @@ var/list/robot_verbs_default = list(
|
||||
//languages
|
||||
module.add_languages(src)
|
||||
//subsystems
|
||||
module.add_subsystems(src)
|
||||
module.add_subsystems_and_actions(src)
|
||||
|
||||
//Custom_sprite check and entry
|
||||
if(custom_sprite == 1)
|
||||
@@ -976,21 +977,17 @@ var/list/robot_verbs_default = list(
|
||||
else
|
||||
overlays -= "eyes"
|
||||
|
||||
if(opened && custom_sprite == 1) //Custom borgs also have custom panels, heh
|
||||
if(wiresexposed)
|
||||
overlays += "[src.ckey]-openpanel +w"
|
||||
else if(cell)
|
||||
overlays += "[src.ckey]-openpanel +c"
|
||||
else
|
||||
overlays += "[src.ckey]-openpanel -c"
|
||||
|
||||
if(opened)
|
||||
var/panelprefix = "ov"
|
||||
if(custom_sprite) //Custom borgs also have custom panels, heh
|
||||
panelprefix = "[ckey]"
|
||||
|
||||
if(wiresexposed)
|
||||
overlays += "ov-openpanel +w"
|
||||
overlays += "[panelprefix]-openpanel +w"
|
||||
else if(cell)
|
||||
overlays += "ov-openpanel +c"
|
||||
overlays += "[panelprefix]-openpanel +c"
|
||||
else
|
||||
overlays += "ov-openpanel -c"
|
||||
overlays += "[panelprefix]-openpanel -c"
|
||||
|
||||
var/combat = list("Combat","Peacekeeper")
|
||||
if(modtype in combat)
|
||||
@@ -1424,7 +1421,7 @@ var/list/robot_verbs_default = list(
|
||||
//languages
|
||||
module.add_languages(src)
|
||||
//subsystems
|
||||
module.add_subsystems(src)
|
||||
module.add_subsystems_and_actions(src)
|
||||
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
@@ -1443,7 +1440,7 @@ var/list/robot_verbs_default = list(
|
||||
//languages
|
||||
module.add_languages(src)
|
||||
//subsystems
|
||||
module.add_subsystems(src)
|
||||
module.add_subsystems_and_actions(src)
|
||||
|
||||
status_flags &= ~CANPUSH
|
||||
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
/datum/action/innate/robot_sight
|
||||
var/sight_mode = null
|
||||
icon_icon = 'icons/obj/decals.dmi'
|
||||
button_icon_state = "securearea"
|
||||
|
||||
/datum/action/innate/robot_sight/Activate()
|
||||
var/mob/living/silicon/robot/R = owner
|
||||
R.sight_mode |= sight_mode
|
||||
R.update_sight()
|
||||
active = 1
|
||||
|
||||
/datum/action/innate/robot_sight/Deactivate()
|
||||
var/mob/living/silicon/robot/R = owner
|
||||
R.sight_mode &= ~sight_mode
|
||||
R.update_sight()
|
||||
active = 0
|
||||
|
||||
/datum/action/innate/robot_sight/xray
|
||||
name = "X-ray Vision"
|
||||
sight_mode = BORGXRAY
|
||||
|
||||
/datum/action/innate/robot_sight/thermal
|
||||
name = "Thermal Vision"
|
||||
sight_mode = BORGTHERM
|
||||
icon_icon = 'icons/obj/clothing/glasses.dmi'
|
||||
button_icon_state = "thermal"
|
||||
|
||||
// ayylmao
|
||||
/datum/action/innate/robot_sight/thermal/alien
|
||||
icon_icon = 'icons/mob/alien.dmi'
|
||||
button_icon_state = "borg-extra-vision"
|
||||
|
||||
/datum/action/innate/robot_sight/meson
|
||||
name = "Meson Vision"
|
||||
sight_mode = BORGMESON
|
||||
icon_icon = 'icons/obj/clothing/glasses.dmi'
|
||||
button_icon_state = "meson"
|
||||
@@ -9,6 +9,7 @@
|
||||
var/list/modules = list()
|
||||
var/obj/item/emag = null
|
||||
var/list/subsystems = list()
|
||||
var/list/module_actions = list()
|
||||
|
||||
var/module_type = "NoMod" // For icon usage
|
||||
|
||||
@@ -92,11 +93,19 @@
|
||||
R.add_language("Orluum", 0)
|
||||
R.add_language("Clownish",0)
|
||||
|
||||
/obj/item/weapon/robot_module/proc/add_subsystems(mob/living/silicon/robot/R)
|
||||
/obj/item/weapon/robot_module/proc/add_subsystems_and_actions(mob/living/silicon/robot/R)
|
||||
R.verbs |= subsystems
|
||||
for(var/A in module_actions)
|
||||
var/datum/action/act = new A()
|
||||
act.Grant(R)
|
||||
R.module_actions += act
|
||||
|
||||
/obj/item/weapon/robot_module/proc/remove_subsystems(mob/living/silicon/robot/R)
|
||||
/obj/item/weapon/robot_module/proc/remove_subsystems_and_actions(mob/living/silicon/robot/R)
|
||||
R.verbs -= subsystems
|
||||
for(var/datum/action/A in R.module_actions)
|
||||
A.Remove(R)
|
||||
qdel(A)
|
||||
R.module_actions.Cut()
|
||||
|
||||
/obj/item/weapon/robot_module/standard
|
||||
name = "standard robot module"
|
||||
@@ -166,6 +175,9 @@
|
||||
name = "engineering robot module"
|
||||
module_type = "Engineer"
|
||||
subsystems = list(/mob/living/silicon/proc/subsystem_power_monitor)
|
||||
module_actions = list(
|
||||
/datum/action/innate/robot_sight/meson,
|
||||
)
|
||||
|
||||
stacktypes = list(
|
||||
/obj/item/stack/sheet/metal/cyborg = 50,
|
||||
@@ -178,7 +190,6 @@
|
||||
|
||||
/obj/item/weapon/robot_module/engineering/New()
|
||||
..()
|
||||
modules += new /obj/item/borg/sight/meson(src)
|
||||
modules += new /obj/item/weapon/rcd/borg(src)
|
||||
modules += new /obj/item/weapon/extinguisher(src)
|
||||
modules += new /obj/item/weapon/weldingtool/largetank/cyborg(src)
|
||||
@@ -297,10 +308,12 @@
|
||||
/obj/item/weapon/robot_module/miner
|
||||
name = "miner robot module"
|
||||
module_type = "Miner"
|
||||
module_actions = list(
|
||||
/datum/action/innate/robot_sight/meson,
|
||||
)
|
||||
|
||||
/obj/item/weapon/robot_module/miner/New()
|
||||
..()
|
||||
modules += new /obj/item/borg/sight/meson(src)
|
||||
modules += new /obj/item/weapon/storage/bag/ore/cyborg(src)
|
||||
modules += new /obj/item/weapon/pickaxe/drill/cyborg(src)
|
||||
modules += new /obj/item/weapon/shovel(src)
|
||||
@@ -317,10 +330,12 @@
|
||||
/obj/item/weapon/robot_module/deathsquad
|
||||
name = "NT advanced combat module"
|
||||
module_type = "Malf"
|
||||
module_actions = list(
|
||||
/datum/action/innate/robot_sight/thermal,
|
||||
)
|
||||
|
||||
/obj/item/weapon/robot_module/deathsquad/New()
|
||||
..()
|
||||
modules += new /obj/item/borg/sight/thermal(src)
|
||||
modules += new /obj/item/weapon/melee/energy/sword/cyborg(src)
|
||||
modules += new /obj/item/weapon/gun/energy/pulse/cyborg(src)
|
||||
modules += new /obj/item/weapon/crowbar(src)
|
||||
@@ -385,11 +400,13 @@
|
||||
/obj/item/weapon/robot_module/combat
|
||||
name = "combat robot module"
|
||||
module_type = "Malf"
|
||||
module_actions = list(
|
||||
/datum/action/innate/robot_sight/thermal,
|
||||
)
|
||||
|
||||
/obj/item/weapon/robot_module/combat/New()
|
||||
..()
|
||||
modules += new /obj/item/weapon/restraints/handcuffs/cable/zipties/cyborg(src)
|
||||
modules += new /obj/item/borg/sight/thermal(src)
|
||||
modules += new /obj/item/weapon/gun/energy/gun/cyborg(src)
|
||||
modules += new /obj/item/weapon/pickaxe/drill/jackhammer(src)
|
||||
modules += new /obj/item/borg/combat/shield(src)
|
||||
@@ -418,11 +435,13 @@
|
||||
/obj/item/weapon/robot_module/alien/hunter
|
||||
name = "alien hunter module"
|
||||
module_type = "Standard"
|
||||
module_actions = list(
|
||||
/datum/action/innate/robot_sight/thermal/alien,
|
||||
)
|
||||
|
||||
/obj/item/weapon/robot_module/alien/hunter/New()
|
||||
modules += new /obj/item/weapon/melee/energy/alien/claws(src)
|
||||
modules += new /obj/item/device/flash/cyborg/alien(src)
|
||||
modules += new /obj/item/borg/sight/thermal/alien(src)
|
||||
var/obj/item/weapon/reagent_containers/spray/alien/stun/S = new /obj/item/weapon/reagent_containers/spray/alien/stun(src)
|
||||
S.reagents.add_reagent("ether",250) //nerfed to sleeptoxin to make it less instant drop.
|
||||
modules += S
|
||||
|
||||
@@ -67,7 +67,8 @@
|
||||
var/bodytemperature = 310.055 //98.7 F
|
||||
var/flying = 0
|
||||
var/charges = 0.0
|
||||
var/nutrition = 400.0//Carbon
|
||||
var/nutrition = NUTRITION_LEVEL_FED + 50 //Carbon
|
||||
var/satiety = 0 //Carbon
|
||||
|
||||
var/overeatduration = 0 // How long this guy is overeating //Carbon
|
||||
var/intent = null//Living
|
||||
|
||||
@@ -494,6 +494,9 @@
|
||||
if(mind.assigned_role == "Clown") //give them a clownname if they are a clown
|
||||
new_character.real_name = pick(clown_names) //I hate this being here of all places but unfortunately dna is based on real_name!
|
||||
new_character.rename_self("clown")
|
||||
else if(mind.assigned_role == "Mime")
|
||||
new_character.real_name = pick(mime_names)
|
||||
new_character.rename_self("mime")
|
||||
else if(new_character.species == "Diona")
|
||||
new_character.real_name = pick(diona_names) //I hate this being here of all places but unfortunately dna is based on real_name!
|
||||
new_character.rename_self("diona")
|
||||
|
||||
Reference in New Issue
Block a user