mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
I started with the desire to fix issue 634. It sounded like a simple issue, right? Well one complete rewrite of how equipping and stripping works later, this commit fixes issue 645
Code-wide changes: /mob -level procs: equip_if_possible() is now known as equip_to_slot_or_del() to prevent confusion with equip_to_slot_if_possible() and to better describe what it does. equip_to_slot_if_possible(item, slot, del_on_fail, disable_warning, redraw_mob) equip_to_appropriate_slot() is now a /mob - level proc. equip_to_slot() is an unsafe proc, which just handles the final step of actually getting an item onto the mob. It has no checks of whether it can or can't do that. Use equip_to_slot_if_possible() for that purpose. New /obj/item -level proc: /obj/item/proc/mob_can_equip(M as mob, slot, disable_warning = 0) This proc can be used to determine whehter a mob can pick up an item from the item's side. Carn, I'll need you to review code/modules/mob/living/carbon/human/inventory.dm to ensure that I'm not redrawing the mob too many times. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4423 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -833,8 +833,8 @@ var/global/BSACooldown = 0
|
||||
M.loc = pick(prisonwarp)
|
||||
if(istype(M, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/prisoner = M
|
||||
prisoner.equip_if_possible(new /obj/item/clothing/under/color/orange(prisoner), prisoner.slot_w_uniform)
|
||||
prisoner.equip_if_possible(new /obj/item/clothing/shoes/orange(prisoner), prisoner.slot_shoes)
|
||||
prisoner.equip_to_slot_or_del(new /obj/item/clothing/under/color/orange(prisoner), slot_w_uniform)
|
||||
prisoner.equip_to_slot_or_del(new /obj/item/clothing/shoes/orange(prisoner), slot_shoes)
|
||||
spawn(50)
|
||||
M << "\red You have been sent to the prison station!"
|
||||
log_admin("[key_name(usr)] sent [key_name(M)] to the prison station.")
|
||||
@@ -984,8 +984,8 @@ var/global/BSACooldown = 0
|
||||
W.layer = initial(W.layer)
|
||||
if(istype(M, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/observer = M
|
||||
observer.equip_if_possible(new /obj/item/clothing/under/suit_jacket(observer), observer.slot_w_uniform)
|
||||
observer.equip_if_possible(new /obj/item/clothing/shoes/black(observer), observer.slot_shoes)
|
||||
observer.equip_to_slot_or_del(new /obj/item/clothing/under/suit_jacket(observer), slot_w_uniform)
|
||||
observer.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(observer), slot_shoes)
|
||||
M.Paralyse(5)
|
||||
sleep(5)
|
||||
M.loc = pick(tdomeobserve)
|
||||
@@ -1220,9 +1220,9 @@ var/global/BSACooldown = 0
|
||||
var/mob/M = locate(href_list["adminspawncookie"])
|
||||
if(M && ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.equip_if_possible( new /obj/item/weapon/reagent_containers/food/snacks/cookie(H), H.slot_l_hand )
|
||||
H.equip_to_slot_or_del( new /obj/item/weapon/reagent_containers/food/snacks/cookie(H), slot_l_hand )
|
||||
if(!(istype(H.l_hand,/obj/item/weapon/reagent_containers/food/snacks/cookie)))
|
||||
H.equip_if_possible( new /obj/item/weapon/reagent_containers/food/snacks/cookie(H), H.slot_r_hand )
|
||||
H.equip_to_slot_or_del( new /obj/item/weapon/reagent_containers/food/snacks/cookie(H), slot_r_hand )
|
||||
if(!(istype(H.r_hand,/obj/item/weapon/reagent_containers/food/snacks/cookie)))
|
||||
log_admin("[key_name(H)] has their hands full, so they did not receive their cookie, spawned by [key_name(src.owner)].")
|
||||
message_admins("[key_name(H)] has their hands full, so they did not receive their cookie, spawned by [key_name(src.owner)].")
|
||||
@@ -1741,8 +1741,8 @@ var/global/BSACooldown = 0
|
||||
W.layer = initial(W.layer)
|
||||
//teleport person to cell
|
||||
H.loc = pick(prisonwarp)
|
||||
H.equip_if_possible(new /obj/item/clothing/under/color/orange(H), H.slot_w_uniform)
|
||||
H.equip_if_possible(new /obj/item/clothing/shoes/orange(H), H.slot_shoes)
|
||||
H.equip_to_slot_or_del(new /obj/item/clothing/under/color/orange(H), slot_w_uniform)
|
||||
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/orange(H), slot_shoes)
|
||||
else
|
||||
//teleport security person
|
||||
H.loc = pick(prisonsecuritywarp)
|
||||
|
||||
@@ -379,7 +379,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
id.registered_name = H.real_name
|
||||
id.assignment = "Captain"
|
||||
id.name = "[id.registered_name]'s ID Card ([id.assignment])"
|
||||
H.equip_if_possible(id, H.slot_wear_id)
|
||||
H.equip_to_slot_or_del(id, slot_wear_id)
|
||||
H.update_inv_wear_id()
|
||||
else
|
||||
alert("Invalid mob")
|
||||
@@ -463,151 +463,151 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
if ("strip")
|
||||
//do nothing
|
||||
if ("standard space gear")
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
|
||||
M.equip_if_possible(new /obj/item/clothing/under/color/grey(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/space(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/helmet/space(M), M.slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/color/grey(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/space(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space(M), slot_head)
|
||||
var /obj/item/weapon/tank/jetpack/J = new /obj/item/weapon/tank/jetpack/oxygen(M)
|
||||
M.equip_if_possible(J, M.slot_back)
|
||||
M.equip_to_slot_or_del(J, slot_back)
|
||||
J.toggle()
|
||||
M.equip_if_possible(new /obj/item/clothing/mask/breath(M), M.slot_wear_mask)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/mask/breath(M), slot_wear_mask)
|
||||
J.Topic(null, list("stat" = 1))
|
||||
if ("tournament standard red","tournament standard green") //we think stunning weapon is too overpowered to use it on tournaments. --rastaf0
|
||||
if (dresscode=="tournament standard red")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/color/red(M), M.slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/color/red(M), slot_w_uniform)
|
||||
else
|
||||
M.equip_if_possible(new /obj/item/clothing/under/color/green(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/color/green(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/armor/vest(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/helmet/thunderdome(M), M.slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/armor/vest(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/helmet/thunderdome(M), slot_head)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/gun/energy/pulse_rifle/destroyer(M), M.slot_r_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/kitchenknife(M), M.slot_l_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/grenade/smokebomb(M), M.slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/energy/pulse_rifle/destroyer(M), slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/kitchenknife(M), slot_l_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/grenade/smokebomb(M), slot_r_store)
|
||||
|
||||
|
||||
if ("tournament gangster") //gangster are supposed to fight each other. --rastaf0
|
||||
M.equip_if_possible(new /obj/item/clothing/under/det(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/det(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/det_suit(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/thermal/monocle(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/det_hat(M), M.slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/det_suit(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/monocle(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/det_hat(M), slot_head)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/cloaking_device(M), M.slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/cloaking_device(M), slot_r_store)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/gun/projectile(M), M.slot_r_hand)
|
||||
M.equip_if_possible(new /obj/item/ammo_magazine/a357(M), M.slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/projectile(M), slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/ammo_magazine/a357(M), slot_l_store)
|
||||
|
||||
if ("tournament chef") //Steven Seagal FTW
|
||||
M.equip_if_possible(new /obj/item/clothing/under/rank/chef(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/chef(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/chefhat(M), M.slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/chef(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/chef(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/chefhat(M), slot_head)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/kitchen/rollingpin(M), M.slot_r_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/kitchenknife(M), M.slot_l_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/kitchenknife(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/kitchenknife(M), M.slot_s_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/kitchen/rollingpin(M), slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/kitchenknife(M), slot_l_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/kitchenknife(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/kitchenknife(M), slot_s_store)
|
||||
|
||||
if ("tournament janitor")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/rank/janitor(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/janitor(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
var/obj/item/weapon/storage/backpack/backpack = new(M)
|
||||
for(var/obj/item/I in backpack)
|
||||
del(I)
|
||||
M.equip_if_possible(backpack, M.slot_back)
|
||||
M.equip_to_slot_or_del(backpack, slot_back)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/mop(M), M.slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/mop(M), slot_r_hand)
|
||||
var/obj/item/weapon/reagent_containers/glass/bucket/bucket = new(M)
|
||||
bucket.reagents.add_reagent("water", 70)
|
||||
M.equip_if_possible(bucket, M.slot_l_hand)
|
||||
M.equip_to_slot_or_del(bucket, slot_l_hand)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/grenade/chem_grenade/cleaner(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/grenade/chem_grenade/cleaner(M), M.slot_l_store)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_if_possible(new /obj/item/stack/tile/plasteel(M), M.slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/grenade/chem_grenade/cleaner(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/grenade/chem_grenade/cleaner(M), slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/stack/tile/plasteel(M), slot_in_backpack)
|
||||
|
||||
if ("pirate")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/pirate(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/brown(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/bandana(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/eyepatch(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/weapon/melee/energy/sword/pirate(M), M.slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/pirate(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/brown(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/bandana(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/eyepatch(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/melee/energy/sword/pirate(M), slot_r_hand)
|
||||
|
||||
if ("space pirate")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/pirate(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/brown(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/space/pirate(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/helmet/space/pirate(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/eyepatch(M), M.slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/pirate(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/brown(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/space/pirate(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/pirate(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/eyepatch(M), slot_glasses)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/melee/energy/sword/pirate(M), M.slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/melee/energy/sword/pirate(M), slot_r_hand)
|
||||
|
||||
/*
|
||||
if ("soviet soldier")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/soviet(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/ushanka(M), M.slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/soviet(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/ushanka(M), slot_head)
|
||||
*/
|
||||
|
||||
if("tunnel clown")//Tunnel clowns rule!
|
||||
M.equip_if_possible(new /obj/item/clothing/under/rank/clown(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/clown_shoes(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/black(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/clothing/mask/gas/clown_hat(M), M.slot_wear_mask)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/chaplain_hood(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/thermal/monocle(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/chaplain_hoodie(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/weapon/reagent_containers/food/snacks/grown/banana(M), M.slot_l_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/bikehorn(M), M.slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/clown(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/clown_shoes(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/clown_hat(M), slot_wear_mask)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/chaplain_hood(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/monocle(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/chaplain_hoodie(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/reagent_containers/food/snacks/grown/banana(M), slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/bikehorn(M), slot_r_store)
|
||||
|
||||
var/obj/item/weapon/card/id/W = new(M)
|
||||
W.name = "[M.real_name]'s ID Card"
|
||||
W.access = get_all_accesses()
|
||||
W.assignment = "Tunnel Clown!"
|
||||
W.registered_name = M.real_name
|
||||
M.equip_if_possible(W, M.slot_wear_id)
|
||||
M.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
var/obj/item/weapon/twohanded/fireaxe/fire_axe = new(M)
|
||||
M.equip_if_possible(fire_axe, M.slot_r_hand)
|
||||
M.equip_to_slot_or_del(fire_axe, slot_r_hand)
|
||||
|
||||
if("masked killer")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/overalls(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/white(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/latex(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/clothing/mask/surgical(M), M.slot_wear_mask)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/welding(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/thermal/monocle(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/apron(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/weapon/kitchenknife(M), M.slot_l_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/scalpel(M), M.slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/overalls(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/white(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/latex(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/mask/surgical(M), slot_wear_mask)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/welding(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/monocle(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/apron(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/kitchenknife(M), slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/scalpel(M), slot_r_store)
|
||||
|
||||
var/obj/item/weapon/twohanded/fireaxe/fire_axe = new(M)
|
||||
M.equip_if_possible(fire_axe, M.slot_r_hand)
|
||||
M.equip_to_slot_or_del(fire_axe, slot_r_hand)
|
||||
|
||||
for(var/obj/item/carried_item in M.contents)
|
||||
if(!istype(carried_item, /obj/item/weapon/implant))//If it's not an implant.
|
||||
carried_item.add_blood(M)//Oh yes, there will be blood...
|
||||
|
||||
if("assassin")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/suit_jacket(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/black(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/sunglasses(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/wcoat(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/weapon/melee/energy/sword(M), M.slot_l_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/cloaking_device(M), M.slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/suit_jacket(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/sunglasses(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/wcoat(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/melee/energy/sword(M), slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/cloaking_device(M), slot_r_store)
|
||||
|
||||
var/obj/item/weapon/secstorage/sbriefcase/sec_briefcase = new(M)
|
||||
for(var/obj/item/briefcase_item in sec_briefcase)
|
||||
@@ -618,21 +618,21 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
sec_briefcase.contents += new /obj/item/weapon/gun/projectile/mateba
|
||||
sec_briefcase.contents += new /obj/item/ammo_magazine/a357
|
||||
sec_briefcase.contents += new /obj/item/weapon/plastique
|
||||
M.equip_if_possible(sec_briefcase, M.slot_l_hand)
|
||||
M.equip_to_slot_or_del(sec_briefcase, slot_l_hand)
|
||||
|
||||
var/obj/item/device/pda/heads/pda = new(M)
|
||||
pda.owner = M.real_name
|
||||
pda.ownjob = "Reaper"
|
||||
pda.name = "PDA-[M.real_name] ([pda.ownjob])"
|
||||
|
||||
M.equip_if_possible(pda, M.slot_belt)
|
||||
M.equip_to_slot_or_del(pda, slot_belt)
|
||||
|
||||
var/obj/item/weapon/card/id/syndicate/W = new(M)
|
||||
W.name = "[M.real_name]'s ID Card"
|
||||
W.access = get_all_accesses()
|
||||
W.assignment = "Reaper"
|
||||
W.registered_name = M.real_name
|
||||
M.equip_if_possible(W, M.slot_wear_id)
|
||||
M.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
if("death commando")//Was looking to add this for a while.
|
||||
M.equip_death_commando()
|
||||
@@ -641,22 +641,22 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
M.equip_syndicate_commando()
|
||||
|
||||
if("centcom official")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/rank/centcom_officer(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/black(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/black(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset/heads/hop(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/sunglasses(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/weapon/gun/energy(M), M.slot_belt)
|
||||
M.equip_if_possible(new /obj/item/weapon/pen(M), M.slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/centcom_officer(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/black(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/black(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/hop(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/sunglasses(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/energy(M), slot_belt)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/pen(M), slot_l_store)
|
||||
|
||||
var/obj/item/device/pda/heads/pda = new(M)
|
||||
pda.owner = M.real_name
|
||||
pda.ownjob = "CentCom Review Official"
|
||||
pda.name = "PDA-[M.real_name] ([pda.ownjob])"
|
||||
|
||||
M.equip_if_possible(pda, M.slot_r_store)
|
||||
M.equip_to_slot_or_del(pda, slot_r_store)
|
||||
|
||||
M.equip_if_possible(new /obj/item/weapon/clipboard(M), M.slot_l_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/clipboard(M), slot_l_hand)
|
||||
|
||||
var/obj/item/weapon/card/id/W = new(M)
|
||||
W.name = "[M.real_name]'s ID Card"
|
||||
@@ -665,20 +665,20 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
W.access += list("VIP Guest","Custodian","Thunderdome Overseer","Intel Officer","Medical Officer","Death Commando","Research Officer")
|
||||
W.assignment = "CentCom Review Official"
|
||||
W.registered_name = M.real_name
|
||||
M.equip_if_possible(W, M.slot_wear_id)
|
||||
M.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
if("centcom commander")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/rank/centcom_commander(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/armor/bulletproof(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/swat(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/swat(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset/heads/captain(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/eyepatch(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/mask/cigarette/cigar/cohiba(M), M.slot_wear_mask)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/centhat(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/weapon/gun/projectile/mateba(M), M.slot_belt)
|
||||
M.equip_if_possible(new /obj/item/weapon/lighter/zippo(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/ammo_magazine/a357(M), M.slot_l_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/centcom_commander(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/armor/bulletproof(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/captain(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/eyepatch(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/mask/cigarette/cigar/cohiba(M), slot_wear_mask)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/centhat(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/projectile/mateba(M), slot_belt)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/lighter/zippo(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/ammo_magazine/a357(M), slot_l_store)
|
||||
|
||||
var/obj/item/weapon/card/id/W = new(M)
|
||||
W.name = "[M.real_name]'s ID Card"
|
||||
@@ -687,20 +687,20 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
W.access += get_all_centcom_access()
|
||||
W.assignment = "CentCom Commanding Officer"
|
||||
W.registered_name = M.real_name
|
||||
M.equip_if_possible(W, M.slot_wear_id)
|
||||
M.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
if("special ops officer")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/syndicate/combat(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/armor/swat/officer(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/combat(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/combat(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset/heads/captain(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/thermal/eyepatch(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/mask/cigarette/cigar/havana(M), M.slot_wear_mask)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/helmet/space/deathsquad/beret(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/weapon/gun/energy/pulse_rifle/M1911(M), M.slot_belt)
|
||||
M.equip_if_possible(new /obj/item/weapon/lighter/zippo(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/backpack/satchel(M), M.slot_back)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/syndicate/combat(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/armor/swat/officer(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/combat(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/captain(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/eyepatch(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/mask/cigarette/cigar/havana(M), slot_wear_mask)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/deathsquad/beret(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/energy/pulse_rifle/M1911(M), slot_belt)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/lighter/zippo(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(M), slot_back)
|
||||
|
||||
var/obj/item/weapon/card/id/W = new(M)
|
||||
W.name = "[M.real_name]'s ID Card"
|
||||
@@ -709,53 +709,53 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
W.access += get_all_centcom_access()
|
||||
W.assignment = "Special Operations Officer"
|
||||
W.registered_name = M.real_name
|
||||
M.equip_if_possible(W, M.slot_wear_id)
|
||||
M.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
if("blue wizard")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/lightpurple(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/wizrobe(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/sandal(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/wizard(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/weapon/teleportation_scroll(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/spellbook(M), M.slot_r_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/staff(M), M.slot_l_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/backpack(M), M.slot_back)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/box(M), M.slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/lightpurple(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/sandal(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/wizard(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/teleportation_scroll(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/spellbook(M), slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/staff(M), slot_l_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(M), slot_back)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/box(M), slot_in_backpack)
|
||||
|
||||
if("red wizard")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/lightpurple(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/wizrobe/red(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/sandal(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/wizard/red(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/weapon/teleportation_scroll(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/spellbook(M), M.slot_r_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/staff(M), M.slot_l_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/backpack(M), M.slot_back)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/box(M), M.slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/lightpurple(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe/red(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/sandal(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/wizard/red(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/teleportation_scroll(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/spellbook(M), slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/staff(M), slot_l_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(M), slot_back)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/box(M), slot_in_backpack)
|
||||
|
||||
if("marisa wizard")
|
||||
M.equip_if_possible(new /obj/item/clothing/under/lightpurple(M), M.slot_w_uniform)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/wizrobe/marisa(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/sandal/marisa(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/head/wizard/marisa(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/weapon/teleportation_scroll(M), M.slot_r_store)
|
||||
M.equip_if_possible(new /obj/item/weapon/spellbook(M), M.slot_r_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/staff(M), M.slot_l_hand)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/backpack(M), M.slot_back)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/box(M), M.slot_in_backpack)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/lightpurple(M), slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe/marisa(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/sandal/marisa(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/wizard/marisa(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/teleportation_scroll(M), slot_r_store)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/spellbook(M), slot_r_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/staff(M), slot_l_hand)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack(M), slot_back)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/box(M), slot_in_backpack)
|
||||
if("soviet admiral")
|
||||
M.equip_if_possible(new /obj/item/clothing/head/hgpiratecap(M), M.slot_head)
|
||||
M.equip_if_possible(new /obj/item/clothing/shoes/combat(M), M.slot_shoes)
|
||||
M.equip_if_possible(new /obj/item/clothing/gloves/combat(M), M.slot_gloves)
|
||||
M.equip_if_possible(new /obj/item/device/radio/headset/heads/captain(M), M.slot_ears)
|
||||
M.equip_if_possible(new /obj/item/clothing/glasses/thermal/eyepatch(M), M.slot_glasses)
|
||||
M.equip_if_possible(new /obj/item/clothing/suit/hgpirate(M), M.slot_wear_suit)
|
||||
M.equip_if_possible(new /obj/item/weapon/storage/backpack/bandolier(M), M.slot_back)
|
||||
M.equip_if_possible(new /obj/item/weapon/gun/projectile/mateba(M), M.slot_belt)
|
||||
M.equip_if_possible(new /obj/item/clothing/under/soviet(M), M.slot_w_uniform)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/head/hgpiratecap(M), slot_head)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(M), slot_shoes)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/combat(M), slot_gloves)
|
||||
M.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/captain(M), slot_ears)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/eyepatch(M), slot_glasses)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/suit/hgpirate(M), slot_wear_suit)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/bandolier(M), slot_back)
|
||||
M.equip_to_slot_or_del(new /obj/item/weapon/gun/projectile/mateba(M), slot_belt)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/under/soviet(M), slot_w_uniform)
|
||||
var/obj/item/weapon/card/id/W = new(M)
|
||||
W.name = "[M.real_name]'s ID Card"
|
||||
W.icon_state = "centcom"
|
||||
@@ -763,7 +763,7 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
|
||||
W.access += get_all_centcom_access()
|
||||
W.assignment = "Admiral"
|
||||
W.registered_name = M.real_name
|
||||
M.equip_if_possible(W, M.slot_wear_id)
|
||||
M.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
M.regenerate_icons()
|
||||
|
||||
|
||||
@@ -36,12 +36,12 @@
|
||||
continue
|
||||
del(I)
|
||||
|
||||
H.equip_if_possible(new /obj/item/clothing/under/kilt(H), H.slot_w_uniform)
|
||||
H.equip_if_possible(new /obj/item/device/radio/headset/heads/captain(H), H.slot_ears)
|
||||
H.equip_if_possible(new /obj/item/clothing/head/beret(H), H.slot_head)
|
||||
H.equip_if_possible(new /obj/item/weapon/claymore(H), H.slot_l_hand)
|
||||
H.equip_if_possible(new /obj/item/clothing/shoes/combat(H), H.slot_shoes)
|
||||
H.equip_if_possible(new /obj/item/weapon/pinpointer(H.loc), H.slot_l_store)
|
||||
H.equip_to_slot_or_del(new /obj/item/clothing/under/kilt(H), slot_w_uniform)
|
||||
H.equip_to_slot_or_del(new /obj/item/device/radio/headset/heads/captain(H), slot_ears)
|
||||
H.equip_to_slot_or_del(new /obj/item/clothing/head/beret(H), slot_head)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/claymore(H), slot_l_hand)
|
||||
H.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(H), slot_shoes)
|
||||
H.equip_to_slot_or_del(new /obj/item/weapon/pinpointer(H.loc), slot_l_store)
|
||||
|
||||
var/obj/item/weapon/card/id/W = new(H)
|
||||
W.name = "[H.real_name]'s ID Card"
|
||||
@@ -50,7 +50,7 @@
|
||||
W.access += get_all_centcom_access()
|
||||
W.assignment = "Highlander"
|
||||
W.registered_name = H.real_name
|
||||
H.equip_if_possible(W, H.slot_wear_id)
|
||||
H.equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
message_admins("\blue [key_name_admin(usr)] used THERE CAN BE ONLY ONE!", 1)
|
||||
log_admin("[key_name(usr)] used there can be only one.")
|
||||
@@ -35,8 +35,8 @@
|
||||
M.loc = pick(prisonwarp)
|
||||
if(istype(M, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/prisoner = M
|
||||
prisoner.equip_if_possible(new /obj/item/clothing/under/color/orange(prisoner), prisoner.slot_w_uniform)
|
||||
prisoner.equip_if_possible(new /obj/item/clothing/shoes/orange(prisoner), prisoner.slot_shoes)
|
||||
prisoner.equip_to_slot_or_del(new /obj/item/clothing/under/color/orange(prisoner), slot_w_uniform)
|
||||
prisoner.equip_to_slot_or_del(new /obj/item/clothing/shoes/orange(prisoner), slot_shoes)
|
||||
spawn(50)
|
||||
M << "\red You have been sent to the prison station!"
|
||||
log_admin("[key_name(usr)] sent [key_name(M)] to the prison station.")
|
||||
|
||||
@@ -133,37 +133,37 @@ var/global/sent_strike_team = 0
|
||||
|
||||
var/obj/item/device/radio/R = new /obj/item/device/radio/headset(src)
|
||||
R.set_frequency(1441)
|
||||
equip_if_possible(R, slot_ears)
|
||||
equip_to_slot_or_del(R, slot_ears)
|
||||
if (leader_selected == 0)
|
||||
equip_if_possible(new /obj/item/clothing/under/color/green(src), slot_w_uniform)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/under/color/green(src), slot_w_uniform)
|
||||
else
|
||||
equip_if_possible(new /obj/item/clothing/under/rank/centcom_officer(src), slot_w_uniform)
|
||||
equip_if_possible(new /obj/item/clothing/shoes/swat(src), slot_shoes)
|
||||
equip_if_possible(new /obj/item/clothing/suit/armor/swat(src), slot_wear_suit)
|
||||
equip_if_possible(new /obj/item/clothing/gloves/swat(src), slot_gloves)
|
||||
equip_if_possible(new /obj/item/clothing/head/helmet/space/deathsquad(src), slot_head)
|
||||
equip_if_possible(new /obj/item/clothing/mask/gas/swat(src), slot_wear_mask)
|
||||
equip_if_possible(new /obj/item/clothing/glasses/thermal(src), slot_glasses)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/under/rank/centcom_officer(src), slot_w_uniform)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(src), slot_shoes)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/suit/armor/swat(src), slot_wear_suit)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(src), slot_gloves)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/deathsquad(src), slot_head)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/mask/gas/swat(src), slot_wear_mask)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal(src), slot_glasses)
|
||||
|
||||
equip_if_possible(new /obj/item/weapon/storage/backpack/security(src), slot_back)
|
||||
equip_if_possible(new /obj/item/weapon/storage/box(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/security(src), slot_back)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/box(src), slot_in_backpack)
|
||||
|
||||
equip_if_possible(new /obj/item/ammo_magazine/a357(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/weapon/storage/firstaid/regular(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/weapon/storage/flashbang_kit(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/device/flashlight(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/ammo_magazine/a357(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/regular(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/flashbang_kit(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/device/flashlight(src), slot_in_backpack)
|
||||
if (!leader_selected)
|
||||
equip_if_possible(new /obj/item/weapon/plastique(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/plastique(src), slot_in_backpack)
|
||||
else
|
||||
equip_if_possible(new /obj/item/weapon/pinpointer(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/weapon/disk/nuclear(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/pinpointer(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/disk/nuclear(src), slot_in_backpack)
|
||||
|
||||
equip_if_possible(new /obj/item/weapon/melee/energy/sword(src), slot_l_store)
|
||||
equip_if_possible(new /obj/item/weapon/grenade/flashbang(src), slot_r_store)
|
||||
equip_if_possible(new /obj/item/weapon/tank/emergency_oxygen(src), slot_s_store)
|
||||
equip_if_possible(new /obj/item/weapon/gun/projectile/mateba(src), slot_belt)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/melee/energy/sword(src), slot_l_store)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/grenade/flashbang(src), slot_r_store)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/tank/emergency_oxygen(src), slot_s_store)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/projectile/mateba(src), slot_belt)
|
||||
|
||||
equip_if_possible(new /obj/item/weapon/gun/energy/pulse_rifle(src), slot_r_hand)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/energy/pulse_rifle(src), slot_r_hand)
|
||||
|
||||
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(src)//Here you go Deuryn
|
||||
@@ -179,7 +179,7 @@ var/global/sent_strike_team = 0
|
||||
W.access += list(access_cent_general, access_cent_specops, access_cent_living, access_cent_storage)//Let's add their alloted CentCom access.
|
||||
W.assignment = "Death Commando"
|
||||
W.registered_name = real_name
|
||||
equip_if_possible(W, slot_wear_id)
|
||||
equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
resistances += "alien_embryo"
|
||||
return 1
|
||||
@@ -134,40 +134,40 @@ var/global/sent_syndicate_strike_team = 0
|
||||
|
||||
var/obj/item/device/radio/R = new /obj/item/device/radio/headset/syndicate(src)
|
||||
R.set_frequency(SYND_FREQ) //Same frequency as the syndicate team in Nuke mode.
|
||||
equip_if_possible(R, slot_ears)
|
||||
equip_if_possible(new /obj/item/clothing/under/syndicate(src), slot_w_uniform)
|
||||
equip_if_possible(new /obj/item/clothing/shoes/swat(src), slot_shoes)
|
||||
equip_to_slot_or_del(R, slot_ears)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/under/syndicate(src), slot_w_uniform)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/shoes/swat(src), slot_shoes)
|
||||
if (!syndicate_leader_selected)
|
||||
equip_if_possible(new /obj/item/clothing/suit/space/syndicate/black(src), slot_wear_suit)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/suit/space/syndicate/black(src), slot_wear_suit)
|
||||
else
|
||||
equip_if_possible(new /obj/item/clothing/suit/space/syndicate/black/red(src), slot_wear_suit)
|
||||
equip_if_possible(new /obj/item/clothing/gloves/swat(src), slot_gloves)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/suit/space/syndicate/black/red(src), slot_wear_suit)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(src), slot_gloves)
|
||||
if (!syndicate_leader_selected)
|
||||
equip_if_possible(new /obj/item/clothing/head/helmet/space/syndicate/black(src), slot_head)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/syndicate/black(src), slot_head)
|
||||
else
|
||||
equip_if_possible(new /obj/item/clothing/head/helmet/space/syndicate/black/red(src), slot_head)
|
||||
equip_if_possible(new /obj/item/clothing/mask/gas/syndicate(src), slot_wear_mask)
|
||||
equip_if_possible(new /obj/item/clothing/glasses/thermal(src), slot_glasses)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/head/helmet/space/syndicate/black/red(src), slot_head)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/mask/gas/syndicate(src), slot_wear_mask)
|
||||
equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal(src), slot_glasses)
|
||||
|
||||
equip_if_possible(new /obj/item/weapon/storage/backpack/security(src), slot_back)
|
||||
equip_if_possible(new /obj/item/weapon/storage/box(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/security(src), slot_back)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/box(src), slot_in_backpack)
|
||||
|
||||
equip_if_possible(new /obj/item/ammo_magazine/c45(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/weapon/storage/firstaid/regular(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/weapon/plastique(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/device/flashlight(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/ammo_magazine/c45(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/storage/firstaid/regular(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/plastique(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/device/flashlight(src), slot_in_backpack)
|
||||
if (!syndicate_leader_selected)
|
||||
equip_if_possible(new /obj/item/weapon/plastique(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/plastique(src), slot_in_backpack)
|
||||
else
|
||||
equip_if_possible(new /obj/item/weapon/pinpointer(src), slot_in_backpack)
|
||||
equip_if_possible(new /obj/item/weapon/disk/nuclear(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/pinpointer(src), slot_in_backpack)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/disk/nuclear(src), slot_in_backpack)
|
||||
|
||||
equip_if_possible(new /obj/item/weapon/melee/energy/sword(src), slot_l_store)
|
||||
equip_if_possible(new /obj/item/weapon/grenade/empgrenade(src), slot_r_store)
|
||||
equip_if_possible(new /obj/item/weapon/tank/emergency_oxygen(src), slot_s_store)
|
||||
equip_if_possible(new /obj/item/weapon/gun/projectile/silenced(src), slot_belt)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/melee/energy/sword(src), slot_l_store)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/grenade/empgrenade(src), slot_r_store)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/tank/emergency_oxygen(src), slot_s_store)
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/projectile/silenced(src), slot_belt)
|
||||
|
||||
equip_if_possible(new /obj/item/weapon/gun/energy/pulse_rifle(src), slot_r_hand) //Will change to something different at a later time -- Superxpdude
|
||||
equip_to_slot_or_del(new /obj/item/weapon/gun/energy/pulse_rifle(src), slot_r_hand) //Will change to something different at a later time -- Superxpdude
|
||||
|
||||
var/obj/item/weapon/card/id/syndicate/W = new(src) //Untrackable by AI
|
||||
W.name = "[real_name]'s ID Card"
|
||||
@@ -176,7 +176,7 @@ var/global/sent_syndicate_strike_team = 0
|
||||
W.access += list(access_cent_general, access_cent_specops, access_cent_living, access_cent_storage, access_syndicate)//Let's add their forged CentCom access and syndicate access.
|
||||
W.assignment = "Syndicate Commando"
|
||||
W.registered_name = real_name
|
||||
equip_if_possible(W, slot_wear_id)
|
||||
equip_to_slot_or_del(W, slot_wear_id)
|
||||
|
||||
resistances += "alien_embryo"
|
||||
return 1
|
||||
@@ -90,6 +90,15 @@ BLIND // can't see anything
|
||||
permeability_coefficient = 0.50
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
|
||||
//Suit
|
||||
/obj/item/clothing/suit
|
||||
icon = 'icons/obj/clothing/suits.dmi'
|
||||
name = "suit"
|
||||
var/fire_resist = T0C+100
|
||||
flags = FPRINT | TABLEPASS | ONESIZEFITSALL
|
||||
allowed = list(/obj/item/weapon/tank/emergency_oxygen)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0)
|
||||
slot_flags = SLOT_OCLOTHING
|
||||
|
||||
//Spacesuit
|
||||
//Note: Everything in modules/clothing/spacesuits should have the entire suit grouped together.
|
||||
@@ -104,7 +113,6 @@ BLIND // can't see anything
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 50)
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE
|
||||
|
||||
|
||||
/obj/item/clothing/suit/space
|
||||
name = "Space suit"
|
||||
desc = "A suit that protects against low pressure environments. Has a big 13 on the back."
|
||||
@@ -123,17 +131,6 @@ BLIND // can't see anything
|
||||
flags_inv = HIDEGLOVES|HIDESHOES|HIDEJUMPSUIT
|
||||
|
||||
|
||||
//Suit
|
||||
/obj/item/clothing/suit
|
||||
icon = 'icons/obj/clothing/suits.dmi'
|
||||
name = "suit"
|
||||
var/fire_resist = T0C+100
|
||||
flags = FPRINT | TABLEPASS | ONESIZEFITSALL
|
||||
allowed = list(/obj/item/weapon/tank/emergency_oxygen)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0)
|
||||
slot_flags = SLOT_OCLOTHING
|
||||
|
||||
|
||||
//Under clothing
|
||||
/obj/item/clothing/under
|
||||
icon = 'icons/obj/clothing/uniforms.dmi'
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
l_hand = W
|
||||
W.layer = 20 //TODO: move to equipped?
|
||||
// l_hand.screen_loc = ui_lhand
|
||||
W.equipped(src,"l_hand")
|
||||
W.equipped(src,slot_l_hand)
|
||||
if(client) client.screen |= W
|
||||
update_inv_l_hand()
|
||||
return 1
|
||||
@@ -36,7 +36,7 @@
|
||||
r_hand = W
|
||||
W.layer = 20
|
||||
// r_hand.screen_loc = ui_rhand
|
||||
W.equipped(src,"r_hand")
|
||||
W.equipped(src,slot_r_hand)
|
||||
if(client) client.screen |= W
|
||||
update_inv_r_hand()
|
||||
return 1
|
||||
|
||||
@@ -116,6 +116,7 @@
|
||||
using.icon = 'icons/mob/screen1_alien.dmi'
|
||||
using.icon_state = "equip"
|
||||
using.screen_loc = ui_alien_oclothing
|
||||
using.slot_id = slot_wear_suit
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -129,6 +130,7 @@
|
||||
using.screen_loc = ui_rhand
|
||||
using.layer = 19
|
||||
src.r_hand_hud_object = using
|
||||
using.slot_id = slot_r_hand
|
||||
src.adding += using
|
||||
|
||||
using = new src.h_type( src )
|
||||
@@ -140,6 +142,7 @@
|
||||
using.icon_state = "hand_active"
|
||||
using.screen_loc = ui_lhand
|
||||
using.layer = 19
|
||||
using.slot_id = slot_l_hand
|
||||
src.l_hand_hud_object = using
|
||||
src.adding += using
|
||||
|
||||
@@ -149,6 +152,7 @@
|
||||
using.icon = 'icons/mob/screen1_alien.dmi'
|
||||
using.icon_state = "pocket"
|
||||
using.screen_loc = ui_storage1
|
||||
using.slot_id = slot_l_store
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -158,6 +162,7 @@
|
||||
using.icon = 'icons/mob/screen1_alien.dmi'
|
||||
using.icon_state = "pocket"
|
||||
using.screen_loc = ui_storage2
|
||||
using.slot_id = slot_r_store
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -167,6 +172,7 @@
|
||||
using.icon = 'icons/mob/screen1_alien.dmi'
|
||||
using.icon_state = "hair"
|
||||
using.screen_loc = ui_alien_head
|
||||
using.slot_id = slot_head
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
//end of equippable shit
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
l_hand = null
|
||||
update_inv_l_hand(0)
|
||||
|
||||
/mob/living/carbon/alien/humanoid/db_click(text, t1)
|
||||
/mob/living/carbon/alien/humanoid/attack_ui(slot_id)
|
||||
var/obj/item/W = get_active_hand()
|
||||
if(W)
|
||||
if(!istype(W)) return
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
|
||||
|
||||
//can't equip anything
|
||||
/mob/living/carbon/alien/larva/db_click(text, t1)
|
||||
/mob/living/carbon/alien/larva/attack_ui(slot_id)
|
||||
return
|
||||
|
||||
/mob/living/carbon/alien/larva/meteorhit(O as obj)
|
||||
|
||||
@@ -113,6 +113,7 @@
|
||||
using.name = "i_clothing"
|
||||
using.dir = SOUTH
|
||||
using.icon = ui_style
|
||||
using.slot_id = slot_w_uniform
|
||||
using.icon_state = "center"
|
||||
using.screen_loc = ui_iclothing
|
||||
using.layer = 19
|
||||
@@ -122,6 +123,7 @@
|
||||
using.name = "o_clothing"
|
||||
using.dir = SOUTH
|
||||
using.icon = ui_style
|
||||
using.slot_id = slot_wear_suit
|
||||
using.icon_state = "equip"
|
||||
using.screen_loc = ui_oclothing
|
||||
using.layer = 19
|
||||
@@ -144,6 +146,7 @@
|
||||
if(mymob && !mymob.hand) //This being 0 or null means the right hand is in use
|
||||
using.icon_state = "hand_active"
|
||||
using.screen_loc = ui_rhand
|
||||
using.slot_id = slot_r_hand
|
||||
using.layer = 19
|
||||
src.r_hand_hud_object = using
|
||||
src.adding += using
|
||||
@@ -156,6 +159,7 @@
|
||||
if(mymob && mymob.hand) //This being 1 means the left hand is in use
|
||||
using.icon_state = "hand_active"
|
||||
using.screen_loc = ui_lhand
|
||||
using.slot_id = slot_l_hand
|
||||
using.layer = 19
|
||||
src.l_hand_hud_object = using
|
||||
src.adding += using
|
||||
@@ -184,6 +188,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "id"
|
||||
using.screen_loc = ui_id
|
||||
using.slot_id = slot_wear_id
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -193,6 +198,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "equip"
|
||||
using.screen_loc = ui_mask
|
||||
using.slot_id = slot_wear_mask
|
||||
using.layer = 19
|
||||
src.other += using
|
||||
|
||||
@@ -202,6 +208,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "back"
|
||||
using.screen_loc = ui_back
|
||||
using.slot_id = slot_back
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -210,6 +217,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "pocket"
|
||||
using.screen_loc = ui_storage1
|
||||
using.slot_id = slot_l_store
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -218,6 +226,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "pocket"
|
||||
using.screen_loc = ui_storage2
|
||||
using.slot_id = slot_r_store
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -227,6 +236,7 @@
|
||||
using.dir = 8 //The sprite at dir=8 has the background whereas the others don't.
|
||||
using.icon_state = "belt"
|
||||
using.screen_loc = ui_sstore1
|
||||
using.slot_id = slot_s_store
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -275,6 +285,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "gloves"
|
||||
using.screen_loc = ui_gloves
|
||||
using.slot_id = slot_gloves
|
||||
using.layer = 19
|
||||
src.other += using
|
||||
|
||||
@@ -283,6 +294,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "glasses"
|
||||
using.screen_loc = ui_glasses
|
||||
using.slot_id = slot_glasses
|
||||
using.layer = 19
|
||||
src.other += using
|
||||
|
||||
@@ -291,6 +303,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "ears"
|
||||
using.screen_loc = ui_ears
|
||||
using.slot_id = slot_ears
|
||||
using.layer = 19
|
||||
src.other += using
|
||||
|
||||
@@ -299,6 +312,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "hair"
|
||||
using.screen_loc = ui_head
|
||||
using.slot_id = slot_head
|
||||
using.layer = 19
|
||||
src.other += using
|
||||
|
||||
@@ -307,6 +321,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "shoes"
|
||||
using.screen_loc = ui_shoes
|
||||
using.slot_id = slot_shoes
|
||||
using.layer = 19
|
||||
src.other += using
|
||||
|
||||
@@ -315,6 +330,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "belt"
|
||||
using.screen_loc = ui_belt
|
||||
using.slot_id = slot_belt
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -202,7 +202,7 @@
|
||||
return
|
||||
|
||||
|
||||
/mob/living/carbon/metroid/db_click(text, t1)
|
||||
/mob/living/carbon/metroid/attack_ui(slot)
|
||||
return
|
||||
|
||||
/mob/living/carbon/metroid/meteorhit(O as obj)
|
||||
|
||||
@@ -171,6 +171,7 @@
|
||||
using.icon_state = "hand1"
|
||||
using.screen_loc = ui_swaphand1
|
||||
using.layer = 19
|
||||
using.slot_id = slot_l_hand
|
||||
src.adding += using
|
||||
|
||||
using = new src.h_type( src )
|
||||
@@ -179,6 +180,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "hand2"
|
||||
using.screen_loc = ui_swaphand2
|
||||
using.slot_id = slot_r_hand
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
/*
|
||||
@@ -199,6 +201,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "equip"
|
||||
using.screen_loc = ui_monkey_mask
|
||||
using.slot_id = slot_wear_mask
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
|
||||
@@ -208,6 +211,7 @@
|
||||
using.icon = ui_style
|
||||
using.icon_state = "equip"
|
||||
using.screen_loc = ui_back
|
||||
using.slot_id = slot_back
|
||||
using.layer = 19
|
||||
src.adding += using
|
||||
/*
|
||||
|
||||
@@ -184,4 +184,49 @@
|
||||
source.regenerate_icons()
|
||||
target.regenerate_icons()
|
||||
del(src)
|
||||
return
|
||||
|
||||
|
||||
|
||||
//This is an UNSAFE proc. Use mob_can_equip() before calling this one! Or rather use equip_to_slot_if_possible() or advanced_equip_to_slot_if_possible()
|
||||
//set redraw_mob to 0 if you don't wish the hud to be updated - if you're doing it manually in your own proc.
|
||||
/mob/living/carbon/monkey/equip_to_slot(obj/item/W as obj, slot, redraw_mob = 1)
|
||||
if(!slot) return
|
||||
if(!istype(W)) return
|
||||
|
||||
if(W == get_active_hand())
|
||||
u_equip(W)
|
||||
|
||||
switch(slot)
|
||||
if(slot_back)
|
||||
src.back = W
|
||||
W.equipped(src, slot)
|
||||
update_inv_back(redraw_mob)
|
||||
if(slot_wear_mask)
|
||||
src.wear_mask = W
|
||||
W.equipped(src, slot)
|
||||
update_inv_wear_mask(redraw_mob)
|
||||
if(slot_handcuffed)
|
||||
src.handcuffed = W
|
||||
update_inv_handcuffed(redraw_mob)
|
||||
if(slot_legcuffed)
|
||||
src.legcuffed = W
|
||||
W.equipped(src, slot)
|
||||
update_inv_legcuffed(redraw_mob)
|
||||
if(slot_l_hand)
|
||||
src.l_hand = W
|
||||
W.equipped(src, slot)
|
||||
update_inv_l_hand(redraw_mob)
|
||||
if(slot_r_hand)
|
||||
src.r_hand = W
|
||||
W.equipped(src, slot)
|
||||
update_inv_r_hand(redraw_mob)
|
||||
if(slot_in_backpack)
|
||||
W.loc = src.back
|
||||
else
|
||||
usr << "\red You are trying to eqip this item to an unsupported inventory slot. How the heck did you manage that? Stop it..."
|
||||
return
|
||||
|
||||
W.layer = 20
|
||||
|
||||
return
|
||||
@@ -29,22 +29,6 @@
|
||||
/atom/proc/relaymove()
|
||||
return
|
||||
|
||||
/obj/effect/equip_e/process()
|
||||
return
|
||||
|
||||
/obj/effect/equip_e/proc/done()
|
||||
return
|
||||
|
||||
/obj/effect/equip_e/New()
|
||||
if (!ticker)
|
||||
del(src)
|
||||
return
|
||||
spawn(100)
|
||||
del(src)
|
||||
return
|
||||
..()
|
||||
return
|
||||
|
||||
/mob/proc/show_message(msg, type, alt, alt_type)//Message, type of message (1 or 2), alternative message, alt message type (1 or 2)
|
||||
if(!client) return
|
||||
if (type)
|
||||
@@ -111,35 +95,69 @@
|
||||
return 1
|
||||
return
|
||||
|
||||
//Used by monkeys, *chimpers* //TODO: eliminate this convoluted proc it's incredibly shitty. ~Carn
|
||||
/mob/proc/db_click(text, t1)
|
||||
//This proc is called whenever someone clicks an inventory ui slot.
|
||||
/mob/proc/attack_ui(slot)
|
||||
var/obj/item/W = get_active_hand()
|
||||
if(W)
|
||||
if(!istype(W)) return
|
||||
switch(text)
|
||||
if("mask")
|
||||
if(wear_mask)
|
||||
return
|
||||
if( !(W.slot_flags & SLOT_MASK) )
|
||||
return
|
||||
u_equip(W)
|
||||
wear_mask = W
|
||||
W.equipped(src, text)
|
||||
update_inv_wear_mask()
|
||||
if("back")
|
||||
if(back)
|
||||
return
|
||||
if( !(W.slot_flags & SLOT_BACK) )
|
||||
return
|
||||
if( istype(W,/obj/item/weapon/twohanded) && W:wielded ) //TODO: Carn
|
||||
usr << "<span class='warning'>Unwield the [initial(W.name)] first!</span>"
|
||||
return
|
||||
u_equip(W)
|
||||
back = W
|
||||
W.equipped(src, text)
|
||||
update_inv_back()
|
||||
|
||||
if(istype(W))
|
||||
equip_to_slot_if_possible(W, slot)
|
||||
|
||||
//This is a SAFE proc. Use this instead of equip_to_splot()!
|
||||
//set del_on_fail to have it delete W if it fails to equip
|
||||
//set disable_warning to disable the 'you are unable to equip that' warning.
|
||||
//unset redraw_mob to prevent the mob from being redrawn at the end.
|
||||
/mob/proc/equip_to_slot_if_possible(obj/item/W as obj, slot, del_on_fail = 0, disable_warning = 0, redraw_mob = 1)
|
||||
if(!istype(W)) return 0
|
||||
|
||||
if(!W.mob_can_equip(src, slot, disable_warning))
|
||||
if(del_on_fail)
|
||||
del(W)
|
||||
else
|
||||
if(!disable_warning)
|
||||
src << "\red You are unable to equip that." //Only print if del_on_fail is false
|
||||
return 0
|
||||
|
||||
equip_to_slot(W, slot, redraw_mob) //This proc should not ever fail.
|
||||
return 1
|
||||
|
||||
//This is an UNSAFE proc. It merely handles the actual job of equipping. All the checks on whether you can or can't eqip need to be done before! Use mob_can_equip() for that task.
|
||||
//In most cases you will want to use equip_to_slot_if_possible()
|
||||
/mob/proc/equip_to_slot(obj/item/W as obj, slot)
|
||||
return
|
||||
|
||||
//This is just a commonly used configuration for the equip_to_slot_if_possible() proc, used to equip people when the rounds tarts and when events happen and such.
|
||||
/mob/proc/equip_to_slot_or_del(obj/item/W as obj, slot)
|
||||
equip_to_slot_if_possible(W, slot, 1, 1, 0)
|
||||
|
||||
//The list of slots by priority. equip_to_appropriate_slot() uses this list. Doesn't matter if a mob type doesn't have a slot.
|
||||
var/list/slot_equipment_priority = list( \
|
||||
slot_back,\
|
||||
slot_wear_id,\
|
||||
slot_w_uniform,\
|
||||
slot_wear_suit,\
|
||||
slot_wear_mask,\
|
||||
slot_head,\
|
||||
slot_shoes,\
|
||||
slot_gloves,\
|
||||
slot_ears,\
|
||||
slot_glasses,\
|
||||
slot_belt,\
|
||||
slot_s_store,\
|
||||
slot_l_store,\
|
||||
slot_r_store\
|
||||
)
|
||||
|
||||
//puts the item "W" into an appropriate slot in a human's inventory
|
||||
//returns 0 if it cannot, 1 if successful
|
||||
/mob/proc/equip_to_appropriate_slot(obj/item/W)
|
||||
if(!istype(W)) return 0
|
||||
|
||||
for(var/slot in slot_equipment_priority)
|
||||
if(equip_to_slot_if_possible(W, slot, 0, 1, 1)) //del_on_fail = 0; disable_warning = 0; redraw_mob = 1
|
||||
return 1
|
||||
|
||||
return 0
|
||||
|
||||
/mob/proc/reset_view(atom/A)
|
||||
if (client)
|
||||
if (istype(A, /atom/movable))
|
||||
|
||||
@@ -108,8 +108,8 @@ Put (mob/proc)s here that are in dire need of a code cleanup.
|
||||
Cl = H.wear_suit
|
||||
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
|
||||
// world << "Suit pass [passed]"
|
||||
if(passed && isobj(H.slot_w_uniform))
|
||||
Cl = H.slot_w_uniform
|
||||
if(passed && isobj(slot_w_uniform))
|
||||
Cl = slot_w_uniform
|
||||
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
|
||||
// world << "Uniform pass [passed]"
|
||||
if(3)
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
unacidable = 1
|
||||
var/id = 0.0
|
||||
var/obj/master
|
||||
var/slot_id
|
||||
|
||||
/obj/screen/close
|
||||
name = "close"
|
||||
@@ -537,12 +538,12 @@
|
||||
DblClick()
|
||||
return
|
||||
|
||||
/obj/screen/attack_hand(mob/user as mob, using)
|
||||
user.db_click(name, using)
|
||||
/obj/screen/attack_hand(mob/user as mob)
|
||||
user.attack_ui(slot_id)
|
||||
return
|
||||
|
||||
/obj/screen/attack_paw(mob/user as mob, using)
|
||||
user.db_click(name, using)
|
||||
/obj/screen/attack_paw(mob/user as mob)
|
||||
user.attack_ui(slot_id)
|
||||
return
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user