mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-19 02:54:41 +01:00
Add fake ambient occlusion
This commit is contained in:
@@ -333,6 +333,8 @@
|
||||
if(!prefs)
|
||||
prefs = new /datum/preferences(src)
|
||||
preferences_datums[ckey] = prefs
|
||||
else
|
||||
prefs.parent = src
|
||||
prefs.last_ip = address //these are gonna be used for banning
|
||||
prefs.last_id = computer_id //these are gonna be used for banning
|
||||
if(world.byond_version >= 511 && byond_version >= 511 && prefs.clientfps)
|
||||
@@ -393,10 +395,8 @@
|
||||
if(establish_db_connection())
|
||||
to_chat(src,"<span class='notice'>You have enabled karma gains.")
|
||||
|
||||
if(!void)
|
||||
void = new()
|
||||
|
||||
screen += void
|
||||
generate_clickcatcher()
|
||||
apply_clickcatcher()
|
||||
|
||||
if(!winexists(src, "asset_cache_browser")) // The client is using a custom skin, tell them.
|
||||
to_chat(src, "<span class='warning'>Unable to access asset cache browser, if you are using a custom skin file, please allow DS to download the updated version, if you are not, then make a bug report. This is not a critical issue but can cause issues with resource downloading, as it is impossible to know when extra resources arrived to you.</span>")
|
||||
@@ -772,3 +772,13 @@
|
||||
winset(src, "rpane.changelog", "background-color=#40628a;text-color=#FFFFFF")
|
||||
else
|
||||
winset(src, "rpane.changelog", "background-color=none;text-color=#000000")
|
||||
|
||||
/client/proc/generate_clickcatcher()
|
||||
if(!void)
|
||||
void = new()
|
||||
screen += void
|
||||
|
||||
/client/proc/apply_clickcatcher()
|
||||
generate_clickcatcher()
|
||||
var/list/actualview = getviewsize(view)
|
||||
void.UpdateGreed(actualview[1],actualview[2])
|
||||
@@ -183,7 +183,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
// 0 = character settings, 1 = game preferences
|
||||
var/current_tab = TAB_CHAR
|
||||
|
||||
// OOC Metadata:
|
||||
// OOC Metadata:
|
||||
var/metadata = ""
|
||||
var/slot_name = ""
|
||||
|
||||
@@ -200,6 +200,8 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
var/list/gear = list()
|
||||
var/gear_tab = "General"
|
||||
|
||||
var/ambientocclusion = TRUE
|
||||
|
||||
/datum/preferences/New(client/C)
|
||||
parent = C
|
||||
b_type = pick(4;"O-", 36;"O+", 3;"A-", 28;"A+", 1;"B-", 20;"B+", 1;"AB-", 5;"AB+")
|
||||
@@ -452,6 +454,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
dat += "<b>Donator Publicity:</b> <a href='?_src_=prefs;preference=donor_public'><b>[(toggles & DONATOR_PUBLIC) ? "Public" : "Hidden"]</b></a><br>"
|
||||
dat += "<b>Fancy NanoUI:</b> <a href='?_src_=prefs;preference=nanoui'>[(nanoui_fancy) ? "Yes" : "No"]</a><br>"
|
||||
dat += "<b>FPS:</b> <a href='?_src_=prefs;preference=clientfps;task=input'>[clientfps]</a><br>"
|
||||
dat += "<b>Ambient Occlusion:</b> <a href='?_src_=prefs;preference=ambientocclusion'><b>[ambientocclusion ? "Enabled" : "Disabled"]</b></a><br>"
|
||||
dat += "<b>Ghost Ears:</b> <a href='?_src_=prefs;preference=ghost_ears'><b>[(toggles & CHAT_GHOSTEARS) ? "All Speech" : "Nearest Creatures"]</b></a><br>"
|
||||
dat += "<b>Ghost Sight:</b> <a href='?_src_=prefs;preference=ghost_sight'><b>[(toggles & CHAT_GHOSTSIGHT) ? "All Emotes" : "Nearest Creatures"]</b></a><br>"
|
||||
dat += "<b>Ghost Radio:</b> <a href='?_src_=prefs;preference=ghost_radio'><b>[(toggles & CHAT_GHOSTRADIO) ? "All Chatter" : "Nearest Speakers"]</b></a><br>"
|
||||
@@ -1920,22 +1923,6 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
if(world.byond_version >= 511 && user.client && user.client.byond_version >= 511)
|
||||
parent.fps = clientfps
|
||||
|
||||
/*
|
||||
if("skin_style")
|
||||
var/skin_style_name = input(user, "Select a new skin style") as null|anything in list("default1", "default2", "default3")
|
||||
if(!skin_style_name) return
|
||||
*/
|
||||
|
||||
/* if("spawnpoint")
|
||||
var/list/spawnkeys = list()
|
||||
for(var/S in spawntypes)
|
||||
spawnkeys += S
|
||||
var/choice = input(user, "Where would you like to spawn when latejoining?") as null|anything in spawnkeys
|
||||
if(!choice || !spawntypes[choice])
|
||||
spawnpoint = "Arrivals Shuttle"
|
||||
return
|
||||
spawnpoint = choice */
|
||||
|
||||
else
|
||||
switch(href_list["preference"])
|
||||
if("publicity")
|
||||
@@ -2080,6 +2067,14 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
|
||||
if(href_list["tab"])
|
||||
current_tab = text2num(href_list["tab"])
|
||||
|
||||
if("ambientocclusion")
|
||||
ambientocclusion = !ambientocclusion
|
||||
if(parent && parent.screen && parent.screen.len)
|
||||
var/obj/screen/plane_master/game_world/PM = locate(/obj/screen/plane_master/game_world) in parent.screen
|
||||
PM.filters -= AMBIENT_OCCLUSION
|
||||
if(ambientocclusion)
|
||||
PM.filters += AMBIENT_OCCLUSION
|
||||
|
||||
ShowChoices(user)
|
||||
return 1
|
||||
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
ghost_anonsay,
|
||||
exp,
|
||||
clientfps,
|
||||
atklog
|
||||
atklog,
|
||||
ambientocclusion,
|
||||
FROM [format_table_name("player")]
|
||||
WHERE ckey='[C.ckey]'"}
|
||||
)
|
||||
@@ -50,6 +51,7 @@
|
||||
exp = query.item[16]
|
||||
clientfps = text2num(query.item[17])
|
||||
atklog = text2num(query.item[18])
|
||||
ambientocclusion = text2num(query.item[19])
|
||||
|
||||
//Sanitize
|
||||
ooccolor = sanitize_hexcolor(ooccolor, initial(ooccolor))
|
||||
@@ -69,6 +71,7 @@
|
||||
exp = sanitize_text(exp, initial(exp))
|
||||
clientfps = sanitize_integer(clientfps, 0, 1000, initial(clientfps))
|
||||
atklog = sanitize_integer(atklog, 0, 100, initial(atklog))
|
||||
ambientocclusion = sanitize_integer(ambientocclusion, 0, 1, initial(ambientocclusion))
|
||||
return 1
|
||||
|
||||
/datum/preferences/proc/save_preferences(client/C)
|
||||
@@ -98,7 +101,8 @@
|
||||
windowflashing='[windowflashing]',
|
||||
ghost_anonsay='[ghost_anonsay]',
|
||||
clientfps='[clientfps]',
|
||||
atklog='[atklog]'
|
||||
atklog='[atklog]',
|
||||
ambientocclusion='[ambientocclusion]'
|
||||
WHERE ckey='[C.ckey]'"}
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user