Skip to content

Commit

Permalink
restores the paper assets working on webroot assets (#3780)
Browse files Browse the repository at this point in the history
we don't use browse_rsc stuff in 2023 please

:cl:
fix: paper images should appear once again
/:cl:
  • Loading branch information
harryob authored Jul 3, 2023
1 parent bd5044e commit 194bb97
Showing 1 changed file with 17 additions and 5 deletions.
22 changes: 17 additions & 5 deletions code/modules/paperwork/paper.dm
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@


/obj/item/paper/proc/parsepencode(t, obj/item/tool/pen/P, mob/user as mob, iscrayon = 0)
var/datum/asset/asset = get_asset_datum(/datum/asset/simple/paper)

t = replacetext(t, "\[center\]", "<center>")
t = replacetext(t, "\[/center\]", "</center>")
t = replacetext(t, "\[br\]", "<BR>")
Expand Down Expand Up @@ -251,9 +253,9 @@
t = replacetext(t, "\[/grid\]", "</td></tr></table>")
t = replacetext(t, "\[row\]", "</td><tr>")
t = replacetext(t, "\[cell\]", "<td>")
t = replacetext(t, "\[logo\]", "<img src = wylogo.png>")
t = replacetext(t, "\[wy\]", "<img src = wylogo.png>")
t = replacetext(t, "\[uscm\]", "<img src = uscmlogo.png>")
t = replacetext(t, "\[logo\]", "<img src = [asset.get_url_mappings()["wylogo.png"]]>")
t = replacetext(t, "\[wy\]", "<img src = [asset.get_url_mappings()["wylogo.png"]]>")
t = replacetext(t, "\[uscm\]", "<img src = [asset.get_url_mappings()["uscmlogo.png"]]>")

t = "<font face=\"[deffont]\" color=[P ? P.pen_colour : "black"]>[t]</font>"
else // If it is a crayon, and he still tries to use these, make them empty!
Expand Down Expand Up @@ -619,11 +621,21 @@

/obj/item/paper/wy
icon_state = "paper_wy"
info = "<center><img src = wylogo.png></center><BR>\n<span class=\"paper_field\"></span>"

/obj/item/paper/wy/Initialize(mapload, photo_list)
. = ..()

var/datum/asset/asset = get_asset_datum(/datum/asset/simple/paper)
info = "<center><img src = [asset.get_url_mappings()["wylogo.png"]]></center><BR>\n<span class=\"paper_field\"></span>"

/obj/item/paper/uscm
icon_state = "paper_uscm"
info = "<center><img src = uscmlogo.png></center><BR>\n<span class=\"paper_field\"></span>"

/obj/item/paper/uscm/Initialize(mapload, photo_list)
. = ..()

var/datum/asset/asset = get_asset_datum(/datum/asset/simple/paper)
info = "<center><img src = [asset.get_url_mappings()["uscmlogo.png"]]></center><BR>\n<span class=\"paper_field\"></span>"

/obj/item/paper/research_notes
icon_state = "paper_wy_words"
Expand Down

0 comments on commit 194bb97

Please sign in to comment.