Merge pull request #5131 from Fox-McCloud/cleanup

Cleans up Vars
This commit is contained in:
TheDZD
2016-07-21 09:16:03 -04:00
committed by GitHub
70 changed files with 298 additions and 458 deletions
@@ -1920,15 +1920,15 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
if(disabilities & DISABILITY_FLAG_DEAF)
character.dna.SetSEState(DEAFBLOCK,1,1)
character.sdisabilities|=DEAF
character.disabilities|=DEAF
if(disabilities & DISABILITY_FLAG_BLIND)
character.dna.SetSEState(BLINDBLOCK,1,1)
character.sdisabilities|=BLIND
character.disabilities|=BLIND
if(disabilities & DISABILITY_FLAG_MUTE)
character.dna.SetSEState(MUTEBLOCK,1,1)
character.sdisabilities |= MUTE
character.disabilities |= MUTE
S.handle_dna(character)
+1 -1
View File
@@ -36,7 +36,7 @@ var/list/image/ghost_darkness_images = list() //this is a list of images for thi
verbs += /mob/dead/observer/proc/dead_tele
// Our new boo spell.
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/boo(src))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/boo(null))
can_reenter_corpse = flags & GHOST_CAN_REENTER
started_as_observer = flags & GHOST_IS_OBSERVER
+4 -4
View File
@@ -28,7 +28,7 @@
//non-verbal languages are garbled if you can't see the speaker. Yes, this includes if they are inside a closet.
if(language && (language.flags & NONVERBAL))
if(sdisabilities & BLIND || blinded) //blind people can't see dumbass
if(disabilities & BLIND || blinded) //blind people can't see dumbass
message = stars(message)
if(!speaker || !(speaker in view(src)))
@@ -65,7 +65,7 @@
if(client.prefs.toggles & CHAT_GHOSTEARS && speaker in view(src))
message = "<b>[message]</b>"
if(sdisabilities & DEAF || ear_deaf)
if(disabilities & DEAF || ear_deaf)
if(!language || !(language.flags & INNATE)) // INNATE is the flag for audible-emote-language, so we don't want to show an "x talks but you cannot hear them" message if it's set
if(speaker == src)
to_chat(src, "<span class='warning'>You cannot hear yourself speak!</span>")
@@ -95,7 +95,7 @@
//non-verbal languages are garbled if you can't see the speaker. Yes, this includes if they are inside a closet.
if(language && (language.flags & NONVERBAL))
if(sdisabilities & BLIND || blinded) //blind people can't see dumbass
if(disabilities & BLIND || blinded) //blind people can't see dumbass
message = stars(message)
if(!speaker || !(speaker in view(src)))
@@ -182,7 +182,7 @@
formatted = language.format_message_radio(message, verb)
else
formatted = "[verb], <span class=\"body\">\"[message]\"</span>"
if(sdisabilities & DEAF || ear_deaf)
if(disabilities & DEAF || ear_deaf)
if(prob(20))
to_chat(src, "<span class='warning'>You feel your headset vibrate but can hear nothing from it!</span>")
else if(track)
@@ -96,15 +96,13 @@
f_loss += 60
ear_damage += 30
ear_deaf += 120
adjustEarDamage(30, 120)
if(3.0)
b_loss += 30
if(prob(50) && !shielded)
Paralyse(1)
ear_damage += 15
ear_deaf += 60
adjustEarDamage(15,60)
adjustBruteLoss(b_loss)
adjustFireLoss(f_loss)
@@ -59,7 +59,7 @@
blinded = 1
silent = 0
else //ALIVE. LIGHTS ARE ON
if(health < config.health_threshold_dead || brain_op_stage == 4.0)
if(health < config.health_threshold_dead || !get_int_organ(/obj/item/organ/internal/brain))
death()
blinded = 1
stat = DEAD
@@ -95,7 +95,7 @@
move_delay_add = max(0, move_delay_add - rand(1, 2))
//Eyes
if(sdisabilities & BLIND) //disabled-blind, doesn't get better on its own
if(disabilities & BLIND) //disabled-blind, doesn't get better on its own
blinded = 1
else if(eye_blind) //blindness, heals slowly over time
eye_blind = max(eye_blind-1,0)
@@ -104,12 +104,12 @@
eye_blurry = max(eye_blurry-1, 0)
//Ears
if(sdisabilities & DEAF) //disabled-deaf, doesn't get better on its own
ear_deaf = max(ear_deaf, 1)
if(disabilities & DEAF) //disabled-deaf, doesn't get better on its own
setEarDamage(-1, max(ear_deaf, 1))
else if(ear_deaf) //deafness, heals slowly over time
ear_deaf = max(ear_deaf-1, 0)
adjustEarDamage(0,-1)
else if(ear_damage < 25) //ear damage heals slowly under this threshold. otherwise you'll need earmuffs
ear_damage = max(ear_damage-0.05, 0)
adjustEarDamage(-0.05, 0)
//Other
if(stunned)
@@ -88,37 +88,4 @@
icon_state = "queen_s"
for(var/image/I in overlays_standing)
overlays += I
/*
/mob/living/carbon/alien/humanoid/queen/verb/evolve() // -- TLE
set name = "Evolve (1000)"
set desc = "The ultimate transformation. Become an alien Empress. Only one empress can exist at a time."
set category = "Alien"
if(powerc(1000))
// Queen check
var/no_queen = 1
for(var/mob/living/carbon/alien/humanoid/empress/E in living_mob_list)
if(!E.key && E.brain_op_stage != 4)
continue
no_queen = 0
if(no_queen)
adjustToxLoss(-1000)
to_chat(src, "<span class='noticealien'>You begin to evolve!</span>")
for(var/mob/O in viewers(src, null))
O.show_message(text("<span class='alertalien'>[src] begins to twist and contort!</span>"), 1)
var/mob/living/carbon/alien/humanoid/empress/new_xeno = new(loc)
if(mind)
mind.transfer_to(new_xeno)
else
new_xeno.key = key
new_xeno.mind.name = new_xeno.name
qdel(src)
else
to_chat(src, "<span class='notice'>We already have an alive empress.</span>")
return
*/
overlays += I
@@ -87,15 +87,13 @@
f_loss += 60
ear_damage += 30
ear_deaf += 120
adjustEarDamage(30,120)
if(3.0)
b_loss += 30
if(prob(50))
Paralyse(1)
ear_damage += 15
ear_deaf += 60
adjustEarDamage(15,60)
adjustBruteLoss(b_loss)
adjustFireLoss(f_loss)
@@ -19,7 +19,7 @@
blinded = 1
silent = 0
else //ALIVE. LIGHTS ARE ON
if(health < -25 || brain_op_stage == 4.0)
if(health < -25 || !get_int_organ(/obj/item/organ/internal/brain))
death()
blinded = 1
silent = 0
@@ -54,7 +54,7 @@
move_delay_add = max(0, move_delay_add - rand(1, 2))
//Eyes
if(sdisabilities & BLIND) //disabled-blind, doesn't get better on its own
if(disabilities & BLIND) //disabled-blind, doesn't get better on its own
blinded = 1
else if(eye_blind) //blindness, heals slowly over time
eye_blind = max(eye_blind-1,0)
@@ -63,12 +63,12 @@
eye_blurry = max(eye_blurry-1, 0)
//Ears
if(sdisabilities & DEAF) //disabled-deaf, doesn't get better on its own
ear_deaf = max(ear_deaf, 1)
if(disabilities & DEAF) //disabled-deaf, doesn't get better on its own
setEarDamage(-1, max(ear_deaf, 1))
else if(ear_deaf) //deafness, heals slowly over time
ear_deaf = max(ear_deaf-1, 0)
adjustEarDamage(0,-1)
else if(ear_damage < 25) //ear damage heals slowly under this threshold.
ear_damage = max(ear_damage-0.05, 0)
adjustEarDamage(-0.05,0)
//Other
if(stunned)
@@ -98,4 +98,10 @@ I'm using this for Stat to give it a more nifty interface to work with
stat("Exosuit Integrity", "[!M.health ? "0" : "[(M.health / initial(M.health)) * 100]"]%")
/mob/living/carbon/brain/can_safely_leave_loc()
return 0 //You're not supposed to be ethereal jaunting, brains
return 0 //You're not supposed to be ethereal jaunting, brains
/mob/living/carbon/brain/adjustEarDamage()
return
/mob/living/carbon/brain/setEarDamage() // no ears to damage or heal
return
@@ -21,8 +21,7 @@
/obj/item/organ/internal/brain/surgeryize()
if(!owner)
return
owner.ear_damage = 0 //Yeah, didn't you...hear? The ears are totally inside the brain.
owner.ear_deaf = 0
owner.setEarDamage(0,0) //Yeah, didn't you...hear? The ears are totally inside the brain.
/obj/item/organ/internal/brain/xeno
name = "xenomorph brain"
@@ -183,7 +183,6 @@
src.brainmob.container = src
src.brainmob.stat = 0
src.brainmob.silent = 0
src.brainmob.brain_op_stage = 4.0
dead_mob_list -= src.brainmob
..()
@@ -1,15 +1,12 @@
/mob/living/carbon/
/mob/living/carbon
gender = MALE
hud_possible = list(HEALTH_HUD,STATUS_HUD,SPECIALROLE_HUD)
var/list/stomach_contents = list()
var/list/internal_organs = list()
var/brain_op_stage = 0.0
var/antibodies = 0
var/last_eating = 0 //Not sure what this does... I found it hidden in food.dm
var/life_tick = 0 // The amount of life ticks that have processed on this mob.
var/analgesic = 0 // when this is set, the mob isn't affected by shock or pain
// life should decrease this by 1 every tick
// total amount of wounds on mob, used to spread out healing and the like over all wounds
var/number_wounds = 0
var/obj/item/handcuffed = null //Whether or not the mob is handcuffed
@@ -10,7 +10,7 @@
act = copytext(act, 1, t1)
var/muzzled = is_muzzled()
if(sdisabilities & MUTE || silent)
if(disabilities & MUTE || silent)
muzzled = 1
//var/m_type = 1
@@ -355,8 +355,7 @@
else valid_limbs -= processing_dismember
if(!istype(l_ear, /obj/item/clothing/ears/earmuffs) && !istype(r_ear, /obj/item/clothing/ears/earmuffs))
ear_damage += 30
ear_deaf += 120
adjustEarDamage(30, 120)
if(prob(70) && !shielded)
Paralyse(10)
@@ -380,8 +379,7 @@
else valid_limbs -= processing_dismember
if(!istype(l_ear, /obj/item/clothing/ears/earmuffs) && !istype(r_ear, /obj/item/clothing/ears/earmuffs))
ear_damage += 15
ear_deaf += 60
adjustEarDamage(15,60)
if(prob(50) && !shielded)
Paralyse(10)
+11 -12
View File
@@ -816,9 +816,6 @@
handle_organs()
handle_blood()
//the analgesic effect wears off slowly
analgesic = max(0, analgesic - 1)
if(paralysis)
blinded = 1
stat = UNCONSCIOUS
@@ -864,7 +861,7 @@
else
//blindness
if(sdisabilities & BLIND) // Disabled-blind, doesn't get better on its own
if(disabilities & BLIND) // Disabled-blind, doesn't get better on its own
blinded = 1
else if(eye_blind) // Blindness, heals slowly over time
@@ -884,18 +881,18 @@
//Ears
if(sdisabilities & DEAF) //disabled-deaf, doesn't get better on its own
ear_deaf = max(ear_deaf, 1)
if(disabilities & DEAF) //disabled-deaf, doesn't get better on its own
setEarDamage(-1, max(ear_deaf, 1))
else if(ear_deaf) //deafness, heals slowly over time
ear_deaf = max(ear_deaf - 1, 0)
adjustEarDamage(0,-1)
else if(istype(l_ear, /obj/item/clothing/ears/earmuffs) || istype(r_ear, /obj/item/clothing/ears/earmuffs)) //resting your ears with earmuffs heals ear damage faster
ear_damage = max(ear_damage - 0.15, 0)
ear_deaf = max(ear_deaf, 1)
adjustEarDamage(-0.15,0)
setEarDamage(-1, max(ear_deaf, 1))
else if(ear_damage < 25) //ear damage heals slowly under this threshold. otherwise you'll need earmuffs
ear_damage = max(ear_damage - 0.05, 0)
adjustEarDamage(-0.05,0)
if(flying)
animate(src, pixel_y = pixel_y + 5 , time = 10, loop = 1, easing = SINE_EASING)
@@ -987,8 +984,10 @@
/mob/living/carbon/human/handle_shock()
..()
if(status_flags & GODMODE) return 0 //godmode
if(analgesic || (species && species.flags & NO_PAIN)) return // analgesic avoids all traumatic shock temporarily
if(status_flags & GODMODE)
return 0 //godmode
if(species && species.flags & NO_PAIN)
return
if(health <= config.health_threshold_softcrit)// health 0 makes you immediately collapse
shock_stage = max(shock_stage, 61)
+1 -1
View File
@@ -106,7 +106,7 @@
var/list/returns[3]
var/speech_problem_flag = 0
if(silent || (sdisabilities & MUTE))
if(silent || (disabilities & MUTE))
message = ""
speech_problem_flag = 1
@@ -615,25 +615,22 @@
/datum/species/proc/handle_hud_icons(mob/living/carbon/human/H)
if(H.healths)
if(H.analgesic)
H.healths.icon_state = "health_health_numb"
if(H.stat == DEAD)
H.healths.icon_state = "health7"
else
if(H.stat == DEAD)
H.healths.icon_state = "health7"
else
switch(H.hal_screwyhud)
if(1) H.healths.icon_state = "health6"
if(2) H.healths.icon_state = "health7"
if(5) H.healths.icon_state = "health0"
else
switch(100 - ((flags & NO_PAIN) ? 0 : H.traumatic_shock) - H.staminaloss)
if(100 to INFINITY) H.healths.icon_state = "health0"
if(80 to 100) H.healths.icon_state = "health1"
if(60 to 80) H.healths.icon_state = "health2"
if(40 to 60) H.healths.icon_state = "health3"
if(20 to 40) H.healths.icon_state = "health4"
if(0 to 20) H.healths.icon_state = "health5"
else H.healths.icon_state = "health6"
switch(H.hal_screwyhud)
if(1) H.healths.icon_state = "health6"
if(2) H.healths.icon_state = "health7"
if(5) H.healths.icon_state = "health0"
else
switch(100 - ((flags & NO_PAIN) ? 0 : H.traumatic_shock) - H.staminaloss)
if(100 to INFINITY) H.healths.icon_state = "health0"
if(80 to 100) H.healths.icon_state = "health1"
if(60 to 80) H.healths.icon_state = "health2"
if(40 to 60) H.healths.icon_state = "health3"
if(20 to 40) H.healths.icon_state = "health4"
if(0 to 20) H.healths.icon_state = "health5"
else H.healths.icon_state = "health6"
if(H.healthdoll)
H.healthdoll.overlays.Cut()
-2
View File
@@ -16,8 +16,6 @@
src.traumatic_shock -= R.shock_reduction // now you too can varedit cyanide to reduce shock by 1000 - Iamgoofball
if(src.slurring)
src.traumatic_shock -= 10
if(src.analgesic)
src.traumatic_shock = 0
// broken or ripped off organs will add quite a bit of pain
if(istype(src,/mob/living/carbon/human))
+2 -2
View File
@@ -217,9 +217,9 @@
src.density = !( src.lying )
if(src.sdisabilities & BLIND)
if(src.disabilities & BLIND)
src.blinded = 1
if(src.sdisabilities & DEAF)
if(src.disabilities & DEAF)
src.ear_deaf = 1
if(src.eye_blurry > 0)
@@ -33,8 +33,9 @@
if(default_spells.len)
for(var/spell in default_spells)
var/obj/effect/proc_holder/spell/S = spell
if(!S) return
H.AddSpell(new S)
if(!S)
return
H.mind.AddSpell(new S(null))
/datum/superheroes/proc/assign_id(var/mob/living/carbon/human/H)
var/obj/item/weapon/card/id/syndicate/W = new(H)
+1 -1
View File
@@ -174,7 +174,7 @@
/mob/living/proc/handle_disabilities()
//Eyes
if(sdisabilities & BLIND || stat) //blindness from disability or unconsciousness doesn't get better on its own
if(disabilities & BLIND || stat) //blindness from disability or unconsciousness doesn't get better on its own
eye_blind = max(eye_blind, 1)
else if(eye_blind) //blindness, heals slowly over time
eye_blind = max(eye_blind-1,0)
+3 -5
View File
@@ -346,7 +346,7 @@
dead_mob_list -= src
living_mob_list |= src
mob_list |= src
ear_deaf = 0
setEarDamage(-1,0)
timeofdeath = 0
/mob/living/proc/rejuvenate()
@@ -373,13 +373,11 @@
hallucination = 0
nutrition = 400
bodytemperature = 310
sdisabilities = 0
disabilities = 0
blinded = 0
eye_blind = 0
eye_blurry = 0
ear_deaf = 0
ear_damage = 0
setEarDamage(0,0)
heal_overall_damage(1000, 1000)
ExtinguishMob()
fire_stacks = 0
@@ -646,7 +644,7 @@
//called when the mob receives a bright flash
/mob/living/proc/flash_eyes(intensity = 1, override_blindness_check = 0, affect_silicon = 0, visual = 0, type = /obj/screen/fullscreen/flash)
if(check_eye_prot() < intensity && (override_blindness_check || !(sdisabilities & BLIND)))
if(check_eye_prot() < intensity && (override_blindness_check || !(disabilities & BLIND)))
overlay_fullscreen("flash", type)
addtimer(src, "clear_fullscreen", 25, FALSE, "flash", 25)
return 1
+5 -11
View File
@@ -7,10 +7,10 @@
//Damage related vars, NOTE: THESE SHOULD ONLY BE MODIFIED BY PROCS
var/bruteloss = 0.0 //Brutal damage caused by brute force (punching, being clubbed by a toolbox ect... this also accounts for pressure damage)
var/oxyloss = 0.0 //Oxygen depravation damage (no air in lungs)
var/toxloss = 0.0 //Toxic damage caused by being poisoned or radiated
var/fireloss = 0.0 //Burn damage caused by being way too hot, too cold or burnt.
var/bruteloss = 0 //Brutal damage caused by brute force (punching, being clubbed by a toolbox ect... this also accounts for pressure damage)
var/oxyloss = 0 //Oxygen depravation damage (no air in lungs)
var/toxloss = 0 //Toxic damage caused by being poisoned or radiated
var/fireloss = 0 //Burn damage caused by being way too hot, too cold or burnt.
var/cloneloss = 0 //Damage caused by being cloned or ejected from the cloner early. slimes also deal cloneloss damage to victims
var/brainloss = 0 //'Retardation' damage caused by someone hitting you in the head with a bible or being infected with brainrot.
var/staminaloss = 0 //Stamina damage, or exhaustion. You recover it slowly naturally, and are stunned if it gets too high. Holodeck and hallucinations deal this.
@@ -23,11 +23,6 @@
//Allows mobs to move through dense areas without restriction. For instance, in space or out of holder objects.
var/incorporeal_move = 0 //0 is off, 1 is normal, 2 is for ninjas.
var/t_plasma = null
var/t_oxygen = null
var/t_sl_gas = null
var/t_n2 = null
var/now_pushing = null
var/atom/movable/cameraFollow = null
@@ -36,9 +31,8 @@
var/fire_stacks = 0 //Tracks how many stacks of fire we have on, max is usually 20
var/update_slimes = 1
var/specialsauce = 0 //Has this person consumed enough special sauce? IF so they're a ticking time bomb of death.
var/implanting = 0 //Used for the mind-slave implant
var/silent = null //Can't talk. Value goes down every life proc.
var/silent = 0 //Can't talk. Value goes down every life proc. //NOTE TO FUTURE CODERS: DO NOT INITIALIZE NUMERICAL VARS AS NULL OR I WILL MURDER YOU.
var/floating = 0
var/nightvision = 0
@@ -17,8 +17,7 @@
SetStunned(min(stunned, 30))
SetParalysis(min(paralysis, 30))
SetWeakened(min(weakened, 20))
sleeping = 0
ear_deaf = 0
SetSleeping(0)
/mob/living/silicon/robot/proc/handle_robot_cell()
if(stat != DEAD)
+9 -1
View File
@@ -358,4 +358,12 @@
return ..()
/mob/living/silicon/is_mechanical()
return 1
return 1
/////////////////////////////////// EAR DAMAGE ////////////////////////////////////
/mob/living/silicon/adjustEarDamage()
return
/mob/living/silicon/setEarDamage()
return
@@ -27,7 +27,7 @@
name = text("[initial(name)] ([rand(1, 1000)])")
real_name = name
for(var/spell in construct_spells)
AddSpell(new spell(src))
AddSpell(new spell(null))
updateglow()
/mob/living/simple_animal/construct/death()
@@ -52,9 +52,9 @@
/mob/living/simple_animal/hostile/statue/New(loc, var/mob/living/creator)
..()
// Give spells
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/flicker_lights(src))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/blindness(src))
AddSpell(new /obj/effect/proc_holder/spell/targeted/night_vision(src))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/flicker_lights(null))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/blindness(null))
AddSpell(new /obj/effect/proc_holder/spell/targeted/night_vision(null))
// Give nightvision
see_invisible = SEE_INVISIBLE_OBSERVER_NOLIGHTING
@@ -695,3 +695,9 @@
/mob/living/simple_animal/proc/sentience_act() //Called when a simple animal gains sentience via gold slime potion
return
/mob/living/simple_animal/adjustEarDamage()
return
/mob/living/simple_animal/setEarDamage()
return
+18 -21
View File
@@ -6,6 +6,7 @@
hud_used = null
if(mind && mind.current == src)
spellremove(src)
mobspellremove(src)
for(var/infection in viruses)
qdel(infection)
ghostize()
@@ -61,19 +62,19 @@
if(!client) return
if(type)
if(type & 1 && (sdisabilities & BLIND || blinded || paralysis) )//Vision related
if(type & 1 && (disabilities & BLIND || blinded || paralysis) )//Vision related
if(!( alt ))
return
else
msg = alt
type = alt_type
if(type & 2 && (sdisabilities & DEAF || ear_deaf))//Hearing related
if(type & 2 && (disabilities & DEAF || ear_deaf))//Hearing related
if(!( alt ))
return
else
msg = alt
type = alt_type
if((type & 1 && sdisabilities & BLIND))
if((type & 1 && disabilities & BLIND))
return
// Added voice muffling for Issue 41.
if(stat == UNCONSCIOUS || (sleeping > 0 && stat != 2))
@@ -158,8 +159,6 @@
/mob/proc/Life()
// handle_typing_indicator()
// if(organStructure)
// organStructure.ProcessOrgans()
return
@@ -960,8 +959,8 @@ var/list/slot_equipment_priority = list( \
if(mind && mind.changeling)
add_stings_to_statpanel(mind.changeling.purchasedpowers)
if(spell_list && spell_list.len)
for(var/obj/effect/proc_holder/spell/S in spell_list)
if(mob_spell_list && mob_spell_list.len)
for(var/obj/effect/proc_holder/spell/S in mob_spell_list)
add_spell_to_statpanel(S)
if(mind && istype(src, /mob/living) && mind.spell_list && mind.spell_list.len)
for(var/obj/effect/proc_holder/spell/S in mind.spell_list)
@@ -994,6 +993,7 @@ var/list/slot_equipment_priority = list( \
for(var/obj/effect/proc_holder/changeling/S in stings)
if(S.chemical_cost >=0 && S.can_be_used_by(src))
statpanel("[S.panel]",((S.chemical_cost > 0) ? "[S.chemical_cost]" : ""),S)
/mob/proc/add_spell_to_statpanel(var/obj/effect/proc_holder/spell/S)
switch(S.charge_type)
if("recharge")
@@ -1002,17 +1002,6 @@ var/list/slot_equipment_priority = list( \
statpanel(S.panel,"[S.charge_counter]/[S.charge_max]",S)
if("holdervar")
statpanel(S.panel,"[S.holder_var_type] [S.holder_var_amount]",S)
/* // Why have a duplicate set of turfs in the stat panel?
if(listed_turf)
if(get_dist(listed_turf,src) > 1)
listed_turf = null
else
statpanel(listed_turf.name,listed_turf.name,listed_turf)
for(var/atom/A in listed_turf)
if(A.invisibility > see_invisible)
continue
statpanel(listed_turf.name,A.name,A)
*/
// facing verbs
@@ -1366,9 +1355,17 @@ mob/proc/yank_out_object()
/mob/proc/setEarDamage()
return
/mob/proc/AddSpell(var/obj/effect/proc_holder/spell/spell)
spell_list += spell
spell.action.Grant(src)
/mob/proc/AddSpell(obj/effect/proc_holder/spell/S)
mob_spell_list += S
S.action.Grant(src)
/mob/proc/RemoveSpell(obj/effect/proc_holder/spell/spell) //To remove a specific spell from a mind
if(!spell)
return
for(var/obj/effect/proc_holder/spell/S in mob_spell_list)
if(istype(S, spell))
qdel(S)
mob_spell_list -= S
//override to avoid rotating pixel_xy on mobs
/mob/shuttleRotate(rotation)
+23 -42
View File
@@ -2,15 +2,11 @@
density = 1
layer = 4.0
animate_movement = 2
// flags = NOREACT
pressure_resistance = 8
var/datum/mind/mind
var/stat = 0 //Whether a mob is alive or dead. TODO: Move this to living - Nodrak
//Not in use yet
var/obj/effect/organstructure/organStructure = null
var/obj/screen/hands = null
var/obj/screen/pullin = null
var/obj/screen/i_select = null
@@ -34,24 +30,21 @@
var/lastattacker = null
var/lastattacked = null
var/attack_log = list( )
var/already_placed = 0.0
var/obj/machinery/machine = null
var/other_mobs = null
var/memory = ""
var/poll_answer = 0.0
var/sdisabilities = 0 //Carbon
var/disabilities = 0 //Carbon
var/atom/movable/pulling = null
var/next_move = null
var/notransform = null //Carbon
var/other = 0.0
var/hand = null
var/eye_blind = null //Carbon
var/eye_blurry = null //Carbon
var/ear_deaf = null //Carbon
var/ear_damage = null //Carbon
var/stuttering = null //Carbon
var/slurring = null //Carbon
var/eye_blind = 0 //Carbon
var/eye_blurry = 0 //Carbon
var/ear_deaf = 0 //Carbon
var/ear_damage = 0 //Carbon
var/stuttering = 0 //Carbon
var/slurring = 0 //Carbon
var/real_name = null
var/flavor_text = ""
var/med_record = ""
@@ -63,8 +56,6 @@
var/druggy = 0 //Carbon
var/confused = 0 //Carbon
var/drunk = 0
var/antitoxs = null
var/plasma = null
var/sleeping = 0 //Carbon
var/resting = 0 //Carbon
var/lying = 0
@@ -95,11 +86,11 @@
var/nutrition = 400.0//Carbon
var/overeatduration = 0 // How long this guy is overeating //Carbon
var/paralysis = 0.0
var/stunned = 0.0
var/weakened = 0.0
var/paralysis = 0
var/stunned = 0
var/weakened = 0
var/slowed = 0
var/losebreath = 0.0//Carbon
var/losebreath = 0 //Carbon
var/intent = null//Living
var/shakecamera = 0
var/a_intent = I_HELP//Living
@@ -123,8 +114,8 @@
var/research_scanner = 0 //For research scanner equipped mobs. Enable to show research data when examining.
var/list/grabbed_by = list( )
var/list/requests = list( )
var/list/grabbed_by = list()
var/list/requests = list()
var/list/mapobjs = list()
@@ -134,17 +125,10 @@
var/emote_cd = 0 // Used to supress emote spamming. 1 if on CD, 2 if disabled by admin (manually set), else 0
var/music_lastplayed = "null"
var/job = null//Living
var/const/blindness = 1//Carbon
var/const/deafness = 2//Carbon
var/const/muteness = 4//Carbon
var/datum/dna/dna = null//Carbon
var/radiation = 0.0//Carbon
var/radiation = 0 //Carbon
var/list/mutations = list() //Carbon -- Doohl
//see: setup.dm for list of mutations
@@ -157,24 +141,24 @@
var/has_enabled_antagHUD = 0
var/antagHUD = 0
//Generic list for proc holders. Only way I can see to enable certain verbs/procs. Should be modified if needed.
var/proc_holder_list[] = list()//Right now unused.
//Also unlike the spell list, this would only store the object in contents, not an object in itself.
/* Add this line to whatever stat module you need in order to use the proc holder list.
//Generic list for proc holders. Only way I can see to enable certain verbs/procs. Should be modified if needed.
var/proc_holder_list[] = list()
/* //Also unlike the spell list, this would only store the object in contents, not an object in itself.
Add this line to whatever stat module you need in order to use the proc holder list.
Unlike the object spell system, it's also possible to attach verb procs from these objects to right-click menus.
This requires creating a verb for the object proc holder.
if(proc_holder_list.len)//Generic list for proc_holder objects.
for(var/obj/effect/proc_holder/P in proc_holder_list)
statpanel("[P.panel]","",P)
*/
statpanel("[P.panel]","",P)*/
//The last mob/living/carbon to push/drag/grab this mob (mostly used by slimes friend recognition)
var/mob/living/carbon/LAssailant = null
//Wizard mode, but can be used in other modes thanks to the brand new "Give Spell" badmin button
var/obj/effect/proc_holder/spell/list/spell_list = list()
var/list/mob_spell_list = list() //construct spells and mime spells. Spells that do not transfer from one mob to another and can not be lost in mindswap.
//Changlings, but can be used in other modes
// var/obj/effect/proc_holder/changpower/list/power_list = list()
@@ -195,9 +179,6 @@
var/has_unlimited_silicon_privilege = 0 // Can they interact with station electronics
var/list/radar_blips = list() // list of screen objects, radar blips
var/radar_open = 0 // nonzero is radar is open
var/atom/movable/remote_control //Calls relaymove() to whatever it is
var/remote_view = 0 // Set to 1 to prevent view resets on Life
@@ -219,11 +200,11 @@
var/turf/listed_turf = null //the current turf being examined in the stat panel
var/list/shouldnt_see = list(/atom/movable/lighting_overlay) //list of objects that this mob shouldn't see in the stat panel. this silliness is needed because of AI alt+click and cult blood runes
var/kills=0
var/kills = 0
var/stance_damage = 0 //Whether this mob's ability to stand has been affected
var/list/active_genes=list()
var/list/active_genes = list()
var/last_movement = -100 // Last world.time the mob actually moved of its own accord.
+2 -2
View File
@@ -63,7 +63,7 @@ proc/iscuffed(A)
proc/isdeaf(A)
if(istype(A, /mob))
var/mob/M = A
return (M.sdisabilities & DEAF) || M.ear_deaf
return (M.disabilities & DEAF) || M.ear_deaf
return 0
proc/hassensorlevel(A, var/level)
@@ -358,7 +358,7 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
/proc/is_blind(A)
if(iscarbon(A))
var/mob/living/carbon/C = A
if(C.sdisabilities & BLIND || C.blinded)
if(C.disabilities & BLIND || C.blinded)
return 1
return 0
+3 -3
View File
@@ -4,9 +4,9 @@
/mob/spirit/mask/New()
..()
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/conjure/create_talisman(src))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/blood_speech(src))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/shatter_lights(src))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/conjure/create_talisman(null))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/blood_speech(null))
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/shatter_lights(null))
/mob/spirit/mask/verb/go_to_follower()
+2 -2
View File
@@ -15,10 +15,10 @@ var/global/image/typing_indicator
if(ishuman(src))
var/mob/living/carbon/human/H = src
if(H.sdisabilities & MUTE || H.silent)
if(H.disabilities & MUTE || H.silent)
overlays -= typing_indicator
return
if(client)
if((client.prefs.toggles & SHOW_TYPING) || stat != CONSCIOUS || is_muzzled())
overlays -= typing_indicator
+4 -4
View File
@@ -478,15 +478,15 @@
if(istype(E))
E.damage = max(E.damage-1, 0)
M.eye_blurry = max(M.eye_blurry-1 , 0)
M.ear_damage = max(M.ear_damage-1, 0)
M.adjustEarDamage(-1,0)
if(prob(50))
M.disabilities &= ~NEARSIGHTED
if(prob(30))
M.sdisabilities &= ~BLIND
M.disabilities &= ~BLIND
M.eye_blind = 0
if(M.ear_damage <= 25)
if(prob(30))
M.ear_deaf = 0
M.setEarDamage(-1,0)
..()
/datum/chemical_reaction/oculine
@@ -696,7 +696,7 @@
/datum/reagent/mutadone/on_mob_life(mob/living/carbon/human/M)
M.jitteriness = 0
var/needs_update = M.mutations.len > 0 || M.disabilities > 0 || M.sdisabilities > 0
var/needs_update = M.mutations.len > 0 || M.disabilities > 0
if(needs_update)
for(var/block=1;block<=DNA_SE_LENGTH;block++)
+2 -4
View File
@@ -356,8 +356,7 @@
if(!ear_safety)
M.Stun(max(10/distance, 3))
M.Weaken(max(10/distance, 3))
M.ear_damage += rand(0, 5)
M.ear_deaf = max(M.ear_deaf,15)
M.setEarDamage(M.ear_damage + rand(0, 5), max(M.ear_deaf,15))
if(M.ear_damage >= 15)
to_chat(M, "<span class='warning'>Your ears start to ring badly!</span>")
if(prob(M.ear_damage - 10 + 5))
@@ -385,8 +384,7 @@
if(!ear_safety)
M.Stun(max(10/distance, 3))
M.Weaken(max(10/distance, 3))
M.ear_damage += rand(0, 5)
M.ear_deaf = max(M.ear_deaf,15)
M.setEarDamage(M.ear_damage + rand(0, 5), max(M.ear_deaf,15))
if(M.ear_damage >= 15)
to_chat(M, "<span class='warning'>Your ears start to ring badly!</span>")
if(prob(M.ear_damage - 10 + 5))
@@ -25,7 +25,6 @@
if(E.mend_fracture())
E.perma_injury = 0
M.disabilities = 0
M.sdisabilities = 0
M.eye_blurry = 0
M.eye_blind = 0
M.SetWeakened(0)
@@ -357,7 +357,7 @@
if(!owner)
return
owner.disabilities &= ~NEARSIGHTED
owner.sdisabilities &= ~BLIND
owner.disabilities &= ~BLIND
owner.eye_blurry = 0
owner.eye_blind = 0
@@ -538,7 +538,7 @@
to_chat(owner, "<font color='red' size='7'>HONK</font>")
owner.sleeping = 0
owner.stuttering = 20
owner.ear_deaf = 30
owner.adjustEarDamage(0, 30)
owner.Weaken(3)
owner << 'sound/items/AirHorn.ogg'
if(prob(30))
-6
View File
@@ -12,8 +12,6 @@ mob/living/carbon/proc/pain(var/partname, var/amount, var/force, var/burning = 0
return
if(reagents.has_reagent("hydrocodone"))
return
if(analgesic)
return
if(world.time < next_pain_time && !force)
return
if(amount > 10 && istype(src,/mob/living/carbon/human))
@@ -55,8 +53,6 @@ mob/living/carbon/human/proc/custom_pain(var/message, var/flash_strength)
return
if(reagents.has_reagent("hydrocodone"))
return
if(analgesic)
return
var/msg = "\red <b>[message]</b>"
if(flash_strength >= 1)
msg = "\red <font size=3><b>[message]</b></font>"
@@ -94,8 +90,6 @@ mob/living/carbon/human/proc/handle_pain()
return
if(reagents.has_reagent("hydrocodone"))
return
if(analgesic)
return
var/maxdam = 0
var/obj/item/organ/external/damaged_organ = null
for(var/obj/item/organ/external/E in organs)
@@ -170,7 +170,7 @@
if(!owner)
return
owner.disabilities &= ~NEARSIGHTED
owner.sdisabilities &= ~BLIND
owner.disabilities &= ~BLIND
owner.eye_blurry = 0
owner.eye_blind = 0
@@ -150,7 +150,7 @@
if(!owner)
return
owner.disabilities &= ~NEARSIGHTED
owner.sdisabilities &= ~BLIND
owner.disabilities &= ~BLIND
owner.eye_blurry = 0
owner.eye_blind = 0