Merge branch 'dev' of https://github.com/Baystation12/Baystation12 into sync_to_bay_10/10/2015

Conflicts:
	.travis.yml
	code/game/gamemodes/changeling/changeling_powers.dm
	code/game/gamemodes/changeling/modularchangling.dm
	code/game/turfs/simulated.dm
	code/global.dm
	icons/misc/fullscreen.dmi
	polaris.dme
This commit is contained in:
Neerti
2015-10-10 23:17:26 -04:00
415 changed files with 10938 additions and 11366 deletions
+4 -1
View File
@@ -108,7 +108,10 @@ note dizziness decrements automatically in the mob's Life() proc.
return
/mob/proc/make_floating(var/n)
if(buckled)
if(is_floating)
stop_floating()
return
floatiness = n
if(floatiness && !is_floating)
+11 -4
View File
@@ -123,7 +123,7 @@ Works together with spawning an observer, noted above.
if(antagHUD)
var/list/target_list = list()
for(var/mob/living/target in oview(src, 14))
if(target.mind&&(target.mind.special_role||issilicon(target)) )
if(target.mind && target.mind.special_role)
target_list += target
if(target_list.len)
assess_targets(target_list, src)
@@ -141,6 +141,8 @@ Works together with spawning an observer, noted above.
var/client/C = U.client
for(var/mob/living/carbon/human/target in target_list)
C.images += target.hud_list[SPECIALROLE_HUD]
for(var/mob/living/silicon/target in target_list)
C.images += target.hud_list[SPECIALROLE_HUD]
return 1
/mob/proc/ghostize(var/can_reenter_corpse = 1)
@@ -215,7 +217,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
return
mind.current.ajourn=0
mind.current.key = key
mind.current.aghosted = null
mind.current.teleop = null
if(!admin_ghosted)
announce_ghost_joinleave(mind, 0, "They now occupy their body again.")
return 1
@@ -460,6 +462,11 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
if(!MayRespawn(1))
return
var/turf/T = get_turf(src)
if(!T || (T.z in config.admin_levels))
src << "<span class='warning'>You may not spawn as a mouse on this Z-level.</span>"
return
var/timedifference = world.time - client.time_died_as_mouse
if(client.time_died_as_mouse && timedifference <= mouse_respawn_time * 600)
var/timedifference_text
@@ -475,8 +482,8 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/mob/living/simple_animal/mouse/host
var/obj/machinery/atmospherics/unary/vent_pump/vent_found
var/list/found_vents = list()
for(var/obj/machinery/atmospherics/unary/vent_pump/v in world)
if(!v.welded && v.z == src.z)
for(var/obj/machinery/atmospherics/unary/vent_pump/v in machines)
if(!v.welded && v.z == T.z)
found_vents.Add(v)
if(found_vents.len)
vent_found = pick(found_vents)
+15 -11
View File
@@ -78,13 +78,13 @@ var/list/slot_equipment_priority = list( \
if(istype(src.back,/obj/item/weapon/storage))
var/obj/item/weapon/storage/backpack = src.back
if(backpack.contents.len < backpack.storage_slots)
newitem.loc = src.back
newitem.forceMove(src.back)
return 1
// Try to place it in any item that can store stuff, on the mob.
for(var/obj/item/weapon/storage/S in src.contents)
if (S.contents.len < S.storage_slots)
newitem.loc = S
newitem.forceMove(S)
return 1
return 0
@@ -106,7 +106,7 @@ var/list/slot_equipment_priority = list( \
if(lying) return 0
if(!istype(W)) return 0
if(!l_hand)
W.loc = src //TODO: move to equipped?
W.forceMove(src) //TODO: move to equipped?
l_hand = W
W.layer = 20 //TODO: move to equipped?
// l_hand.screen_loc = ui_lhand
@@ -122,7 +122,7 @@ var/list/slot_equipment_priority = list( \
if(lying) return 0
if(!istype(W)) return 0
if(!r_hand)
W.loc = src
W.forceMove(src)
r_hand = W
W.layer = 20
// r_hand.screen_loc = ui_rhand
@@ -157,7 +157,7 @@ var/list/slot_equipment_priority = list( \
update_inv_r_hand()
return 1
else
W.loc = get_turf(src)
W.forceMove(get_turf(src))
W.layer = initial(W.layer)
W.dropped()
return 0
@@ -219,16 +219,20 @@ var/list/slot_equipment_priority = list( \
/mob/proc/canUnEquip(obj/item/I)
if(!I) //If there's nothing to drop, the drop is automatically successful.
return 1
var/slot = get_inventory_slot(I)
if(slot && !I.mob_can_unequip(src, slot))
return 0
drop_from_inventory(I)
return 1
/mob/proc/get_inventory_slot(obj/item/I)
var/slot
for(var/s in slot_back to slot_tie) //kind of worries me
if(get_equipped_item(s) == I)
slot = s
break
if(slot && !I.mob_can_unequip(src, slot))
return 0
return 1
return slot
//This differs from remove_from_mob() in that it checks if the item can be unequipped first.
/mob/proc/unEquip(obj/item/I, force = 0) //Force overrides NODROP for things like wizarditis and admin undress.
@@ -246,7 +250,7 @@ var/list/slot_equipment_priority = list( \
O.screen_loc = null
if(istype(O, /obj/item))
var/obj/item/I = O
I.loc = src.loc
I.forceMove(src.loc)
I.dropped(src)
return 1
+1 -1
View File
@@ -25,7 +25,7 @@
speech_verb = "says"
whisper_verb = "whispers"
key = "0"
flags = RESTRICTED | COMMON_VERBS
flags = RESTRICTED
syllables = list("blah","blah","blah","bleh","meh","neh","nah","wah")
//TODO flag certain languages to use the mob-type specific say_quote and then get rid of these.
+3 -3
View File
@@ -19,7 +19,7 @@
var/list/syllables // Used when scrambling text for a non-speaker.
var/list/space_chance = 55 // Likelihood of getting a space in the random scramble string
/datum/language/proc/get_random_name(var/gender, name_count=2, syllable_count=4)
/datum/language/proc/get_random_name(var/gender, name_count=2, syllable_count=4, syllable_divisor=2)
if(!syllables || !syllables.len)
if(gender==FEMALE)
return capitalize(pick(first_names_female)) + " " + capitalize(pick(last_names))
@@ -31,7 +31,7 @@
for(var/i = 0;i<name_count;i++)
new_name = ""
for(var/x = rand(Floor(syllable_count/2),syllable_count);x>0;x--)
for(var/x = rand(Floor(syllable_count/syllable_divisor),syllable_count);x>0;x--)
new_name += pick(syllables)
full_name += " [capitalize(lowertext(new_name))]"
@@ -136,7 +136,7 @@
var/datum/language/new_language = all_languages[language]
if(!istype(new_language) || new_language in languages)
if(!istype(new_language) || (new_language in languages))
return 0
languages.Add(new_language)
+9 -1
View File
@@ -123,7 +123,15 @@
colour = "alien"
key = "v"
flags = WHITELISTED
syllables = list("caw","caw","caw","caw","ka")
space_chance = 50
syllables = list(
"ca", "ra", "ma", "sa", "na", "ta", "la", "sha", "scha", "a", "a",
"ce", "re", "me", "se", "ne", "te", "le", "she", "sche", "e", "e",
"ci", "ri", "mi", "si", "ni", "ti", "li", "shi", "schi", "i", "i"
)
/datum/language/resomi/get_random_name(gender)
return ..(gender, 1, 4, 1.5)
//Syllable Lists
/*
+1 -1
View File
@@ -29,7 +29,7 @@
if(drone_only && !istype(S,/mob/living/silicon/robot/drone))
continue
else if(istype(S , /mob/living/silicon/ai))
message_start = "<i><span class='game say'>[name], <a href='byond://?src=\ref[S];track2=\ref[S];track=\ref[speaker];trackname=[html_encode(speaker.name)]'><span class='name'>[speaker.name]</span></a></span>"
message_start = "<i><span class='game say'>[name], <a href='byond://?src=\ref[S];track2=\ref[S];track=\ref[speaker];trackname=[html_encode(speaker.name)]'><span class='name'>[speaker.name]</span></a></span></i>"
else if (!S.binarycheck())
continue
+96
View File
@@ -0,0 +1,96 @@
#define AUTOHISS_OFF 0
#define AUTOHISS_BASIC 1
#define AUTOHISS_FULL 2
#define AUTOHISS_NUM 3
/mob/living/proc/handle_autohiss(message, datum/language/L)
return message // no autohiss at this level
/mob/living/carbon/human/handle_autohiss(message, datum/language/L)
if(!client || client.autohiss_mode == AUTOHISS_OFF) // no need to process if there's no client or they have autohiss off
return message
return species.handle_autohiss(message, L, client.autohiss_mode)
/client
var/autohiss_mode = AUTOHISS_OFF
/client/verb/toggle_autohiss()
set name = "Toggle Auto-Hiss"
set desc = "Toggle automatic hissing as Unathi and r-rolling as Taj"
set category = "OOC"
autohiss_mode = (autohiss_mode + 1) % AUTOHISS_NUM
switch(autohiss_mode)
if(AUTOHISS_OFF)
src << "Auto-hiss is now OFF."
if(AUTOHISS_BASIC)
src << "Auto-hiss is now BASIC."
if(AUTOHISS_FULL)
src << "Auto-hiss is now FULL."
else
soft_assert(0, "invalid autohiss value [autohiss_mode]")
autohiss_mode = AUTOHISS_OFF
src << "Auto-hiss is now OFF."
/datum/species
var/list/autohiss_basic_map = null
var/list/autohiss_extra_map = null
var/list/autohiss_exempt = null
/datum/species/unathi
autohiss_basic_map = list(
"s" = list("ss", "sss", "ssss")
)
autohiss_extra_map = list(
"x" = list("ks", "kss", "ksss")
)
autohiss_exempt = list("Sinta'unathi")
/datum/species/tajaran
autohiss_basic_map = list(
"r" = list("rr", "rrr", "rrrr")
)
autohiss_exempt = list("Siik'tajr")
/datum/species/proc/handle_autohiss(message, datum/language/lang, mode)
if(!autohiss_basic_map)
return message
if(autohiss_exempt && (lang.name in autohiss_exempt))
return message
var/map = autohiss_basic_map.Copy()
if(mode == AUTOHISS_FULL && autohiss_extra_map)
map |= autohiss_extra_map
. = list()
while(length(message))
var/min_index = 10000 // if the message is longer than this, the autohiss is the least of your problems
var/min_char = null
for(var/char in map)
var/i = findtext(message, char)
if(!i) // no more of this character anywhere in the string, don't even bother searching next time
map -= char
else if(i < min_index)
min_index = i
min_char = char
if(!min_char) // we didn't find any of the mapping characters
. += message
break
. += copytext(message, 1, min_index)
if(copytext(message, min_index, min_index+1) == uppertext(min_char))
. += capitalize(pick(map[min_char]))
else
. += pick(map[min_char])
message = copytext(message, min_index + 1)
return list2text(.)
#undef AUTOHISS_OFF
#undef AUTOHISS_BASIC
#undef AUTOHISS_FULL
#undef AUTOHISS_NUM
-253
View File
@@ -1,253 +0,0 @@
/mob/living/blob
name = "blob fragment"
real_name = "blob fragment"
icon = 'icons/mob/blob.dmi'
icon_state = "blob_spore_temp"
pass_flags = PASSBLOB
see_in_dark = 8
see_invisible = SEE_INVISIBLE_LEVEL_TWO
var/ghost_name = "Unknown"
var/creating_blob = 0
faction = "blob"
use_me = 0 //Blobs can't emote
New()
real_name += " [pick(rand(1, 99))]"
name = real_name
..()
say(var/message)
return//No talking for you
emote(var/act,var/m_type=1,var/message = null)
return
Life()
set invisibility = 0
set background = 1
clamp_values()
UpdateDamage()
if(health < 0)
src.dust()
proc/clamp_values()
AdjustStunned(0)
AdjustParalysis(0)
AdjustWeakened(0)
sleeping = 0
if(stat)
stat = CONSCIOUS
return
proc/UpdateDamage()
health = 60 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
return
death(gibbed)
ghostize()
..(gibbed)
blob_act()
src << "The blob attempts to reabsorb you."
adjustToxLoss(20)
return
Process_Spacemove()
if(locate(/obj/effect/blob) in oview(1,src))
return 1
return (..())
/mob/living/blob/verb/create_node()
set category = "Blob"
set name = "Create Node"
set desc = "Create a Node."
if(creating_blob) return
var/turf/T = get_turf(src)
creating_blob = 1
if(!T)
creating_blob = 0
return
var/obj/effect/blob/B = (locate(/obj/effect/blob) in T)
if(!B)//We are on a blob
usr << "There is no blob here!"
creating_blob = 0
return
if(istype(B,/obj/effect/blob/node)||istype(B,/obj/effect/blob/core)||istype(B,/obj/effect/blob/factory))
usr << "Unable to use this blob, find a normal one."
creating_blob = 0
return
for(var/obj/effect/blob/node/blob in orange(5))
usr << "There is another node nearby, move more than 5 tiles away from it!"
creating_blob = 0
return
for(var/obj/effect/blob/factory/blob in orange(2))
usr << "There is a porus blob nearby, move more than 2 tiles away from it!"
creating_blob = 0
B.change_to("Node")
src.dust()
return
/mob/living/blob/verb/create_factory()
set category = "Blob"
set name = "Create Defense"
set desc = "Create a Spore producing blob."
if(creating_blob) return
var/turf/T = get_turf(src)
creating_blob = 1
if(!T)
creating_blob = 0
return
var/obj/effect/blob/B = (locate(/obj/effect/blob) in T)
if(!B)
usr << "You must be on a blob!"
creating_blob = 0
return
if(istype(B,/obj/effect/blob/node)||istype(B,/obj/effect/blob/core)||istype(B,/obj/effect/blob/factory))
usr << "Unable to use this blob, find a normal one."
creating_blob = 0
return
for(var/obj/effect/blob/blob in orange(2))//Not right next to nodes/cores
if(istype(B,/obj/effect/blob/node))
usr << "There is a node nearby, move away from it!"
creating_blob = 0
return
if(istype(B,/obj/effect/blob/core))
usr << "There is a core nearby, move away from it!"
creating_blob = 0
return
if(istype(B,/obj/effect/blob/factory))
usr << "There is another porous blob nearby, move away from it!"
creating_blob = 0
return
B.change_to("Factory")
src.dust()
return
/mob/living/blob/verb/revert()
set category = "Blob"
set name = "Purge Defense"
set desc = "Removes a porous blob."
if(creating_blob) return
var/turf/T = get_turf(src)
creating_blob = 1
if(!T)
creating_blob = 0
return
var/obj/effect/blob/B = (locate(/obj/effect/blob) in T)
if(!B)
usr << "You must be on a blob!"
creating_blob = 0
return
if(!istype(B,/obj/effect/blob/factory))
usr << "Unable to use this blob, find another one."
creating_blob = 0
return
B.change_to("Normal")
src.dust()
return
/mob/living/blob/verb/spawn_blob()
set category = "Blob"
set name = "Create new blob"
set desc = "Attempts to create a new blob in this tile."
if(creating_blob) return
var/turf/T = get_turf(src)
creating_blob = 1
if(!T)
creating_blob = 0
return
var/obj/effect/blob/B = (locate(/obj/effect/blob) in T)
if(B)
usr << "There is a blob here!"
creating_blob = 0
return
new/obj/effect/blob(src.loc)
src.dust()
return
///mob/proc/Blobize()
/client/proc/Blobcount()
set category = "Debug"
set name = "blobreport"
set desc = "blob report."
set hidden = 1
if(!holder)
src << "Only administrators may use this command."
return
if(ticker && ticker.mode)
src << "blobs: [blobs.len]"
src << "cores: [blob_cores.len]"
src << "nodes: [blob_nodes.len]"
return
/client/proc/Blobize()//Mostly stolen from the respawn command
set category = "Debug"
set name = "Ghostblob"
set desc = "Ghost into blobthing."
set hidden = 1
if(!holder)
src << "Only administrators may use this command."
return
var/input = input(src, "Please specify which key will be turned into a bloby.", "Key", "")
var/mob/dead/observer/G_found
if(!input)
var/list/ghosts = list()
for(var/mob/dead/observer/G in player_list)
ghosts += G
if(ghosts.len)
G_found = pick(ghosts)
else
for(var/mob/dead/observer/G in player_list)
if(G.client&&ckey(G.key)==ckey(input))
G_found = G
break
if(!G_found)//If a ghost was not found.
alert("There is no active key like that in the game or the person is not currently a ghost. Aborting command.")
return
if(G_found.client)
G_found.client.screen.len = null
var/mob/living/blob/B = new/mob/living/blob(locate(0,0,1))//temp area also just in case should do this better but tired
if(blob_cores.len > 0)
var/obj/effect/blob/core/core = pick(blob_cores)
if(core)
B.loc = core.loc
B.ghost_name = G_found.real_name
if (G_found.client)
G_found.client.mob = B
B.verbs += /mob/living/blob/verb/create_node
B.verbs += /mob/living/blob/verb/create_factory
B << "<B>You are now a blob fragment.</B>"
B << "You are a weak bit that has temporarily broken off of the blob."
B << "If you stay on the blob for too long you will likely be reabsorbed."
B << "If you stray from the blob you will likely be killed by other organisms."
B << "You have the power to create a new blob node that will help expand the blob."
B << "To create this node you will have to be on a normal blob tile and far enough away from any other node."
B << "Check your Blob verbs and hit Create Node to build a node."
spawn(10)
qdel(G_found)
+6
View File
@@ -70,6 +70,11 @@
else
icon_state = "secbot[on]"
if(on)
set_light(2, 1, "#FF6A00")
else
set_light(0)
/mob/living/bot/secbot/attack_hand(var/mob/user)
user.set_machine(src)
var/dat
@@ -183,6 +188,7 @@
if(!Adjacent(target))
awaiting_surrender = 5 // I'm done playing nice
mode = SECBOT_HUNT
return
var/threat = check_threat(target)
if(threat < 4)
target = null
@@ -31,26 +31,3 @@
adjustFireLoss(f_loss)
updatehealth()
/mob/living/carbon/alien/blob_act()
if (stat == 2)
return
var/shielded = 0
var/damage = null
if (stat != 2)
damage = rand(10,30)
if(shielded)
damage /= 4
//paralysis += 1
show_message("\red The blob attacks you!")
adjustFireLoss(damage)
updatehealth()
return
+1 -1
View File
@@ -262,7 +262,7 @@
var/show_ssd
var/mob/living/carbon/human/H = src
if(istype(H)) show_ssd = H.species.show_ssd
if(show_ssd && !client && !aghosted)
if(show_ssd && !client && !teleop)
M.visible_message("<span class='notice'>[M] shakes [src] trying to wake [t_him] up!</span>", \
"<span class='notice'>You shake [src], but they do not respond... Maybe they have S.S.D?</span>")
else if(lying || src.sleeping)
+23 -14
View File
@@ -168,15 +168,6 @@
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if(update) UpdateDamageIcon()
/mob/living/carbon/human/blob_act()
if(stat == 2) return
show_message("\red The blob attacks you!")
var/dam_zone = pick(organs_by_name)
var/obj/item/organ/external/affecting = get_organ(ran_zone(dam_zone))
apply_damage(rand(30,40), BRUTE, affecting, run_armor_check(affecting, "melee"))
return
/mob/living/carbon/human/proc/implant_loyalty(mob/living/carbon/human/M, override = FALSE) // Won't override by default.
if(!config.use_loyalty_implants && !override) return // Nuh-uh.
@@ -238,7 +229,7 @@
// Other incidentals.
if(istype(suit) && suit.has_sensor == 1)
dat += "<BR><A href='?src=\ref[src];item=sensors'>Set sensors.</A>"
dat += "<BR><A href='?src=\ref[src];item=sensors'>Set sensors</A>"
if(handcuffed)
dat += "<BR><A href='?src=\ref[src];item=[slot_handcuffed]'>Handcuffed</A>"
if(legcuffed)
@@ -696,6 +687,28 @@
number += 2
return number
//Used by various things that knock people out by applying blunt trauma to the head.
//Checks that the species has a "head" (brain containing organ) and that hit_zone refers to it.
/mob/living/carbon/human/proc/headcheck(var/target_zone, var/brain_tag = "brain")
if(!species.has_organ[brain_tag])
return 0
var/obj/item/organ/affecting = internal_organs_by_name[brain_tag]
target_zone = check_zone(target_zone)
if(!affecting || affecting.parent_organ != target_zone)
return 0
//if the parent organ is significantly larger than the brain organ, then hitting it is not guaranteed
var/obj/item/organ/parent = get_organ(target_zone)
if(!parent)
return 0
if(parent.w_class > affecting.w_class + 1)
return prob(100 / 2**(parent.w_class - affecting.w_class - 1))
return 1
/mob/living/carbon/human/IsAdvancedToolUser(var/silent)
if(species.has_fine_manipulation)
return 1
@@ -1155,10 +1168,6 @@
else
return 0
mob_bump_flag = species.bump_flag
mob_swap_flags = species.swap_flags
mob_push_flags = species.push_flags
/mob/living/carbon/human/proc/bloody_doodle()
set category = "IC"
set name = "Write in blood"
@@ -155,7 +155,7 @@ emp_act
if(user == src) // Attacking yourself can't miss
target_zone = user.zone_sel.selecting
if(!target_zone)
visible_message("\red <B>[user] misses [src] with \the [I]!")
visible_message("<span class='danger'>[user] misses [src] with \the [I]!</span>")
return 1
var/obj/item/organ/external/affecting = get_organ(target_zone)
@@ -219,29 +219,32 @@ emp_act
H.bloody_hands(src)
if(!stat)
if(headcheck(hit_area))
//Harder to score a stun but if you do it lasts a bit longer
if(prob(effective_force))
apply_effect(20, PARALYZE, armor)
visible_message("<span class='danger'>[src] [species.knockout_message]</span>")
else
//Easier to score a stun but lasts less time
if(prob(effective_force + 10))
apply_effect(6, WEAKEN, armor)
visible_message("<span class='danger'>[src] has been knocked down!</span>")
//Apply blood
if(bloody)
switch(hit_area)
if("head")//Harder to score a stun but if you do it lasts a bit longer
if(prob(effective_force))
apply_effect(20, PARALYZE, armor)
visible_message("\red <B>[src] has been knocked unconscious!</B>")
if(bloody)//Apply blood
if(wear_mask)
wear_mask.add_blood(src)
update_inv_wear_mask(0)
if(head)
head.add_blood(src)
update_inv_head(0)
if(glasses && prob(33))
glasses.add_blood(src)
update_inv_glasses(0)
if("chest")//Easier to score a stun but lasts less time
if(prob((effective_force + 10)))
apply_effect(6, WEAKEN, armor)
visible_message("\red <B>[src] has been knocked down!</B>")
if(bloody)
bloody_body(src)
if("head")
if(wear_mask)
wear_mask.add_blood(src)
update_inv_wear_mask(0)
if(head)
head.add_blood(src)
update_inv_head(0)
if(glasses && prob(33))
glasses.add_blood(src)
update_inv_glasses(0)
if("chest")
bloody_body(src)
if(Iforce > 10 || Iforce >= 5 && prob(33))
forcesay(hit_appends) //forcesay checks stat already
+7 -35
View File
@@ -159,7 +159,7 @@
for(var/mob/O in viewers(src, null))
if(O == src)
continue
O.show_message(text("\red <B>[src] starts having a seizure!"), 1)
O.show_message(text("<span class='danger'>[src] starts having a seizure!</span>"), 1)
Paralyse(10)
make_jittery(1000)
if (disabilities & COUGHING)
@@ -920,11 +920,7 @@
if(status_flags & GODMODE) return 0
//SSD check, if a logged player is awake put them back to sleep!
if(species.show_ssd && !client && !aghosted)
sleeping = 2
//SSD check, if a logged player is awake put them back to sleep!
if(species.show_ssd && !client && !aghosted)
if(species.show_ssd && !client && !teleop)
Sleeping(2)
if(stat == DEAD) //DEAD. BROWN BREAD. SWIMMING WITH THE SPESS CARP
blinded = 1
@@ -1684,35 +1680,11 @@
if (BITTEST(hud_updateflag, SPECIALROLE_HUD))
var/image/holder = hud_list[SPECIALROLE_HUD]
holder.icon_state = "hudblank"
if(mind)
// TODO: Update to new antagonist system.
switch(mind.special_role)
if("traitor","Mercenary")
holder.icon_state = "hudsyndicate"
if("Revolutionary")
holder.icon_state = "hudrevolutionary"
if("Head Revolutionary")
holder.icon_state = "hudheadrevolutionary"
if("Cultist")
holder.icon_state = "hudcultist"
if("Changeling")
holder.icon_state = "hudchangeling"
if("Wizard","Fake Wizard")
holder.icon_state = "hudwizard"
if("Death Commando")
holder.icon_state = "huddeathsquad"
if("Ninja")
holder.icon_state = "hudninja"
if("head_loyalist")
holder.icon_state = "hudloyalist"
if("loyalist")
holder.icon_state = "hudloyalist"
if("head_mutineer")
holder.icon_state = "hudmutineer"
if("mutineer")
holder.icon_state = "hudmutineer"
if(mind && mind.special_role)
if(hud_icon_reference[mind.special_role])
holder.icon_state = hud_icon_reference[mind.special_role]
else
holder.icon_state = "hudsyndicate"
hud_list[SPECIALROLE_HUD] = holder
hud_updateflag = 0
@@ -28,7 +28,7 @@
var/tail_hair
var/race_key = 0 // Used for mob icon cache string.
var/icon/icon_template // Used for mob icon generation for non-32x32 species.
var/is_small
var/mob_size = MOB_MEDIUM
var/show_ssd = "fast asleep"
var/virus_immune
var/short_sighted
@@ -40,6 +40,7 @@
var/list/speech_sounds // A list of sounds to potentially play when speaking.
var/list/speech_chance // The likelihood of a speech sound playing.
var/num_alternate_languages = 0 // How many secondary languages are available to select at character creation
var/name_language = "Galactic Common" // The language to use when determining names for this species, or null to use the first name/last name generator
// Combat vars.
var/total_health = 100 // Point at which the mob will enter crit.
@@ -65,6 +66,7 @@
var/dusted_anim = "dust-h"
var/death_sound
var/death_message = "seizes up and falls limp, their eyes dead and lifeless..."
var/knockout_message = "has been knocked unconscious!"
// Environment tolerance/life processes vars.
var/reagent_tag //Used for metabolizing reagents.
@@ -148,6 +150,8 @@
var/push_flags = ~HEAVY // What can we push?
var/swap_flags = ~HEAVY // What can we swap place with?
var/pass_flags = 0
/datum/species/New()
if(hud_type)
hud = new hud_type()
@@ -195,7 +199,13 @@
H << "<span class='danger'>[pick(heat_discomfort_strings)]</span>"
/datum/species/proc/get_random_name(var/gender)
var/datum/language/species_language = all_languages[language]
if(!name_language)
if(gender == FEMALE)
return capitalize(pick(first_names_female)) + " " + capitalize(pick(last_names))
else
return capitalize(pick(first_names_male)) + " " + capitalize(pick(last_names))
var/datum/language/species_language = all_languages[name_language]
if(!species_language)
species_language = all_languages[default_language]
if(!species_language)
@@ -271,6 +281,11 @@
/datum/species/proc/handle_post_spawn(var/mob/living/carbon/human/H) //Handles anything not already covered by basic species assignment.
add_inherent_verbs(H)
H.mob_bump_flag = bump_flag
H.mob_swap_flags = swap_flags
H.mob_push_flags = push_flags
H.pass_flags = pass_flags
H.mob_size = mob_size
/datum/species/proc/handle_death(var/mob/living/carbon/human/H) //Handles any species-specific death events (such as dionaea nymph spawns).
return
@@ -11,7 +11,7 @@
language = null
default_language = "Chimpanzee"
greater_form = "Human"
is_small = 1
mob_size = MOB_SMALL
has_fine_manipulation = 0
show_ssd = null
@@ -38,6 +38,8 @@
swap_flags = MONKEY|SLIME|SIMPLE_ANIMAL
push_flags = MONKEY|SLIME|SIMPLE_ANIMAL|ALIEN
pass_flags = PASSTABLE
/datum/species/monkey/handle_npc(var/mob/living/carbon/human/H)
if(H.stat != CONSCIOUS)
return
@@ -8,6 +8,7 @@
num_alternate_languages = 2
secondary_langs = list("Resomi")
name_language = "Resomi"
blood_color = "#D514F7"
flesh_color = "#5F7BB0"
@@ -26,7 +27,7 @@
total_health = 50
brute_mod = 1.35
burn_mod = 1.35
is_small = 1
mob_size = MOB_SMALL
holder_type = /obj/item/weapon/holder/human
short_sighted = 1
gluttonous = 1
@@ -1,7 +1,7 @@
/datum/species/slime
name = "Slime"
name_plural = "slimes"
is_small = 1
mob_size = MOB_SMALL
icobase = 'icons/mob/human_races/r_slime.dmi'
deform = 'icons/mob/human_races/r_slime.dmi'
@@ -10,6 +10,7 @@
worlds tumultous at best."
num_alternate_languages = 2
secondary_langs = list("Sol Common")
name_language = null // Use the first-name last-name generator rather than a language scrambler
spawn_flags = CAN_JOIN
appearance_flags = HAS_HAIR_COLOR | HAS_SKIN_TONE | HAS_LIPS | HAS_UNDERWEAR | HAS_EYE_COLOR
@@ -32,6 +33,7 @@
brute_mod = 0.8
num_alternate_languages = 2
secondary_langs = list("Sinta'unathi")
name_language = "Sinta'unathi"
blurb = "A heavily reptillian species, Unathi (or 'Sinta as they call themselves) hail from the \
Uuosa-Eso system, which roughly translates to 'burning mother'.<br/><br/>Coming from a harsh, radioactive \
@@ -88,6 +90,7 @@
gluttonous = 1
num_alternate_languages = 2
secondary_langs = list("Siik'tajr")
name_language = "Siik'tajr"
blurb = "The Tajaran race is a species of feline-like bipeds hailing from the planet of Ahdomai in the \
S'randarr system. They have been brought up into the space age by the Humans and Skrell, and have been \
@@ -138,6 +141,7 @@
the secrets of their empire to their allies."
num_alternate_languages = 2
secondary_langs = list("Skrellian")
name_language = null
spawn_flags = CAN_JOIN | IS_WHITELISTED
appearance_flags = HAS_HAIR_COLOR | HAS_LIPS | HAS_UNDERWEAR | HAS_SKIN_COLOR
@@ -163,7 +167,7 @@
eyes = "blank_eyes"
show_ssd = "completely quiescent"
num_alternate_languages = 1
name_language = "Rootspeak"
blurb = "Commonly referred to (erroneously) as 'plant people', the Dionaea are a strange space-dwelling collective \
species hailing from Epsilon Ursae Minoris. Each 'diona' is a cluster of numerous cat-sized organisms called nymphs; \
@@ -269,11 +273,14 @@
unarmed_types = list(/datum/unarmed_attack/punch)
rarity_value = 2
num_alternate_languages = 1 // potentially could be 2?
name_language = "Encoded Audio Language"
eyes = "blank_eyes"
brute_mod = 1.875 // 100% * 1.875 * 0.8 (robolimbs) ~= 150%
burn_mod = 1.875 // So they take 50% extra damage from brute/burn overall.
show_ssd = "flashing a 'system offline' glyph on their monitor"
death_message = "gives one shrill beep before falling lifeless."
knockout_message = "encounters a hardware fault and suddenly reboots!"
warning_low_pressure = 50
hazard_low_pressure = 0
@@ -113,24 +113,25 @@ Please contact me on #coderbus IRC. ~Carn x
#define ID_LAYER 5
#define SHOES_LAYER 6
#define GLOVES_LAYER 7
#define SUIT_LAYER 8
#define TAIL_LAYER 9 //bs12 specific. this hack is probably gonna come back to haunt me
#define GLASSES_LAYER 10
#define BELT_LAYER 11 //Possible make this an overlay of somethign required to wear a belt?
#define SUIT_STORE_LAYER 12
#define BACK_LAYER 13
#define HAIR_LAYER 14 //TODO: make part of head layer?
#define EARS_LAYER 15
#define FACEMASK_LAYER 16
#define HEAD_LAYER 17
#define COLLAR_LAYER 18
#define HANDCUFF_LAYER 19
#define LEGCUFF_LAYER 20
#define L_HAND_LAYER 21
#define R_HAND_LAYER 22
#define FIRE_LAYER 23 //If you're on fire
#define TARGETED_LAYER 24 //BS12: Layer for the target overlay from weapon targeting system
#define TOTAL_LAYERS 24
#define BELT_LAYER 8
#define SUIT_LAYER 9
#define TAIL_LAYER 10 //bs12 specific. this hack is probably gonna come back to haunt me
#define GLASSES_LAYER 11
#define BELT_LAYER_ALT 12
#define SUIT_STORE_LAYER 13
#define BACK_LAYER 14
#define HAIR_LAYER 15 //TODO: make part of head layer?
#define EARS_LAYER 16
#define FACEMASK_LAYER 17
#define HEAD_LAYER 18
#define COLLAR_LAYER 19
#define HANDCUFF_LAYER 20
#define LEGCUFF_LAYER 21
#define L_HAND_LAYER 22
#define R_HAND_LAYER 23
#define FIRE_LAYER 24 //If you're on fire
#define TARGETED_LAYER 25 //BS12: Layer for the target overlay from weapon targeting system
#define TOTAL_LAYERS 25
//////////////////////////////////
/mob/living/carbon/human
@@ -718,15 +719,24 @@ var/global/list/damage_icon_parts = list()
else
standing.icon = 'icons/mob/belt.dmi'
if(belt.contents.len && istype(belt, /obj/item/weapon/storage/belt))
for(var/obj/item/i in belt.contents)
var/i_state = i.item_state
if(!i_state) i_state = i.icon_state
standing.overlays += image("icon" = 'icons/mob/belt.dmi', "icon_state" = "[i_state]")
var/belt_layer = BELT_LAYER
if(istype(belt, /obj/item/weapon/storage/belt))
var/obj/item/weapon/storage/belt/ubelt = belt
if(ubelt.show_above_suit)
overlays_standing[BELT_LAYER] = null
belt_layer = BELT_LAYER_ALT
else
overlays_standing[BELT_LAYER_ALT] = null
if(belt.contents.len)
for(var/obj/item/i in belt.contents)
var/i_state = i.item_state
if(!i_state) i_state = i.icon_state
standing.overlays += image("icon" = 'icons/mob/belt.dmi', "icon_state" = "[i_state]")
overlays_standing[BELT_LAYER] = standing
overlays_standing[belt_layer] = standing
else
overlays_standing[BELT_LAYER] = null
overlays_standing[BELT_LAYER_ALT] = null
if(update_icons) update_icons()
@@ -194,26 +194,6 @@
updatehealth()
/mob/living/carbon/slime/blob_act()
if (stat == 2)
return
var/shielded = 0
var/damage = null
if (stat != 2)
damage = rand(10,30)
if(shielded)
damage /= 4
show_message("<span class='danger'> The blob attacks you!</span>")
adjustFireLoss(damage)
updatehealth()
return
/mob/living/carbon/slime/u_equip(obj/item/W as obj)
return
+1 -1
View File
@@ -2,7 +2,7 @@
/mob/living/carbon/process_resist()
//drop && roll
if(on_fire)
if(on_fire && !buckled)
fire_stacks -= 1.2
Weaken(3)
spin(32,2)
+2 -2
View File
@@ -41,7 +41,7 @@
/mob/living/proc/apply_effect(var/effect = 0,var/effecttype = STUN, var/blocked = 0)
/mob/living/proc/apply_effect(var/effect = 0,var/effecttype = STUN, var/blocked = 0, var/check_protection = 1)
if(!effect || (blocked >= 2)) return 0
switch(effecttype)
if(STUN)
@@ -53,7 +53,7 @@
if(AGONY)
halloss += effect // Useful for objects that cause "subdual" damage. PAIN!
if(IRRADIATE)
var/rad_protection = getarmor(null, "rad")/100
var/rad_protection = check_protection ? getarmor(null, "rad")/100 : 0
radiation += max((1-rad_protection)*effect/(blocked+1),0)//Rads auto check armor
if(STUTTER)
if(status_flags & CANSTUN) // stun is usually associated with stutter
+10 -31
View File
@@ -87,8 +87,8 @@ default behaviour is:
if((tmob.mob_always_swap || (tmob.a_intent == I_HELP || tmob.restrained()) && (a_intent == I_HELP || src.restrained())) && tmob.canmove && canmove && !dense && can_move_mob(tmob, 1, 0)) // mutual brohugs all around!
var/turf/oldloc = loc
loc = tmob.loc
tmob.loc = oldloc
forceMove(tmob.loc)
tmob.forceMove(oldloc)
now_pushing = 0
for(var/mob/living/carbon/slime/slime in view(1,tmob))
if(slime.Victim == tmob)
@@ -573,21 +573,12 @@ default behaviour is:
set name = "Resist"
set category = "IC"
if(can_resist())
if(!(stat || next_move > world.time))
setClickCooldown(20)
resist_grab()
if(!weakened && !restrained())
if(!weakened)
process_resist()
/mob/living/proc/can_resist()
//need to allow !canmove, or otherwise neck grabs can't be resisted
//similar thing with weakened and pinning
if(stat)
return 0
if(!canClick())
return 0
return 1
/mob/living/proc/process_resist()
//Getting out of someone's inventory.
if(istype(src.loc, /obj/item/weapon/holder))
@@ -614,7 +605,7 @@ default behaviour is:
src << "<span class='warning'>You wriggle out of [M]'s grip!</span>"
else if(istype(H.loc,/obj/item))
src << "<span class='warning'>You struggle free of [H.loc].</span>"
H.loc = get_turf(H)
H.forceMove(get_turf(H))
if(istype(M))
for(var/atom/A in M.contents)
@@ -655,27 +646,15 @@ default behaviour is:
set category = "IC"
resting = !resting
src << "<span class='notice'>You are now [resting ? "resting" : "getting up"].</span>"
src << "<span class='notice'>You are now [resting ? "resting" : "getting up"]</span>"
/mob/living/proc/is_allowed_vent_crawl_item(var/obj/item/carried_item)
if(istype(carried_item, /obj/item/weapon/implant))
return 1
if(istype(carried_item, /obj/item/clothing/mask/facehugger))
return 1
return 0
/mob/living/carbon/is_allowed_vent_crawl_item(var/obj/item/carried_item)
if(carried_item in internal_organs)
return 1
return ..()
/mob/living/carbon/human/is_allowed_vent_crawl_item(var/obj/item/carried_item)
if(carried_item in organs)
return 1
return ..()
return isnull(get_inventory_slot(carried_item))
/mob/living/simple_animal/spiderbot/is_allowed_vent_crawl_item(var/obj/item/carried_item)
return carried_item != held_item
if(carried_item == held_item)
return 0
return ..()
/mob/living/proc/handle_ventcrawl(var/obj/machinery/atmospherics/unary/vent_pump/vent_found = null, var/ignore_items = 0) // -- TLE -- Merged by Carn
if(stat)
+1 -1
View File
@@ -230,7 +230,7 @@
/mob/living/proc/handle_fire()
if(fire_stacks < 0)
fire_stacks = min(0, fire_stacks++) //If we've doused ourselves in water to avoid fire, dry off slowly
fire_stacks = min(0, ++fire_stacks) //If we've doused ourselves in water to avoid fire, dry off slowly
if(!on_fire)
return 1
@@ -39,10 +39,7 @@
var/tod = null // Time of death
var/update_slimes = 1
var/silent = null // Can't talk. Value goes down every life proc.
var/mob_size // Used by lockers.
var/on_fire = 0 //The "Are we on fire?" var
var/fire_stacks
var/failed_last_breath = 0 //This is used to determine if the mob failed a breath. If they did fail a brath, they will attempt to breathe each tick, otherwise just once per 4 ticks.
+9 -13
View File
@@ -161,19 +161,13 @@ proc/get_radio_key_from_channel(var/channel)
else
speaking = get_default_language()
if (speaking)
// This is broadcast to all mobs with the language,
// irrespective of distance or anything else.
if(speaking.flags & HIVEMIND)
speaking.broadcast(src,trim(message))
return 1
//If we've gotten this far, keep going!
if(speaking.flags & COMMON_VERBS)
verb = say_quote(message)
else
verb = speaking.get_spoken_verb(copytext(message, length(message)))
else
verb = say_quote(message)
// This is broadcast to all mobs with the language,
// irrespective of distance or anything else.
if(speaking && (speaking.flags & HIVEMIND))
speaking.broadcast(src,trim(message))
return 1
verb = say_quote(message, speaking)
if(is_muzzled())
src << "<span class='danger'>You're muzzled and cannot speak!</span>"
@@ -182,6 +176,8 @@ proc/get_radio_key_from_channel(var/channel)
message = trim_left(message)
if(!(speaking && (speaking.flags & NO_STUTTER)))
message = handle_autohiss(message, speaking)
var/list/handle_s = handle_speech_problems(message, verb)
message = handle_s[1]
verb = handle_s[2]
+2 -2
View File
@@ -128,8 +128,8 @@ var/list/ai_verbs_default = list(
aiRadio = new(src)
common_radio = aiRadio
aiRadio.myAi = src
additional_law_channels += "Binary"
additional_law_channels += "Holopad"
additional_law_channels["Binary"] = ":b"
additional_law_channels["Holopad"] = ":h"
aiCamera = new/obj/item/device/camera/siliconcam/ai_camera(src)
+1 -1
View File
@@ -79,7 +79,7 @@
//Blind the AI
updateicon()
src.blind.screen_loc = "1,1 to 15,15"
src.blind.screen_loc = ui_entire_screen
if (src.blind.layer!=18)
src.blind.layer = 18
src.sight = src.sight&~SEE_TURFS
+2 -2
View File
@@ -6,12 +6,12 @@
flash = new /obj/screen()
flash.icon_state = "blank"
flash.name = "flash"
flash.screen_loc = "1,1 to 15,15"
flash.screen_loc = ui_entire_screen
flash.layer = 17
blind = new /obj/screen()
blind.icon_state = "black"
blind.name = " "
blind.screen_loc = "1,1 to 15,15"
blind.screen_loc = ui_entire_screen
blind.layer = 0
client.screen.Add( blind, flash )
+1 -2
View File
@@ -136,6 +136,5 @@
// Cleaner proc for creating powersupply for an AI.
/mob/living/silicon/ai/proc/create_powersupply()
if(psupply)
del(psupply)
qdel(psupply)
psupply = new/obj/machinery/ai_powersupply(src)
+7 -6
View File
@@ -1,6 +1,6 @@
/mob/living/silicon
var/datum/ai_laws/laws = null
var/list/additional_law_channels = list("State")
var/list/additional_law_channels = list("State" = "")
/mob/living/silicon/proc/laws_sanity_check()
if (!src.laws)
@@ -59,11 +59,12 @@
/mob/living/silicon/proc/statelaws(var/datum/ai_laws/laws)
var/prefix = ""
switch(lawchannel)
if(MAIN_CHANNEL) prefix = ";"
if("Binary") prefix = ":b "
else
prefix = get_radio_key_from_channel(lawchannel == "Holopad" ? "department" : lawchannel) + " "
if(MAIN_CHANNEL == lawchannel)
prefix = ";"
else if(lawchannel in additional_law_channels)
prefix = additional_law_channels[lawchannel]
else
prefix = get_radio_key_from_channel(lawchannel)
dostatelaws(lawchannel, prefix, laws)
+4 -8
View File
@@ -4,8 +4,8 @@
icon_state = "repairbot"
emote_type = 2 // pAIs emotes are heard, not seen, so they can be seen through a container (eg. person)
small = 1
pass_flags = 1
mob_size = MOB_SMALL
var/network = "SS13"
var/obj/machinery/camera/current = null
@@ -119,13 +119,6 @@
return -1
return 0
/mob/living/silicon/pai/blob_act()
if (src.stat != 2)
src.adjustBruteLoss(60)
src.updatehealth()
return 1
return 0
/mob/living/silicon/pai/restrained()
if(istype(src.loc,/obj/item/device/paicard))
return 0
@@ -379,6 +372,9 @@
src.client.perspective = EYE_PERSPECTIVE
src.client.eye = card
//stop resting
resting = 0
// If we are being held, handle removing our holder from their inv.
var/obj/item/weapon/holder/H = loc
if(istype(H))
@@ -42,6 +42,8 @@ var/list/mob_hat_cache = list()
mob_push_flags = SIMPLE_ANIMAL
mob_always_swap = 1
mob_size = MOB_TINY
//Used for self-mailing.
var/mail_destination = ""
var/obj/machinery/drone_fabricator/master_fabricator
@@ -68,6 +70,7 @@ var/list/mob_hat_cache = list()
can_pull_mobs = 1
hat_x_offset = 1
hat_y_offset = -12
mob_size = MOB_SMALL
/mob/living/silicon/robot/drone/New()
@@ -95,7 +98,7 @@ var/list/mob_hat_cache = list()
/mob/living/silicon/robot/drone/init()
aiCamera = new/obj/item/device/camera/siliconcam/drone_camera(src)
additional_law_channels["Drone"] = ":d"
if(!laws) laws = new law_type
if(!module) module = new module_type(src)
@@ -30,7 +30,7 @@
for(var/mob/living/silicon/robot/drone/D in world)
if(D.z != src.z)
continue
dat += "<BR>[D.real_name] ([D.stat == 2 ? "<font color='red'>INACTIVE" : "<font color='green'>ACTIVE"]</FONT>)"
dat += "<BR>[D.real_name] ([D.stat == 2 ? "<font color='red'>INACTIVE</FONT>" : "<font color='green'>ACTIVE</FONT>"])"
dat += "<font dize = 9><BR>Cell charge: [D.cell.charge]/[D.cell.maxcharge]."
dat += "<BR>Currently located in: [get_area(D)]."
dat += "<BR><A href='?src=\ref[src];resync=\ref[D]'>Resync</A> | <A href='?src=\ref[src];shutdown=\ref[D]'>Shutdown</A></font>"
@@ -22,7 +22,7 @@
src << "<b>Laws synced with AI, be sure to note any changes.</b>"
// TODO: Update to new antagonist system.
if(mind && mind.special_role == "traitor" && mind.original == src)
src << "<b>Remember, your AI does NOT share or know about your law 0."
src << "<b>Remember, your AI does NOT share or know about your law 0.</b>"
else
src << "<b>No AI selected to sync laws with, disabling lawsync protocol.</b>"
lawupdate = 0
@@ -314,7 +314,7 @@
killswitch_time --
if(killswitch_time <= 0)
if(src.client)
src << "\red <B>Killswitch Activated"
src << "<span class='danger'>Killswitch Activated</span>"
killswitch = 0
spawn(5)
gib()
@@ -325,7 +325,7 @@
weaponlock_time --
if(weaponlock_time <= 0)
if(src.client)
src << "\red <B>Weapon Lock Timed Out!"
src << "<span class='danger'>Weapon Lock Timed Out!</span>"
weapon_lock = 0
weaponlock_time = 120
@@ -155,7 +155,7 @@
/mob/living/silicon/robot/proc/init()
aiCamera = new/obj/item/device/camera/siliconcam/robot_camera(src)
laws = new /datum/ai_laws/nanotrasen()
additional_law_channels += "Binary"
additional_law_channels["Binary"] = ":b"
var/new_ai = select_active_ai_with_fewest_borgs()
if(new_ai)
lawupdate = 1
@@ -214,7 +214,9 @@
mmi = null
if(connected_ai)
connected_ai.connected_robots -= src
..()
qdel(wires)
wires = null
return ..()
/mob/living/silicon/robot/proc/set_module_sprites(var/list/new_sprites)
module_sprites = new_sprites.Copy()
@@ -34,7 +34,7 @@ var/global/list/robot_modules = list(
var/list/obj/item/borg/upgrade/supported_upgrades = list()
// Bookkeeping
var/list/added_languages = list()
var/list/original_languages = list()
var/list/added_networks = list()
/obj/item/weapon/robot_module/New(var/mob/living/silicon/robot/R)
@@ -69,7 +69,7 @@ var/global/list/robot_modules = list(
for(var/module in modules)
qdel(module)
for(var/synth in synths)
qdel(synths)
qdel(synth)
modules.Cut()
synths.Cut()
qdel(emag)
@@ -105,14 +105,22 @@ var/global/list/robot_modules = list(
modules += O
/obj/item/weapon/robot_module/proc/add_languages(var/mob/living/silicon/robot/R)
// Stores the languages as they were before receiving the module, and whether they could be synthezized.
for(var/datum/language/language_datum in R.languages)
original_languages[language_datum] = (language_datum in R.speech_synthesizer_langs)
for(var/language in languages)
if(R.add_language(language, languages[language]))
added_languages |= language
R.add_language(language, languages[language])
/obj/item/weapon/robot_module/proc/remove_languages(var/mob/living/silicon/robot/R)
for(var/language in added_languages)
// Clear all added languages, whether or not we originally had them.
for(var/language in languages)
R.remove_language(language)
added_languages.Cut()
// Then add back all the original languages, and the relevant synthezising ability
for(var/original_language in original_languages)
R.add_language(original_language, original_languages[original_language])
original_languages.Cut()
/obj/item/weapon/robot_module/proc/add_camera_networks(var/mob/living/silicon/robot/R)
if(R.camera && (NETWORK_ROBOTS in R.camera.network))
+12 -13
View File
@@ -97,13 +97,6 @@
/mob/living/silicon/IsAdvancedToolUser()
return 1
/mob/living/silicon/blob_act()
if (src.stat != 2)
src.adjustBruteLoss(60)
src.updatehealth()
return 1
return 0
/mob/living/silicon/bullet_act(var/obj/item/projectile/Proj)
if(!Proj.nodamage)
@@ -201,16 +194,22 @@
return universal_speak || (speaking in src.speech_synthesizer_langs) //need speech synthesizer support to vocalize a language
/mob/living/silicon/add_language(var/language, var/can_speak=1)
if (..(language) && can_speak)
speech_synthesizer_langs.Add(all_languages[language])
var/var/datum/language/added_language = all_languages[language]
if(!added_language)
return
. = ..(language)
if (can_speak && (added_language in languages) && !(added_language in speech_synthesizer_langs))
speech_synthesizer_langs += added_language
return 1
/mob/living/silicon/remove_language(var/rem_language)
..(rem_language)
var/var/datum/language/removed_language = all_languages[rem_language]
if(!removed_language)
return
for (var/datum/language/L in speech_synthesizer_langs)
if (L.name == rem_language)
speech_synthesizer_langs -= L
..(rem_language)
speech_synthesizer_langs -= removed_language
/mob/living/silicon/check_languages()
set name = "Check Known Languages"
+1 -1
View File
@@ -76,7 +76,7 @@
set name = "Law Manager"
set category = "Subystems"
law_manager.ui_interact(usr, state = self_state)
law_manager.ui_interact(usr, state = conscious_state)
/********************
* Power Monitor *
@@ -34,9 +34,6 @@
/mob/living/captive_brain/emote(var/message)
return
/mob/living/captive_brain/can_resist()
return !(stat || !canClick())
/mob/living/captive_brain/process_resist()
//Resisting control by an alien mind.
if(istype(src.loc,/mob/living/simple_animal/borer))
@@ -59,7 +59,7 @@
if(istype(user, /mob/living/simple_animal/construct/builder))
if(health < maxHealth)
adjustBruteLoss(-5)
user.visible_message("<span class='notice'>\The [user]</b> mends some of \the [src]'s wounds.</span>")
user.visible_message("<span class='notice'>\The [user] mends some of \the [src]'s wounds.</span>")
else
user << "<span class='notice'>\The [src] is undamaged.</span>"
return
@@ -98,7 +98,7 @@
melee_damage_lower = 30
melee_damage_upper = 30
attacktext = "smashed their armoured gauntlet into"
mob_size = 20
mob_size = MOB_LARGE
speed = 3
environment_smash = 2
attack_sound = 'sound/weapons/heavysmash.ogg'
@@ -23,7 +23,7 @@
minbodytemp = 223 //Below -50 Degrees Celcius
maxbodytemp = 323 //Above 50 Degrees Celcius
holder_type = /obj/item/weapon/holder/cat
mob_size = 5
mob_size = MOB_SMALL
/mob/living/simple_animal/cat/Life()
//MICE!
@@ -5,7 +5,7 @@
icon_state = "crab"
icon_living = "crab"
icon_dead = "crab_dead"
small = 1
mob_size = MOB_SMALL
speak_emote = list("clicks")
emote_hear = list("clicks")
emote_see = list("clacks")
@@ -55,9 +55,9 @@
if(!pulledby)
var/obj/effect/plant/food
food = locate(/obj/effect/plant) in oview(5,loc)
food = locate(/obj/effect/plant) in oview(5,loc)
if(food)
var/step = get_step_to(src, food, 0)
var/step = get_step_to(src, food, 0)
Move(step)
/mob/living/simple_animal/hostile/retaliate/goat/Retaliate()
@@ -167,7 +167,7 @@
health = 1
var/amount_grown = 0
pass_flags = PASSTABLE | PASSGRILLE
small = 1
mob_size = MOB_MINISCULE
/mob/living/simple_animal/chick/New()
..()
@@ -209,7 +209,7 @@ var/global/chicken_count = 0
var/eggsleft = 0
var/body_color
pass_flags = PASSTABLE
small = 1
mob_size = MOB_SMALL
/mob/living/simple_animal/chicken/New()
..()
@@ -5,7 +5,6 @@
icon_state = "lizard"
icon_living = "lizard"
icon_dead = "lizard-dead"
small = 1
speak_emote = list("hisses")
health = 5
maxHealth = 5
@@ -15,4 +14,4 @@
response_help = "pets"
response_disarm = "shoos"
response_harm = "stomps on"
mob_size = 1
mob_size = MOB_MINISCULE
@@ -10,7 +10,6 @@
emote_hear = list("squeeks","squeaks","squiks")
emote_see = list("runs in a circle", "shakes", "scritches at something")
pass_flags = PASSTABLE
small = 1
speak_chance = 1
turns_per_move = 5
see_in_dark = 6
@@ -29,7 +28,7 @@
universal_speak = 0
universal_understand = 1
holder_type = /obj/item/weapon/holder/mouse
mob_size = 1
mob_size = MOB_MINISCULE
/mob/living/simple_animal/mouse/Life()
..()
@@ -4,7 +4,7 @@
icon_state = "mushroom"
icon_living = "mushroom"
icon_dead = "mushroom_dead"
small = 1
mob_size = MOB_SMALL
speak_chance = 0
turns_per_move = 1
maxHealth = 5
@@ -5,7 +5,7 @@
max_co2 = 0
minbodytemp = 0
maxbodytemp = 500
mob_size = 5
mob_size = MOB_SMALL
var/obj/item/device/radio/borg/radio = null
var/mob/living/silicon/ai/connected_ai = null
@@ -39,7 +39,6 @@
var/obj/item/held_item = null //Storage for single item they can hold.
speed = -1 //Spiderbots gotta go fast.
pass_flags = PASSTABLE
small = 1
speak_emote = list("beeps","clicks","chirps")
/mob/living/simple_animal/spiderbot/New()
@@ -132,7 +131,7 @@
else
attacked_with_item(O, user)
/mob/living/simple_animal/spiderbot/emag_act(var/remaining_charges, var/mob/user)
if (emagged)
user << "<span class='warning'>[src] is already overloaded - better run.</span>"
@@ -33,7 +33,7 @@
icon_living = "parrot_fly"
icon_dead = "parrot_dead"
pass_flags = PASSTABLE
small = 1
mob_size = MOB_SMALL
speak = list("Hi","Hello!","Cracker?","BAWWWWK george mellons griffing me")
speak_emote = list("squawks","says","yells")
@@ -285,7 +285,7 @@
if(meat_type && (stat == DEAD)) //if the animal has a meat, and if it is dead.
if(istype(O, /obj/item/weapon/material/knife) || istype(O, /obj/item/weapon/material/knife/butch))
harvest(user)
else
else
attacked_with_item(O, user)
//TODO: refactor mob attackby(), attacked_by(), and friends.
@@ -307,7 +307,7 @@
usr << "<span class='danger'>This weapon is ineffective, it does no damage.</span>"
visible_message("<span class='danger'>\The [src] has been attacked with \the [O] by [user].</span>")
user.do_attack_animation(src)
user.do_attack_animation(src)
/mob/living/simple_animal/movement_delay()
var/tally = 0 //Incase I need to add stuff other than "speed" later
@@ -396,7 +396,7 @@
for(var/i=0;i<actual_meat_amount;i++)
var/obj/item/meat = new meat_type(get_turf(src))
meat.name = "[src.name] [meat.name]"
if(small)
if(issmall(src))
user.visible_message("<span class='danger'>[user] chops up \the [src]!</span>")
new/obj/effect/decal/cleanable/blood/splatter(get_turf(src))
qdel(src)
+2 -2
View File
@@ -17,10 +17,10 @@
spawn() alert("You have logged in already with another key this round, please log out of this one NOW or risk being banned!")
if(matches)
if(M.client)
message_admins("<font color='red'><B>Notice: </B><font color='blue'><A href='?src=\ref[usr];priv_msg=\ref[src]'>[key_name_admin(src)]</A> has the same [matches] as <A href='?src=\ref[usr];priv_msg=\ref[M]'>[key_name_admin(M)]</A>.</font>", 1)
message_admins("<font color='red'><B>Notice: </B></font><font color='blue'><A href='?src=\ref[usr];priv_msg=\ref[src]'>[key_name_admin(src)]</A> has the same [matches] as <A href='?src=\ref[usr];priv_msg=\ref[M]'>[key_name_admin(M)]</A>.</font>", 1)
log_access("Notice: [key_name(src)] has the same [matches] as [key_name(M)].")
else
message_admins("<font color='red'><B>Notice: </B><font color='blue'><A href='?src=\ref[usr];priv_msg=\ref[src]'>[key_name_admin(src)]</A> has the same [matches] as [key_name_admin(M)] (no longer logged in). </font>", 1)
message_admins("<font color='red'><B>Notice: </B></font><font color='blue'><A href='?src=\ref[usr];priv_msg=\ref[src]'>[key_name_admin(src)]</A> has the same [matches] as [key_name_admin(M)] (no longer logged in). </font>", 1)
log_access("Notice: [key_name(src)] has the same [matches] as [key_name(M)] (no longer logged in).")
/mob/Login()
+1 -1
View File
@@ -966,7 +966,7 @@ mob/proc/yank_out_object()
var/mob/living/carbon/human/human_user = U
human_user.bloody_hands(H)
selection.loc = get_turf(src)
selection.forceMove(get_turf(src))
if(!(U.l_hand && U.r_hand))
U.put_in_hands(selection)
+4 -5
View File
@@ -89,7 +89,6 @@
var/incorporeal_move = 0 //0 is off, 1 is normal, 2 is for ninjas.
var/lastpuke = 0
var/unacidable = 0
var/small = 0
var/list/pinned = list() // List of things pinning this creature to walls (see living_defense.dm)
var/list/embedded = list() // Embedded items, since simple mobs don't have organs.
var/list/languages = list() // For speaking/listening.
@@ -215,12 +214,12 @@
var/stance_damage = 0 //Whether this mob's ability to stand has been affected
//Indicates if a clientless mob is actually an admin aghosting
var/mob/dead/observer/aghosted = null
//If set, indicates that the client "belonging" to this (clientless) mob is currently controlling some other mob
//so don't treat them as being SSD even though their client var is null.
var/mob/teleop = null
var/turf/listed_turf = null //the current turf being examined in the stat panel
var/list/shouldnt_see = list() //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/list/active_genes=list()
var/mob_size = MOB_MEDIUM
+6 -6
View File
@@ -91,15 +91,15 @@
var/damage = 20
var/obj/item/clothing/hat = attacker.head
if(istype(hat))
damage += hat.force * 10
damage += hat.force * 3
var/armor = target.run_armor_check("head", "melee")
target.apply_damage(damage*rand(90, 110)/100, BRUTE, "head", armor)
attacker.apply_damage(10*rand(90, 110)/100, BRUTE, "head", attacker.run_armor_check("head", "melee"))
target.apply_damage(damage, BRUTE, "head", armor)
attacker.apply_damage(10, BRUTE, "head", attacker.run_armor_check("head", "melee"))
if(!armor && prob(damage))
if(!armor && target.headcheck("head") && prob(damage))
target.apply_effect(20, PARALYZE)
target.visible_message("<span class='danger'>[target] has been knocked unconscious!</span>")
target.visible_message("<span class='danger'>[target] [target.species.knockout_message]</span>")
playsound(attacker.loc, "swing_hit", 25, 1, -1)
attacker.attack_log += text("\[[time_stamp()]\] <font color='red'>Headbutted [target.name] ([target.ckey])</font>")
@@ -149,7 +149,7 @@
if(istype(H) && H.species.gluttonous)
if(H.species.gluttonous == 2)
can_eat = 2
else if(!ishuman(target) && !issmall(target) && (target.small || iscarbon(target)))
else if((H.mob_size > target.mob_size) && !ishuman(target) && iscarbon(target))
can_eat = 1
if(can_eat)
+12 -127
View File
@@ -1,14 +1,4 @@
// fun if you want to typecast humans/monkeys/etc without writing long path-filled lines.
/proc/ishuman(A)
if(istype(A, /mob/living/carbon/human))
return 1
return 0
/proc/isalien(A)
if(istype(A, /mob/living/carbon/alien))
return 1
return 0
/proc/isxenomorph(A)
if(istype(A, /mob/living/carbon/human))
var/mob/living/carbon/human/H = A
@@ -16,85 +6,12 @@
return 0
/proc/issmall(A)
if(A && istype(A, /mob/living/carbon/human))
var/mob/living/carbon/human/H = A
if(H.species && H.species.is_small)
return 1
if(A && istype(A, /mob/living))
var/mob/living/L = A
return L.mob_size <= MOB_SMALL
return 0
/proc/isbrain(A)
if(A && istype(A, /mob/living/carbon/brain))
return 1
return 0
/proc/isslime(A)
if(istype(A, /mob/living/carbon/slime))
return 1
return 0
/proc/isrobot(A)
if(istype(A, /mob/living/silicon/robot))
return 1
return 0
/proc/isanimal(A)
if(istype(A, /mob/living/simple_animal))
return 1
return 0
/proc/iscorgi(A)
if(istype(A, /mob/living/simple_animal/corgi))
return 1
return 0
/proc/iscrab(A)
if(istype(A, /mob/living/simple_animal/crab))
return 1
return 0
/proc/iscat(A)
if(istype(A, /mob/living/simple_animal/cat))
return 1
return 0
/proc/ismouse(A)
if(istype(A, /mob/living/simple_animal/mouse))
return 1
return 0
/proc/isbear(A)
if(istype(A, /mob/living/simple_animal/hostile/bear))
return 1
return 0
/proc/iscarp(A)
if(istype(A, /mob/living/simple_animal/hostile/carp))
return 1
return 0
/proc/isclown(A)
if(istype(A, /mob/living/simple_animal/hostile/retaliate/clown))
return 1
return 0
/mob/proc/isSilicon()
return 0
/mob/living/silicon/isSilicon()
return 1
/proc/isAI(A)
if(istype(A, /mob/living/silicon/ai))
return 1
return 0
/mob/proc/isMobAI()
return 0
/mob/living/silicon/ai/isMobAI()
return 1
/mob/proc/isSynthetic()
/mob/living/proc/isSynthetic()
return 0
/mob/living/carbon/human/isSynthetic()
@@ -107,56 +24,18 @@
/mob/living/silicon/isSynthetic()
return 1
/mob/living/carbon/human/isMonkey()
return istype(species, /datum/species/monkey)
/mob/proc/isMonkey()
return 0
/mob/living/carbon/human/isMonkey()
return istype(species, /datum/species/monkey)
/proc/ispAI(A)
if(istype(A, /mob/living/silicon/pai))
return 1
return 0
/proc/iscarbon(A)
if(istype(A, /mob/living/carbon))
return 1
return 0
/proc/issilicon(A)
if(istype(A, /mob/living/silicon))
return 1
return 0
/proc/isliving(A)
if(istype(A, /mob/living))
return 1
return 0
proc/isobserver(A)
if(istype(A, /mob/dead/observer))
return 1
return 0
proc/isorgan(A)
if(istype(A, /obj/item/organ/external))
return 1
return 0
proc/isdeaf(A)
if(istype(A, /mob))
var/mob/M = A
return (M.sdisabilities & DEAF) || M.ear_deaf
return 0
proc/isnewplayer(A)
if(istype(A, /mob/new_player))
return 1
return 0
proc/hasorgans(A) // Fucking really??
return ishuman(A)
@@ -410,7 +289,7 @@ It's fairly easy to fix if dealing with single letters but not so much with comp
/proc/shake_camera(mob/M, duration, strength=1)
if(!M || !M.client || M.shakecamera)
if(!M || !M.client || M.shakecamera || M.stat || isEye(M) || isAI(M))
return
M.shakecamera = 1
spawn(1)
@@ -626,6 +505,12 @@ proc/is_blind(A)
return 0
/mob/living/carbon/assess_perp(var/obj/access_obj, var/check_access, var/auth_weapons, var/check_records, var/check_arrest)
if(handcuffed)
return SAFE_PERP
return ..()
/mob/living/carbon/human/assess_perp(var/obj/access_obj, var/check_access, var/auth_weapons, var/check_records, var/check_arrest)
var/threatcount = ..()
if(. == SAFE_PERP)
@@ -638,7 +523,7 @@ proc/is_blind(A)
// A proper CentCom id is hard currency.
else if(id && istype(id, /obj/item/weapon/card/id/centcom))
return SAFE_PERP
if(check_access && !access_obj.allowed(src))
threatcount += 4
+5 -5
View File
@@ -176,7 +176,7 @@
if(!mob.control_object) return
mob.control_object.dir = direct
else
mob.control_object.loc = get_step(mob.control_object,direct)
mob.control_object.forceMove(get_step(mob.control_object,direct))
return
@@ -382,7 +382,7 @@
mob << "<span class='warning'>You cannot get past holy grounds while you are in this plane of existence!</span>"
return
else
mob.loc = get_step(mob, direct)
mob.forceMove(get_step(mob, direct))
mob.dir = direct
if(2)
if(prob(50))
@@ -411,7 +411,7 @@
return
else
return
mob.loc = locate(locx,locy,mobloc.z)
mob.forceMove(locate(locx,locy,mobloc.z))
spawn(0)
var/limit = 2//For only two trailing shadows.
for(var/turf/T in getline(mobloc, mob.loc))
@@ -422,7 +422,7 @@
else
spawn(0)
anim(mobloc,mob,'icons/mob/mob.dmi',,"shadow",,mob.dir)
mob.loc = get_step(mob, direct)
mob.forceMove(get_step(mob, direct))
mob.dir = direct
// Crossed is always a bit iffy
for(var/obj/S in mob.loc)
@@ -457,7 +457,7 @@
return 0
//Check to see if we slipped
if(prob(Process_Spaceslipping(5)))
if(prob(Process_Spaceslipping(5)) && !buckled)
src << "\blue <B>You slipped!</B>"
src.inertia_dir = src.last_move
step(src, src.inertia_dir)
+9 -15
View File
@@ -1,3 +1,9 @@
/var/atom/movable/lobby_image = new /atom/movable{icon = 'icons/misc/title.dmi'; icon_state = "title"; screen_loc = "1,1"; name = "Baystation12"}
/mob/new_player
var/client/my_client // Need to keep track of this ourselves, since by the time Logout() is called the client has already been nulled
/mob/new_player/Login()
update_Login_details() //handles setting lastKnownIP and computer_id for use by the ban systems as well as checking for multikeying
if(join_motd)
@@ -8,24 +14,12 @@
mind.active = 1
mind.current = src
if(length(newplayer_start))
loc = pick(newplayer_start)
else
loc = locate(1,1,1)
lastarea = loc
loc = null
client.screen += lobby_image
my_client = client
sight |= SEE_TURFS
player_list |= src
/*
var/list/watch_locations = list()
for(var/obj/effect/landmark/landmark in landmarks_list)
if(landmark.tag == "landmark*new_player")
watch_locations += landmark.loc
if(watch_locations.len>0)
loc = pick(watch_locations)
*/
new_player_panel()
spawn(40)
if(client)
+7 -1
View File
@@ -1,7 +1,13 @@
/mob/new_player/Logout()
ready = 0
// see login.dm
if(my_client)
my_client.screen -= lobby_image
my_client = null
..()
if(!spawning)//Here so that if they are spawning and log out, the other procs can play out and they will have a mob to come back to.
key = null//We null their key before deleting the mob, so they are properly kicked out.
qdel(src)
return
return
+2 -18
View File
@@ -330,23 +330,7 @@
return
//Find our spawning point.
var/join_message
var/datum/spawnpoint/S
if(spawning_at)
S = spawntypes[spawning_at]
if(S && istype(S))
if(S.check_job_spawning(rank))
character.loc = pick(S.turfs)
join_message = S.msg
else
character << "Your chosen spawnpoint ([S.display_name]) is unavailable for your chosen job. Spawning you at the Arrivals shuttle instead."
character.loc = pick(latejoin)
join_message = "has arrived on the station"
else
character.loc = pick(latejoin)
join_message = "has arrived on the station"
var/join_message = job_master.LateSpawn(character, rank)
character.lastarea = get_area(loc)
// Moving wheelchair if they have one
@@ -486,7 +470,7 @@
src << browse(null, "window=playersetup") //closes the player setup window
proc/has_admin_rights()
return client.holder.rights & R_ADMIN
return check_rights(R_ADMIN, 0, src)
proc/is_species_whitelisted(datum/species/S)
if(!S) return 1