From 4db062c9c0739174b0896bb3bbd5d0450b8b442c Mon Sep 17 00:00:00 2001 From: Poojawa Date: Sun, 18 Mar 2018 20:20:20 -0500 Subject: [PATCH] didn't fix anything, reee. but I have an idea --- modular_citadel/code/modules/client/preferences.dm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modular_citadel/code/modules/client/preferences.dm b/modular_citadel/code/modules/client/preferences.dm index c3dd517afb..56011f0333 100644 --- a/modular_citadel/code/modules/client/preferences.dm +++ b/modular_citadel/code/modules/client/preferences.dm @@ -513,7 +513,7 @@ if(i == href_list["select_category"]) gear_tab = i if(href_list["toggle_gear_path"]) - var/datum/gear/G = GLOB.loadout_items[gear_tab][href_list["toggle_gear_path"]] + var/datum/gear/G = GLOB.loadout_items[gear_tab][html_decode(href_list["toggle_gear_path"])] if(!G) return var/toggle = text2num(href_list["toggle_gear"]) @@ -524,11 +524,13 @@ if(!is_loadout_slot_available(G.category)) to_chat(user, "You cannot take this loadout, as you've already chosen too many of the same category!") return + if(G.ckeywhitelist && G.ckeywhitelist.len && !(user.ckey in G.ckeywhitelist)) + to_chat(user, "This is an item intended for donator use only. You are not authorized to use this item.") + return if(gear_points >= initial(G.cost)) LAZYADD(chosen_gear, G.type) gear_points -= initial(G.cost) - /datum/preferences/proc/citadel_dat_replace(current_tab) var/mob/user @@ -724,7 +726,7 @@ var/donoritem if(gear.ckeywhitelist && gear.ckeywhitelist.len) donoritem = TRUE - if(user && !(user.ckey in gear.ckeywhitelist)) + if(user && user.client.ckey && !(gear.ckeywhitelist.Find(user.client.ckey))) continue var/class_link = "" if(gear.type in chosen_gear)