mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-11 15:14:27 +01:00
Bugfixes:
◦ Some head gear (nurse masks, kitty ears...) no longer block CPR. (Issue 167)
◦ DNA Scanners no longer attempt to empty their contents whenever something enters them. This fixes the issue with constructed scanners puking out the circuitry they were made with. (Issue 169)
◦ You can longer /me emote when you've been paralyzed by Zombie Powder. (Issue 168)
◦ Fixed some problems with MMIs / Robots / pAIs being able to understand eachother.
◦ You can put items, that are not clothing/under or clothing/suit, on food trays. How it works is it loops through all acceptable items in the location and adds them to its overlays and a special list variable. I had to change the way mob/drop_item() works a bit. Trays have a maximum capacity, and items of a larger w_class take up more capacity.
◦ Slippery items like banana peels and soap have been nerfed significantly.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2335 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -2,13 +2,13 @@
|
||||
name = "Rabbit Ears"
|
||||
desc = "Wearing these makes you looks useless, and only good for your sex appeal."
|
||||
icon_state = "bunny"
|
||||
flags = FPRINT | TABLEPASS | HEADSPACE
|
||||
flags = FPRINT | TABLEPASS
|
||||
|
||||
/obj/item/clothing/head/kitty
|
||||
name = "Kitty Ears"
|
||||
desc = "A pair of kitty ears. Meow!"
|
||||
icon_state = "kitty"
|
||||
flags = FPRINT | TABLEPASS | HEADSPACE
|
||||
flags = FPRINT | TABLEPASS
|
||||
var/icon/mob
|
||||
var/icon/mob2
|
||||
|
||||
|
||||
@@ -261,7 +261,7 @@
|
||||
desc = "An amish looking helmet"
|
||||
icon_state = "tophat"
|
||||
item_state = "that"
|
||||
flags = FPRINT|TABLEPASS|HEADSPACE
|
||||
flags = FPRINT|TABLEPASS
|
||||
armor = list(melee = 0, bullet = 0, laser = 2,energy = 2, bomb = 0, bio = 0, rad = 0)
|
||||
|
||||
/obj/item/clothing/head/helmet/greenbandana
|
||||
@@ -269,7 +269,7 @@
|
||||
desc = "A green bandana with some fine nanotech lining."
|
||||
icon_state = "greenbandana"
|
||||
item_state = "greenbandana"
|
||||
flags = FPRINT|TABLEPASS|HEADSPACE
|
||||
flags = FPRINT|TABLEPASS
|
||||
armor = list(melee = 5, bullet = 5, laser = 5,energy = 5, bomb = 15, bio = 15, rad = 15)
|
||||
|
||||
/obj/item/clothing/head/helmet/riot
|
||||
@@ -303,4 +303,4 @@
|
||||
name = "Nurse Hat"
|
||||
desc = "Smokin'"
|
||||
icon_state = "nursehat"
|
||||
flags = FPRINT|TABLEPASS|HEADSPACE
|
||||
flags = FPRINT|TABLEPASS
|
||||
@@ -1249,6 +1249,7 @@
|
||||
w_class = 3.0
|
||||
flags = FPRINT | TABLEPASS | CONDUCT
|
||||
m_amt = 3000
|
||||
/* // NOPE
|
||||
var/food_total= 0
|
||||
var/burger_amt = 0
|
||||
var/cheese_amt = 0
|
||||
@@ -1262,6 +1263,11 @@
|
||||
var/meatbreadslice_amt = 0
|
||||
var/salad_amt = 0
|
||||
var/miscfood_amt = 0
|
||||
*/
|
||||
var/list/carrying = list() // List of things on the tray. - Doohl
|
||||
var/max_carry = 10 // w_class = 1 -- takes up 1
|
||||
// w_class = 2 -- takes up 3
|
||||
// w_class = 3 -- takes up 5
|
||||
|
||||
|
||||
/obj/item/weapon/kitchen/utensil
|
||||
|
||||
+6
-2
@@ -546,10 +546,12 @@
|
||||
usr.loc = src
|
||||
src.occupant = usr
|
||||
src.icon_state = "scanner_1"
|
||||
for(var/obj/O in src)
|
||||
/*
|
||||
for(var/obj/O in src) // THIS IS P. STUPID -- LOVE, DOOHL
|
||||
//O = null
|
||||
del(O)
|
||||
//Foreach goto(124)
|
||||
*/
|
||||
src.add_fingerprint(usr)
|
||||
return
|
||||
|
||||
@@ -569,9 +571,11 @@
|
||||
M.loc = src
|
||||
src.occupant = M
|
||||
src.icon_state = "scanner_1"
|
||||
for(var/obj/O in src)
|
||||
/*
|
||||
for(var/obj/O in src) // this is stupid too
|
||||
O.loc = src.loc
|
||||
//Foreach goto(154)
|
||||
*/
|
||||
src.add_fingerprint(user)
|
||||
//G = null
|
||||
|
||||
|
||||
@@ -16,8 +16,8 @@ BIKE HORN
|
||||
M.pulling = null
|
||||
M << "\blue You slipped on the [name]!"
|
||||
playsound(src.loc, 'slip.ogg', 50, 1, -3)
|
||||
M.stunned = 8
|
||||
M.weakened = 5
|
||||
M.stunned = 4
|
||||
M.weakened = 2
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato/HasEntered(AM as mob|obj)
|
||||
if (istype(AM, /mob/living/carbon))
|
||||
@@ -28,8 +28,8 @@ BIKE HORN
|
||||
M.pulling = null
|
||||
M << "\blue You slipped on the [name]!"
|
||||
playsound(src.loc, 'slip.ogg', 50, 1, -3)
|
||||
M.stunned = 10
|
||||
M.weakened = 7
|
||||
M.stunned = 8
|
||||
M.weakened = 5
|
||||
|
||||
/obj/item/weapon/soap/HasEntered(AM as mob|obj) //EXACTLY the same as bananapeel for now, so it makes sense to put it in the same dm -- Urist
|
||||
if (istype(AM, /mob/living/carbon))
|
||||
@@ -40,8 +40,8 @@ BIKE HORN
|
||||
M.pulling = null
|
||||
M << "\blue You slipped on the [name]!"
|
||||
playsound(src.loc, 'slip.ogg', 50, 1, -3)
|
||||
M.stunned = 8
|
||||
M.weakened = 5
|
||||
M.stunned = 3
|
||||
M.weakened = 2
|
||||
|
||||
/obj/item/weapon/soap/afterattack(atom/target, mob/user as mob)
|
||||
if(istype(target,/obj/effect/decal/cleanable))
|
||||
|
||||
@@ -93,6 +93,20 @@ KNIFE
|
||||
///////////////////////////////// TRAY -Agouri :3 ///////////////////////////////////////////////
|
||||
|
||||
/obj/item/weapon/tray/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob)
|
||||
|
||||
// Drop all the things. All of them.
|
||||
overlays = null
|
||||
for(var/obj/item/I in carrying)
|
||||
I.loc = M.loc
|
||||
carrying.Remove(I)
|
||||
if(isturf(I.loc))
|
||||
spawn()
|
||||
for(var/i = 1, i <= rand(1,2), i++)
|
||||
if(I)
|
||||
step(I, pick(NORTH,SOUTH,EAST,WEST))
|
||||
sleep(rand(2,4))
|
||||
|
||||
|
||||
if((user.mutations & CLOWN) && prob(50)) //What if he's a clown?
|
||||
M << "\red You accidentally slam yourself with the [src]!"
|
||||
M.weakened += 1
|
||||
@@ -123,12 +137,12 @@ KNIFE
|
||||
else
|
||||
M.take_organ_damage(5)
|
||||
if(prob(50))
|
||||
//playsound(M, 'trayhit1.wav', 50, 1)
|
||||
playsound(M, 'trayhit1.ogg', 50, 1)
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red <B>[] slams [] with the tray!</B>", user, M), 1)
|
||||
return
|
||||
else
|
||||
//playsound(M, 'trayhit2.wav', 50, 1) //we applied the damage, we played the sound, we showed the appropriate messages. Time to return and stop the proc
|
||||
playsound(M, 'trayhit2.ogg', 50, 1) //we applied the damage, we played the sound, we showed the appropriate messages. Time to return and stop the proc
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red <B>[] slams [] with the tray!</B>", user, M), 1)
|
||||
return
|
||||
@@ -151,11 +165,11 @@ KNIFE
|
||||
location.add_blood(H)
|
||||
|
||||
if(prob(50))
|
||||
//playsound(M, 'trayhit1.wav', 50, 1)
|
||||
playsound(M, 'trayhit1.ogg', 50, 1)
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red <B>[] slams [] with the tray!</B>", user, M), 1)
|
||||
else
|
||||
//playsound(M, 'trayhit2.wav', 50, 1) //sound playin'
|
||||
playsound(M, 'trayhit2.ogg', 50, 1) //sound playin'
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red <B>[] slams [] with the tray!</B>", user, M), 1)
|
||||
if(prob(10))
|
||||
@@ -175,11 +189,11 @@ KNIFE
|
||||
location.add_blood(H)
|
||||
|
||||
if(prob(50))
|
||||
// playsound(M, 'trayhit1.ogg', 50, 1)
|
||||
playsound(M, 'trayhit1.ogg', 50, 1)
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red <B>[] slams [] in the face with the tray!</B>", user, M), 1)
|
||||
else
|
||||
//playsound(M, 'trayhit2.ogg', 50, 1) //sound playin' again
|
||||
playsound(M, 'trayhit2.ogg', 50, 1) //sound playin' again
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red <B>[] slams [] in the face with the tray!</B>", user, M), 1)
|
||||
if(prob(30))
|
||||
@@ -193,6 +207,73 @@ KNIFE
|
||||
return
|
||||
return
|
||||
|
||||
|
||||
/*
|
||||
===============~~~~~================================~~~~~====================
|
||||
= =
|
||||
= Code for trays carrying things. By Doohl for Doohl erryday Doohl Doohl~ =
|
||||
= =
|
||||
===============~~~~~================================~~~~~====================
|
||||
*/
|
||||
/obj/item/weapon/tray/proc/calc_carry()
|
||||
// calculate the weight of the items on the tray
|
||||
var/val = 0 // value to return
|
||||
|
||||
for(var/obj/item/I in carrying)
|
||||
if(I.w_class == 1.0)
|
||||
val ++
|
||||
else if(I.w_class == 2.0)
|
||||
val += 3
|
||||
else
|
||||
val += 5
|
||||
|
||||
return val
|
||||
|
||||
/obj/item/weapon/tray/pickup(mob/user)
|
||||
overlays = null
|
||||
|
||||
if(!isturf(loc))
|
||||
return
|
||||
|
||||
for(var/obj/item/I in loc)
|
||||
if( I != src && !I.anchored && !istype(I, /obj/item/clothing/under) && !istype(I, /obj/item/clothing/suit) && !istype(I, /obj/item/projectile) )
|
||||
var/add = 0
|
||||
if(I.w_class == 1.0)
|
||||
add = 1
|
||||
else if(I.w_class == 2.0)
|
||||
add = 3
|
||||
else
|
||||
add = 5
|
||||
if(calc_carry() + add >= max_carry)
|
||||
break
|
||||
|
||||
I.loc = src
|
||||
carrying.Add(I)
|
||||
overlays += image("icon" = I.icon, "icon_state" = I.icon_state, "layer" = 30 + I.layer)
|
||||
|
||||
/obj/item/weapon/tray/dropped(mob/user)
|
||||
var/foundtable = 0
|
||||
for(var/obj/structure/table/T in loc)
|
||||
foundtable = 1
|
||||
break
|
||||
|
||||
overlays = null
|
||||
|
||||
for(var/obj/item/I in carrying)
|
||||
I.loc = loc
|
||||
carrying.Remove(I)
|
||||
if(!foundtable && isturf(loc))
|
||||
// if no table, presume that the person just shittily dropped the tray on the ground and made a mess everywhere!
|
||||
spawn()
|
||||
for(var/i = 1, i <= rand(1,2), i++)
|
||||
if(I)
|
||||
step(I, pick(NORTH,SOUTH,EAST,WEST))
|
||||
sleep(rand(2,4))
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////////////////
|
||||
//Enough with the violent stuff, here's what happens if you try putting food on it
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -129,6 +129,20 @@
|
||||
user << "\red This [W] is too big for this [src]"
|
||||
return
|
||||
|
||||
if(istype(W, /obj/item/weapon/tray))
|
||||
var/obj/item/weapon/tray/T = W
|
||||
if(T.calc_carry() > 0)
|
||||
if(prob(85))
|
||||
user << "\red The tray won't fit in [src]."
|
||||
return
|
||||
else
|
||||
|
||||
W.loc = user.loc
|
||||
if ((user.client && user.s_active != src))
|
||||
user.client.screen -= W
|
||||
W.dropped(user)
|
||||
user << "\red God damnit!"
|
||||
|
||||
var/sum_w_class = W.w_class
|
||||
for(var/obj/item/I in contents)
|
||||
sum_w_class += I.w_class //Adds up the combined w_classes which will be in the storage item if the item is added to it.
|
||||
@@ -138,7 +152,7 @@
|
||||
return
|
||||
|
||||
if ( W.w_class >= src.w_class && (istype(W, /obj/item/weapon/storage)))
|
||||
user << "\red The [src] cannot hold [W] as it's a storage item of the same size."
|
||||
user << "\red The [src] cannot hold [W] as it's a storage item of the same size."
|
||||
return //To prevent the stacking of the same sized items.
|
||||
|
||||
user.u_equip(W)
|
||||
|
||||
@@ -155,8 +155,8 @@ TABLE AND RACK OBJECT INTERATIONS
|
||||
del(src)
|
||||
return
|
||||
|
||||
user.drop_item()
|
||||
if(W && W.loc) W.loc = src.loc
|
||||
user.drop_item(src)
|
||||
//if(W && W.loc) W.loc = src.loc // Unnecessary - see: mob/proc/drop_item(atom) - Doohl
|
||||
return
|
||||
|
||||
|
||||
@@ -197,8 +197,8 @@ TABLE AND RACK OBJECT INTERATIONS
|
||||
del(src)
|
||||
return
|
||||
|
||||
user.drop_item()
|
||||
if(W && W.loc) W.loc = src.loc
|
||||
user.drop_item(src)
|
||||
//if(W && W.loc) W.loc = src.loc
|
||||
return
|
||||
|
||||
|
||||
@@ -239,8 +239,8 @@ TABLE AND RACK OBJECT INTERATIONS
|
||||
return
|
||||
if(isrobot(user))
|
||||
return
|
||||
user.drop_item()
|
||||
if(W && W.loc) W.loc = src.loc
|
||||
user.drop_item(src)
|
||||
//if(W && W.loc) W.loc = src.loc
|
||||
return
|
||||
|
||||
if (istype(W, /obj/item/weapon/wrench))
|
||||
@@ -267,8 +267,8 @@ TABLE AND RACK OBJECT INTERATIONS
|
||||
del(src)
|
||||
return
|
||||
|
||||
user.drop_item()
|
||||
if(W && W.loc) W.loc = src.loc
|
||||
user.drop_item(src)
|
||||
//if(W && W.loc) W.loc = src.loc
|
||||
return
|
||||
|
||||
//RACKS
|
||||
|
||||
@@ -20,8 +20,12 @@
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/decoy))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/pai))
|
||||
return 1
|
||||
if (istype(other, /mob/living/silicon/robot))
|
||||
return 1
|
||||
if (istype(other, /mob/living/carbon/human))
|
||||
return 1
|
||||
if (istype(other, /mob/living/carbon/metroid))
|
||||
return 1
|
||||
return ..()
|
||||
@@ -62,6 +62,10 @@
|
||||
message = "<B>[src]</B> [input]"
|
||||
|
||||
if ("me")
|
||||
if (muted || silent)
|
||||
return
|
||||
if (stat)
|
||||
return
|
||||
if(!(message))
|
||||
return
|
||||
else
|
||||
|
||||
@@ -159,7 +159,7 @@
|
||||
T.Entered(item)
|
||||
return
|
||||
|
||||
/mob/proc/drop_item()
|
||||
/mob/proc/drop_item(var/atom/target)
|
||||
var/obj/item/W = equipped()
|
||||
|
||||
if (W)
|
||||
@@ -178,7 +178,10 @@
|
||||
if (client)
|
||||
client.screen -= W
|
||||
if (W)
|
||||
W.loc = loc
|
||||
if(target)
|
||||
W.loc = target.loc
|
||||
else
|
||||
W.loc = loc
|
||||
W.dropped(src)
|
||||
if (W)
|
||||
W.layer = initial(W.layer)
|
||||
|
||||
Reference in New Issue
Block a user