Skip to content

Commit

Permalink
UI tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
SabreML committed Dec 4, 2023
1 parent b84c688 commit 92736c0
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 9 deletions.
2 changes: 1 addition & 1 deletion code/modules/admin/create_mob.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
create_mob_html = replacetext(create_mob_html, "null /* object types */", "\"[mobjs]\"")
create_mob_html = replacetext(create_mob_html, "/* href token */", RawHrefToken(forceGlobal = TRUE))

show_browser(user, replacetext(create_mob_html, "/* ref src */", "\ref[src]"), "Create Mob", "create_mob", "size=425x475")
show_browser(user, replacetext(create_mob_html, "/* ref src */", "\ref[src]"), "Create Mob", "create_mob", "size=450x525")
4 changes: 2 additions & 2 deletions code/modules/admin/create_object.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
create_object_html = replacetext(create_object_html, "null /* object types */", "\"[objectjs]\"")
create_object_html = replacetext(create_object_html, "/* href token */", RawHrefToken(forceGlobal = TRUE))

show_browser(user, replacetext(create_object_html, "/* ref src */", "\ref[src]"), "Create Object", "create_object", "size=425x475")
show_browser(user, replacetext(create_object_html, "/* ref src */", "\ref[src]"), "Create Object", "create_object", "size=450x525")


/datum/admins/proc/quick_create_object(mob/user)
Expand Down Expand Up @@ -46,4 +46,4 @@
quick_create_object_html = replacetext(quick_create_object_html, "null /* object types */", "\"[objectjs]\"")
quick_create_object_html = replacetext(quick_create_object_html, "/* href token */", RawHrefToken(forceGlobal = TRUE))

show_browser(user, replacetext(quick_create_object_html, "/* ref src */", "\ref[src]"), "Quick Create Object", "quick_create_object", "size=425x475")
show_browser(user, replacetext(quick_create_object_html, "/* ref src */", "\ref[src]"), "Quick Create Object", "quick_create_object", "size=450x525")
2 changes: 1 addition & 1 deletion code/modules/admin/create_turf.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
create_turf_html = replacetext(create_turf_html, "null /* object types */", "\"[turfjs]\"")
create_turf_html = replacetext(create_turf_html, "/* href token */", RawHrefToken(forceGlobal = TRUE))

show_browser(usr, replacetext(create_turf_html, "/* ref src */", "\ref[src]"), "Create Turf", "create_turf", "size=425x475")
show_browser(usr, replacetext(create_turf_html, "/* ref src */", "\ref[src]"), "Create Turf", "create_turf", "size=450x525")
12 changes: 7 additions & 5 deletions html/create_object.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,25 @@
<form name="spawner" action="byond://?src=/* ref src */" method="get">
<input type="hidden" name="src" value="/* ref src */">
<input type="hidden" name="admin_token" value="/* href token */">
Type <input type="text" name="filter" value="" onkeypress="submitFirst(event)" style="width:350px"> <input
Type: <input type="text" name="filter" onkeypress="submitFirst(event)" style="width:350px"> <input
type="button" class="button" value="Search" onclick="updateSearch()" /><br>
Offset: <input type="text" name="offset" value="x,y,z" style="width:250px">

Offset: <input type="text" name="offset" value="x,y,z" style="width:250px">
A <input type="radio" class="radioButton" name="offset_type" value="absolute">
R <input type="radio" class="radioButton" name="offset_type" value="relative" checked="checked"><br>

Number: <input type="text" name="object_count" value="1" style="width:30px">
Dir: <input type="text" name="object_dir" value="2" style="width:30px">
Name: <input type="text" name="object_name" value="" style="width:180px"><br>
Name: <input type="text" name="object_name" style="width:180px"><br>

Where:
<select name='object_where' style="width:320px">
<option value='onfloor'>On floor below own mob</option>
<!-- <option value='inhand'>In own mob's hand</option> -->
<option value='inmarked'>In marked object</option>
</select>
<br><br>

<select name="object_list" size="18" multiple style="width:98%"></select><br>
<input type="submit" class="button" value="Spawn">
</form>
Expand All @@ -41,8 +43,7 @@
function populateList(from_list) {
object_list.options.length = 0;

var i;
for (i in from_list) {
for (var i in from_list) {
var new_option = document.createElement("option");
new_option.value = from_list[i];
new_option.text = from_list[i];
Expand Down Expand Up @@ -70,6 +71,7 @@
return false;
}

// Carriage return
if (event.keyCode == 13 || event.which == 13) {
object_list.options[0].selected = 'true';
}
Expand Down

0 comments on commit 92736c0

Please sign in to comment.