mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
#Finished the respawn_character proc. Use it to quickly bring a player back into the game with their previous character if they were gibbed/deleted. If you want them to make a new character, kick them out and let them rejoin. Can also be used to quickly enter the game by admins and the like. It's fairly robust so you can read the code to find out what it does (and does not).
#Added a locked list to datacore in order to track character spawn, particularly for respawn_character(). May be useful in the future. #Added a proc to randomize appearance for any human mob, randomize_appearance_for(mob). It will not take into account gender as you will have to provide it. Names and so on are also randomized but that can be overwritten in the code following. #Added AI holopads around the station. To use as the AI: click on the pad to center view on it. Click again to activate the hologram. Move it with the directional keys. You can still interact with objects normally. To remove it, either move it too far out or click the pad again. Use robot talk to directly speak through the holopad (and only the holopad, unlike regular robot speak). Could be added on to (like different images for different AIs) but it's basically finished. #Fixed a bugged message on changeling transformation sting. It will no longer give away your identity. #Made law datum a silicon define. var/datum/ai_laws/laws. #A few more ninja adjustments. Added a new view mode for the ninja mask, allowing to see special roles and a few other things. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@1608 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -18,8 +18,6 @@
|
||||
say_understands(var/other)
|
||||
if (istype(other, /mob/living/silicon/ai))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/aihologram))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/robot))
|
||||
return 1
|
||||
if (istype(other, /mob/living/carbon/human))
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
emote("deathgasp") //let the world KNOW WE ARE DEAD
|
||||
|
||||
//For ninjas exploding when they die./N
|
||||
if (istype(wear_suit, /obj/item/clothing/suit/space/space_ninja)&&wear_suit:initialize)
|
||||
if (istype(wear_suit, /obj/item/clothing/suit/space/space_ninja)&&wear_suit:s_initialized)
|
||||
src << browse(null, "window=spideros")//Just in case.
|
||||
var/location = loc
|
||||
explosion(location, 1, 2, 3, 4)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -11,7 +11,7 @@
|
||||
set invisibility = 0
|
||||
set background = 1
|
||||
|
||||
if (src.monkeyizing)
|
||||
if (monkeyizing)
|
||||
return
|
||||
|
||||
if(!loc) // Fixing a null error that occurs when the mob isn't found in the world -- TLE
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
var/datum/gas_mixture/environment = loc.return_air()
|
||||
|
||||
if (src.stat != 2) //still breathing
|
||||
if (stat != 2) //still breathing
|
||||
|
||||
//First, resolve location and get a breath
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
//blinded get reset each cycle and then get activated later in the
|
||||
//code. Very ugly. I dont care. Moving this stuff here so its easy
|
||||
//to find it.
|
||||
src.blinded = null
|
||||
blinded = null
|
||||
|
||||
//Disease Check
|
||||
handle_virus_updates()
|
||||
@@ -135,42 +135,42 @@
|
||||
|
||||
|
||||
handle_disabilities()
|
||||
if (src.disabilities & 2)
|
||||
if ((prob(1) && src.paralysis < 1 && src.r_epil < 1))
|
||||
if (disabilities & 2)
|
||||
if ((prob(1) && paralysis < 1 && r_epil < 1))
|
||||
src << "\red You have a seizure!"
|
||||
for(var/mob/O in viewers(src, null))
|
||||
if(O == src)
|
||||
continue
|
||||
O.show_message(text("\red <B>[src] starts having a seizure!"), 1)
|
||||
src.paralysis = max(10, src.paralysis)
|
||||
src.make_jittery(1000)
|
||||
if (src.disabilities & 4)
|
||||
if ((prob(5) && src.paralysis <= 1 && src.r_ch_cou < 1))
|
||||
src.drop_item()
|
||||
paralysis = max(10, paralysis)
|
||||
make_jittery(1000)
|
||||
if (disabilities & 4)
|
||||
if ((prob(5) && paralysis <= 1 && r_ch_cou < 1))
|
||||
drop_item()
|
||||
spawn( 0 )
|
||||
emote("cough")
|
||||
return
|
||||
if (src.disabilities & 8)
|
||||
if ((prob(10) && src.paralysis <= 1 && src.r_Tourette < 1))
|
||||
src.stunned = max(10, src.stunned)
|
||||
if (disabilities & 8)
|
||||
if ((prob(10) && paralysis <= 1 && r_Tourette < 1))
|
||||
stunned = max(10, stunned)
|
||||
spawn( 0 )
|
||||
switch(rand(1, 3))
|
||||
if(1)
|
||||
emote("twitch")
|
||||
if(2 to 3)
|
||||
say("[prob(50) ? ";" : ""][pick("SHIT", "PISS", "FUCK", "CUNT", "COCKSUCKER", "MOTHERFUCKER", "TITS")]")
|
||||
var/old_x = src.pixel_x
|
||||
var/old_y = src.pixel_y
|
||||
src.pixel_x += rand(-2,2)
|
||||
src.pixel_y += rand(-1,1)
|
||||
var/old_x = pixel_x
|
||||
var/old_y = pixel_y
|
||||
pixel_x += rand(-2,2)
|
||||
pixel_y += rand(-1,1)
|
||||
sleep(2)
|
||||
src.pixel_x = old_x
|
||||
src.pixel_y = old_y
|
||||
pixel_x = old_x
|
||||
pixel_y = old_y
|
||||
return
|
||||
if (src.disabilities & 16)
|
||||
if (disabilities & 16)
|
||||
if (prob(10))
|
||||
src.stuttering = max(10, src.stuttering)
|
||||
if (src.brainloss >= 60 && src.stat != 2)
|
||||
stuttering = max(10, stuttering)
|
||||
if (brainloss >= 60 && stat != 2)
|
||||
if (prob(7))
|
||||
switch(pick(1,2,3))
|
||||
if(1)
|
||||
@@ -182,67 +182,67 @@
|
||||
|
||||
handle_mutations_and_radiation()
|
||||
|
||||
if(src.fireloss)
|
||||
if(src.mutations & COLD_RESISTANCE || (prob(1) && prob(75)))
|
||||
src.heal_organ_damage(0,1)
|
||||
if(fireloss)
|
||||
if(mutations & COLD_RESISTANCE || (prob(1) && prob(75)))
|
||||
heal_organ_damage(0,1)
|
||||
|
||||
if (src.mutations & HULK && src.health <= 25)
|
||||
src.mutations &= ~HULK
|
||||
if (mutations & HULK && health <= 25)
|
||||
mutations &= ~HULK
|
||||
src << "\red You suddenly feel very weak."
|
||||
src.weakened = 3
|
||||
weakened = 3
|
||||
emote("collapse")
|
||||
|
||||
if (src.radiation)
|
||||
if (src.radiation > 100)
|
||||
src.radiation = 100
|
||||
src.weakened = 10
|
||||
if (radiation)
|
||||
if (radiation > 100)
|
||||
radiation = 100
|
||||
weakened = 10
|
||||
src << "\red You feel weak."
|
||||
emote("collapse")
|
||||
|
||||
if (src.radiation < 0)
|
||||
src.radiation = 0
|
||||
if (radiation < 0)
|
||||
radiation = 0
|
||||
|
||||
switch(src.radiation)
|
||||
switch(radiation)
|
||||
if(1 to 49)
|
||||
src.radiation--
|
||||
radiation--
|
||||
if(prob(25))
|
||||
src.toxloss++
|
||||
src.updatehealth()
|
||||
toxloss++
|
||||
updatehealth()
|
||||
|
||||
if(50 to 74)
|
||||
src.radiation -= 2
|
||||
src.toxloss++
|
||||
radiation -= 2
|
||||
toxloss++
|
||||
if(prob(5))
|
||||
src.radiation -= 5
|
||||
src.weakened = 3
|
||||
radiation -= 5
|
||||
weakened = 3
|
||||
src << "\red You feel weak."
|
||||
emote("collapse")
|
||||
src.updatehealth()
|
||||
updatehealth()
|
||||
|
||||
if(75 to 100)
|
||||
src.radiation -= 3
|
||||
src.toxloss += 3
|
||||
radiation -= 3
|
||||
toxloss += 3
|
||||
if(prob(1))
|
||||
src << "\red You mutate!"
|
||||
randmutb(src)
|
||||
domutcheck(src,null)
|
||||
emote("gasp")
|
||||
src.updatehealth()
|
||||
updatehealth()
|
||||
|
||||
|
||||
breathe()
|
||||
|
||||
if(src.reagents.has_reagent("lexorin")) return
|
||||
if(reagents.has_reagent("lexorin")) return
|
||||
if(istype(loc, /obj/machinery/atmospherics/unary/cryo_cell)) return
|
||||
|
||||
var/datum/gas_mixture/environment = loc.return_air()
|
||||
var/datum/air_group/breath
|
||||
// HACK NEED CHANGING LATER
|
||||
if(src.health < 0)
|
||||
src.losebreath++
|
||||
if(health < 0)
|
||||
losebreath++
|
||||
|
||||
if(losebreath>0) //Suffocating so do not take a breath
|
||||
src.losebreath--
|
||||
losebreath--
|
||||
if (prob(75)) //High chance of gasping for air
|
||||
spawn emote("gasp")
|
||||
if(istype(loc, /obj/))
|
||||
@@ -282,17 +282,17 @@
|
||||
|
||||
get_breath_from_internal(volume_needed)
|
||||
if(internal)
|
||||
if (!contents.Find(src.internal))
|
||||
if (!contents.Find(internal))
|
||||
internal = null
|
||||
if (!wear_mask || !(wear_mask.flags & MASKINTERNALS) )
|
||||
internal = null
|
||||
if(internal)
|
||||
//if (src.internals) //should be unnecessary, uncomment if it isn't. -raftaf0
|
||||
// src.internals.icon_state = "internal1"
|
||||
//if (internals) //should be unnecessary, uncomment if it isn't. -raftaf0
|
||||
// internals.icon_state = "internal1"
|
||||
return internal.remove_air_volume(volume_needed)
|
||||
else
|
||||
if (src.internals)
|
||||
src.internals.icon_state = "internal0"
|
||||
if (internals)
|
||||
internals.icon_state = "internal0"
|
||||
return null
|
||||
|
||||
update_canmove()
|
||||
@@ -300,11 +300,11 @@
|
||||
else canmove = 1
|
||||
|
||||
handle_breath(datum/gas_mixture/breath)
|
||||
if(src.nodamage)
|
||||
if(nodamage)
|
||||
return
|
||||
|
||||
if(!breath || (breath.total_moles() == 0))
|
||||
if(src.reagents.has_reagent("inaprovaline"))
|
||||
if(reagents.has_reagent("inaprovaline"))
|
||||
return
|
||||
oxyloss += 7
|
||||
|
||||
@@ -357,7 +357,7 @@
|
||||
if(!co2overloadtime) // If it's the first breath with too much CO2 in it, lets start a counter, then have them pass out after 12s or so.
|
||||
co2overloadtime = world.time
|
||||
else if(world.time - co2overloadtime > 120)
|
||||
src.paralysis = max(src.paralysis, 3)
|
||||
paralysis = max(paralysis, 3)
|
||||
oxyloss += 3 // Lets hurt em a little, let them know we mean business
|
||||
if(world.time - co2overloadtime > 300) // They've been in here 30s now, lets start to kill them for their own good!
|
||||
oxyloss += 8
|
||||
@@ -378,15 +378,15 @@
|
||||
for(var/datum/gas/sleeping_agent/SA in breath.trace_gases)
|
||||
var/SA_pp = (SA.moles/breath.total_moles())*breath_pressure
|
||||
if(SA_pp > SA_para_min) // Enough to make us paralysed for a bit
|
||||
src.paralysis = max(src.paralysis, 3) // 3 gives them one second to wake up and run away a bit!
|
||||
paralysis = max(paralysis, 3) // 3 gives them one second to wake up and run away a bit!
|
||||
if(SA_pp > SA_sleep_min) // Enough to make us sleep as well
|
||||
src.sleeping = max(src.sleeping, 2)
|
||||
sleeping = max(sleeping, 2)
|
||||
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
|
||||
if(prob(20))
|
||||
spawn(0) emote(pick("giggle", "laugh"))
|
||||
|
||||
|
||||
if(breath.temperature > (T0C+66) && !(src.mutations & COLD_RESISTANCE)) // Hot air hurts :(
|
||||
if(breath.temperature > (T0C+66) && !(mutations & COLD_RESISTANCE)) // Hot air hurts :(
|
||||
if(prob(20))
|
||||
src << "\red You feel a searing heat in your lungs!"
|
||||
fire_alert = max(fire_alert, 1)
|
||||
@@ -412,18 +412,18 @@
|
||||
loc_temp = environment.temperature
|
||||
|
||||
var/thermal_protection = get_thermal_protection()
|
||||
if(stat != 2 && abs(src.bodytemperature - 310.15) < 50)
|
||||
src.bodytemperature += adjust_body_temperature(src.bodytemperature, 310.15, thermal_protection)
|
||||
if(stat != 2 && abs(bodytemperature - 310.15) < 50)
|
||||
bodytemperature += adjust_body_temperature(bodytemperature, 310.15, thermal_protection)
|
||||
if(loc_temp < 310.15) // a cold place -> add in cold protection
|
||||
src.bodytemperature += adjust_body_temperature(src.bodytemperature, loc_temp, 1/thermal_protection)
|
||||
bodytemperature += adjust_body_temperature(bodytemperature, loc_temp, 1/thermal_protection)
|
||||
else // a hot place -> add in heat protection
|
||||
thermal_protection += add_fire_protection(loc_temp)
|
||||
src.bodytemperature += adjust_body_temperature(src.bodytemperature, loc_temp, 1/thermal_protection)
|
||||
bodytemperature += adjust_body_temperature(bodytemperature, loc_temp, 1/thermal_protection)
|
||||
|
||||
|
||||
// lets give them a fair bit of leeway so they don't just start dying
|
||||
//as that may be realistic but it's no fun
|
||||
if((src.bodytemperature > (T0C + 50)) || (src.bodytemperature < (T0C + 10)) && (!istype(loc, /obj/machinery/atmospherics/unary/cryo_cell))) // Last bit is just disgusting, i know
|
||||
if((bodytemperature > (T0C + 50)) || (bodytemperature < (T0C + 10)) && (!istype(loc, /obj/machinery/atmospherics/unary/cryo_cell))) // Last bit is just disgusting, i know
|
||||
if(environment.temperature > (T0C + 50) || (environment.temperature < (T0C + 10)))
|
||||
var/transfer_coefficient
|
||||
|
||||
@@ -532,7 +532,7 @@
|
||||
thermal_protection += 3
|
||||
if(head && (head.flags & HEADSPACE))
|
||||
thermal_protection += 1
|
||||
if(src.mutations & COLD_RESISTANCE)
|
||||
if(mutations & COLD_RESISTANCE)
|
||||
thermal_protection += 5
|
||||
|
||||
return thermal_protection
|
||||
@@ -567,7 +567,7 @@
|
||||
return fire_prot
|
||||
|
||||
handle_temperature_damage(body_part, exposed_temperature, exposed_intensity)
|
||||
if(src.nodamage)
|
||||
if(nodamage)
|
||||
return
|
||||
var/discomfort = min(abs(exposed_temperature - bodytemperature)*(exposed_intensity)/2000000, 1.0)
|
||||
|
||||
@@ -613,17 +613,17 @@
|
||||
if(oxyloss)
|
||||
oxyloss--
|
||||
|
||||
if(overeatduration > 500 && !(src.mutations & FAT))
|
||||
if(overeatduration > 500 && !(mutations & FAT))
|
||||
src << "\red You suddenly feel blubbery!"
|
||||
src.mutations |= FAT
|
||||
mutations |= FAT
|
||||
update_body()
|
||||
if (overeatduration < 100 && src.mutations & FAT)
|
||||
if (overeatduration < 100 && mutations & FAT)
|
||||
src << "\blue You feel fit again!"
|
||||
src.mutations &= ~FAT
|
||||
mutations &= ~FAT
|
||||
update_body()
|
||||
|
||||
// nutrition decrease
|
||||
if (nutrition > 0 && src.stat != 2)
|
||||
if (nutrition > 0 && stat != 2)
|
||||
nutrition = max (0, nutrition - HUNGER_FACTOR)
|
||||
|
||||
if (nutrition > 450)
|
||||
@@ -637,12 +637,12 @@
|
||||
if(nutrition < 200)
|
||||
take_overall_damage(2,0)
|
||||
|
||||
if (src.drowsyness)
|
||||
src.drowsyness--
|
||||
src.eye_blurry = max(2, src.eye_blurry)
|
||||
if (drowsyness)
|
||||
drowsyness--
|
||||
eye_blurry = max(2, eye_blurry)
|
||||
if (prob(5))
|
||||
src.sleeping = 1
|
||||
src.paralysis = 5
|
||||
sleeping = 1
|
||||
paralysis = 5
|
||||
|
||||
confused = max(0, confused - 1)
|
||||
// decrement dizziness counter, clamped to 0
|
||||
@@ -653,7 +653,7 @@
|
||||
dizziness = max(0, dizziness - 3)
|
||||
jitteriness = max(0, jitteriness - 3)
|
||||
|
||||
src.updatehealth()
|
||||
updatehealth()
|
||||
|
||||
return //TODO: DEFERRED
|
||||
|
||||
@@ -663,84 +663,84 @@
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
if(src.sleeping)
|
||||
src.paralysis = max(src.paralysis, 3)
|
||||
if(sleeping)
|
||||
paralysis = max(paralysis, 3)
|
||||
if (prob(10) && health) spawn(0) emote("snore")
|
||||
src.sleeping--
|
||||
sleeping--
|
||||
|
||||
if(src.resting)
|
||||
src.weakened = max(src.weakened, 5)
|
||||
if(resting)
|
||||
weakened = max(weakened, 5)
|
||||
|
||||
if(health < -100 || src.brain_op_stage == 4.0)
|
||||
if(health < -100 || brain_op_stage == 4.0)
|
||||
death()
|
||||
else if(src.health < 0)
|
||||
if(src.health <= 20 && prob(1)) spawn(0) emote("gasp")
|
||||
else if(health < 0)
|
||||
if(health <= 20 && prob(1)) spawn(0) emote("gasp")
|
||||
|
||||
//if(!src.rejuv) src.oxyloss++
|
||||
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++
|
||||
//if(!rejuv) oxyloss++
|
||||
if(!reagents.has_reagent("inaprovaline")) oxyloss++
|
||||
|
||||
if(src.stat != 2) src.stat = 1
|
||||
src.paralysis = max(src.paralysis, 5)
|
||||
if(stat != 2) stat = 1
|
||||
paralysis = max(paralysis, 5)
|
||||
|
||||
if (src.stat != 2) //Alive.
|
||||
if (src.silent)
|
||||
src.silent--
|
||||
if (stat != 2) //Alive.
|
||||
if (silent)
|
||||
silent--
|
||||
|
||||
if (src.paralysis || src.stunned || src.weakened || changeling_fakedeath) //Stunned etc.
|
||||
if (src.stunned > 0)
|
||||
src.stunned--
|
||||
src.stat = 0
|
||||
if (src.weakened > 0)
|
||||
src.weakened--
|
||||
src.lying = 1
|
||||
src.stat = 0
|
||||
if (src.paralysis > 0)
|
||||
src.paralysis--
|
||||
src.blinded = 1
|
||||
src.lying = 1
|
||||
src.stat = 1
|
||||
var/h = src.hand
|
||||
src.hand = 0
|
||||
if (paralysis || stunned || weakened || changeling_fakedeath) //Stunned etc.
|
||||
if (stunned > 0)
|
||||
stunned--
|
||||
stat = 0
|
||||
if (weakened > 0)
|
||||
weakened--
|
||||
lying = 1
|
||||
stat = 0
|
||||
if (paralysis > 0)
|
||||
paralysis--
|
||||
blinded = 1
|
||||
lying = 1
|
||||
stat = 1
|
||||
var/h = hand
|
||||
hand = 0
|
||||
drop_item()
|
||||
src.hand = 1
|
||||
hand = 1
|
||||
drop_item()
|
||||
src.hand = h
|
||||
hand = h
|
||||
|
||||
else //Not stunned.
|
||||
src.lying = 0
|
||||
src.stat = 0
|
||||
lying = 0
|
||||
stat = 0
|
||||
|
||||
else //Dead.
|
||||
src.lying = 1
|
||||
src.blinded = 1
|
||||
src.stat = 2
|
||||
src.silent = 0
|
||||
lying = 1
|
||||
blinded = 1
|
||||
stat = 2
|
||||
silent = 0
|
||||
|
||||
if (src.stuttering) src.stuttering--
|
||||
if (stuttering) stuttering--
|
||||
|
||||
if (src.eye_blind)
|
||||
src.eye_blind--
|
||||
src.blinded = 1
|
||||
if (eye_blind)
|
||||
eye_blind--
|
||||
blinded = 1
|
||||
|
||||
if (src.ear_deaf > 0) src.ear_deaf--
|
||||
if (src.ear_damage < 25)
|
||||
src.ear_damage -= 0.05
|
||||
src.ear_damage = max(src.ear_damage, 0)
|
||||
if (ear_deaf > 0) ear_deaf--
|
||||
if (ear_damage < 25)
|
||||
ear_damage -= 0.05
|
||||
ear_damage = max(ear_damage, 0)
|
||||
|
||||
src.density = !( src.lying )
|
||||
density = !( lying )
|
||||
|
||||
if ((src.sdisabilities & 1 || istype(src.glasses, /obj/item/clothing/glasses/blindfold)))
|
||||
src.blinded = 1
|
||||
if ((src.sdisabilities & 4 || istype(src.ears, /obj/item/clothing/ears/earmuffs)))
|
||||
src.ear_deaf = 1
|
||||
if ((sdisabilities & 1 || istype(glasses, /obj/item/clothing/glasses/blindfold)))
|
||||
blinded = 1
|
||||
if ((sdisabilities & 4 || istype(ears, /obj/item/clothing/ears/earmuffs)))
|
||||
ear_deaf = 1
|
||||
|
||||
if (src.eye_blurry > 0)
|
||||
src.eye_blurry--
|
||||
src.eye_blurry = max(0, src.eye_blurry)
|
||||
if (eye_blurry > 0)
|
||||
eye_blurry--
|
||||
eye_blurry = max(0, eye_blurry)
|
||||
|
||||
if (src.druggy > 0)
|
||||
src.druggy--
|
||||
src.druggy = max(0, src.druggy)
|
||||
if (druggy > 0)
|
||||
druggy--
|
||||
druggy = max(0, druggy)
|
||||
|
||||
return 1
|
||||
|
||||
@@ -751,16 +751,16 @@
|
||||
if(copytext(hud.icon_state,1,4) == "hud") //ugly, but icon comparison is worse, I believe
|
||||
del(hud)
|
||||
|
||||
if (src.stat == 2 || src.mutations & XRAY)
|
||||
src.sight |= SEE_TURFS
|
||||
src.sight |= SEE_MOBS
|
||||
src.sight |= SEE_OBJS
|
||||
src.see_in_dark = 8
|
||||
if(!src.druggy)
|
||||
src.see_invisible = 2
|
||||
if (stat == 2 || mutations & XRAY)
|
||||
sight |= SEE_TURFS
|
||||
sight |= SEE_MOBS
|
||||
sight |= SEE_OBJS
|
||||
see_in_dark = 8
|
||||
if(!druggy)
|
||||
see_invisible = 2
|
||||
|
||||
else if (src.seer)
|
||||
var/obj/rune/R = locate() in src.loc
|
||||
else if (seer)
|
||||
var/obj/rune/R = locate() in loc
|
||||
if (istype(R) && R.word1 == wordsee && R.word2 == wordhell && R.word3 == wordjoin)
|
||||
see_invisible = 15
|
||||
else
|
||||
@@ -768,6 +768,16 @@
|
||||
see_invisible = 0
|
||||
else if (istype(wear_mask, /obj/item/clothing/mask/gas/voice/space_ninja))
|
||||
switch(wear_mask:mode)
|
||||
if(0)
|
||||
if(client)
|
||||
var/target_list[] = list()
|
||||
for(var/mob/living/target in oview(src))
|
||||
if( target.mind&&(target.mind.special_role||issilicon(target)) )//They need to have a mind.
|
||||
target_list += target
|
||||
if(target_list.len)//Everything else is handled by the ninja mask proc.
|
||||
wear_mask:assess_targets(target_list, src)
|
||||
if (!druggy)
|
||||
see_invisible = 0
|
||||
if(1)
|
||||
see_in_dark = 5
|
||||
if(!druggy)
|
||||
@@ -781,22 +791,22 @@
|
||||
if(!druggy)
|
||||
see_invisible = 0
|
||||
|
||||
else if (istype(src.glasses, /obj/item/clothing/glasses/meson))
|
||||
src.sight |= SEE_TURFS
|
||||
if(!src.druggy)
|
||||
src.see_invisible = 0
|
||||
else if (istype(src.glasses, /obj/item/clothing/glasses/night))
|
||||
src.see_in_dark = 5
|
||||
if(!src.druggy)
|
||||
src.see_invisible = 0
|
||||
else if (istype(src.glasses, /obj/item/clothing/glasses/thermal))
|
||||
src.sight |= SEE_MOBS
|
||||
if(!src.druggy)
|
||||
src.see_invisible = 2
|
||||
else if (istype(src.glasses, /obj/item/clothing/glasses/material))
|
||||
src.sight |= SEE_OBJS
|
||||
if (!src.druggy)
|
||||
src.see_invisible = 0
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/meson))
|
||||
sight |= SEE_TURFS
|
||||
if(!druggy)
|
||||
see_invisible = 0
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/night))
|
||||
see_in_dark = 5
|
||||
if(!druggy)
|
||||
see_invisible = 0
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/thermal))
|
||||
sight |= SEE_MOBS
|
||||
if(!druggy)
|
||||
see_invisible = 2
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/material))
|
||||
sight |= SEE_OBJS
|
||||
if (!druggy)
|
||||
see_invisible = 0
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/hud/security))
|
||||
if(client)
|
||||
var/icon/tempHud = 'hud.dmi'
|
||||
@@ -820,8 +830,8 @@
|
||||
break
|
||||
else
|
||||
client.images += image(tempHud,perp,"hudunknown")
|
||||
if (!src.druggy)
|
||||
src.see_invisible = 0
|
||||
if (!druggy)
|
||||
see_invisible = 0
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/hud/health))
|
||||
if(client)
|
||||
var/icon/tempHud = 'hud.dmi'
|
||||
@@ -835,130 +845,130 @@
|
||||
client.images += image(tempHud,patient,"hudill")
|
||||
else
|
||||
client.images += image(tempHud,patient,"hudhealthy")
|
||||
if (!src.druggy)
|
||||
src.see_invisible = 0
|
||||
if (!druggy)
|
||||
see_invisible = 0
|
||||
|
||||
else if (src.stat != 2)
|
||||
src.sight &= ~SEE_TURFS
|
||||
src.sight &= ~SEE_MOBS
|
||||
src.sight &= ~SEE_OBJS
|
||||
if (src.mutantrace == "lizard" || src.mutantrace == "metroid")
|
||||
src.see_in_dark = 3
|
||||
src.see_invisible = 1
|
||||
else if (src.druggy) // If drugged~
|
||||
src.see_in_dark = 2
|
||||
else if (stat != 2)
|
||||
sight &= ~SEE_TURFS
|
||||
sight &= ~SEE_MOBS
|
||||
sight &= ~SEE_OBJS
|
||||
if (mutantrace == "lizard" || mutantrace == "metroid")
|
||||
see_in_dark = 3
|
||||
see_invisible = 1
|
||||
else if (druggy) // If drugged~
|
||||
see_in_dark = 2
|
||||
//see_invisible regulated by drugs themselves.
|
||||
else
|
||||
src.see_in_dark = 2
|
||||
see_in_dark = 2
|
||||
var/seer = 0
|
||||
for(var/obj/rune/R in world)
|
||||
if(src.loc==R.loc && R.word1==wordsee && R.word2==wordhell && R.word3==wordjoin)
|
||||
if(loc==R.loc && R.word1==wordsee && R.word2==wordhell && R.word3==wordjoin)
|
||||
seer = 1
|
||||
if(!seer)
|
||||
src.see_invisible = 0
|
||||
see_invisible = 0
|
||||
|
||||
else if (istype(src.glasses, /obj/item/clothing/glasses/sunglasses))
|
||||
src.see_in_dark = 1
|
||||
else if (istype(src.head, /obj/item/clothing/head/helmet/welding))
|
||||
if(!src.head:up && tinted_weldhelh)
|
||||
src.see_in_dark = 1
|
||||
else if (istype(glasses, /obj/item/clothing/glasses/sunglasses))
|
||||
see_in_dark = 1
|
||||
else if (istype(head, /obj/item/clothing/head/helmet/welding))
|
||||
if(!head:up && tinted_weldhelh)
|
||||
see_in_dark = 1
|
||||
|
||||
if (src.sleep) src.sleep.icon_state = text("sleep[]", src.sleeping)
|
||||
if (src.rest) src.rest.icon_state = text("rest[]", src.resting)
|
||||
if (sleep) sleep.icon_state = text("sleep[]", sleeping)
|
||||
if (rest) rest.icon_state = text("rest[]", resting)
|
||||
|
||||
if (src.healths)
|
||||
if (src.stat != 2)
|
||||
if (healths)
|
||||
if (stat != 2)
|
||||
switch(health)
|
||||
if(100 to INFINITY)
|
||||
src.healths.icon_state = "health0"
|
||||
healths.icon_state = "health0"
|
||||
if(80 to 100)
|
||||
src.healths.icon_state = "health1"
|
||||
healths.icon_state = "health1"
|
||||
if(60 to 80)
|
||||
src.healths.icon_state = "health2"
|
||||
healths.icon_state = "health2"
|
||||
if(40 to 60)
|
||||
src.healths.icon_state = "health3"
|
||||
healths.icon_state = "health3"
|
||||
if(20 to 40)
|
||||
src.healths.icon_state = "health4"
|
||||
healths.icon_state = "health4"
|
||||
if(0 to 20)
|
||||
src.healths.icon_state = "health5"
|
||||
healths.icon_state = "health5"
|
||||
else
|
||||
src.healths.icon_state = "health6"
|
||||
healths.icon_state = "health6"
|
||||
else
|
||||
src.healths.icon_state = "health7"
|
||||
healths.icon_state = "health7"
|
||||
|
||||
if (src.nutrition_icon)
|
||||
if (nutrition_icon)
|
||||
switch(nutrition)
|
||||
if(450 to INFINITY)
|
||||
src.nutrition_icon.icon_state = "nutrition0"
|
||||
nutrition_icon.icon_state = "nutrition0"
|
||||
if(350 to 450)
|
||||
src.nutrition_icon.icon_state = "nutrition1"
|
||||
nutrition_icon.icon_state = "nutrition1"
|
||||
if(250 to 350)
|
||||
src.nutrition_icon.icon_state = "nutrition2"
|
||||
nutrition_icon.icon_state = "nutrition2"
|
||||
if(150 to 250)
|
||||
src.nutrition_icon.icon_state = "nutrition3"
|
||||
nutrition_icon.icon_state = "nutrition3"
|
||||
else
|
||||
src.nutrition_icon.icon_state = "nutrition4"
|
||||
nutrition_icon.icon_state = "nutrition4"
|
||||
|
||||
if(src.pullin) src.pullin.icon_state = "pull[src.pulling ? 1 : 0]"
|
||||
if(pullin) pullin.icon_state = "pull[pulling ? 1 : 0]"
|
||||
|
||||
if(src.resting || src.lying || src.sleeping) src.rest.icon_state = "rest[(src.resting || src.lying || src.sleeping) ? 1 : 0]"
|
||||
if(resting || lying || sleeping) rest.icon_state = "rest[(resting || lying || sleeping) ? 1 : 0]"
|
||||
|
||||
|
||||
if (src.toxin) src.toxin.icon_state = "tox[src.toxins_alert ? 1 : 0]"
|
||||
if (src.oxygen) src.oxygen.icon_state = "oxy[src.oxygen_alert ? 1 : 0]"
|
||||
if (src.fire) src.fire.icon_state = "fire[src.fire_alert ? 1 : 0]"
|
||||
if (toxin) toxin.icon_state = "tox[toxins_alert ? 1 : 0]"
|
||||
if (oxygen) oxygen.icon_state = "oxy[oxygen_alert ? 1 : 0]"
|
||||
if (fire) fire.icon_state = "fire[fire_alert ? 1 : 0]"
|
||||
//NOTE: the alerts dont reset when youre out of danger. dont blame me,
|
||||
//blame the person who coded them. Temporary fix added.
|
||||
|
||||
switch(src.bodytemperature) //310.055 optimal body temp
|
||||
switch(bodytemperature) //310.055 optimal body temp
|
||||
|
||||
if(370 to INFINITY)
|
||||
src.bodytemp.icon_state = "temp4"
|
||||
bodytemp.icon_state = "temp4"
|
||||
if(350 to 370)
|
||||
src.bodytemp.icon_state = "temp3"
|
||||
bodytemp.icon_state = "temp3"
|
||||
if(335 to 350)
|
||||
src.bodytemp.icon_state = "temp2"
|
||||
bodytemp.icon_state = "temp2"
|
||||
if(320 to 335)
|
||||
src.bodytemp.icon_state = "temp1"
|
||||
bodytemp.icon_state = "temp1"
|
||||
if(300 to 320)
|
||||
src.bodytemp.icon_state = "temp0"
|
||||
bodytemp.icon_state = "temp0"
|
||||
if(295 to 300)
|
||||
src.bodytemp.icon_state = "temp-1"
|
||||
bodytemp.icon_state = "temp-1"
|
||||
if(280 to 295)
|
||||
src.bodytemp.icon_state = "temp-2"
|
||||
bodytemp.icon_state = "temp-2"
|
||||
if(260 to 280)
|
||||
src.bodytemp.icon_state = "temp-3"
|
||||
bodytemp.icon_state = "temp-3"
|
||||
else
|
||||
src.bodytemp.icon_state = "temp-4"
|
||||
bodytemp.icon_state = "temp-4"
|
||||
|
||||
src.client.screen -= src.hud_used.blurry
|
||||
src.client.screen -= src.hud_used.druggy
|
||||
src.client.screen -= src.hud_used.vimpaired
|
||||
src.client.screen -= src.hud_used.darkMask
|
||||
client.screen -= hud_used.blurry
|
||||
client.screen -= hud_used.druggy
|
||||
client.screen -= hud_used.vimpaired
|
||||
client.screen -= hud_used.darkMask
|
||||
|
||||
if ((src.blind && src.stat != 2))
|
||||
if ((src.blinded))
|
||||
src.blind.layer = 18
|
||||
if ((blind && stat != 2))
|
||||
if ((blinded))
|
||||
blind.layer = 18
|
||||
else
|
||||
src.blind.layer = 0
|
||||
blind.layer = 0
|
||||
|
||||
if (src.disabilities & 1 && !istype(src.glasses, /obj/item/clothing/glasses/regular) )
|
||||
src.client.screen += src.hud_used.vimpaired
|
||||
if (disabilities & 1 && !istype(glasses, /obj/item/clothing/glasses/regular) )
|
||||
client.screen += hud_used.vimpaired
|
||||
|
||||
if (src.eye_blurry)
|
||||
src.client.screen += src.hud_used.blurry
|
||||
if (eye_blurry)
|
||||
client.screen += hud_used.blurry
|
||||
|
||||
if (src.druggy)
|
||||
src.client.screen += src.hud_used.druggy
|
||||
if (druggy)
|
||||
client.screen += hud_used.druggy
|
||||
|
||||
if (istype(src.head, /obj/item/clothing/head/helmet/welding))
|
||||
if(!src.head:up && tinted_weldhelh)
|
||||
src.client.screen += src.hud_used.darkMask
|
||||
if (istype(head, /obj/item/clothing/head/helmet/welding))
|
||||
if(!head:up && tinted_weldhelh)
|
||||
client.screen += hud_used.darkMask
|
||||
|
||||
if (src.stat != 2)
|
||||
if (src.machine)
|
||||
if (!( src.machine.check_eye(src) ))
|
||||
src.reset_view(null)
|
||||
if (stat != 2)
|
||||
if (machine)
|
||||
if (!( machine.check_eye(src) ))
|
||||
reset_view(null)
|
||||
else
|
||||
if(!client.adminobs)
|
||||
reset_view(null)
|
||||
@@ -972,19 +982,19 @@
|
||||
return
|
||||
|
||||
handle_virus_updates()
|
||||
if(src.bodytemperature > 406 && src.virus)
|
||||
src.virus.cure()
|
||||
if(bodytemperature > 406 && virus)
|
||||
virus.cure()
|
||||
return
|
||||
|
||||
|
||||
check_if_buckled()
|
||||
if (src.buckled)
|
||||
src.lying = istype(src.buckled, /obj/stool/bed) || istype(src.buckled, /obj/machinery/conveyor)
|
||||
if(src.lying)
|
||||
src.drop_item()
|
||||
src.density = 1
|
||||
if (buckled)
|
||||
lying = istype(buckled, /obj/stool/bed) || istype(buckled, /obj/machinery/conveyor)
|
||||
if(lying)
|
||||
drop_item()
|
||||
density = 1
|
||||
else
|
||||
src.density = !src.lying
|
||||
density = !lying
|
||||
|
||||
handle_stomach()
|
||||
spawn(0)
|
||||
@@ -992,7 +1002,7 @@
|
||||
if(M.loc != src)
|
||||
stomach_contents.Remove(M)
|
||||
continue
|
||||
if(istype(M, /mob/living/carbon) && src.stat != 2)
|
||||
if(istype(M, /mob/living/carbon) && stat != 2)
|
||||
if(M.stat == 2)
|
||||
M.death(1)
|
||||
stomach_contents.Remove(M)
|
||||
@@ -1001,73 +1011,73 @@
|
||||
if(air_master.current_cycle%3==1)
|
||||
if(!M.nodamage)
|
||||
M.bruteloss += 5
|
||||
src.nutrition += 10
|
||||
nutrition += 10
|
||||
|
||||
handle_changeling()
|
||||
if (mind)
|
||||
if (mind.special_role == "Changeling")
|
||||
src.chem_charges = between(0, (max((0.9 - (chem_charges / 50)), 0.1) + chem_charges), 50)
|
||||
chem_charges = between(0, (max((0.9 - (chem_charges / 50)), 0.1) + chem_charges), 50)
|
||||
|
||||
|
||||
/*
|
||||
// Commented out so hunger system won't be such shock
|
||||
// Damage and effects from not eating
|
||||
if(src.nutrition <= 50)
|
||||
if(nutrition <= 50)
|
||||
if (prob (0.1))
|
||||
src << "\red Your stomach rumbles."
|
||||
if (prob (10))
|
||||
src.bruteloss++
|
||||
bruteloss++
|
||||
if (prob (5))
|
||||
src << "You feel very weak."
|
||||
src.weakened += rand(2, 3)
|
||||
weakened += rand(2, 3)
|
||||
*/
|
||||
/*
|
||||
snippets
|
||||
|
||||
if (src.mach)
|
||||
if (src.machine)
|
||||
src.mach.icon_state = "mach1"
|
||||
if (mach)
|
||||
if (machine)
|
||||
mach.icon_state = "mach1"
|
||||
else
|
||||
src.mach.icon_state = null
|
||||
mach.icon_state = null
|
||||
|
||||
if (!src.m_flag)
|
||||
src.moved_recently = 0
|
||||
src.m_flag = null
|
||||
if (!m_flag)
|
||||
moved_recently = 0
|
||||
m_flag = null
|
||||
|
||||
|
||||
|
||||
if ((istype(src.loc, /turf/space) && !( locate(/obj/movable, src.loc) )))
|
||||
if ((istype(loc, /turf/space) && !( locate(/obj/movable, loc) )))
|
||||
var/layers = 20
|
||||
// ******* Check
|
||||
if (((istype(src.head, /obj/item/clothing/head) && src.head.flags & 4) || (istype(src.wear_mask, /obj/item/clothing/mask) && (!( src.wear_mask.flags & 4 ) && src.wear_mask.flags & 8))))
|
||||
if (((istype(head, /obj/item/clothing/head) && head.flags & 4) || (istype(wear_mask, /obj/item/clothing/mask) && (!( wear_mask.flags & 4 ) && wear_mask.flags & 8))))
|
||||
layers -= 5
|
||||
if (istype(src.w_uniform, /obj/item/clothing/under))
|
||||
if (istype(w_uniform, /obj/item/clothing/under))
|
||||
layers -= 5
|
||||
if ((istype(src.wear_suit, /obj/item/clothing/suit) && src.wear_suit.flags & 8))
|
||||
if ((istype(wear_suit, /obj/item/clothing/suit) && wear_suit.flags & 8))
|
||||
layers -= 10
|
||||
if (layers > oxcheck)
|
||||
oxcheck = layers
|
||||
|
||||
|
||||
if(src.bodytemperature < 282.591 && (!src.firemut))
|
||||
if(src.bodytemperature < 250)
|
||||
src.fireloss += 4
|
||||
src.updatehealth()
|
||||
if(src.paralysis <= 2) src.paralysis += 2
|
||||
else if(prob(1) && !src.paralysis)
|
||||
if(src.paralysis <= 5) src.paralysis += 5
|
||||
if(bodytemperature < 282.591 && (!firemut))
|
||||
if(bodytemperature < 250)
|
||||
fireloss += 4
|
||||
updatehealth()
|
||||
if(paralysis <= 2) paralysis += 2
|
||||
else if(prob(1) && !paralysis)
|
||||
if(paralysis <= 5) paralysis += 5
|
||||
emote("collapse")
|
||||
src << "\red You collapse from the cold!"
|
||||
if(src.bodytemperature > 327.444 && (!src.firemut))
|
||||
if(src.bodytemperature > 345.444)
|
||||
if(!src.eye_blurry) src << "\red The heat blurs your vision!"
|
||||
src.eye_blurry = max(4, src.eye_blurry)
|
||||
if(prob(3)) src.fireloss += rand(1,2)
|
||||
else if(prob(3) && !src.paralysis)
|
||||
src.paralysis += 2
|
||||
if(bodytemperature > 327.444 && (!firemut))
|
||||
if(bodytemperature > 345.444)
|
||||
if(!eye_blurry) src << "\red The heat blurs your vision!"
|
||||
eye_blurry = max(4, eye_blurry)
|
||||
if(prob(3)) fireloss += rand(1,2)
|
||||
else if(prob(3) && !paralysis)
|
||||
paralysis += 2
|
||||
emote("collapse")
|
||||
src << "\red You collapse from heat exaustion!"
|
||||
plcheck = src.t_plasma
|
||||
oxcheck = src.t_oxygen
|
||||
plcheck = t_plasma
|
||||
oxcheck = t_oxygen
|
||||
G.turf_add(T, G.total_moles())
|
||||
*/
|
||||
@@ -76,8 +76,6 @@
|
||||
/mob/living/carbon/human/say_understands(var/other)
|
||||
if (istype(other, /mob/living/silicon/ai))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/aihologram))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/robot))
|
||||
return 1
|
||||
if (istype(other, /mob/living/carbon/brain))
|
||||
|
||||
@@ -13,9 +13,9 @@
|
||||
|
||||
if(L)
|
||||
if (istype(L, /datum/ai_laws))
|
||||
laws_object = L
|
||||
laws = L
|
||||
else
|
||||
laws_object = new /datum/ai_laws/asimov
|
||||
laws = new /datum/ai_laws/asimov
|
||||
|
||||
verbs += /mob/living/silicon/ai/proc/show_laws_verb
|
||||
|
||||
@@ -293,7 +293,7 @@
|
||||
/mob/living/silicon/ai/attack_hand(mob/living/carbon/M as mob)
|
||||
if(ishuman(M))//Checks to see if they are ninja
|
||||
if(istype(M:gloves, /obj/item/clothing/gloves/space_ninja)&&M:gloves:candrain&&!M:gloves:draining)
|
||||
if(M:wear_suit:control)
|
||||
if(M:wear_suit:s_control)
|
||||
M:wear_suit:transfer_ai("AICORE", "NINJASUIT", src, M)
|
||||
else
|
||||
M << "\red <b>ERROR</b>: \black Remote access channel disabled."
|
||||
|
||||
@@ -14,39 +14,39 @@
|
||||
who << "<b>Obey these laws:</b>"
|
||||
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.show_laws(who)
|
||||
src.laws.show_laws(who)
|
||||
|
||||
/mob/living/silicon/ai/proc/laws_sanity_check()
|
||||
if (!src.laws_object)
|
||||
src.laws_object = new /datum/ai_laws/asimov
|
||||
if (!src.laws)
|
||||
src.laws = new /datum/ai_laws/asimov
|
||||
|
||||
/mob/living/silicon/ai/proc/set_zeroth_law(var/law)
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.set_zeroth_law(law)
|
||||
src.laws.set_zeroth_law(law)
|
||||
|
||||
/mob/living/silicon/ai/proc/add_inherent_law(var/law)
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.add_inherent_law(law)
|
||||
src.laws.add_inherent_law(law)
|
||||
|
||||
/mob/living/silicon/ai/proc/clear_inherent_laws()
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.clear_inherent_laws()
|
||||
src.laws.clear_inherent_laws()
|
||||
|
||||
/mob/living/silicon/ai/proc/add_ion_law(var/law)
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.add_ion_law(law)
|
||||
src.laws.add_ion_law(law)
|
||||
|
||||
/mob/living/silicon/ai/proc/clear_ion_laws()
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.clear_ion_laws()
|
||||
src.laws.clear_ion_laws()
|
||||
|
||||
/mob/living/silicon/ai/proc/add_supplied_law(var/number, var/law)
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.add_supplied_law(number, law)
|
||||
src.laws.add_supplied_law(number, law)
|
||||
|
||||
/mob/living/silicon/ai/proc/clear_supplied_laws()
|
||||
src.laws_sanity_check()
|
||||
src.laws_object.clear_supplied_laws()
|
||||
src.laws.clear_supplied_laws()
|
||||
|
||||
|
||||
|
||||
@@ -57,27 +57,27 @@
|
||||
// set name = "State Laws"
|
||||
src.say("Current Active Laws:")
|
||||
//src.laws_sanity_check()
|
||||
//src.laws_object.show_laws(world)
|
||||
//src.laws.show_laws(world)
|
||||
var/number = 1
|
||||
sleep(10)
|
||||
|
||||
|
||||
|
||||
if (src.laws_object.zeroth)
|
||||
if (src.laws.zeroth)
|
||||
if (src.lawcheck[1] == "Yes") //This line and the similar lines below make sure you don't state a law unless you want to. --NeoFite
|
||||
src.say("0. [src.laws_object.zeroth]")
|
||||
src.say("0. [src.laws.zeroth]")
|
||||
sleep(10)
|
||||
|
||||
for (var/index = 1, index <= src.laws_object.ion.len, index++)
|
||||
var/law = src.laws_object.ion[index]
|
||||
for (var/index = 1, index <= src.laws.ion.len, index++)
|
||||
var/law = src.laws.ion[index]
|
||||
var/num = ionnum()
|
||||
if (length(law) > 0)
|
||||
if (src.ioncheck[index] == "Yes")
|
||||
src.say("[num]. [law]")
|
||||
sleep(10)
|
||||
|
||||
for (var/index = 1, index <= src.laws_object.inherent.len, index++)
|
||||
var/law = src.laws_object.inherent[index]
|
||||
for (var/index = 1, index <= src.laws.inherent.len, index++)
|
||||
var/law = src.laws.inherent[index]
|
||||
|
||||
if (length(law) > 0)
|
||||
if (src.lawcheck[index+1] == "Yes")
|
||||
@@ -86,8 +86,8 @@
|
||||
number++
|
||||
|
||||
|
||||
for (var/index = 1, index <= src.laws_object.supplied.len, index++)
|
||||
var/law = src.laws_object.supplied[index]
|
||||
for (var/index = 1, index <= src.laws.supplied.len, index++)
|
||||
var/law = src.laws.supplied[index]
|
||||
|
||||
if (length(law) > 0)
|
||||
if (src.lawcheck[number+1] == "Yes")
|
||||
@@ -104,13 +104,13 @@
|
||||
|
||||
|
||||
|
||||
if (src.laws_object.zeroth)
|
||||
if (src.laws.zeroth)
|
||||
if (!src.lawcheck[1])
|
||||
src.lawcheck[1] = "No" //Given Law 0's usual nature, it defaults to NOT getting reported. --NeoFite
|
||||
list += {"<A href='byond://?src=\ref[src];lawc=0'>[src.lawcheck[1]] 0:</A> [src.laws_object.zeroth]<BR>"}
|
||||
list += {"<A href='byond://?src=\ref[src];lawc=0'>[src.lawcheck[1]] 0:</A> [src.laws.zeroth]<BR>"}
|
||||
|
||||
for (var/index = 1, index <= src.laws_object.ion.len, index++)
|
||||
var/law = src.laws_object.ion[index]
|
||||
for (var/index = 1, index <= src.laws.ion.len, index++)
|
||||
var/law = src.laws.ion[index]
|
||||
|
||||
if (length(law) > 0)
|
||||
|
||||
@@ -121,8 +121,8 @@
|
||||
src.ioncheck.len += 1
|
||||
|
||||
var/number = 1
|
||||
for (var/index = 1, index <= src.laws_object.inherent.len, index++)
|
||||
var/law = src.laws_object.inherent[index]
|
||||
for (var/index = 1, index <= src.laws.inherent.len, index++)
|
||||
var/law = src.laws.inherent[index]
|
||||
|
||||
if (length(law) > 0)
|
||||
src.lawcheck.len += 1
|
||||
@@ -132,8 +132,8 @@
|
||||
list += {"<A href='byond://?src=\ref[src];lawc=[number]'>[src.lawcheck[number+1]] [number]:</A> [law]<BR>"}
|
||||
number++
|
||||
|
||||
for (var/index = 1, index <= src.laws_object.supplied.len, index++)
|
||||
var/law = src.laws_object.supplied[index]
|
||||
for (var/index = 1, index <= src.laws.supplied.len, index++)
|
||||
var/law = src.laws.supplied[index]
|
||||
if (length(law) > 0)
|
||||
src.lawcheck.len += 1
|
||||
if (!src.lawcheck[number+1])
|
||||
|
||||
@@ -19,6 +19,13 @@
|
||||
S.hologram.dir = direct
|
||||
return//Whatever the case, return since you can't move anyway.
|
||||
|
||||
if(user.client)//To make AI holograms work. They will relay directions as long as they are centered on the object.
|
||||
var/obj/machinery/holopad/T = user.client.eye//Client eye centers on an object.
|
||||
if(istype(T)&&T.hologram&&T.master==user)//If there is a hologram and its master is the user.
|
||||
T.hologram.loc = get_step(T.hologram, direct)
|
||||
T.hologram.dir = direct
|
||||
return//Relay move and then return if that's the case.
|
||||
|
||||
if(!old) return
|
||||
|
||||
var/dx = 0
|
||||
@@ -32,7 +39,6 @@
|
||||
else if(direct & WEST)
|
||||
dx = -1
|
||||
|
||||
|
||||
var/area/A = get_area(old)
|
||||
var/list/old_types = dd_text2list("[A.type]", "/")
|
||||
|
||||
|
||||
@@ -1,47 +0,0 @@
|
||||
/mob/living/silicon/aihologram/New()
|
||||
..()
|
||||
if(parent_ai)
|
||||
src.name = parent_ai:name
|
||||
src.real_name = parent_ai:real_name
|
||||
|
||||
/mob/living/silicon/aihologram/Stat()
|
||||
..()
|
||||
statpanel("Status")
|
||||
if (src.client.statpanel == "Status")
|
||||
if(emergency_shuttle.online && emergency_shuttle.location < 2)
|
||||
var/timeleft = emergency_shuttle.timeleft()
|
||||
if (timeleft)
|
||||
stat(null, "ETA-[(timeleft / 60) % 60]:[add_zero(num2text(timeleft % 60), 2)]")
|
||||
|
||||
/mob/living/silicon/aihologram/proc/ai_roster()
|
||||
set category = "AI Commands"
|
||||
set name = "Show Crew Manifest"
|
||||
|
||||
var/dat = "<html><head><title>Crew Roster</title></head><body><b>Crew Roster:</b><br><br>"
|
||||
|
||||
for (var/datum/data/record/t in data_core.general)
|
||||
dat += "[t.fields["name"]] - [t.fields["rank"]]<br>"
|
||||
|
||||
dat += "</body></html>"
|
||||
|
||||
src << browse(dat, "window=airoster")
|
||||
onclose(src, "airoster")
|
||||
|
||||
/mob/living/silicon/aihologram/ex_act(severity) //something immaterial is immune to bombs and everything else, really
|
||||
return
|
||||
|
||||
/mob/living/silicon/aihologram/meteorhit(obj/O as obj)
|
||||
return
|
||||
|
||||
/mob/living/silicon/aihologram/bullet_act(flag)
|
||||
return
|
||||
|
||||
/mob/living/silicon/aihologram/Life()
|
||||
if(src.stat)
|
||||
del(src)
|
||||
..()
|
||||
|
||||
/mob/living/silicon/aihologram/proc/back_to_ai()
|
||||
set category = "AI Commands"
|
||||
set name = "Return To AI"
|
||||
del(src)
|
||||
@@ -1,4 +0,0 @@
|
||||
/mob/living/silicon/aihologram/Del() //can't "die" per se, so it's only Del()
|
||||
if(parent_ai)
|
||||
parent_ai:client = src.client //parent_ai is always an ai mob, so : is okay
|
||||
..()
|
||||
@@ -1,454 +0,0 @@
|
||||
/mob/living/silicon/aihologram/emote(var/act)
|
||||
var/param = null
|
||||
|
||||
if (findtext(act, "-", 1, null))
|
||||
var/t1 = findtext(act, "-", 1, null)
|
||||
param = copytext(act, t1 + 1, length(act) + 1)
|
||||
act = copytext(act, 1, t1)
|
||||
|
||||
var/muzzled = istype(src.wear_mask, /obj/item/clothing/mask/muzzle)
|
||||
var/m_type = 1
|
||||
|
||||
for (var/obj/item/weapon/implant/I in src)
|
||||
if (I.implanted)
|
||||
I.trigger(act, src)
|
||||
|
||||
var/message
|
||||
|
||||
switch(act)
|
||||
if ("airguitar")
|
||||
if (!src.restrained())
|
||||
message = "<B>[src]</B> is strumming the air and headbanging like a safari chimp."
|
||||
m_type = 1
|
||||
|
||||
if ("blink")
|
||||
message = "<B>[src]</B> blinks."
|
||||
m_type = 1
|
||||
|
||||
if ("blink_r")
|
||||
message = "<B>[src]</B> blinks rapidly."
|
||||
m_type = 1
|
||||
|
||||
if ("bow")
|
||||
if (!src.buckled)
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(null, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (!M)
|
||||
param = null
|
||||
|
||||
if (param)
|
||||
message = "<B>[src]</B> bows to [param]."
|
||||
else
|
||||
message = "<B>[src]</B> bows."
|
||||
m_type = 1
|
||||
|
||||
if ("custom")
|
||||
var/input = input("Choose an emote to display.") as text|null
|
||||
if (!input)
|
||||
return
|
||||
input = sanitize(input)
|
||||
var/input2 = input("Is this a visible or hearable emote?") in list("Visible","Hearable")
|
||||
if (input2 == "Visible")
|
||||
m_type = 1
|
||||
else if (input2 == "Hearable")
|
||||
if (src.miming)
|
||||
return
|
||||
m_type = 2
|
||||
else
|
||||
alert("Unable to use this emote, must be either hearable or visible.")
|
||||
return
|
||||
message = "<B>[src]</B> [input]"
|
||||
|
||||
|
||||
if ("salute")
|
||||
if (!src.buckled)
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(null, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (!M)
|
||||
param = null
|
||||
|
||||
if (param)
|
||||
message = "<B>[src]</B> salutes to [param]."
|
||||
else
|
||||
message = "<B>[src]</b> salutes."
|
||||
m_type = 1
|
||||
|
||||
if ("choke")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> chokes!"
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a strong noise."
|
||||
m_type = 2
|
||||
|
||||
if ("clap")
|
||||
if (!src.restrained())
|
||||
message = "<B>[src]</B> claps."
|
||||
m_type = 2
|
||||
if ("flap")
|
||||
if (!src.restrained())
|
||||
message = "<B>[src]</B> flaps his wings."
|
||||
m_type = 2
|
||||
|
||||
if ("aflap")
|
||||
if (!src.restrained())
|
||||
message = "<B>[src]</B> flaps his wings ANGRILY!"
|
||||
m_type = 2
|
||||
|
||||
if ("drool")
|
||||
message = "<B>[src]</B> drools."
|
||||
m_type = 1
|
||||
|
||||
if ("eyebrow")
|
||||
message = "<B>[src]</B> raises an eyebrow."
|
||||
m_type = 1
|
||||
|
||||
if ("chuckle")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> chuckles."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a noise."
|
||||
m_type = 2
|
||||
|
||||
if ("twitch")
|
||||
message = "<B>[src]</B> twitches violently."
|
||||
m_type = 1
|
||||
|
||||
if ("twitch_s")
|
||||
message = "<B>[src]</B> twitches."
|
||||
m_type = 1
|
||||
|
||||
if ("faint")
|
||||
message = "<B>[src]</B> faints."
|
||||
src.sleeping = 1
|
||||
m_type = 1
|
||||
|
||||
if ("cough")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> coughs!"
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a strong noise."
|
||||
m_type = 2
|
||||
|
||||
if ("frown")
|
||||
message = "<B>[src]</B> frowns."
|
||||
m_type = 1
|
||||
|
||||
if ("nod")
|
||||
message = "<B>[src]</B> nods."
|
||||
m_type = 1
|
||||
|
||||
if ("blush")
|
||||
message = "<B>[src]</B> blushes."
|
||||
m_type = 1
|
||||
|
||||
if ("gasp")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> gasps!"
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a weak noise."
|
||||
m_type = 2
|
||||
|
||||
if ("deathgasp")
|
||||
message = "<B>[src]</B> seizes up and falls limp, \his eyes dead and lifeless..."
|
||||
m_type = 1
|
||||
|
||||
if ("giggle")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> giggles."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a noise."
|
||||
m_type = 2
|
||||
|
||||
if ("glare")
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(null, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (!M)
|
||||
param = null
|
||||
|
||||
if (param)
|
||||
message = "<B>[src]</B> glares at [param]."
|
||||
else
|
||||
message = "<B>[src]</B> glares."
|
||||
|
||||
if ("stare")
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(null, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (!M)
|
||||
param = null
|
||||
|
||||
if (param)
|
||||
message = "<B>[src]</B> stares at [param]."
|
||||
else
|
||||
message = "<B>[src]</B> stares."
|
||||
|
||||
if ("look")
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(null, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
|
||||
if (!M)
|
||||
param = null
|
||||
|
||||
if (param)
|
||||
message = "<B>[src]</B> looks at [param]."
|
||||
else
|
||||
message = "<B>[src]</B> looks."
|
||||
m_type = 1
|
||||
|
||||
if ("grin")
|
||||
message = "<B>[src]</B> grins."
|
||||
m_type = 1
|
||||
|
||||
if ("cry")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> cries."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a weak noise. \He frowns."
|
||||
m_type = 2
|
||||
|
||||
if ("sigh")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> sighs."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a weak noise."
|
||||
m_type = 2
|
||||
|
||||
if ("laugh")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> laughs."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a noise."
|
||||
m_type = 2
|
||||
|
||||
if ("mumble")
|
||||
message = "<B>[src]</B> mumbles!"
|
||||
m_type = 2
|
||||
|
||||
if ("grumble")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> grumbles!"
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a noise."
|
||||
m_type = 2
|
||||
|
||||
if ("groan")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> groans!"
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a loud noise."
|
||||
m_type = 2
|
||||
|
||||
if ("moan")
|
||||
message = "<B>[src]</B> moans!"
|
||||
m_type = 2
|
||||
|
||||
if ("johnny")
|
||||
var/M
|
||||
if (param)
|
||||
M = param
|
||||
if (!M)
|
||||
param = null
|
||||
else
|
||||
message = "<B>[src]</B> says, \"[M], please. He had a family.\" [src.name] takes a drag from a cigarette and blows his name out in smoke."
|
||||
m_type = 2
|
||||
|
||||
if ("point")
|
||||
if (!src.restrained())
|
||||
var/mob/M = null
|
||||
if (param)
|
||||
for (var/atom/A as mob|obj|turf|area in view(null, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
|
||||
if (!M)
|
||||
message = "<B>[src]</B> points."
|
||||
else
|
||||
M.point()
|
||||
|
||||
if (M)
|
||||
message = "<B>[src]</B> points to [M]."
|
||||
else
|
||||
m_type = 1
|
||||
|
||||
if ("raise")
|
||||
if (!src.restrained())
|
||||
message = "<B>[src]</B> raises a hand."
|
||||
m_type = 1
|
||||
|
||||
if("shake")
|
||||
message = "<B>[src]</B> shakes \his head."
|
||||
m_type = 1
|
||||
|
||||
if ("shrug")
|
||||
message = "<B>[src]</B> shrugs."
|
||||
m_type = 1
|
||||
|
||||
if ("signal")
|
||||
if (!src.restrained())
|
||||
var/t1 = round(text2num(param))
|
||||
if (isnum(t1))
|
||||
if (t1 <= 5 && (!src.r_hand || !src.l_hand))
|
||||
message = "<B>[src]</B> raises [t1] finger\s."
|
||||
else if (t1 <= 10 && (!src.r_hand && !src.l_hand))
|
||||
message = "<B>[src]</B> raises [t1] finger\s."
|
||||
m_type = 1
|
||||
|
||||
if ("smile")
|
||||
message = "<B>[src]</B> smiles."
|
||||
m_type = 1
|
||||
|
||||
if ("shiver")
|
||||
message = "<B>[src]</B> shivers."
|
||||
m_type = 2
|
||||
|
||||
if ("pale")
|
||||
message = "<B>[src]</B> goes pale for a second."
|
||||
m_type = 1
|
||||
|
||||
if ("tremble")
|
||||
message = "<B>[src]</B> trembles in fear!"
|
||||
m_type = 1
|
||||
|
||||
if ("sneeze")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> sneezes."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a strange noise."
|
||||
m_type = 2
|
||||
|
||||
if ("sniff")
|
||||
message = "<B>[src]</B> sniffs."
|
||||
m_type = 2
|
||||
|
||||
if ("snore")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> snores."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a noise."
|
||||
m_type = 2
|
||||
|
||||
if ("whimper")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> whimpers."
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a weak noise."
|
||||
m_type = 2
|
||||
|
||||
if ("wink")
|
||||
message = "<B>[src]</B> winks."
|
||||
m_type = 1
|
||||
|
||||
if ("yawn")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> yawns."
|
||||
m_type = 2
|
||||
|
||||
if ("collapse")
|
||||
if (!src.paralysis)
|
||||
src.paralysis += 2
|
||||
message = "<B>[src]</B> collapses!"
|
||||
m_type = 2
|
||||
|
||||
if("hug")
|
||||
m_type = 1
|
||||
if (!src.restrained())
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(1, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (M == src)
|
||||
M = null
|
||||
|
||||
if (M)
|
||||
message = "<B>[src]</B> hugs [M]."
|
||||
else
|
||||
message = "<B>[src]</B> hugs \himself."
|
||||
|
||||
if ("handshake")
|
||||
m_type = 1
|
||||
if (!src.restrained() && !src.r_hand)
|
||||
var/mob/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(1, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (M == src)
|
||||
M = null
|
||||
|
||||
if (M)
|
||||
if (M.canmove && !M.r_hand && !M.restrained())
|
||||
message = "<B>[src]</B> shakes hands with [M]."
|
||||
else
|
||||
message = "<B>[src]</B> holds out \his hand to [M]."
|
||||
|
||||
if("daps")
|
||||
m_type = 1
|
||||
if (!src.restrained())
|
||||
var/M = null
|
||||
if (param)
|
||||
for (var/mob/A in view(1, null))
|
||||
if (param == A.name)
|
||||
M = A
|
||||
break
|
||||
if (M)
|
||||
message = "<B>[src]</B> gives daps to [M]."
|
||||
else
|
||||
message = "<B>[src]</B> sadly can't find anybody to give daps to, and daps \himself. Shameful."
|
||||
|
||||
if ("scream")
|
||||
if (!muzzled)
|
||||
message = "<B>[src]</B> screams!"
|
||||
m_type = 2
|
||||
else
|
||||
message = "<B>[src]</B> makes a very loud noise."
|
||||
m_type = 2
|
||||
|
||||
if ("help")
|
||||
src << "blink, blink_r, blush, bow-(none)/mob, burp, choke, chuckle, clap, collapse, cough,\ncry, custom, deathgasp, drool, eyebrow, frown, gasp, giggle, groan, grumble, handshake, hug-(none)/mob, glare-(none)/mob,\ngrin, laugh, look-(none)/mob, moan, mumble, nod, pale, point-atom, raise, salute, shake, shiver, shrug,\nsigh, signal-#1-10, smile, sneeze, sniff, snore, stare-(none)/mob, tremble, twitch, twitch_s, whimper,\nwink, yawn"
|
||||
|
||||
else
|
||||
src << "\blue Unusable emote '[act]'. Say *help for a list."
|
||||
|
||||
if (message)
|
||||
if (m_type & 1)
|
||||
for (var/mob/O in viewers(src, null))
|
||||
O.show_message(message, m_type)
|
||||
else if (m_type & 2)
|
||||
for (var/mob/O in hearers(src, null))
|
||||
O.show_message(message, m_type)
|
||||
@@ -1,5 +0,0 @@
|
||||
/mob/living/silicon/aihologram/examine()
|
||||
set src in oview()
|
||||
usr << "\blue *---------*"
|
||||
usr << text("\blue This is \icon[] <B>[]</B>!", src, src.name)
|
||||
return
|
||||
@@ -1,10 +0,0 @@
|
||||
/obj/hud/proc/aihologram_hud()
|
||||
|
||||
src.station_explosion = new src.h_type( src )
|
||||
src.station_explosion.icon = 'station_explosion.dmi'
|
||||
src.station_explosion.icon_state = "start"
|
||||
src.station_explosion.layer = 20
|
||||
src.station_explosion.mouse_opacity = 0
|
||||
src.station_explosion.screen_loc = "1,3"
|
||||
|
||||
return
|
||||
@@ -1,25 +0,0 @@
|
||||
//I don't even know -- Urist
|
||||
|
||||
//I do. -- NEOFite
|
||||
|
||||
/mob/living/silicon/aihologram/verb/show_laws_verb()
|
||||
set category = "AI Commands"
|
||||
set name = "Show Laws"
|
||||
src.show_laws()
|
||||
|
||||
/mob/living/silicon/aihologram/show_laws(var/everyone = 0)
|
||||
var/who
|
||||
|
||||
if (everyone)
|
||||
who = world
|
||||
else
|
||||
who = src
|
||||
who << "<b>Obey these laws:</b>"
|
||||
|
||||
src.laws_sanity_check()
|
||||
src.ailaws.show_laws(who)
|
||||
|
||||
/mob/living/silicon/aihologram/proc/laws_sanity_check()
|
||||
if (!src.ailaws)
|
||||
src << "You are somehow an AI hologram without referencing a set of AI laws, so I got you a laws datum to prevent runtime errors."
|
||||
src.ailaws = new /datum/ai_laws/asimov
|
||||
@@ -1,10 +0,0 @@
|
||||
/mob/living/silicon/aihologram/Login()
|
||||
..()
|
||||
|
||||
src.client.screen = null
|
||||
|
||||
if (!isturf(src.loc))
|
||||
src.client.eye = src.loc
|
||||
src.client.perspective = EYE_PERSPECTIVE
|
||||
|
||||
return
|
||||
@@ -1,16 +0,0 @@
|
||||
/mob/living/silicon/aihologram/say_understands(var/other)
|
||||
if (istype(other, /mob/living/carbon/human))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon))
|
||||
return 1
|
||||
return ..()
|
||||
|
||||
/mob/living/silicon/aihologram/say_quote(var/text)
|
||||
var/ending = copytext(text, length(text))
|
||||
|
||||
if (ending == "?")
|
||||
return "queries, \"[text]\"";
|
||||
else if (ending == "!")
|
||||
return "declares, \"[copytext(text, 1, length(text))]\"";
|
||||
|
||||
return "states, \"[text]\"";
|
||||
@@ -54,12 +54,12 @@
|
||||
who << "<b>Obey these laws:</b>"
|
||||
|
||||
connected_ai.laws_sanity_check()
|
||||
connected_ai.laws_object.show_laws(who)
|
||||
connected_ai.laws.show_laws(who)
|
||||
|
||||
*/
|
||||
|
||||
/mob/living/silicon/robot/proc/lawsync()
|
||||
var/datum/ai_laws/master = src.connected_ai.laws_object
|
||||
var/datum/ai_laws/master = src.connected_ai.laws
|
||||
var/temp
|
||||
if (master)
|
||||
src.laws.ion.len = master.ion.len
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
connected_ai = activeais()
|
||||
if (connected_ai)
|
||||
connected_ai.connected_robots += src
|
||||
// laws = connected_ai.laws_object //The borg inherits its AI's laws
|
||||
// laws = connected_ai.laws //The borg inherits its AI's laws
|
||||
laws = new /datum/ai_laws
|
||||
lawsync()
|
||||
src << "<b>Unit slaved to [connected_ai.name], downloading laws.</b>"
|
||||
@@ -613,7 +613,7 @@
|
||||
|
||||
if(ishuman(user))
|
||||
if(istype(user:gloves, /obj/item/clothing/gloves/space_ninja)&&user:gloves:candrain&&!user:gloves:draining)
|
||||
call(/obj/item/clothing/gloves/space_ninja/proc/drain)("CYBORG",src,user:wear_suit,user:gloves)
|
||||
call(/obj/item/clothing/gloves/space_ninja/proc/drain)("CYBORG",src,user:wear_suit)
|
||||
return
|
||||
|
||||
/mob/living/silicon/robot/proc/allowed(mob/M)
|
||||
|
||||
@@ -2,22 +2,22 @@
|
||||
if (!message)
|
||||
return
|
||||
|
||||
if (src.muted)
|
||||
if (muted)
|
||||
return
|
||||
|
||||
if (src.stat == 2)
|
||||
if (stat == 2)
|
||||
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
|
||||
return src.say_dead(message)
|
||||
return say_dead(message)
|
||||
|
||||
// wtf?
|
||||
if (src.stat)
|
||||
if (stat)
|
||||
return
|
||||
|
||||
if (length(message) >= 2)
|
||||
if (copytext(message, 1, 3) == ":s")
|
||||
message = copytext(message, 3)
|
||||
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
|
||||
src.robot_talk(message)
|
||||
robot_talk(message)
|
||||
else
|
||||
return ..(message)
|
||||
else
|
||||
@@ -33,12 +33,35 @@
|
||||
if (!message)
|
||||
return
|
||||
|
||||
var/message_a = src.say_quote(message)
|
||||
var/rendered = "<i><span class='game say'>Robotic Talk, <span class='name'>[src.name]</span> <span class='message'>[message_a]</span></span></i>"
|
||||
var/message_a = say_quote(message)//Here so I don't have to define it again.
|
||||
|
||||
if(isAI(src)&&client)//For patching directly into AI holopads.
|
||||
var/obj/machinery/holopad/T = client.eye//Client eye centers on an object.
|
||||
if(istype(T)&&T.hologram&&T.master==src)//If there is a hologram and its master is the user.
|
||||
|
||||
//Human-like, sorta, heard by those who understand humans.
|
||||
var/rendered_a = "<span class='game say'><span class='name'>[name]</span> <span class='message'>[message_a]</span></span>"
|
||||
|
||||
//Speach distorted, heard by those who do not understand AIs.
|
||||
message = stars(message)
|
||||
var/message_b = say_quote(message)
|
||||
var/rendered_b = "<span class='game say'><span class='name'>[voice_name]</span> <span class='message'>[message_b]</span></span>"
|
||||
|
||||
src << "<i><span class='game say'>Holopad transmitted, <span class='name'>[real_name]</span> <span class='message'>[message_a]</span></span></i>"//The AI can "hear" its own message.
|
||||
for(var/mob/M in hearers(T.loc))//The location is the object, default distance.
|
||||
if(M.say_understands(src))//If they understand AI speak. Humans and the like will be able to.
|
||||
M.show_message(rendered_a, 2)
|
||||
else//If they do not.
|
||||
M.show_message(rendered_b, 2)
|
||||
/*Radios "filter out" this conversation channel so we don't need to account for them.
|
||||
This is another way of saying that we won't bother dealing with them.*/
|
||||
return
|
||||
|
||||
var/rendered = "<i><span class='game say'>Robotic Talk, <span class='name'>[name]</span> <span class='message'>[message_a]</span></span></i>"
|
||||
for (var/mob/living/S in world)
|
||||
if(!S.stat)
|
||||
if(S.robot_talk_understand)
|
||||
if(S.robot_talk_understand == src.robot_talk_understand)
|
||||
if(S.robot_talk_understand == robot_talk_understand)
|
||||
S.show_message(rendered, 2)
|
||||
else if (S.binarycheck())
|
||||
S.show_message(rendered, 2)
|
||||
@@ -52,22 +75,21 @@
|
||||
if(!istype(M, /mob/living/silicon) && !M.robot_talk_understand)
|
||||
heard += M
|
||||
|
||||
|
||||
if (length(heard))
|
||||
var/message_b
|
||||
|
||||
message_b = "beep beep beep"
|
||||
message_b = src.say_quote(message_b)
|
||||
message_b = say_quote(message_b)
|
||||
message_b = "<i>[message_b]</i>"
|
||||
|
||||
rendered = "<i><span class='game say'><span class='name'>[src.voice_name]</span> <span class='message'>[message_b]</span></span></i>"
|
||||
rendered = "<i><span class='game say'><span class='name'>[voice_name]</span> <span class='message'>[message_b]</span></span></i>"
|
||||
|
||||
for (var/mob/M in heard)
|
||||
M.show_message(rendered, 2)
|
||||
|
||||
message = src.say_quote(message)
|
||||
message = say_quote(message)
|
||||
|
||||
rendered = "<i><span class='game say'>Robotic Talk, <span class='name'>[src.name]</span> <span class='message'>[message_a]</span></span></i>"
|
||||
rendered = "<i><span class='game say'>Robotic Talk, <span class='name'>[name]</span> <span class='message'>[message_a]</span></span></i>"
|
||||
|
||||
for (var/mob/M in world)
|
||||
if (istype(M, /mob/new_player))
|
||||
|
||||
@@ -276,18 +276,8 @@ mob/new_player
|
||||
if(character.mind.assigned_role != "Cyborg")
|
||||
ManifestLateSpawn(character)
|
||||
if(ticker)
|
||||
if (ticker.current_state == GAME_STATE_PLAYING)
|
||||
var/list/mob/living/silicon/ai/ailist = list()
|
||||
for (var/mob/living/silicon/ai/A in world)
|
||||
if (!A.stat)
|
||||
ailist += A
|
||||
if (ailist.len)
|
||||
var/mob/living/silicon/ai/announcer = pick(ailist)
|
||||
if(character.mind.assigned_role != "Cyborg")
|
||||
announcer.say("[character.real_name] has signed up as [rank].")
|
||||
|
||||
var/starting_loc = pick(latejoin)
|
||||
character.loc = starting_loc
|
||||
character.loc = pick(latejoin)
|
||||
AnnounceArrival(character, rank)
|
||||
if(character.mind.assigned_role == "Cyborg")
|
||||
character.Robotize()
|
||||
del(src)
|
||||
@@ -295,13 +285,24 @@ mob/new_player
|
||||
else
|
||||
src << alert("[rank] is not available. Please try another.")
|
||||
|
||||
proc/AnnounceArrival(var/mob/living/carbon/human/character, var/rank)
|
||||
if (ticker.current_state == GAME_STATE_PLAYING)
|
||||
var/ailist[] = list()
|
||||
for (var/mob/living/silicon/ai/A in world)
|
||||
if (!A.stat)
|
||||
ailist += A
|
||||
if (ailist.len)
|
||||
var/mob/living/silicon/ai/announcer = pick(ailist)
|
||||
if(character.mind.assigned_role != "Cyborg"&&character.mind.special_role != "MODE")
|
||||
announcer.say("[character.real_name] has signed up as [rank].")
|
||||
|
||||
proc/ManifestLateSpawn(var/mob/living/carbon/human/H) // Attempted fix to add late joiners to various databases -- TLE
|
||||
// This is basically ripped wholesale from the normal code for adding people to the databases during a fresh round
|
||||
if (!isnull(H.mind) && (H.mind.assigned_role != "MODE"))
|
||||
var/datum/data/record/G = new /datum/data/record( )
|
||||
var/datum/data/record/M = new /datum/data/record( )
|
||||
var/datum/data/record/S = new /datum/data/record( )
|
||||
var/datum/data/record/G = new()
|
||||
var/datum/data/record/M = new()
|
||||
var/datum/data/record/S = new()
|
||||
var/datum/data/record/L = new()
|
||||
var/obj/item/weapon/card/id/C = H.wear_id
|
||||
if (C)
|
||||
G.fields["rank"] = C.assignment
|
||||
@@ -322,7 +323,7 @@ mob/new_player
|
||||
G.fields["p_stat"] = "Active"
|
||||
G.fields["m_stat"] = "Stable"
|
||||
M.fields["b_type"] = text("[]", H.b_type)
|
||||
M.fields["b_dna"] = "" //H.dna.unique_enzymes //nope. Scan them yourself, detective.
|
||||
M.fields["b_dna"] = ""//H.dna.unique_enzymes
|
||||
M.fields["mi_dis"] = "None"
|
||||
M.fields["mi_dis_d"] = "No minor disabilities have been declared."
|
||||
M.fields["ma_dis"] = "None"
|
||||
@@ -338,9 +339,22 @@ mob/new_player
|
||||
S.fields["ma_crim"] = "None"
|
||||
S.fields["ma_crim_d"] = "No major crime convictions."
|
||||
S.fields["notes"] = "No notes."
|
||||
|
||||
//Begin locked reporting
|
||||
L.fields["name"] = H.real_name
|
||||
L.fields["sex"] = H.gender
|
||||
L.fields["age"] = H.age
|
||||
L.fields["id"] = md5("[H.real_name][H.mind.assigned_role]")
|
||||
L.fields["rank"] = H.mind.assigned_role
|
||||
L.fields["b_type"] = H.b_type
|
||||
L.fields["b_dna"] = H.dna.unique_enzymes
|
||||
L.fields["identity"] = H.dna.uni_identity
|
||||
//End locked reporting
|
||||
|
||||
data_core.general += G
|
||||
data_core.medical += M
|
||||
data_core.security += S
|
||||
data_core.locked += L
|
||||
return
|
||||
|
||||
// This fxn creates positions for assistants based on existing positions. This could be more elegant.
|
||||
|
||||
@@ -38,15 +38,87 @@ datum/preferences
|
||||
|
||||
New()
|
||||
randomize_name()
|
||||
|
||||
..()
|
||||
|
||||
//The mob should have a gender you want before running this proc.
|
||||
proc/randomize_appearance_for(var/mob/living/carbon/human/H)
|
||||
if(H.gender == MALE)
|
||||
gender = MALE
|
||||
else
|
||||
gender = FEMALE
|
||||
randomize_skin_tone()
|
||||
randomize_hair(gender)
|
||||
randomize_hair_color("hair")
|
||||
if(gender == MALE)//only for dudes.
|
||||
randomize_facial()
|
||||
randomize_hair_color("facial")
|
||||
randomize_eyes_color()
|
||||
underwear = pick(0,1)
|
||||
b_type = pick("A+", "A-", "B+", "B-", "AB+", "AB-", "O+", "O-")
|
||||
age = rand(19,35)
|
||||
copy_to(H)
|
||||
|
||||
proc/randomize_name()
|
||||
if (gender == MALE)
|
||||
real_name = capitalize(pick(first_names_male) + " " + capitalize(pick(last_names)))
|
||||
else
|
||||
real_name = capitalize(pick(first_names_female) + " " + capitalize(pick(last_names)))
|
||||
|
||||
proc/randomize_hair(var/gender)
|
||||
//Women are more likely to have longer hair.
|
||||
var/temp = gender==FEMALE&&prob(80) ? pick(2,6,8) : rand(1,9)
|
||||
switch(temp)
|
||||
if(1)
|
||||
h_style = "Short Hair"
|
||||
if(2)
|
||||
h_style = "Long Hair"
|
||||
if(3)
|
||||
h_style = "Cut Hair"
|
||||
if(4)
|
||||
h_style = "Mohawk"
|
||||
if(5)
|
||||
h_style = "Balding"
|
||||
if(6)
|
||||
h_style = "Fag"
|
||||
if(7)
|
||||
h_style = "Bedhead"
|
||||
if(8)
|
||||
h_style = "Dreadlocks"
|
||||
else
|
||||
h_style = "bald"
|
||||
|
||||
proc/randomize_facial()
|
||||
var/temp = prob(50) ? 14 : rand(1,13)//50% of not having a beard. Otherwise get a random one.
|
||||
switch(temp)
|
||||
if(1)
|
||||
f_style = "Watson"
|
||||
if(2)
|
||||
f_style = "Chaplin"
|
||||
if(3)
|
||||
f_style = "Selleck"
|
||||
if(4)
|
||||
f_style = "Neckbeard"
|
||||
if(5)
|
||||
f_style = "Full Beard"
|
||||
if(6)
|
||||
f_style = "Long Beard"
|
||||
if(7)
|
||||
f_style = "Van Dyke"
|
||||
if(8)
|
||||
f_style = "Elvis"
|
||||
if(9)
|
||||
f_style = "Abe"
|
||||
if(10)
|
||||
f_style = "Chinstrap"
|
||||
if(11)
|
||||
f_style = "Hipster"
|
||||
if(12)
|
||||
f_style = "Goatee"
|
||||
if(13)
|
||||
f_style = "Hogan"
|
||||
else
|
||||
f_style = "bald"
|
||||
|
||||
proc/randomize_skin_tone()
|
||||
var/tone
|
||||
|
||||
@@ -65,7 +137,7 @@ datum/preferences
|
||||
if ("weird")
|
||||
tone = -(rand (1, 220)) + 35
|
||||
|
||||
src.s_tone = min(max(tone + rand (-25, 25), -185), 34)
|
||||
s_tone = min(max(tone + rand (-25, 25), -185), 34)
|
||||
|
||||
proc/randomize_hair_color(var/target = "hair")
|
||||
if (prob (75) && target == "facial") // Chance to inherit hair color
|
||||
@@ -180,27 +252,27 @@ datum/preferences
|
||||
b_eyes = blue
|
||||
|
||||
proc/update_preview_icon()
|
||||
del(src.preview_icon)
|
||||
del(preview_icon)
|
||||
|
||||
var/g = "m"
|
||||
if (src.gender == MALE)
|
||||
if (gender == MALE)
|
||||
g = "m"
|
||||
else if (src.gender == FEMALE)
|
||||
else if (gender == FEMALE)
|
||||
g = "f"
|
||||
|
||||
src.preview_icon = new /icon('human.dmi', "body_[g]_s")
|
||||
preview_icon = new /icon('human.dmi', "body_[g]_s")
|
||||
|
||||
// Skin tone
|
||||
if (src.s_tone >= 0)
|
||||
src.preview_icon.Blend(rgb(src.s_tone, src.s_tone, src.s_tone), ICON_ADD)
|
||||
if (s_tone >= 0)
|
||||
preview_icon.Blend(rgb(s_tone, s_tone, s_tone), ICON_ADD)
|
||||
else
|
||||
src.preview_icon.Blend(rgb(-src.s_tone, -src.s_tone, -src.s_tone), ICON_SUBTRACT)
|
||||
preview_icon.Blend(rgb(-s_tone, -s_tone, -s_tone), ICON_SUBTRACT)
|
||||
|
||||
if (src.underwear > 0)
|
||||
src.preview_icon.Blend(new /icon('human.dmi', "underwear[src.underwear]_[g]_s"), ICON_OVERLAY)
|
||||
if (underwear > 0)
|
||||
preview_icon.Blend(new /icon('human.dmi', "underwear[underwear]_[g]_s"), ICON_OVERLAY)
|
||||
|
||||
var/icon/eyes_s = new/icon("icon" = 'human_face.dmi', "icon_state" = "eyes_s")
|
||||
eyes_s.Blend(rgb(src.r_eyes, src.g_eyes, src.b_eyes), ICON_ADD)
|
||||
eyes_s.Blend(rgb(r_eyes, g_eyes, b_eyes), ICON_ADD)
|
||||
|
||||
var/h_style_r = null
|
||||
switch(h_style)
|
||||
@@ -255,10 +327,10 @@ datum/preferences
|
||||
f_style_r = "bald"
|
||||
|
||||
var/icon/hair_s = new/icon("icon" = 'human_face.dmi', "icon_state" = "[h_style_r]_s")
|
||||
hair_s.Blend(rgb(src.r_hair, src.g_hair, src.b_hair), ICON_ADD)
|
||||
hair_s.Blend(rgb(r_hair, g_hair, b_hair), ICON_ADD)
|
||||
|
||||
var/icon/facial_s = new/icon("icon" = 'human_face.dmi', "icon_state" = "[f_style_r]_s")
|
||||
facial_s.Blend(rgb(src.r_facial, src.g_facial, src.b_facial), ICON_ADD)
|
||||
facial_s.Blend(rgb(r_facial, g_facial, b_facial), ICON_ADD)
|
||||
|
||||
var/icon/mouth_s = new/icon("icon" = 'human_face.dmi', "icon_state" = "mouth_[g]_s")
|
||||
|
||||
@@ -266,7 +338,7 @@ datum/preferences
|
||||
eyes_s.Blend(mouth_s, ICON_OVERLAY)
|
||||
eyes_s.Blend(facial_s, ICON_OVERLAY)
|
||||
|
||||
src.preview_icon.Blend(eyes_s, ICON_OVERLAY)
|
||||
preview_icon.Blend(eyes_s, ICON_OVERLAY)
|
||||
|
||||
del(mouth_s)
|
||||
del(facial_s)
|
||||
@@ -280,17 +352,17 @@ datum/preferences
|
||||
var/list/destructive = assistant_occupations.Copy()
|
||||
var/dat = "<html><body>"
|
||||
dat += "<b>Name:</b> "
|
||||
dat += "<a href=\"byond://?src=\ref[user];preferences=1;real_name=input\"><b>[src.real_name]</b></a> "
|
||||
dat += "<a href=\"byond://?src=\ref[user];preferences=1;real_name=input\"><b>[real_name]</b></a> "
|
||||
dat += "(<a href=\"byond://?src=\ref[user];preferences=1;real_name=random\">®</A>) "
|
||||
dat += "(® = <a href=\"byond://?src=\ref[user];preferences=1;b_random_name=1\">[src.be_random_name ? "Yes" : "No"]</a>)"
|
||||
dat += "(® = <a href=\"byond://?src=\ref[user];preferences=1;b_random_name=1\">[be_random_name ? "Yes" : "No"]</a>)"
|
||||
dat += "<br>"
|
||||
|
||||
dat += "<b>Gender:</b> <a href=\"byond://?src=\ref[user];preferences=1;gender=input\"><b>[src.gender == MALE ? "Male" : "Female"]</b></a><br>"
|
||||
dat += "<b>Age:</b> <a href='byond://?src=\ref[user];preferences=1;age=input'>[src.age]</a>"
|
||||
dat += "<b>Gender:</b> <a href=\"byond://?src=\ref[user];preferences=1;gender=input\"><b>[gender == MALE ? "Male" : "Female"]</b></a><br>"
|
||||
dat += "<b>Age:</b> <a href='byond://?src=\ref[user];preferences=1;age=input'>[age]</a>"
|
||||
|
||||
dat += "<br>"
|
||||
dat += "<b>UI Style:</b> <a href=\"byond://?src=\ref[user];preferences=1;UI=input\"><b>[src.UI == 'screen1.dmi' ? "New" : "Old"]</b></a><br>"
|
||||
dat += "<b>Play admin midis:</b> <a href=\"byond://?src=\ref[user];preferences=1;midis=input\"><b>[src.midis == 1 ? "Yes" : "No"]</b></a><br>"
|
||||
dat += "<b>UI Style:</b> <a href=\"byond://?src=\ref[user];preferences=1;UI=input\"><b>[UI == 'screen1.dmi' ? "New" : "Old"]</b></a><br>"
|
||||
dat += "<b>Play admin midis:</b> <a href=\"byond://?src=\ref[user];preferences=1;midis=input\"><b>[midis == 1 ? "Yes" : "No"]</b></a><br>"
|
||||
|
||||
if(user.client.holder)
|
||||
if(user.client.holder.rank)
|
||||
@@ -299,23 +371,23 @@ datum/preferences
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;ooccolor=input'>Change colour</a> <font face=\"fixedsys\" size=\"3\" color=\"[ooccolor]\"><table bgcolor=\"[ooccolor]\"><tr><td>IM</td></tr></table></font>"
|
||||
|
||||
dat += "<hr><b>Occupation Choices</b><br>"
|
||||
if (destructive.Find(src.occupation1))
|
||||
if (destructive.Find(occupation1))
|
||||
dat += "\t<a href=\"byond://?src=\ref[user];preferences=1;occ=1\"><b>[occupation1]</b></a><br>"
|
||||
else
|
||||
if (jobban_isbanned(user, src.occupation1))
|
||||
src.occupation1 = "Assistant"
|
||||
if (jobban_isbanned(user, src.occupation2))
|
||||
src.occupation2 = "Assistant"
|
||||
if (jobban_isbanned(user, src.occupation3))
|
||||
src.occupation3 = "Assistant"
|
||||
if (src.occupation1 != "No Preference")
|
||||
if (jobban_isbanned(user, occupation1))
|
||||
occupation1 = "Assistant"
|
||||
if (jobban_isbanned(user, occupation2))
|
||||
occupation2 = "Assistant"
|
||||
if (jobban_isbanned(user, occupation3))
|
||||
occupation3 = "Assistant"
|
||||
if (occupation1 != "No Preference")
|
||||
dat += "\tFirst Choice: <a href=\"byond://?src=\ref[user];preferences=1;occ=1\"><b>[occupation1]</b></a><br>"
|
||||
|
||||
if (destructive.Find(src.occupation2))
|
||||
if (destructive.Find(occupation2))
|
||||
dat += "\tSecond Choice: <a href=\"byond://?src=\ref[user];preferences=1;occ=2\"><b>[occupation2]</b></a><BR>"
|
||||
|
||||
else
|
||||
if (src.occupation2 != "No Preference")
|
||||
if (occupation2 != "No Preference")
|
||||
dat += "\tSecond Choice: <a href=\"byond://?src=\ref[user];preferences=1;occ=2\"><b>[occupation2]</b></a><BR>"
|
||||
dat += "\tLast Choice: <a href=\"byond://?src=\ref[user];preferences=1;occ=3\"><b>[occupation3]</b></a><BR>"
|
||||
|
||||
@@ -327,47 +399,47 @@ datum/preferences
|
||||
dat += "<hr><table><tr><td><b>Body</b> "
|
||||
dat += "(<a href=\"byond://?src=\ref[user];preferences=1;s_tone=random;underwear=random;age=random;b_type=random;hair=random;h_style=random;facial=random;f_style=random;eyes=random\">®</A>)" // Random look
|
||||
dat += "<br>"
|
||||
dat += "Blood Type: <a href='byond://?src=\ref[user];preferences=1;b_type=input'>[src.b_type]</a><br>"
|
||||
dat += "Skin Tone: <a href='byond://?src=\ref[user];preferences=1;s_tone=input'>[-src.s_tone + 35]/220<br></a>"
|
||||
dat += "Blood Type: <a href='byond://?src=\ref[user];preferences=1;b_type=input'>[b_type]</a><br>"
|
||||
dat += "Skin Tone: <a href='byond://?src=\ref[user];preferences=1;s_tone=input'>[-s_tone + 35]/220<br></a>"
|
||||
|
||||
if (!IsGuestKey(user.key))
|
||||
dat += "Underwear: <a href =\"byond://?src=\ref[user];preferences=1;underwear=1\"><b>[src.underwear == 1 ? "Yes" : "No"]</b></a><br>"
|
||||
dat += "Underwear: <a href =\"byond://?src=\ref[user];preferences=1;underwear=1\"><b>[underwear == 1 ? "Yes" : "No"]</b></a><br>"
|
||||
dat += "</td><td><b>Preview</b><br><img src=previewicon.png height=64 width=64></td></tr></table>"
|
||||
|
||||
dat += "<hr><b>Hair</b><br>"
|
||||
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;hair=input'>Change Color</a> <font face=\"fixedsys\" size=\"3\" color=\"#[num2hex(src.r_hair, 2)][num2hex(src.g_hair, 2)][num2hex(src.b_hair, 2)]\"><table bgcolor=\"#[num2hex(src.r_hair, 2)][num2hex(src.g_hair, 2)][num2hex(src.b_hair)]\"><tr><td>IM</td></tr></table></font>"
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;hair=input'>Change Color</a> <font face=\"fixedsys\" size=\"3\" color=\"#[num2hex(r_hair, 2)][num2hex(g_hair, 2)][num2hex(b_hair, 2)]\"><table bgcolor=\"#[num2hex(r_hair, 2)][num2hex(g_hair, 2)][num2hex(b_hair)]\"><tr><td>IM</td></tr></table></font>"
|
||||
/*
|
||||
dat += " <font color=\"#[num2hex(src.r_hair, 2)]0000\">Red</font> - <a href='byond://?src=\ref[user];preferences=1;r_hair=input'>[src.r_hair]</a>"
|
||||
dat += " <font color=\"#00[num2hex(src.g_hair, 2)]00\">Green</font> - <a href='byond://?src=\ref[user];preferences=1;g_hair=input'>[src.g_hair]</a>"
|
||||
dat += " <font color=\"#0000[num2hex(src.b_hair, 2)]\">Blue</font> - <a href='byond://?src=\ref[user];preferences=1;b_hair=input'>[src.b_hair]</a><br>"
|
||||
dat += " <font color=\"#[num2hex(r_hair, 2)]0000\">Red</font> - <a href='byond://?src=\ref[user];preferences=1;r_hair=input'>[r_hair]</a>"
|
||||
dat += " <font color=\"#00[num2hex(g_hair, 2)]00\">Green</font> - <a href='byond://?src=\ref[user];preferences=1;g_hair=input'>[g_hair]</a>"
|
||||
dat += " <font color=\"#0000[num2hex(b_hair, 2)]\">Blue</font> - <a href='byond://?src=\ref[user];preferences=1;b_hair=input'>[b_hair]</a><br>"
|
||||
*/
|
||||
dat += "Style: <a href='byond://?src=\ref[user];preferences=1;h_style=input'>[src.h_style]</a>"
|
||||
dat += "Style: <a href='byond://?src=\ref[user];preferences=1;h_style=input'>[h_style]</a>"
|
||||
|
||||
dat += "<hr><b>Facial</b><br>"
|
||||
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;facial=input'>Change Color</a> <font face=\"fixedsys\" size=\"3\" color=\"#[num2hex(src.r_facial, 2)][num2hex(src.g_facial, 2)][num2hex(src.b_facial, 2)]\"><table bgcolor=\"#[num2hex(src.r_facial, 2)][num2hex(src.g_facial, 2)][num2hex(src.b_facial)]\"><tr><td>GO</td></tr></table></font>"
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;facial=input'>Change Color</a> <font face=\"fixedsys\" size=\"3\" color=\"#[num2hex(r_facial, 2)][num2hex(g_facial, 2)][num2hex(b_facial, 2)]\"><table bgcolor=\"#[num2hex(r_facial, 2)][num2hex(g_facial, 2)][num2hex(b_facial)]\"><tr><td>GO</td></tr></table></font>"
|
||||
/*
|
||||
dat += " <font color=\"#[num2hex(src.r_facial, 2)]0000\">Red</font> - <a href='byond://?src=\ref[user];preferences=1;r_facial=input'>[src.r_facial]</a>"
|
||||
dat += " <font color=\"#00[num2hex(src.g_facial, 2)]00\">Green</font> - <a href='byond://?src=\ref[user];preferences=1;g_facial=input'>[src.g_facial]</a>"
|
||||
dat += " <font color=\"#0000[num2hex(src.b_facial, 2)]\">Blue</font> - <a href='byond://?src=\ref[user];preferences=1;b_facial=input'>[src.b_facial]</a><br>"
|
||||
dat += " <font color=\"#[num2hex(r_facial, 2)]0000\">Red</font> - <a href='byond://?src=\ref[user];preferences=1;r_facial=input'>[r_facial]</a>"
|
||||
dat += " <font color=\"#00[num2hex(g_facial, 2)]00\">Green</font> - <a href='byond://?src=\ref[user];preferences=1;g_facial=input'>[g_facial]</a>"
|
||||
dat += " <font color=\"#0000[num2hex(b_facial, 2)]\">Blue</font> - <a href='byond://?src=\ref[user];preferences=1;b_facial=input'>[b_facial]</a><br>"
|
||||
*/
|
||||
dat += "Style: <a href='byond://?src=\ref[user];preferences=1;f_style=input'>[src.f_style]</a>"
|
||||
dat += "Style: <a href='byond://?src=\ref[user];preferences=1;f_style=input'>[f_style]</a>"
|
||||
|
||||
dat += "<hr><b>Eyes</b><br>"
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;eyes=input'>Change Color</a> <font face=\"fixedsys\" size=\"3\" color=\"#[num2hex(src.r_eyes, 2)][num2hex(src.g_eyes, 2)][num2hex(src.b_eyes, 2)]\"><table bgcolor=\"#[num2hex(src.r_eyes, 2)][num2hex(src.g_eyes, 2)][num2hex(src.b_eyes)]\"><tr><td>KU</td></tr></table></font>"
|
||||
dat += "<a href='byond://?src=\ref[user];preferences=1;eyes=input'>Change Color</a> <font face=\"fixedsys\" size=\"3\" color=\"#[num2hex(r_eyes, 2)][num2hex(g_eyes, 2)][num2hex(b_eyes, 2)]\"><table bgcolor=\"#[num2hex(r_eyes, 2)][num2hex(g_eyes, 2)][num2hex(b_eyes)]\"><tr><td>KU</td></tr></table></font>"
|
||||
/*
|
||||
dat += " <font color=\"#[num2hex(src.r_eyes, 2)]0000\">Red</font> - <a href='byond://?src=\ref[user];preferences=1;r_eyes=input'>[src.r_eyes]</a>"
|
||||
dat += " <font color=\"#00[num2hex(src.g_eyes, 2)]00\">Green</font> - <a href='byond://?src=\ref[user];preferences=1;g_eyes=input'>[src.g_eyes]</a>"
|
||||
dat += " <font color=\"#0000[num2hex(src.b_eyes, 2)]\">Blue</font> - <a href='byond://?src=\ref[user];preferences=1;b_eyes=input'>[src.b_eyes]</a>"
|
||||
dat += " <font color=\"#[num2hex(r_eyes, 2)]0000\">Red</font> - <a href='byond://?src=\ref[user];preferences=1;r_eyes=input'>[r_eyes]</a>"
|
||||
dat += " <font color=\"#00[num2hex(g_eyes, 2)]00\">Green</font> - <a href='byond://?src=\ref[user];preferences=1;g_eyes=input'>[g_eyes]</a>"
|
||||
dat += " <font color=\"#0000[num2hex(b_eyes, 2)]\">Blue</font> - <a href='byond://?src=\ref[user];preferences=1;b_eyes=input'>[b_eyes]</a>"
|
||||
*/
|
||||
dat += "<hr>"
|
||||
dat += "<b>Be alien candidate:</b> <a href=\"byond://?src=\ref[user];preferences=1;be_alien=input\"><b>[src.be_alien == 1 ? "Yes" : "No"]</b></a><br>"
|
||||
dat += "<b>Be alien candidate:</b> <a href=\"byond://?src=\ref[user];preferences=1;be_alien=input\"><b>[be_alien == 1 ? "Yes" : "No"]</b></a><br>"
|
||||
if(!jobban_isbanned(user, "Syndicate"))
|
||||
dat += "<b>Be syndicate?:</b> <a href =\"byond://?src=\ref[user];preferences=1;b_syndicate=1\"><b>[(src.be_syndicate ? "Yes" : "No")]</b></a><br>"
|
||||
dat += "<b>Be syndicate?:</b> <a href =\"byond://?src=\ref[user];preferences=1;b_syndicate=1\"><b>[(be_syndicate ? "Yes" : "No")]</b></a><br>"
|
||||
else
|
||||
dat += "<b> You are banned from being syndicate.</b>"
|
||||
src.be_syndicate = 0
|
||||
be_syndicate = 0
|
||||
dat += "<hr>"
|
||||
|
||||
if (!IsGuestKey(user.key))
|
||||
@@ -420,70 +492,70 @@ datum/preferences
|
||||
return
|
||||
else
|
||||
if (job == "No Preference")
|
||||
src.occupation1 = "No Preference"
|
||||
occupation1 = "No Preference"
|
||||
else
|
||||
if (job == src.occupation2)
|
||||
job = src.occupation1
|
||||
src.occupation1 = src.occupation2
|
||||
src.occupation2 = job
|
||||
if (job == occupation2)
|
||||
job = occupation1
|
||||
occupation1 = occupation2
|
||||
occupation2 = job
|
||||
else
|
||||
if (job == src.occupation3)
|
||||
job = src.occupation1
|
||||
src.occupation1 = src.occupation3
|
||||
src.occupation3 = job
|
||||
if (job == occupation3)
|
||||
job = occupation1
|
||||
occupation1 = occupation3
|
||||
occupation3 = job
|
||||
else
|
||||
src.occupation1 = job
|
||||
occupation1 = job
|
||||
if(2.0)
|
||||
if (job == src.occupation2)
|
||||
if (job == occupation2)
|
||||
user << browse(null, "window=mob_occupation")
|
||||
return
|
||||
else
|
||||
if (job == "No Preference")
|
||||
if (src.occupation3 != "No Preference")
|
||||
src.occupation2 = src.occupation3
|
||||
src.occupation3 = "No Preference"
|
||||
if (occupation3 != "No Preference")
|
||||
occupation2 = occupation3
|
||||
occupation3 = "No Preference"
|
||||
else
|
||||
src.occupation2 = "No Preference"
|
||||
occupation2 = "No Preference"
|
||||
else
|
||||
if (job == src.occupation1)
|
||||
if (src.occupation2 == "No Preference")
|
||||
if (job == occupation1)
|
||||
if (occupation2 == "No Preference")
|
||||
user << browse(null, "window=mob_occupation")
|
||||
return
|
||||
job = src.occupation2
|
||||
src.occupation2 = src.occupation1
|
||||
src.occupation1 = job
|
||||
job = occupation2
|
||||
occupation2 = occupation1
|
||||
occupation1 = job
|
||||
else
|
||||
if (job == src.occupation3)
|
||||
job = src.occupation2
|
||||
src.occupation2 = src.occupation3
|
||||
src.occupation3 = job
|
||||
if (job == occupation3)
|
||||
job = occupation2
|
||||
occupation2 = occupation3
|
||||
occupation3 = job
|
||||
else
|
||||
src.occupation2 = job
|
||||
occupation2 = job
|
||||
if(3.0)
|
||||
if (job == src.occupation3)
|
||||
if (job == occupation3)
|
||||
user << browse(null, "window=mob_occupation")
|
||||
return
|
||||
else
|
||||
if (job == "No Preference")
|
||||
src.occupation3 = "No Preference"
|
||||
occupation3 = "No Preference"
|
||||
else
|
||||
if (job == src.occupation1)
|
||||
if (src.occupation3 == "No Preference")
|
||||
if (job == occupation1)
|
||||
if (occupation3 == "No Preference")
|
||||
user << browse(null, "window=mob_occupation")
|
||||
return
|
||||
job = src.occupation3
|
||||
src.occupation3 = src.occupation1
|
||||
src.occupation1 = job
|
||||
job = occupation3
|
||||
occupation3 = occupation1
|
||||
occupation1 = job
|
||||
else
|
||||
if (job == src.occupation2)
|
||||
if (src.occupation3 == "No Preference")
|
||||
if (job == occupation2)
|
||||
if (occupation3 == "No Preference")
|
||||
user << browse(null, "window=mob_occupation")
|
||||
return
|
||||
job = src.occupation3
|
||||
src.occupation3 = src.occupation2
|
||||
src.occupation2 = job
|
||||
job = occupation3
|
||||
occupation3 = occupation2
|
||||
occupation2 = job
|
||||
else
|
||||
src.occupation3 = job
|
||||
occupation3 = job
|
||||
|
||||
user << browse(null, "window=mob_occupation")
|
||||
ShowChoices(user)
|
||||
@@ -497,9 +569,9 @@ datum/preferences
|
||||
user << browse(null, "window=\ref[user]occupation")
|
||||
return
|
||||
else if(link_tags["job"])
|
||||
src.SetJob(user, text2num(link_tags["occ"]), link_tags["job"])
|
||||
SetJob(user, text2num(link_tags["occ"]), link_tags["job"])
|
||||
else
|
||||
src.SetChoices(user, text2num(link_tags["occ"]))
|
||||
SetChoices(user, text2num(link_tags["occ"]))
|
||||
|
||||
return 1
|
||||
|
||||
@@ -517,30 +589,30 @@ datum/preferences
|
||||
return
|
||||
|
||||
if("random")
|
||||
src.randomize_name()
|
||||
randomize_name()
|
||||
|
||||
if(new_name)
|
||||
if(length(new_name) >= 26)
|
||||
new_name = copytext(new_name, 1, 26)
|
||||
src.real_name = new_name
|
||||
real_name = new_name
|
||||
|
||||
if (link_tags["age"])
|
||||
switch(link_tags["age"])
|
||||
if ("input")
|
||||
var/new_age = input(user, "Please select type in age: 20-45", "Character Generation") as num
|
||||
if(new_age)
|
||||
src.age = max(min(round(text2num(new_age)), 45), 20)
|
||||
age = max(min(round(text2num(new_age)), 45), 20)
|
||||
if ("random")
|
||||
src.age = rand (20, 45)
|
||||
age = rand (20, 45)
|
||||
|
||||
if (link_tags["b_type"])
|
||||
switch(link_tags["b_type"])
|
||||
if ("input")
|
||||
var/new_b_type = input(user, "Please select a blood type:", "Character Generation") as null|anything in list( "A+", "A-", "B+", "B-", "AB+", "AB-", "O+", "O-" )
|
||||
if (new_b_type)
|
||||
src.b_type = new_b_type
|
||||
b_type = new_b_type
|
||||
if ("random")
|
||||
src.b_type = pickweight ( list ("A+" = 31, "A-" = 7, "B+" = 8, "B-" = 2, "AB+" = 2, "AB-" = 1, "O+" = 40, "O-" = 9))
|
||||
b_type = pickweight ( list ("A+" = 31, "A-" = 7, "B+" = 8, "B-" = 2, "AB+" = 2, "AB-" = 1, "O+" = 40, "O-" = 9))
|
||||
|
||||
|
||||
if (link_tags["hair"])
|
||||
@@ -548,9 +620,9 @@ datum/preferences
|
||||
if ("input")
|
||||
var/new_hair = input(user, "Please select hair color.", "Character Generation") as color
|
||||
if(new_hair)
|
||||
src.r_hair = hex2num(copytext(new_hair, 2, 4))
|
||||
src.g_hair = hex2num(copytext(new_hair, 4, 6))
|
||||
src.b_hair = hex2num(copytext(new_hair, 6, 8))
|
||||
r_hair = hex2num(copytext(new_hair, 2, 4))
|
||||
g_hair = hex2num(copytext(new_hair, 4, 6))
|
||||
b_hair = hex2num(copytext(new_hair, 6, 8))
|
||||
if ("random")
|
||||
randomize_hair_color("hair")
|
||||
|
||||
@@ -559,19 +631,19 @@ datum/preferences
|
||||
var/new_component = input(user, "Please select red hair component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.r_hair = max(min(round(text2num(new_component)), 255), 1)
|
||||
r_hair = max(min(round(text2num(new_component)), 255), 1)
|
||||
|
||||
if (link_tags["g_hair"])
|
||||
var/new_component = input(user, "Please select green hair component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.g_hair = max(min(round(text2num(new_component)), 255), 1)
|
||||
g_hair = max(min(round(text2num(new_component)), 255), 1)
|
||||
|
||||
if (link_tags["b_hair"])
|
||||
var/new_component = input(user, "Please select blue hair component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.b_hair = max(min(round(text2num(new_component)), 255), 1)
|
||||
b_hair = max(min(round(text2num(new_component)), 255), 1)
|
||||
*/
|
||||
|
||||
if (link_tags["facial"])
|
||||
@@ -579,9 +651,9 @@ datum/preferences
|
||||
if ("input")
|
||||
var/new_facial = input(user, "Please select facial hair color.", "Character Generation") as color
|
||||
if(new_facial)
|
||||
src.r_facial = hex2num(copytext(new_facial, 2, 4))
|
||||
src.g_facial = hex2num(copytext(new_facial, 4, 6))
|
||||
src.b_facial = hex2num(copytext(new_facial, 6, 8))
|
||||
r_facial = hex2num(copytext(new_facial, 2, 4))
|
||||
g_facial = hex2num(copytext(new_facial, 4, 6))
|
||||
b_facial = hex2num(copytext(new_facial, 6, 8))
|
||||
if ("random")
|
||||
randomize_hair_color("facial")
|
||||
|
||||
@@ -590,28 +662,28 @@ datum/preferences
|
||||
var/new_component = input(user, "Please select red facial component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.r_facial = max(min(round(text2num(new_component)), 255), 1)
|
||||
r_facial = max(min(round(text2num(new_component)), 255), 1)
|
||||
|
||||
if (link_tags["g_facial"])
|
||||
var/new_component = input(user, "Please select green facial component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.g_facial = max(min(round(text2num(new_component)), 255), 1)
|
||||
g_facial = max(min(round(text2num(new_component)), 255), 1)
|
||||
|
||||
if (link_tags["b_facial"])
|
||||
var/new_component = input(user, "Please select blue facial component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.b_facial = max(min(round(text2num(new_component)), 255), 1)
|
||||
b_facial = max(min(round(text2num(new_component)), 255), 1)
|
||||
*/
|
||||
if (link_tags["eyes"])
|
||||
switch(link_tags["eyes"])
|
||||
if ("input")
|
||||
var/new_eyes = input(user, "Please select eye color.", "Character Generation") as color
|
||||
if(new_eyes)
|
||||
src.r_eyes = hex2num(copytext(new_eyes, 2, 4))
|
||||
src.g_eyes = hex2num(copytext(new_eyes, 4, 6))
|
||||
src.b_eyes = hex2num(copytext(new_eyes, 6, 8))
|
||||
r_eyes = hex2num(copytext(new_eyes, 2, 4))
|
||||
g_eyes = hex2num(copytext(new_eyes, 4, 6))
|
||||
b_eyes = hex2num(copytext(new_eyes, 6, 8))
|
||||
if ("random")
|
||||
randomize_eyes_color()
|
||||
|
||||
@@ -620,19 +692,19 @@ datum/preferences
|
||||
var/new_component = input(user, "Please select red eyes component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.r_eyes = max(min(round(text2num(new_component)), 255), 1)
|
||||
r_eyes = max(min(round(text2num(new_component)), 255), 1)
|
||||
|
||||
if (link_tags["g_eyes"])
|
||||
var/new_component = input(user, "Please select green eyes component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.g_eyes = max(min(round(text2num(new_component)), 255), 1)
|
||||
g_eyes = max(min(round(text2num(new_component)), 255), 1)
|
||||
|
||||
if (link_tags["b_eyes"])
|
||||
var/new_component = input(user, "Please select blue eyes component: 1-255", "Character Generation") as text
|
||||
|
||||
if (new_component)
|
||||
src.b_eyes = max(min(round(text2num(new_component)), 255), 1)
|
||||
b_eyes = max(min(round(text2num(new_component)), 255), 1)
|
||||
*/
|
||||
if (link_tags["s_tone"])
|
||||
switch(link_tags["s_tone"])
|
||||
@@ -641,84 +713,84 @@ datum/preferences
|
||||
if("input")
|
||||
var/new_tone = input(user, "Please select skin tone level: 1-220 (1=albino, 35=caucasian, 150=black, 220='very' black)", "Character Generation") as text
|
||||
if (new_tone)
|
||||
src.s_tone = max(min(round(text2num(new_tone)), 220), 1)
|
||||
src.s_tone = -src.s_tone + 35
|
||||
s_tone = max(min(round(text2num(new_tone)), 220), 1)
|
||||
s_tone = -s_tone + 35
|
||||
|
||||
if (link_tags["h_style"])
|
||||
switch(link_tags["h_style"])
|
||||
if ("random")
|
||||
if (src.gender == FEMALE)
|
||||
src.h_style = pickweight ( list ("Cut Hair" = 5, "Short Hair" = 5, "Long Hair" = 5, "Mohawk" = 5, "Balding" = 1, "Fag" = 5, "Bedhead" = 5, "Dreadlocks" = 5, "Bald" = 5))
|
||||
if (gender == FEMALE)
|
||||
h_style = pickweight ( list ("Cut Hair" = 5, "Short Hair" = 5, "Long Hair" = 5, "Mohawk" = 5, "Balding" = 1, "Fag" = 5, "Bedhead" = 5, "Dreadlocks" = 5, "Bald" = 5))
|
||||
else
|
||||
src.h_style = pickweight ( list ("Cut Hair" = 5, "Short Hair" = 5, "Long Hair" = 5, "Mohawk" = 5, "Balding" = 5, "Fag" = 5, "Bedhead" = 5, "Dreadlocks" = 5, "Bald" = 5))
|
||||
h_style = pickweight ( list ("Cut Hair" = 5, "Short Hair" = 5, "Long Hair" = 5, "Mohawk" = 5, "Balding" = 5, "Fag" = 5, "Bedhead" = 5, "Dreadlocks" = 5, "Bald" = 5))
|
||||
|
||||
if("input")
|
||||
var/new_style = input(user, "Please select hair style", "Character Generation") as null|anything in list( "Cut Hair", "Short Hair", "Long Hair", "Mohawk", "Balding", "Fag", "Bedhead", "Dreadlocks", "Bald" )
|
||||
if (new_style)
|
||||
src.h_style = new_style
|
||||
h_style = new_style
|
||||
|
||||
if (link_tags["ooccolor"])
|
||||
var/ooccolor = input(user, "Please select OOC colour.", "OOC colour") as color
|
||||
|
||||
if(ooccolor)
|
||||
src.ooccolor = ooccolor
|
||||
ooccolor = ooccolor
|
||||
|
||||
if (link_tags["f_style"])
|
||||
switch(link_tags["f_style"])
|
||||
if ("random")
|
||||
if (src.gender == FEMALE)
|
||||
src.f_style = pickweight ( list("Watson" = 1, "Chaplin" = 1, "Selleck" = 1, "Full Beard" = 1, "Long Beard" = 1, "Neckbeard" = 1, "Van Dyke" = 1, "Elvis" = 1, "Abe" = 1, "Chinstrap" = 1, "Hipster" = 1, "Goatee" = 1, "Hogan" = 1, "Shaved" = 100))
|
||||
if (gender == FEMALE)
|
||||
f_style = pickweight ( list("Watson" = 1, "Chaplin" = 1, "Selleck" = 1, "Full Beard" = 1, "Long Beard" = 1, "Neckbeard" = 1, "Van Dyke" = 1, "Elvis" = 1, "Abe" = 1, "Chinstrap" = 1, "Hipster" = 1, "Goatee" = 1, "Hogan" = 1, "Shaved" = 100))
|
||||
else
|
||||
src.f_style = pickweight ( list("Watson" = 1, "Chaplin" = 1, "Selleck" = 1, "Full Beard" = 1, "Long Beard" = 1, "Neckbeard" = 1, "Van Dyke" = 1, "Elvis" = 1, "Abe" = 1, "Chinstrap" = 1, "Hipster" = 1, "Goatee" = 1, "Hogan" = 1, "Shaved" = 10))
|
||||
f_style = pickweight ( list("Watson" = 1, "Chaplin" = 1, "Selleck" = 1, "Full Beard" = 1, "Long Beard" = 1, "Neckbeard" = 1, "Van Dyke" = 1, "Elvis" = 1, "Abe" = 1, "Chinstrap" = 1, "Hipster" = 1, "Goatee" = 1, "Hogan" = 1, "Shaved" = 10))
|
||||
if("input")
|
||||
var/new_style = input(user, "Please select facial style", "Character Generation") as null|anything in list("Watson", "Chaplin", "Selleck", "Full Beard", "Long Beard", "Neckbeard", "Van Dyke", "Elvis", "Abe", "Chinstrap", "Hipster", "Goatee", "Hogan", "Shaved")
|
||||
if (new_style)
|
||||
src.f_style = new_style
|
||||
f_style = new_style
|
||||
|
||||
if (link_tags["gender"])
|
||||
if (src.gender == MALE)
|
||||
src.gender = FEMALE
|
||||
if (gender == MALE)
|
||||
gender = FEMALE
|
||||
else
|
||||
src.gender = MALE
|
||||
gender = MALE
|
||||
|
||||
if (link_tags["UI"])
|
||||
if (src.UI == 'screen1.dmi')
|
||||
src.UI = 'screen1_old.dmi'
|
||||
if (UI == 'screen1.dmi')
|
||||
UI = 'screen1_old.dmi'
|
||||
else
|
||||
src.UI = 'screen1.dmi'
|
||||
UI = 'screen1.dmi'
|
||||
|
||||
if (link_tags["midis"])
|
||||
src.midis = (src.midis+1)%2
|
||||
midis = (midis+1)%2
|
||||
|
||||
if (link_tags["be_alien"])
|
||||
src.be_alien = (src.be_alien+1)%2
|
||||
be_alien = (be_alien+1)%2
|
||||
|
||||
if (link_tags["underwear"])
|
||||
if(!IsGuestKey(user.key))
|
||||
switch(link_tags["underwear"])
|
||||
if ("random")
|
||||
if (prob (75))
|
||||
src.underwear = 1
|
||||
underwear = 1
|
||||
else
|
||||
src.underwear = 0
|
||||
underwear = 0
|
||||
if("input")
|
||||
if (src.underwear == 1)
|
||||
src.underwear = 0
|
||||
if (underwear == 1)
|
||||
underwear = 0
|
||||
else
|
||||
src.underwear = 1
|
||||
underwear = 1
|
||||
|
||||
if (link_tags["b_syndicate"])
|
||||
src.be_syndicate = !( src.be_syndicate )
|
||||
be_syndicate = !( be_syndicate )
|
||||
|
||||
if (link_tags["b_random_name"])
|
||||
src.be_random_name = !src.be_random_name
|
||||
be_random_name = !be_random_name
|
||||
|
||||
if(!IsGuestKey(user.key))
|
||||
if(link_tags["save"])
|
||||
src.savefile_save(user)
|
||||
savefile_save(user)
|
||||
|
||||
else if(link_tags["load"])
|
||||
if (!src.savefile_load(user, 0))
|
||||
if (!savefile_load(user, 0))
|
||||
alert(user, "You do not have a savefile.")
|
||||
|
||||
if (link_tags["reset_all"])
|
||||
@@ -749,7 +821,7 @@ datum/preferences
|
||||
midis = 1
|
||||
|
||||
|
||||
src.ShowChoices(user)
|
||||
ShowChoices(user)
|
||||
|
||||
proc/copy_to(mob/living/carbon/human/character)
|
||||
if(be_random_name)
|
||||
|
||||
Reference in New Issue
Block a user