mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 19:44:09 +01:00
Massive traitor item overhaul
This commit is contained in:
@@ -464,10 +464,10 @@
|
||||
<BR>[(internal ? text("<A href='?src=\ref[src];item=internal'>Remove Internal</A>") : "")]
|
||||
<BR><A href='?src=\ref[src];item=pockets'>Empty Pockets</A>
|
||||
<BR><A href='?src=\ref[user];refresh=1'>Refresh</A>
|
||||
<BR><A href='?src=\ref[user];mach_close=mob[name]'>Close</A>
|
||||
<BR><A href='?src=\ref[user];mach_close=mob\ref[src]'>Close</A>
|
||||
<BR>"}
|
||||
user << browse(dat, text("window=mob[];size=325x500", name))
|
||||
onclose(user, "mob[name]")
|
||||
user << browse(dat, text("window=mob\ref[src];size=325x500"))
|
||||
onclose(user, "mob\ref[src]")
|
||||
return
|
||||
|
||||
//generates realistic-ish pulse output based on preset levels
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
#define STRIP_DELAY 40 //time taken (in deciseconds) to strip somebody
|
||||
/mob/living/carbon/human
|
||||
name = "unknown"
|
||||
real_name = "unknown"
|
||||
@@ -388,7 +389,11 @@
|
||||
|
||||
|
||||
/mob/living/carbon/human/show_inv(mob/user as mob)
|
||||
|
||||
var/obj/item/clothing/gloves/G
|
||||
var/pickpocket = 0
|
||||
if(user:gloves)
|
||||
G = user:gloves
|
||||
pickpocket = G.pickpocket
|
||||
user.set_machine(src)
|
||||
var/dat = {"
|
||||
<B><HR><FONT size=3>[name]</FONT></B>
|
||||
@@ -411,12 +416,13 @@
|
||||
<BR>[(legcuffed ? text("<A href='?src=\ref[src];item=legcuff'>Legcuffed</A>") : text(""))]
|
||||
<BR>[(internal ? text("<A href='?src=\ref[src];item=internal'>Remove Internal</A>") : "")]
|
||||
<BR><A href='?src=\ref[src];item=splints'>Remove Splints</A>
|
||||
<BR><A href='?src=\ref[src];item=pockets'>Empty Pockets</A>
|
||||
<BR><BR><A href='?src=\ref[src];pockets=left'>Left Pocket ([l_store ? (pickpocket ? l_store.name : "Full") : "Empty"])</A>
|
||||
<BR><A href='?src=\ref[src];pockets=right'>Right Pocket ([r_store ? (pickpocket ? r_store.name : "Full") : "Empty"])</A>
|
||||
<BR><A href='?src=\ref[user];refresh=1'>Refresh</A>
|
||||
<BR><A href='?src=\ref[user];mach_close=mob[name]'>Close</A>
|
||||
<BR><A href='?src=\ref[user];mach_close=mob\ref[src]'>Close</A>
|
||||
<BR>"}
|
||||
user << browse(dat, text("window=mob[name];size=340x480"))
|
||||
onclose(user, "mob[name]")
|
||||
user << browse(dat, text("window=mob\ref[src];size=340x480"))
|
||||
onclose(user, "mob\ref[src]")
|
||||
return
|
||||
|
||||
// called when something steps onto a human
|
||||
@@ -511,6 +517,43 @@
|
||||
|
||||
|
||||
/mob/living/carbon/human/Topic(href, href_list)
|
||||
var/pickpocket = 0
|
||||
if(!usr.stat && usr.canmove && !usr.restrained() && in_range(src, usr))
|
||||
if(href_list["pockets"])
|
||||
if(usr:gloves)
|
||||
var/obj/item/clothing/gloves/G = usr:gloves
|
||||
pickpocket = G.pickpocket
|
||||
var/pocket_side = href_list["pockets"]
|
||||
var/pocket_id = (pocket_side == "right" ? slot_r_store : slot_l_store)
|
||||
var/obj/item/pocket_item = (pocket_id == slot_r_store ? src.r_store : src.l_store)
|
||||
var/obj/item/place_item = usr.get_active_hand() // Item to place in the pocket, if it's empty
|
||||
|
||||
if(pocket_item)
|
||||
usr << "<span class='notice'>You try to empty [src]'s [pocket_side] pocket.</span>"
|
||||
else if(place_item && place_item.mob_can_equip(src, pocket_id, 1))
|
||||
usr << "<span class='notice'>You try to place [place_item] into [src]'s [pocket_side] pocket.</span>"
|
||||
else
|
||||
return
|
||||
|
||||
if(do_mob(usr, src, STRIP_DELAY))
|
||||
if(pocket_item)
|
||||
u_equip(pocket_item)
|
||||
if(pickpocket) usr.put_in_hands(pocket_item)
|
||||
else
|
||||
if(place_item)
|
||||
usr.u_equip(place_item)
|
||||
equip_to_slot_if_possible(place_item, pocket_id, 0, 1)
|
||||
|
||||
// Update strip window
|
||||
if(usr.machine == src && in_range(src, usr))
|
||||
show_inv(usr)
|
||||
|
||||
|
||||
|
||||
else if(!pickpocket)
|
||||
// Display a warning if the user mocks up
|
||||
src << "<span class='warning'>You feel your [pocket_side] pocket being fumbled with!</span>"
|
||||
|
||||
if (href_list["refresh"])
|
||||
if((machine)&&(in_range(src, usr)))
|
||||
show_inv(machine)
|
||||
@@ -522,12 +565,16 @@
|
||||
|
||||
if ((href_list["item"] && !( usr.stat ) && usr.canmove && !( usr.restrained() ) && in_range(src, usr) && ticker)) //if game hasn't started, can't make an equip_e
|
||||
var/obj/effect/equip_e/human/O = new /obj/effect/equip_e/human( )
|
||||
if(usr:gloves)
|
||||
var/obj/item/clothing/gloves/G = usr:gloves
|
||||
pickpocket = G.pickpocket
|
||||
O.source = usr
|
||||
O.target = src
|
||||
O.item = usr.get_active_hand()
|
||||
O.s_loc = usr.loc
|
||||
O.t_loc = loc
|
||||
O.place = href_list["item"]
|
||||
O.pickpocket = pickpocket //Stealthy
|
||||
requests += O
|
||||
spawn( 0 )
|
||||
O.process()
|
||||
|
||||
@@ -228,13 +228,14 @@
|
||||
if(istype(used_weapon,/obj/item/weapon))
|
||||
var/obj/item/weapon/W = used_weapon //Sharp objects will always embed if they do enough damage.
|
||||
if( (damage > (10*W.w_class)) && ( (sharp && !ismob(W.loc)) || prob(damage/W.w_class) ) )
|
||||
organ.implants += W
|
||||
visible_message("<span class='danger'>\The [W] sticks in the wound!</span>")
|
||||
W.add_blood(src)
|
||||
if(ismob(W.loc))
|
||||
var/mob/living/H = W.loc
|
||||
H.drop_item()
|
||||
W.loc = src
|
||||
if(!istype(W, /obj/item/weapon/butch/meatcleaver))
|
||||
organ.implants += W
|
||||
visible_message("<span class='danger'>\The [W] sticks in the wound!</span>")
|
||||
W.add_blood(src)
|
||||
if(ismob(W.loc))
|
||||
var/mob/living/H = W.loc
|
||||
H.drop_item()
|
||||
W.loc = src
|
||||
|
||||
else if(istype(used_weapon,/obj/item/projectile)) //We don't want to use the actual projectile item, so we spawn some shrapnel.
|
||||
if(prob(75) && damagetype == BRUTE)
|
||||
|
||||
@@ -168,10 +168,26 @@ emp_act
|
||||
var/target_zone = get_zone_with_miss_chance(user.zone_sel.selecting, src)
|
||||
if(user == src) // Attacking yourself can't miss
|
||||
target_zone = user.zone_sel.selecting
|
||||
if(!target_zone)
|
||||
if(!target_zone && !src.stat)
|
||||
visible_message("\red <B>[user] misses [src] with \the [I]!")
|
||||
return
|
||||
|
||||
if(istype(I, /obj/item/weapon/butch/meatcleaver) && src.stat == DEAD && user.a_intent == "hurt")
|
||||
var/obj/item/weapon/reagent_containers/food/snacks/meat/human/newmeat = new /obj/item/weapon/reagent_containers/food/snacks/meat/human(get_turf(src.loc))
|
||||
newmeat.name = src.real_name + newmeat.name
|
||||
newmeat.subjectname = src.real_name
|
||||
newmeat.subjectjob = src.job
|
||||
newmeat.reagents.add_reagent ("nutriment", (src.nutrition / 15) / 3)
|
||||
src.reagents.trans_to (newmeat, round ((src.reagents.total_volume) / 3, 1))
|
||||
src.loc.add_blood(src)
|
||||
--src.meatleft
|
||||
user << "\red You hack off a chunk of meat from [src.name]"
|
||||
if(!src.meatleft)
|
||||
src.attack_log += "\[[time_stamp()]\] Was chopped up into meat by <b>[user]/[user.ckey]</b>"
|
||||
user.attack_log += "\[[time_stamp()]\] Chopped up <b>[src]/[src.ckey]</b> into meat</b>"
|
||||
msg_admin_attack("[user.name] ([user.ckey]) chopped up [src] ([src.ckey]) into meat (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
|
||||
del(src)
|
||||
|
||||
var/datum/organ/external/affecting = get_organ(target_zone)
|
||||
if (!affecting)
|
||||
return
|
||||
|
||||
@@ -55,3 +55,4 @@
|
||||
var/xylophone = 0 //For the spoooooooky xylophone cooldown
|
||||
|
||||
var/mob/remoteview_target = null
|
||||
var/meatleft = 3 //For chef item
|
||||
@@ -278,6 +278,7 @@
|
||||
var/t_loc = null //target location
|
||||
var/obj/item/item = null
|
||||
var/place = null
|
||||
var/pickpocket = null
|
||||
|
||||
/obj/effect/equip_e/human
|
||||
name = "human"
|
||||
@@ -430,7 +431,10 @@
|
||||
if("belt")
|
||||
target.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had their belt item ([target.belt]) removed by [source.name] ([source.ckey])</font>")
|
||||
source.attack_log += text("\[[time_stamp()]\] <font color='red'>Attempted to remove [target.name]'s ([target.ckey]) belt item ([target.belt])</font>")
|
||||
message = "\red <B>[source] is trying to take off the [target.belt] from [target]'s belt!</B>"
|
||||
if(!pickpocket)
|
||||
message = "\red <B>[source] is trying to take off the [target.belt] from [target]'s belt!</B>"
|
||||
else
|
||||
source << "\blue You try to take off the [target.belt] from [target]'s belt!"
|
||||
if("suit")
|
||||
target.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had their suit ([target.wear_suit]) removed by [source.name] ([source.ckey])</font>")
|
||||
source.attack_log += text("\[[time_stamp()]\] <font color='red'>Attempted to remove [target.name]'s ([target.ckey]) suit ([target.wear_suit])</font>")
|
||||
@@ -481,7 +485,10 @@
|
||||
if("id")
|
||||
target.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had their ID ([target.wear_id]) removed by [source.name] ([source.ckey])</font>")
|
||||
source.attack_log += text("\[[time_stamp()]\] <font color='red'>Attempted to remove [target.name]'s ([target.ckey]) ID ([target.wear_id])</font>")
|
||||
message = "\red <B>[source] is trying to take off [target.wear_id] from [target]'s uniform!</B>"
|
||||
if(!pickpocket)
|
||||
message = "\red <B>[source] is trying to take off [target.wear_id] from [target]'s uniform!</B>"
|
||||
else
|
||||
source << "\blue You try to take off [target.wear_id] from [target]'s uniform!"
|
||||
if("internal")
|
||||
target.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has had their internals toggled by [source.name] ([source.ckey])</font>")
|
||||
source.attack_log += text("\[[time_stamp()]\] <font color='red'>Attempted to toggle [target.name]'s ([target.ckey]) internals</font>")
|
||||
|
||||
@@ -1,4 +1,26 @@
|
||||
|
||||
/mob/living/Life()
|
||||
..()
|
||||
if (monkeyizing) return
|
||||
if(!loc) return // Fixing a null error that occurs when the mob isn't found in the world -- TLE
|
||||
if(mind)
|
||||
if(mind in ticker.mode.implanted)
|
||||
if(implanting) return
|
||||
//world << "[src.name]"
|
||||
var/datum/mind/head = ticker.mode.implanted[mind]
|
||||
//var/list/removal
|
||||
if(!(locate(/obj/item/weapon/implant/traitor) in src.contents))
|
||||
//world << "doesn't have an implant"
|
||||
ticker.mode.remove_traitor_mind(mind, head)
|
||||
/*
|
||||
if((head in ticker.mode.implanters))
|
||||
ticker.mode.implanter[head] -= src.mind
|
||||
ticker.mode.implanted -= src.mind
|
||||
if(src.mind in ticker.mode.traitors)
|
||||
ticker.mode.traitors -= src.mind
|
||||
special_role = null
|
||||
current << "\red <FONT size = 3><B>The fog clouding your mind clears. You remember nothing from the moment you were implanted until now..(You don't remember who enslaved you)</B></FONT>"
|
||||
*/
|
||||
/mob/living/verb/succumb()
|
||||
set hidden = 1
|
||||
if ((src.health < 0 && src.health > -95.0))
|
||||
|
||||
@@ -59,6 +59,9 @@
|
||||
if(!P.nodamage)
|
||||
apply_damage((P.damage/(absorb+1)), P.damage_type, def_zone, absorb, 0, P)
|
||||
P.on_hit(src, absorb)
|
||||
if(istype(P, /obj/item/projectile/beam/lightning))
|
||||
if(src.health <= -100)
|
||||
src.dust()
|
||||
return absorb
|
||||
|
||||
/mob/living/hitby(atom/movable/AM as mob|obj,var/speed = 5)//Standardization and logging -Sieve
|
||||
|
||||
@@ -35,4 +35,6 @@
|
||||
|
||||
var/tod = null // Time of death
|
||||
var/update_slimes = 1
|
||||
var/silent = null //Can't talk. Value goes down every life proc.
|
||||
var/silent = null //Can't talk. Value goes down every life proc.
|
||||
var/specialsauce = 0 //Has this person consumed enough special sauce? IF so they're a ticking time bomb of death.
|
||||
var/implanting = 0 //Used for the mind-slave implant
|
||||
@@ -16,8 +16,14 @@
|
||||
if("nuclear emergency")
|
||||
if(mind in ticker.mode:syndicates)
|
||||
ticker.mode.update_all_synd_icons()
|
||||
var/ref = "\ref[mind]"
|
||||
if(ref in ticker.mode.implanter)
|
||||
ticker.mode.update_traitor_icons_added(mind)
|
||||
if(mind in ticker.mode.implanted)
|
||||
ticker.mode.update_traitor_icons_added(mind)
|
||||
return .
|
||||
|
||||
|
||||
//This stuff needs to be merged from cloning.dm but I'm not in the mood to be shouted at for breaking all the things :< ~Carn
|
||||
/* clones
|
||||
switch(ticker.mode.name)
|
||||
|
||||
@@ -228,10 +228,10 @@ var/list/slot_equipment_priority = list( \
|
||||
<BR>[(internal ? text("<A href='?src=\ref[src];item=internal'>Remove Internal</A>") : "")]
|
||||
<BR><A href='?src=\ref[src];item=pockets'>Empty Pockets</A>
|
||||
<BR><A href='?src=\ref[user];refresh=1'>Refresh</A>
|
||||
<BR><A href='?src=\ref[user];mach_close=mob[name]'>Close</A>
|
||||
<BR><A href='?src=\ref[user];mach_close=mob\ref[src]'>Close</A>
|
||||
<BR>"}
|
||||
user << browse(dat, text("window=mob[];size=325x500", name))
|
||||
onclose(user, "mob[name]")
|
||||
onclose(user, "mob\ref[src]")
|
||||
return
|
||||
|
||||
/mob/proc/ret_grab(obj/effect/list_container/mobl/L as obj, flag)
|
||||
|
||||
Reference in New Issue
Block a user