Made some object lists less terrible to read

This commit is contained in:
CitadelStationBot
2017-07-18 09:44:43 -05:00
parent c294d781b6
commit a72962c300
236 changed files with 733 additions and 629 deletions
+1 -1
View File
@@ -562,7 +562,7 @@
self_contained = FALSE // Don't disappear when they're empty
can_change_colour = TRUE
validSurfaces = list(/turf/open/floor,/turf/closed/wall)
validSurfaces = list(/turf/open/floor, /turf/closed/wall)
reagent_contents = list("welding_fuel" = 1, "ethanol" = 1)
pre_noise = TRUE
@@ -122,7 +122,7 @@
var/replaced_something = TRUE
for(var/obj/item/I in S.contents)
if(istype(I,/obj/item/weapon/light))
if(istype(I, /obj/item/weapon/light))
var/obj/item/weapon/light/L = I
found_lightbulbs = TRUE
if(src.uses >= max_uses)
@@ -23,7 +23,7 @@
if(!proximity_flag)
return
if(!istype(A,/obj/machinery/atmospherics/pipe))
if(!istype(A, /obj/machinery/atmospherics/pipe))
return
var/obj/machinery/atmospherics/pipe/P = A
+1 -1
View File
@@ -283,7 +283,7 @@
O.lockcharge = TRUE
O.update_canmove()
else if(istype(W,/obj/item/weapon/pen))
else if(istype(W, /obj/item/weapon/pen))
to_chat(user, "<span class='warning'>You need to use a multitool to name [src]!</span>")
else
return ..()
+1 -1
View File
@@ -55,7 +55,7 @@ GLOBAL_LIST_INIT(rod_recipes, list ( \
if (!R && replace)
user.put_in_hands(new_item)
else if(istype(W,/obj/item/weapon/reagent_containers/food/snacks))
else if(istype(W, /obj/item/weapon/reagent_containers/food/snacks))
var/obj/item/weapon/reagent_containers/food/snacks/S = W
if(amount != 1)
to_chat(user, "<span class='warning'>You must use a single rod!</span>")
@@ -14,7 +14,7 @@
/obj/item/stack/light_w/attackby(obj/item/O, mob/user, params)
if(istype(O,/obj/item/weapon/wirecutters))
if(istype(O, /obj/item/weapon/wirecutters))
var/obj/item/stack/cable_coil/CC = new (user.loc)
CC.amount = 5
CC.add_fingerprint(user)
@@ -86,7 +86,7 @@ GLOBAL_LIST_INIT(sandbag_recipes, list ( \
w_class = WEIGHT_CLASS_TINY
/obj/item/weapon/emptysandbag/attackby(obj/item/W, mob/user, params)
if(istype(W,/obj/item/weapon/ore/glass))
if(istype(W, /obj/item/weapon/ore/glass))
to_chat(user, "<span class='notice'>You fill the sandbag.</span>")
var/obj/item/stack/sheet/mineral/sandbags/I = new /obj/item/stack/sheet/mineral/sandbags
qdel(src)
@@ -312,7 +312,7 @@ GLOBAL_LIST_INIT(plastitanium_recipes, list ( \
origin_tech = "materials=1"
GLOBAL_LIST_INIT(snow_recipes, list ( \
new/datum/stack_recipe("Snow Wall",/turf/closed/wall/mineral/snow, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Snow Wall", /turf/closed/wall/mineral/snow, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Snowman", /obj/structure/statue/snow/snowman, 5, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("Snowball", /obj/item/toy/snowball, 1), \
))
@@ -20,7 +20,7 @@
state = 0 //fine
/obj/item/stack/tile/light/attackby(obj/item/O, mob/user, params)
if(istype(O,/obj/item/weapon/crowbar))
if(istype(O, /obj/item/weapon/crowbar))
new/obj/item/stack/sheet/metal(user.loc)
amount--
new/obj/item/stack/light_w(user.loc)
+1 -1
View File
@@ -518,7 +518,7 @@ GLOBAL_LIST_INIT(RPD_recipes, list(
/obj/item/weapon/pipe_dispenser/pre_attackby(atom/A, mob/user)
if(!user.IsAdvancedToolUser() || istype(A,/turf/open/space/transit))
if(!user.IsAdvancedToolUser() || istype(A, /turf/open/space/transit))
return ..()
//make sure what we're clicking is valid for the current mode
@@ -60,7 +60,7 @@
//So this is a workaround. This also makes more sense from an IC standpoint. ~Carn
if(user.client && (target in user.client.screen))
to_chat(user, "<span class='warning'>You need to take that [target.name] off before cleaning it!</span>")
else if(istype(target,/obj/effect/decal/cleanable))
else if(istype(target, /obj/effect/decal/cleanable))
user.visible_message("[user] begins to scrub \the [target.name] out with [src].", "<span class='warning'>You begin to scrub \the [target.name] out with [src]...</span>")
if(do_after(user, src.cleanspeed, target = target))
to_chat(user, "<span class='notice'>You scrub \the [target.name] out.</span>")
@@ -115,7 +115,7 @@
update_icon()
return
else if(istype(W,/obj/item/weapon/tank/internals/plasma))
else if(istype(W, /obj/item/weapon/tank/internals/plasma))
if(ptank)
if(user.transferItemToLoc(W,src))
ptank.forceMove(get_turf(src))
+1 -1
View File
@@ -72,7 +72,7 @@
var/gift_type = pick(gift_type_list)
if(!ispath(gift_type,/obj/item))
if(!ispath(gift_type, /obj/item))
return
qdel(src)
@@ -193,7 +193,7 @@
name = "large grenade"
desc = "A custom made large grenade. It affects a larger area."
icon_state = "large_grenade"
allowed_containers = list(/obj/item/weapon/reagent_containers/glass,/obj/item/weapon/reagent_containers/food/condiment,
allowed_containers = list(/obj/item/weapon/reagent_containers/glass, /obj/item/weapon/reagent_containers/food/condiment,
/obj/item/weapon/reagent_containers/food/drinks)
origin_tech = "combat=3;engineering=3"
affected_area = 5
@@ -228,7 +228,7 @@
return
if((istype(AM, /obj/item/weapon/storage/)) && !((istype(AM, /obj/item/weapon/storage/secure)) || (istype(AM, /obj/item/weapon/storage/lockbox)))) //If its storage but not secure storage OR a lockbox, then place it inside.
return
if((istype(AM,/obj/item/weapon/storage/secure)) || (istype(AM, /obj/item/weapon/storage/lockbox)))
if((istype(AM, /obj/item/weapon/storage/secure)) || (istype(AM, /obj/item/weapon/storage/lockbox)))
var/obj/item/weapon/storage/secure/S = AM
if(!S.locked) //Literal hacks, this works for lockboxes despite incorrect type casting, because they both share the locked var. But if its unlocked, place it inside, otherwise PLANTING C4!
return
@@ -56,7 +56,7 @@
imp_type = /obj/item/weapon/implant/chem
/obj/item/weapon/implantcase/chem/attackby(obj/item/weapon/W, mob/user, params)
if(istype(W,/obj/item/weapon/reagent_containers/syringe) && imp)
if(istype(W, /obj/item/weapon/reagent_containers/syringe) && imp)
W.afterattack(imp, user, TRUE, params)
return TRUE
else
+2 -2
View File
@@ -60,7 +60,7 @@
/obj/item/weapon/inducer/attackby(obj/item/weapon/W, mob/user)
if(istype(W,/obj/item/weapon/screwdriver))
if(istype(W, /obj/item/weapon/screwdriver))
playsound(src, W.usesound, 50, 1)
if(!opened)
to_chat(user, "<span class='notice'>You unscrew the battery compartment.</span>")
@@ -72,7 +72,7 @@
opened = FALSE
update_icon()
return
if(istype(W,/obj/item/weapon/stock_parts/cell))
if(istype(W, /obj/item/weapon/stock_parts/cell))
if(opened)
if(!cell)
if(!user.transferItemToLoc(W, src))
@@ -45,7 +45,7 @@
step_towards(A,pull)
else if(ishuman(X))
var/mob/living/carbon/human/H = X
if(istype(H.shoes,/obj/item/clothing/shoes/magboots))
if(istype(H.shoes, /obj/item/clothing/shoes/magboots))
var/obj/item/clothing/shoes/magboots/M = H.shoes
if(M.magpulse)
continue
@@ -305,7 +305,7 @@
/obj/item/weapon/storage/backpack/satchel/flat/secret/Initialize()
..()
if(isfloorturf(loc) && !istype(loc,/turf/open/floor/plating/))
if(isfloorturf(loc) && !istype(loc, /turf/open/floor/plating/))
hide(1)
/obj/item/weapon/storage/backpack/satchel/flat/secret/hide(intact)
@@ -112,7 +112,7 @@
max_combined_w_class = 100 //Doesn't matter what this is, so long as it's more or equal to storage_slots * plants.w_class
max_w_class = WEIGHT_CLASS_NORMAL
w_class = WEIGHT_CLASS_TINY
can_hold = list(/obj/item/weapon/reagent_containers/food/snacks/grown,/obj/item/seeds,/obj/item/weapon/grown,/obj/item/weapon/reagent_containers/honeycomb)
can_hold = list(/obj/item/weapon/reagent_containers/food/snacks/grown, /obj/item/seeds, /obj/item/weapon/grown, /obj/item/weapon/reagent_containers/honeycomb)
resistance_flags = FLAMMABLE
////////
@@ -152,7 +152,7 @@
allow_quick_empty = 1 // this function is superceded
/obj/item/weapon/storage/bag/sheetsnatcher/can_be_inserted(obj/item/W, stop_messages = 0)
if(!istype(W,/obj/item/stack/sheet) || istype(W,/obj/item/stack/sheet/mineral/sandstone) || istype(W,/obj/item/stack/sheet/mineral/wood))
if(!istype(W, /obj/item/stack/sheet) || istype(W, /obj/item/stack/sheet/mineral/sandstone) || istype(W, /obj/item/stack/sheet/mineral/wood))
if(!stop_messages)
to_chat(usr, "The snatcher does not accept [W].")
return 0 //I don't care, but the existing code rejects them for not being "sheets" *shrug* -Sayu
@@ -144,7 +144,7 @@
icon = 'icons/obj/chemical.dmi'
item_state = "contsolid"
w_class = WEIGHT_CLASS_SMALL
can_hold = list(/obj/item/weapon/reagent_containers/pill,/obj/item/weapon/dice)
can_hold = list(/obj/item/weapon/reagent_containers/pill, /obj/item/weapon/dice)
allow_quick_gather = 1
use_to_pickup = 1
@@ -34,7 +34,7 @@
if(!over_object)
return
if (istype(usr.loc,/obj/mecha)) // stops inventory actions in a mech
if (istype(usr.loc, /obj/mecha)) // stops inventory actions in a mech
return
// this must come before the screen objects only block, dunno why it wasn't before
@@ -73,10 +73,10 @@
return ..()
/obj/item/weapon/storage/wallet/random/PopulateContents()
var/item1_type = pick( /obj/item/stack/spacecash/c10,/obj/item/stack/spacecash/c100,/obj/item/stack/spacecash/c1000,/obj/item/stack/spacecash/c20,/obj/item/stack/spacecash/c200,/obj/item/stack/spacecash/c50, /obj/item/stack/spacecash/c500)
var/item1_type = pick( /obj/item/stack/spacecash/c10, /obj/item/stack/spacecash/c100, /obj/item/stack/spacecash/c1000, /obj/item/stack/spacecash/c20, /obj/item/stack/spacecash/c200, /obj/item/stack/spacecash/c50, /obj/item/stack/spacecash/c500)
var/item2_type
if(prob(50))
item2_type = pick( /obj/item/stack/spacecash/c10,/obj/item/stack/spacecash/c100,/obj/item/stack/spacecash/c1000,/obj/item/stack/spacecash/c20,/obj/item/stack/spacecash/c200,/obj/item/stack/spacecash/c50, /obj/item/stack/spacecash/c500)
item2_type = pick( /obj/item/stack/spacecash/c10, /obj/item/stack/spacecash/c100, /obj/item/stack/spacecash/c1000, /obj/item/stack/spacecash/c20, /obj/item/stack/spacecash/c200, /obj/item/stack/spacecash/c50, /obj/item/stack/spacecash/c500)
var/item3_type = pick( /obj/item/weapon/coin/silver, /obj/item/weapon/coin/silver, /obj/item/weapon/coin/gold, /obj/item/weapon/coin/iron, /obj/item/weapon/coin/iron, /obj/item/weapon/coin/iron )
spawn(2)
@@ -76,7 +76,7 @@
return 1
/obj/item/weapon/tank/jetpack/suicide_act(mob/user)
if (istype(user,/mob/living/carbon/human/))
if (istype(user, /mob/living/carbon/human/))
var/mob/living/carbon/human/H = user
H.forcesay("WHAT THE FUCK IS CARBON DIOXIDE?")
H.visible_message("<span class='suicide'>[user] is suffocating [user.p_them()]self with [src]! It looks like [user.p_they()] didn't read what that jetpack says!</span>")
@@ -231,7 +231,7 @@
var/pressure = air_contents.return_pressure()
if(pressure > TANK_FRAGMENT_PRESSURE)
if(!istype(src.loc,/obj/item/device/transfer_valve))
if(!istype(src.loc, /obj/item/device/transfer_valve))
message_admins("Explosive tank rupture! Last key to touch the tank was [src.fingerprintslast].")
log_game("Explosive tank rupture! Last key to touch the tank was [src.fingerprintslast].")
//to_chat(world, "\blue[x],[y] tank is exploding: [pressure] kPa")
@@ -246,7 +246,7 @@
//to_chat(world, "\blue Exploding Pressure: [pressure] kPa, intensity: [range]")
explosion(epicenter, round(range*0.25), round(range*0.5), round(range), round(range*1.5))
if(istype(src.loc,/obj/item/device/transfer_valve))
if(istype(src.loc, /obj/item/device/transfer_valve))
qdel(src.loc)
else
qdel(src)
+2 -2
View File
@@ -225,10 +225,10 @@
if(!proximity)
return
if(wielded) //destroys windows and grilles in one hit
if(istype(A,/obj/structure/window))
if(istype(A, /obj/structure/window))
var/obj/structure/window/W = A
W.take_damage(200, BRUTE, "melee", 0)
else if(istype(A,/obj/structure/grille))
else if(istype(A, /obj/structure/grille))
var/obj/structure/grille/G = A
G.take_damage(40, BRUTE, "melee", 0)