mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-31 07:57:47 +01:00
-Added photo support for newscasters, news feeds and wanted posters.
-You can now emag door control buttons to remove access from them. -Removed out of place shutters in the RnD's chemistry desk. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5279 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -24,6 +24,10 @@
|
||||
*/
|
||||
if(istype(W, /obj/item/device/detective_scanner))
|
||||
return
|
||||
if(istype(W, /obj/item/weapon/card/emag))
|
||||
req_access = list()
|
||||
req_one_access = list()
|
||||
playsound(src.loc, "sparks", 100, 1)
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/door_control/attack_hand(mob/user as mob)
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
var/backup_body =""
|
||||
var/backup_author =""
|
||||
var/is_admin_message = 0
|
||||
var/icon/img = null
|
||||
|
||||
/datum/feed_channel
|
||||
var/channel_name=""
|
||||
@@ -26,6 +27,7 @@
|
||||
src.body = ""
|
||||
src.backup_body = ""
|
||||
src.backup_author = ""
|
||||
src.img = null
|
||||
|
||||
/datum/feed_channel/proc/clear()
|
||||
src.channel_name = ""
|
||||
@@ -83,6 +85,7 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
// 1 = there has
|
||||
var/scanned_user = "Unknown" //Will contain the name of the person who currently uses the newscaster
|
||||
var/msg = ""; //Feed message
|
||||
var/obj/item/weapon/photo/photo = null
|
||||
var/channel_name = ""; //the feed channel which will be receiving the feed, or being created
|
||||
var/c_locked=0; //Will our new channel be locked to public submissions?
|
||||
var/hitstaken = 0 //Death at 3 hits from an item with force>=15
|
||||
@@ -229,6 +232,7 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
dat+="<HR><B><A href='?src=\ref[src];set_channel_receiving=1'>Receiving Channel</A>:</B> [src.channel_name]<BR>" //MARK
|
||||
dat+="<B>Message Author:</B> <FONT COLOR='green'>[src.scanned_user]</FONT><BR>"
|
||||
dat+="<B><A href='?src=\ref[src];set_new_message=1'>Message Body</A>:</B> [src.msg] <BR>"
|
||||
dat+="<B><A href='?src=\ref[src];set_attachment=1'>Attach Photo</A>:</B> [(src.photo ? "Photo Attached" : "No Photo")]</BR>"
|
||||
dat+="<BR><A href='?src=\ref[src];submit_new_message=1'>Submit</A><BR><BR><A href='?src=\ref[src];setScreen=[0]'>Cancel</A><BR>"
|
||||
if(4)
|
||||
dat+="Feed story successfully submitted to [src.channel_name].<BR><BR>"
|
||||
@@ -293,7 +297,11 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
dat+="<I>No feed messages found in channel...</I><BR>"
|
||||
else
|
||||
for(var/datum/feed_message/MESSAGE in src.viewing_channel.messages)
|
||||
dat+="-[MESSAGE.body] <BR><FONT SIZE=1>\[Story by <FONT COLOR='maroon'>[MESSAGE.author]</FONT>\]</FONT><BR><BR>"
|
||||
dat+="-[MESSAGE.body] <BR>"
|
||||
if(MESSAGE.img)
|
||||
usr << browse_rsc(MESSAGE.img, "tmp_photo.png")
|
||||
dat+="<img src='tmp_photo.png'><BR><BR>"
|
||||
dat+="<FONT SIZE=1>\[Story by <FONT COLOR='maroon'>[MESSAGE.author]</FONT>\]</FONT><BR>"
|
||||
dat+="<BR><HR><A href='?src=\ref[src];refresh=1'>Refresh</A>"
|
||||
dat+="<BR><A href='?src=\ref[src];setScreen=[1]'>Back</A>"
|
||||
if(10)
|
||||
@@ -358,6 +366,7 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
dat+="<HR>"
|
||||
dat+="<A href='?src=\ref[src];set_wanted_name=1'>Criminal Name</A>: [src.channel_name] <BR>"
|
||||
dat+="<A href='?src=\ref[src];set_wanted_desc=1'>Description</A>: [src.msg] <BR>"
|
||||
dat+="<A href='?src=\ref[src];set_attachment=1'>Attach Photo</A>: [(src.photo ? "Photo Attached" : "No Photo")]</BR>"
|
||||
if(wanted_already)
|
||||
dat+="<B>Wanted Issue created by:</B><FONT COLOR='green'> [news_network.wanted_issue.backup_author]</FONT><BR>"
|
||||
else
|
||||
@@ -385,7 +394,13 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
dat+="<B><FONT COLOR ='maroon'>-- STATIONWIDE WANTED ISSUE --</B></FONT><BR><FONT SIZE=2>\[Submitted by: <FONT COLOR='green'>[news_network.wanted_issue.backup_author]</FONT>\]</FONT><HR>"
|
||||
dat+="<B>Criminal</B>: [news_network.wanted_issue.author]<BR>"
|
||||
dat+="<B>Description</B>: [news_network.wanted_issue.body]<BR>"
|
||||
dat+="<BR><A href='?src=\ref[src];setScreen=[0]'>Back</A><BR>"
|
||||
dat+="<B>Photo:</B>: "
|
||||
if(news_network.wanted_issue.img)
|
||||
usr << browse_rsc(news_network.wanted_issue.img, "tmp_photo.png")
|
||||
dat+="<BR><img src='tmp_photo.png'>"
|
||||
else
|
||||
dat+="None"
|
||||
dat+="<BR><BR><A href='?src=\ref[src];setScreen=[0]'>Back</A><BR>"
|
||||
if(19)
|
||||
dat+="<FONT COLOR='green'>Wanted issue for [src.channel_name] successfully edited.</FONT><BR><BR>"
|
||||
dat+="<BR><A href='?src=\ref[src];setScreen=[0]'>Return</A><BR>"
|
||||
@@ -473,6 +488,10 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
src.msg = copytext(src.msg,2,lentext(src.msg)+1)
|
||||
src.updateUsrDialog()
|
||||
|
||||
else if(href_list["set_attachment"])
|
||||
AttachPhoto(usr)
|
||||
src.updateUsrDialog()
|
||||
|
||||
else if(href_list["submit_new_message"])
|
||||
if(src.msg =="" || src.msg=="\[REDACTED\]" || src.scanned_user == "Unknown" || src.channel_name == "" )
|
||||
src.screen=6
|
||||
@@ -480,6 +499,8 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
var/datum/feed_message/newMsg = new /datum/feed_message
|
||||
newMsg.author = src.scanned_user
|
||||
newMsg.body = src.msg
|
||||
if(photo)
|
||||
newMsg.img = photo.img
|
||||
feedback_inc("newscaster_stories",1)
|
||||
for(var/datum/feed_channel/FC in news_network.network_channels)
|
||||
if(FC.channel_name == src.channel_name)
|
||||
@@ -553,6 +574,8 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
WANTED.author = src.channel_name
|
||||
WANTED.body = src.msg
|
||||
WANTED.backup_author = src.scanned_user //I know, a bit wacky
|
||||
if(photo)
|
||||
WANTED.img = photo.img
|
||||
news_network.wanted_issue = WANTED
|
||||
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
|
||||
NEWSCASTER.newsAlert()
|
||||
@@ -565,6 +588,8 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
news_network.wanted_issue.author = src.channel_name
|
||||
news_network.wanted_issue.body = src.msg
|
||||
news_network.wanted_issue.backup_author = src.scanned_user
|
||||
if(photo)
|
||||
news_network.wanted_issue.img = photo.img
|
||||
src.screen = 19
|
||||
|
||||
src.updateUsrDialog()
|
||||
@@ -712,6 +737,16 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
|
||||
user << "<font color='blue'>The newscaster controls are far too complicated for your tiny brain!</font>"
|
||||
return
|
||||
|
||||
/obj/machinery/newscaster/proc/AttachPhoto(mob/user as mob)
|
||||
if(photo)
|
||||
photo.loc = src.loc
|
||||
user.put_in_inactive_hand(photo)
|
||||
photo = null
|
||||
if(istype(user.get_active_hand(), /obj/item/weapon/photo))
|
||||
photo = user.get_active_hand()
|
||||
user.drop_item()
|
||||
photo.loc = src
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -53,6 +53,8 @@ should be listed in the changelog upon commit tho. Thanks. -->
|
||||
<h3 class="author">Giacom updated:</h3>
|
||||
<ul class="changes bgimages16">
|
||||
<li class="rscadd">The detective's scanner was upgraded, it can now scan for reagents in items and living beings. Potential uses include, scanning dead bodies for leftover poison or scanning items to see if they have been spiked.</li>
|
||||
<li class="rscadd">You can now attach photos to newscaster news feeds and wanted posters.</li>
|
||||
<li class="tweak">You can now emag buttons to remove access from them.</li>
|
||||
<li class="tweak">The CentComm. Report has been changed so it no longer names potential antagonists. It will just announce the potential round type instead.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
+6160
-6161
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user