mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2025-12-19 14:51:27 +00:00
* admin UI improvement * browser_ui_2 * OptimisAAtion * a Co-authored-by: Sirryan2002 <80364400+Sirryan2002@users.noreply.github.com> * AA fix 2 --------- Co-authored-by: Sirryan2002 <80364400+Sirryan2002@users.noreply.github.com>
18 lines
770 B
Plaintext
18 lines
770 B
Plaintext
GLOBAL_VAR(create_mob_html)
|
|
|
|
/datum/admins/proc/create_mob(mob/user)
|
|
if(!GLOB.create_mob_html)
|
|
var/mobjs = null
|
|
mobjs = jointext(typesof(/mob), ";")
|
|
GLOB.create_mob_html = file2text('html/create_object.html')
|
|
GLOB.create_mob_html = replacetext(GLOB.create_mob_html, "$ATOM$", "Mob")
|
|
GLOB.create_mob_html = replacetext(GLOB.create_mob_html, "null /* object types */", "\"[mobjs]\"")
|
|
|
|
var/datum/browser/popup = new(user, "create_mob", "<div align='center'>Create Mob</div>", 500, 550)
|
|
var/unique_content = GLOB.create_mob_html
|
|
unique_content = replacetext(unique_content, "/* ref src */", UID())
|
|
popup.set_content(unique_content)
|
|
popup.set_window_options("can_close=1;can_minimize=0;can_maximize=1;can_resize=1")
|
|
popup.open()
|
|
onclose(user, "create_mob")
|