mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Missing href token adds
This commit is contained in:
@@ -1,13 +1,17 @@
|
||||
/var/create_object_html = null
|
||||
/datum/admins/proc/create_panel_helper(template)
|
||||
var/final_html = replacetext(template, "/* ref src */", "\ref[src];[HrefToken()]")
|
||||
final_html = replacetext(final_html,"/* hreftokenfield */","[HrefTokenFormField()]")
|
||||
return final_html
|
||||
|
||||
/datum/admins/proc/create_object(var/mob/user)
|
||||
var/static/create_object_html = null
|
||||
if (!create_object_html)
|
||||
var/objectjs = null
|
||||
objectjs = jointext(typesof(/obj), ";")
|
||||
create_object_html = file2text('html/create_object.html')
|
||||
create_object_html = replacetext(create_object_html, "null /* object types */", "\"[objectjs]\"")
|
||||
|
||||
user << browse(replacetext(create_object_html, "/* ref src */", "\ref[src]"), "window=create_object;size=680x600")
|
||||
user << browse(create_panel_helper(create_object_html), "window=create_object;size=680x600")
|
||||
|
||||
|
||||
/datum/admins/proc/quick_create_object(var/mob/user)
|
||||
@@ -28,7 +32,7 @@
|
||||
"/obj/mecha",
|
||||
"/obj/item/mecha_parts",
|
||||
"/obj/item/mecha_parts/mecha_equipment")
|
||||
|
||||
|
||||
pathtext = tgui_input_list(usr, "Select the path of the object you wish to create.", "Path", choices, "/obj")
|
||||
|
||||
if(!pathtext)
|
||||
@@ -41,4 +45,4 @@
|
||||
quick_create_object_html = file2text('html/create_object.html')
|
||||
quick_create_object_html = replacetext(quick_create_object_html, "null /* object types */", "\"[objectjs]\"")
|
||||
|
||||
user << browse(replacetext(quick_create_object_html, "/* ref src */", "\ref[src]"), "window=quick_create_object;size=680x600")
|
||||
user << browse(create_panel_helper(quick_create_object_html), "window=quick_create_object;size=680x600")
|
||||
|
||||
Reference in New Issue
Block a user