mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-28 06:27:26 +01:00
Sight update to strike team admin proc. It should pick people as intended now. Can't really test it locally so who knows.
Admins can again spawn everyone as ninjas, including themselves. Inactive player checking is still there though. A slightly updated stealth graphic for ninjas. Fixed a lawsync() run time error. Fixed station_explosion_cinematic() run time error. Fixed copy_to() run time error. Fixed dnainjector/attack() run time error. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@1667 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -47,7 +47,7 @@ ________________________________________________________________________________
|
||||
xenos, death squads, and cyborgs. Ninjas are not admin PCs--please do not use them for that purpose.
|
||||
I'm currently looking for feedback from regular players since beta testing is largely done. I would appreciate if
|
||||
you spawned regular players as ninjas when rounds are boring. Or exciting, it's all good as long as there is feedback.
|
||||
Admin quick-spawning as ninjas is disabled for that reason. You can spawn ninja gear manually if you want to.
|
||||
You can also spawn ninja gear manually if you want to.
|
||||
|
||||
How to do that:
|
||||
Make sure your character has a mind.
|
||||
@@ -128,8 +128,7 @@ ________________________________________________________________________________
|
||||
var/mob/dead/observer/G
|
||||
var/list/candidates = list()
|
||||
for(G in world)
|
||||
if(G.client&&!G.client.holder)
|
||||
//if(G.client)//Good for testing.
|
||||
if(G.client)//Now everyone can ninja!
|
||||
if(((G.client.inactivity/10)/60) <= 5)
|
||||
candidates.Add(G)
|
||||
if(candidates.len)
|
||||
@@ -209,10 +208,7 @@ client/proc/create_space_ninja(obj/spawn_point)
|
||||
//This proc prevents the suit from being taken off.
|
||||
/obj/item/clothing/suit/space/space_ninja/proc/lock_suit(mob/living/carbon/U, X = 0)
|
||||
if(X)//If you want to check for icons.
|
||||
if(U.gender==FEMALE)
|
||||
icon_state = "s-ninjanf"
|
||||
else
|
||||
icon_state = "s-ninjan"
|
||||
icon_state = U.gender==FEMALE ? "s-ninjanf" : "s-ninjan"
|
||||
U:gloves.icon_state = "s-ninjan"
|
||||
U:gloves.item_state = "s-ninjan"
|
||||
else
|
||||
@@ -266,7 +262,7 @@ client/proc/create_space_ninja(obj/spawn_point)
|
||||
invisibility = 2//Set ninja invis to 2.
|
||||
var/icon/opacity_icon = new(A.icon, A.icon_state)
|
||||
var/icon/alpha_mask = getIconMask(src)
|
||||
var/icon/alpha_mask_2 = new('effects.dmi', "wave1")
|
||||
var/icon/alpha_mask_2 = new('effects.dmi', "at_shield1")
|
||||
alpha_mask.AddAlphaMask(alpha_mask_2)
|
||||
opacity_icon.AddAlphaMask(alpha_mask)
|
||||
for(var/i=0,i<5,i++)//And now we add it as overlays. It's faster than creating an icon and then merging it.
|
||||
@@ -351,10 +347,7 @@ client/proc/create_space_ninja(obj/spawn_point)
|
||||
|
||||
kamikaze = 1
|
||||
|
||||
if(U.gender==FEMALE)
|
||||
icon_state = "s-ninjakf"
|
||||
else
|
||||
icon_state = "s-ninjak"
|
||||
icon_state = U.gender==FEMALE ? "s-ninjakf" : "s-ninjak"
|
||||
if(n_gloves)
|
||||
n_gloves.icon_state = "s-ninjak"
|
||||
n_gloves.item_state = "s-ninjak"
|
||||
|
||||
@@ -124,8 +124,8 @@
|
||||
if (!istype(loc, /obj/item/device/pda))
|
||||
return
|
||||
|
||||
src.generate_menu()
|
||||
src.print_to_host(menu)
|
||||
generate_menu()
|
||||
print_to_host(menu)
|
||||
return
|
||||
|
||||
proc/print_to_host(var/text)
|
||||
@@ -169,14 +169,14 @@
|
||||
Frequency:
|
||||
<a href='byond://?src=\ref[src];choice=Signal Frequency;sfreq=-10'>-</a>
|
||||
<a href='byond://?src=\ref[src];choice=Signal Frequency;sfreq=-2'>-</a>
|
||||
[format_frequency(src.radio:frequency)]
|
||||
[format_frequency(radio:frequency)]
|
||||
<a href='byond://?src=\ref[src];choice=Signal Frequency;sfreq=2'>+</a>
|
||||
<a href='byond://?src=\ref[src];choice=Signal Frequency;sfreq=10'>+</a><br>
|
||||
<br>
|
||||
Code:
|
||||
<a href='byond://?src=\ref[src];choice=Signal Code;scode=-5'>-</a>
|
||||
<a href='byond://?src=\ref[src];choice=Signal Code;scode=-1'>-</a>
|
||||
[src.radio:code]
|
||||
[radio:code]
|
||||
<a href='byond://?src=\ref[src];choice=Signal Code;scode=1'>+</a>
|
||||
<a href='byond://?src=\ref[src];choice=Signal Code;scode=5'>+</a><br>"}
|
||||
if (41) //crew manifest
|
||||
@@ -239,7 +239,7 @@ Code:
|
||||
menu = "<h4><img src=pda_medical.png> Medical Record</h4>"
|
||||
|
||||
if (istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
menu += "Name: [active1.fields["name"]] ID: [src.active1.fields["id"]]<br>"
|
||||
menu += "Name: [active1.fields["name"]] ID: [active1.fields["id"]]<br>"
|
||||
menu += "Sex: [active1.fields["sex"]]<br>"
|
||||
menu += "Age: [active1.fields["age"]]<br>"
|
||||
menu += "Fingerprint: [active1.fields["fingerprint"]]<br>"
|
||||
@@ -251,7 +251,7 @@ Code:
|
||||
menu += "<br>"
|
||||
|
||||
menu += "<h4><img src=pda_medical.png> Medical Data</h4>"
|
||||
if (istype(src.active2, /datum/data/record) && data_core.medical.Find(src.active2))
|
||||
if (istype(active2, /datum/data/record) && data_core.medical.Find(active2))
|
||||
menu += "Blood Type: [active2.fields["b_type"]]<br><br>"
|
||||
|
||||
menu += "Minor Disabilities: [active2.fields["mi_dis"]]<br>"
|
||||
@@ -281,8 +281,8 @@ Code:
|
||||
if(451)
|
||||
menu = "<h4><img src=pda_cuffs.png> Security Record</h4>"
|
||||
|
||||
if (istype(src.active1, /datum/data/record) && data_core.general.Find(src.active1))
|
||||
menu += "Name: [active1.fields["name"]] ID: [src.active1.fields["id"]]<br>"
|
||||
if (istype(active1, /datum/data/record) && data_core.general.Find(active1))
|
||||
menu += "Name: [active1.fields["name"]] ID: [active1.fields["id"]]<br>"
|
||||
menu += "Sex: [active1.fields["sex"]]<br>"
|
||||
menu += "Age: [active1.fields["age"]]<br>"
|
||||
menu += "Fingerprint: [active1.fields["fingerprint"]]<br>"
|
||||
@@ -294,7 +294,7 @@ Code:
|
||||
menu += "<br>"
|
||||
|
||||
menu += "<h4><img src=pda_cuffs.png> Security Data</h4>"
|
||||
if (istype(src.active3, /datum/data/record) && data_core.security.Find(src.active3))
|
||||
if (istype(active3, /datum/data/record) && data_core.security.Find(active3))
|
||||
menu += "Criminal Status: [active3.fields["criminal"]]<br>"
|
||||
|
||||
menu += "Minor Crimes: [active3.fields["mi_crim"]]<br>"
|
||||
@@ -304,7 +304,7 @@ Code:
|
||||
menu += "Details: [active3.fields["ma_crim_d"]]<br><br>"
|
||||
|
||||
menu += "Important Notes:<br>"
|
||||
menu += "[src.active3.fields["notes"]]"
|
||||
menu += "[active3.fields["notes"]]"
|
||||
else
|
||||
menu += "<b>Record Lost!</b><br>"
|
||||
|
||||
@@ -529,20 +529,20 @@ Code:
|
||||
if("Send Signal")
|
||||
for(var/obj/item/assembly/r_i_ptank/R in world) //Bomblist stuff
|
||||
if((R.part1.code == src/radio:code) && (R.part1.frequency == radio:frequency))
|
||||
bombers += "[key_name(usr)] has activated a radio bomb (Freq: [format_frequency(src.radio:frequency)], Code: [src.radio:code]). Temp = [R.part3.air_contents.temperature-T0C]."
|
||||
bombers += "[key_name(usr)] has activated a radio bomb (Freq: [format_frequency(radio:frequency)], Code: [radio:code]). Temp = [R.part3.air_contents.temperature-T0C]."
|
||||
spawn( 0 )
|
||||
radio:send_signal("ACTIVATE")
|
||||
return
|
||||
|
||||
if("Signal Frequency")
|
||||
var/new_frequency = sanitize_frequency(src.radio:frequency + text2num(href_list["sfreq"]))
|
||||
var/new_frequency = sanitize_frequency(radio:frequency + text2num(href_list["sfreq"]))
|
||||
radio:set_frequency(new_frequency)
|
||||
|
||||
if("Signal Code")
|
||||
radio:code += text2num(href_list["scode"])
|
||||
radio:code = round(src.radio:code)
|
||||
radio:code = min(100, src.radio:code)
|
||||
radio:code = max(1, src.radio:code)
|
||||
radio:code = round(radio:code)
|
||||
radio:code = min(100, radio:code)
|
||||
radio:code = max(1, radio:code)
|
||||
|
||||
if("Status")
|
||||
switch(href_list["statdisp"])
|
||||
|
||||
@@ -67,7 +67,7 @@ var/global/list/cached_icons = list()
|
||||
color = "FFFFFF"
|
||||
if("black")
|
||||
color = "333333"
|
||||
src.icon_state = "paint_[t1]"
|
||||
icon_state = "paint_[t1]"
|
||||
add_fingerprint(user)
|
||||
return
|
||||
|
||||
@@ -97,7 +97,7 @@ var/global/list/cached_icons = list()
|
||||
|
||||
|
||||
/obj/item/weapon/dnainjector/attack_paw(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
return attack_hand(user)
|
||||
|
||||
|
||||
/obj/item/weapon/dnainjector/proc/inject(mob/M as mob)
|
||||
@@ -138,8 +138,8 @@ var/global/list/cached_icons = list()
|
||||
if (!(istype(usr, /mob/living/carbon/human) || ticker) && ticker.mode.name != "monkey")
|
||||
user << "\red You don't have the dexterity to do this!"
|
||||
return
|
||||
M.attack_log += text("<font color='orange'>[world.time] - has been injected with [src.name] by [user.name] ([user.ckey])</font>")
|
||||
user.attack_log += text("<font color='red'>[world.time] - has used the [src.name] to inject [M.name] ([M.ckey])</font>")
|
||||
M.attack_log += text("<font color='orange'>[world.time] - has been injected with [name] by [user.name] ([user.ckey])</font>")
|
||||
user.attack_log += text("<font color='red'>[world.time] - has used the [name] to inject [M.name] ([M.ckey])</font>")
|
||||
|
||||
if (user)
|
||||
if (istype(M, /mob/living/carbon/human))
|
||||
@@ -153,14 +153,14 @@ var/global/list/cached_icons = list()
|
||||
M.requests += O
|
||||
if (dnatype == "se")
|
||||
if (isblockon(getblock(dna, 14,3),14) && istype(M, /mob/living/carbon/human))
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [src.name] \red(MONKEY)")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [src.name] (MONKEY)")
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
||||
else
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [src.name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [src.name]")
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
else
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [src.name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [src.name]")
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
|
||||
spawn( 0 )
|
||||
O.process()
|
||||
@@ -172,16 +172,22 @@ var/global/list/cached_icons = list()
|
||||
if (!(istype(M, /mob/living/carbon/human) || istype(M, /mob/living/carbon/monkey)))
|
||||
user << "\red Apparently it didn't work."
|
||||
return
|
||||
inject(M)
|
||||
if (dnatype == "se")
|
||||
if (isblockon(getblock(dna, 14,3),14) && istype(M, /mob/living/carbon/human))
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [src.name] \red(MONKEY)")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [src.name] (MONKEY)")
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
||||
else
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [src.name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [src.name]")
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
else
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [src.name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [src.name]")
|
||||
user.show_message(text("\red You inject [M]"))
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
inject(M)//Now we actually do the heavy lifting.
|
||||
/*
|
||||
A user injecting themselves could mean their own transformation and deletion of mob.
|
||||
I don't have the time to figure out how this code works so this will do for now.
|
||||
I did rearrange things a bit.
|
||||
*/
|
||||
if(!isnull(user))//If the user still exists. Their mob may not.
|
||||
user.show_message(text("\red You inject [M]"))
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user