Merge branch 'master' into upstream-merge-31631

This commit is contained in:
LetterJay
2017-10-13 08:31:13 -04:00
committed by GitHub
38 changed files with 308 additions and 50 deletions
+1 -1
View File
@@ -450,7 +450,7 @@ GLOBAL_LIST_EMPTY(teleportlocs)
if(!L.client.played)
SEND_SOUND(L, sound(sound, repeat = 0, wait = 0, volume = 25, channel = CHANNEL_AMBIENCE))
L.client.played = TRUE
addtimer(CALLBACK(L.client, /client/proc/ResetAmbiencePlayed), 600)
addtimer(CALLBACK(L.client, /client/proc/ResetAmbiencePlayed), 600)
/client/proc/ResetAmbiencePlayed()
played = FALSE
@@ -31,8 +31,5 @@
if(cell && (cell.charge / cell.maxcharge > COG_MAX_SIPHON_THRESHOLD))
cell.use(1)
adjust_clockwork_power(1) //Power is shared, so only do it once; this runs very quickly so it's about 1W/second
if(prob(1))
playsound(apc, 'sound/machines/clockcult/steam_whoosh.ogg', 10, TRUE)
new/obj/effect/temp_visual/steam(get_turf(apc), pick(GLOB.cardinals))
#undef COG_MAX_SIPHON_THRESHOLD
@@ -231,6 +231,13 @@
quickbind = TRUE
quickbind_desc = "Creates a stargazer, which generates power when near starlight."
/datum/clockwork_scripture/create_object/stargazer/check_special_requirements()
var/area/A = get_area(invoker)
if(A.outdoors || A.map_name == "Space" || !A.blob_allowed)
to_chat(invoker, "<span class='danger'>Stargazers can't be built off-station.</span>")
return
return TRUE
//Integration Cog: Creates an integration cog that can be inserted into APCs to passively siphon power.
/datum/clockwork_scripture/create_object/integration_cog
@@ -50,6 +50,10 @@
if(isspaceturf(T))
has_starlight = TRUE
break
if(has_starlight && anchored)
var/area/A = get_area(src)
if(A.outdoors || A.map_name == "Space" || !A.blob_allowed)
has_starlight = FALSE
if(old_status != has_starlight)
if(has_starlight)
visible_message("<span class='nzcrentr_small'>[src] hums and shines brilliantly!</span>")
@@ -67,6 +67,8 @@
push_over()
/obj/item/cardboard_cutout/bullet_act(obj/item/projectile/P)
if(istype(P, /obj/item/projectile/bullet/reusable))
P.on_hit(src, 0)
visible_message("<span class='danger'>[src] has been hit by [P]!</span>")
playsound(src, 'sound/weapons/slice.ogg', 50, 1)
if(prob(P.damage))
+10 -14
View File
@@ -2,11 +2,15 @@
name = "plastic explosive"
desc = "Used to put holes in specific areas without too much extra hole."
icon_state = "plastic-explosive0"
item_state = "plasticx"
item_state = "plastic-explosive"
lefthand_file = 'icons/mob/inhands/weapons/bombs_lefthand.dmi'
righthand_file = 'icons/mob/inhands/weapons/bombs_righthand.dmi'
flags_1 = NOBLUDGEON_1
flags_2 = NO_EMP_WIRES_2
det_time = 10
display_timer = 0
w_class = WEIGHT_CLASS_SMALL
origin_tech = "syndicate=1"
var/atom/target = null
var/mutable_appearance/plastic_overlay
var/obj/item/device/assembly_holder/nadeassembly = null
@@ -16,7 +20,7 @@
var/boom_sizes = list(0, 0, 3)
/obj/item/grenade/plastic/New()
plastic_overlay = mutable_appearance(icon, "[item_state]2")
plastic_overlay = mutable_appearance(icon, "[item_state]2", HIGH_OBJ_LAYER)
..()
/obj/item/grenade/plastic/Destroy()
@@ -112,7 +116,7 @@
message_admins("[ADMIN_LOOKUPFLW(user)] planted [name] on [target.name] at [ADMIN_COORDJMP(target)] with [det_time] second fuse",0,1)
log_game("[key_name(user)] planted [name] on [target.name] at [COORD(src)] with [det_time] second fuse")
target.add_overlay(plastic_overlay, 1)
target.add_overlay(plastic_overlay, TRUE)
if(!nadeassembly)
to_chat(user, "<span class='notice'>You plant the bomb. Timer counting down from [det_time].</span>")
addtimer(CALLBACK(src, .proc/prime), det_time*10)
@@ -154,21 +158,12 @@
name = "C4"
desc = "Used to put holes in specific areas without too much extra hole. A saboteur's favorite."
gender = PLURAL
icon = 'icons/obj/grenade.dmi'
icon_state = "plastic-explosive0"
item_state = "plasticx"
lefthand_file = 'icons/mob/inhands/weapons/bombs_lefthand.dmi'
righthand_file = 'icons/mob/inhands/weapons/bombs_righthand.dmi'
flags_1 = NOBLUDGEON_1
w_class = WEIGHT_CLASS_SMALL
origin_tech = "syndicate=1"
var/timer = 10
var/open_panel = 0
/obj/item/grenade/plastic/c4/New()
wires = new /datum/wires/explosive/c4(src)
..()
plastic_overlay = mutable_appearance(icon, "plastic-explosive2")
/obj/item/grenade/plastic/c4/Destroy()
qdel(wires)
@@ -234,14 +229,14 @@
if(!user.temporarilyRemoveItemFromInventory(src))
return
src.target = AM
forceMove(null)
moveToNullspace()
var/message = "[ADMIN_LOOKUPFLW(user)] planted [name] on [target.name] at [ADMIN_COORDJMP(target)] with [timer] second fuse"
GLOB.bombers += message
message_admins(message,0,1)
log_game("[key_name(user)] planted [name] on [target.name] at [COORD(target)] with [timer] second fuse")
target.add_overlay(plastic_overlay, 1)
target.add_overlay(plastic_overlay, TRUE)
to_chat(user, "<span class='notice'>You plant the bomb. Timer counting down from [timer].</span>")
addtimer(CALLBACK(src, .proc/explode), timer * 10)
@@ -272,5 +267,6 @@
desc = "A shaped high-explosive breaching charge. Designed to ensure user safety and wall nonsafety."
icon_state = "plasticx40"
item_state = "plasticx4"
gender = PLURAL
directional = TRUE
boom_sizes = list(0, 2, 5)
+4 -2
View File
@@ -65,10 +65,12 @@
playsound(src.loc, 'sound/items/bikehorn.ogg', 50, 1)
/obj/item/target/bullet_act(obj/item/projectile/P)
if(istype(P, /obj/item/projectile/bullet/reusable)) // If it's a foam dart, don't bother with any of this other shit
return P.on_hit(src, 0)
var/p_x = P.p_x + pick(0,0,0,0,0,-1,1) // really ugly way of coding "sometimes offset P.p_x!"
var/p_y = P.p_y + pick(0,0,0,0,0,-1,1)
var/decaltype = DECALTYPE_SCORCH
if(istype(/obj/item/projectile/bullet, P))
if(istype(P, /obj/item/projectile/bullet))
decaltype = DECALTYPE_BULLET
var/icon/C = icon(icon,icon_state)
if(C.GetPixel(p_x, p_y) && P.original == src && overlays.len <= 35) // if the located pixel isn't blank (null)
@@ -92,4 +94,4 @@
return -1
#undef DECALTYPE_SCORCH
#undef DECALTYPE_BULLET
#undef DECALTYPE_BULLET
+2 -8
View File
@@ -116,18 +116,12 @@ GLOBAL_PROTECT(security_mode)
/world/Topic(T, addr, master, key)
var/static/list/topic_handlers = TopicHandlers()
var/list/input = params2list(T)
var/datum/world_topic/handler
for(var/I in topic_handlers)
<<<<<<< HEAD
if(input[I])
handler = I
=======
if(I in input)
handler = topic_handlers[I]
>>>>>>> e4a63bb... Merge pull request #31631 from tgstation/Cyberboss-patch-2
break
break
if((!handler || initial(handler.log)) && config && CONFIG_GET(flag/log_world_topic))
WRITE_FILE(GLOB.world_game_log, "TOPIC: \"[T]\", from:[addr], master:[master], key:[key]")
@@ -138,7 +132,7 @@ GLOBAL_PROTECT(security_mode)
return
handler = new handler()
return handler.Run(input)
return handler.TryRun(input)
/world/proc/AnnouncePR(announcement, list/payload)
var/static/list/PRcounts = list() //PR id -> number of times announced this round