Merge branch 'master' of https://github.com/ParadiseSS13/Paradise into BookClub

This commit is contained in:
Crazylemon64
2017-01-06 05:15:11 -08:00
15 changed files with 73 additions and 49 deletions
+12 -5
View File
@@ -78,22 +78,23 @@
if("where" in query_tree)
var/objs_temp = objs
objs = list()
for(var/datum/d in objs_temp)
for(var/d in objs_temp)
if(SDQL_expression(d, query_tree["where"]))
objs += d
switch(query_tree[1])
if("call")
for(var/datum/d in objs)
for(var/d in objs)
SDQL_var(d, query_tree["call"][1], source = d)
if("delete")
for(var/datum/d in objs)
for(var/d in objs)
qdel(d)
if("select")
var/text = ""
for(var/datum/t in objs)
for(var/o in objs)
var/datum/t = o
text += "<A HREF='?_src_=vars;Vars=[t.UID()]'>\ref[t]</A>"
if(istype(t, /atom))
var/atom/a = t
@@ -115,7 +116,7 @@
if("update")
if("set" in query_tree)
var/list/set_list = query_tree["set"]
for(var/datum/d in objs)
for(var/d in objs)
for(var/list/sets in set_list)
var/datum/temp = d
var/i = 0
@@ -252,6 +253,12 @@
if(istype(d, type))
out += d
else if(ispath(type, /client))
for(var/client/C)
if((location != world) && !(C.mob in location))
continue
out += C
else if(location == world)
for(var/datum/d)
if(istype(d, type))
@@ -596,7 +596,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
continue
var/available_in_playtime = job.available_in_playtime(user.client)
if(available_in_playtime)
HTML += "<del>[rank]</del></td><td> \[ " + get_exp_format(available_in_playtime) + " as " + job.get_exp_req_type() + "</td></tr>"
HTML += "<del>[rank]</del></td><td> \[ " + get_exp_format(available_in_playtime) + " as " + job.get_exp_req_type() + " \]</td></tr>"
continue
if(!job.player_old_enough(user.client))
var/available_in_days = job.available_in_days(user.client)
+3 -3
View File
@@ -48,7 +48,7 @@
continue
if(findtext(message," snores.")) //Because we have so many sleeping people.
break
if(M.stat == 2 && (M.client.prefs.toggles & CHAT_GHOSTSIGHT) && !(M in viewers(src,null)))
if(M.stat == DEAD && M.get_preference(CHAT_GHOSTSIGHT) && !(M in viewers(src,null)))
M.show_message(message)
@@ -118,8 +118,8 @@
if(istype(M, /mob/new_player))
continue
if(check_rights(R_ADMIN|R_MOD, 0, M) && (M.client.prefs.toggles & CHAT_DEAD)) // Show the emote to admins/mods
if(check_rights(R_ADMIN|R_MOD, 0, M) && M.get_preference(CHAT_DEAD)) // Show the emote to admins/mods
to_chat(M, message)
else if(M.stat == DEAD && (M.client.prefs.toggles & CHAT_DEAD)) // Show the emote to regular ghosts with deadchat toggled on
else if(M.stat == DEAD && M.get_preference(CHAT_DEAD)) // Show the emote to regular ghosts with deadchat toggled on
M.show_message(message, 2)
@@ -868,7 +868,7 @@
for(var/mob/M in dead_mob_list)
if(!M.client || istype(M, /mob/new_player))
continue //skip monkeys, leavers and new players
if(M.stat == DEAD && (M.client.prefs.toggles & CHAT_GHOSTSIGHT) && !(M in viewers(src,null)))
if(M.stat == DEAD && M.get_preference(CHAT_GHOSTSIGHT) && !(M in viewers(src,null)))
M.show_message(message)
switch(m_type)
+5 -5
View File
@@ -244,7 +244,7 @@ proc/get_radio_key_from_channel(var/channel)
continue //skip monkeys and leavers
if(isnewplayer(M))
continue
if(M.stat == DEAD && M.client && (M.client.prefs.toggles & CHAT_GHOSTEARS) && client) // client is so that ghosts don't have to listen to mice
if(M.stat == DEAD && M.client && M.get_preference(CHAT_GHOSTEARS) && client) // client is so that ghosts don't have to listen to mice
listening |= M
continue
if(get_turf(M) in hearturfs)
@@ -288,8 +288,8 @@ proc/get_radio_key_from_channel(var/channel)
if(client.prefs.muted & MUTE_IC)
to_chat(src, "<span class='danger'>You cannot speak in IC (Muted).</span>")
return
if(stat)
if(stat)
return 0
if(..(act, type, message))
@@ -302,7 +302,7 @@ proc/get_radio_key_from_channel(var/channel)
if(!M.client || istype(M, /mob/new_player))
continue //skip monkeys, leavers and new players //who the hell knows why new players are in the dead mob list
if(M.stat == DEAD && (M.client.prefs.toggles & CHAT_GHOSTSIGHT) && !(M in viewers(src,null)))
if(M.stat == DEAD && M.get_preference(CHAT_GHOSTSIGHT) && !(M in viewers(src,null)))
M.show_message(message)
switch(type)
@@ -402,7 +402,7 @@ proc/get_radio_key_from_channel(var/channel)
for(var/mob/M in dead_mob_list) //does this include players who joined as observers as well?
if(!M.client)
continue
if(M.stat == DEAD && M.client && (M.client.prefs.toggles & CHAT_GHOSTEARS))
if(M.stat == DEAD && M.client && M.get_preference(CHAT_GHOSTEARS))
listening |= M
//Pass whispers on to anything inside the immediate listeners.
+11 -2
View File
@@ -411,7 +411,7 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
name = realname
for(var/mob/M in player_list)
if(M.client && ((!istype(M, /mob/new_player) && M.stat == DEAD) || check_rights(R_ADMIN|R_MOD,0,M)) && (M.client.prefs.toggles & CHAT_DEAD))
if(M.client && ((!istype(M, /mob/new_player) && M.stat == DEAD) || check_rights(R_ADMIN|R_MOD,0,M)) && M.get_preference(CHAT_DEAD))
var/follow
var/lname
if(subject)
@@ -586,4 +586,13 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
if(5)
newletter="glor"
newphrase+="[newletter]";counter-=1
return newphrase
return newphrase
/mob/proc/get_preference(toggleflag)
if(!client)
return FALSE
if(!client.prefs)
log_runtime(EXCEPTION("Mob '[src]', ckey '[ckey]' is missing a prefs datum on the client!"))
return FALSE
// Cast to 1/0
return !!(client.prefs.toggles & toggleflag)
+1 -1
View File
@@ -514,7 +514,7 @@ var/list/SpookyGhosts = list("ghost","shade","shade2","ghost-narsie","horror","s
if(on==0)
src.icon_state = icon_off
camera.c_tag = null
camera.network = null
camera.network = list()
else
src.icon_state = icon_on
camera.network = list("news")
@@ -117,7 +117,7 @@
continue //skip monkeys and leavers
if(istype(M, /mob/new_player))
continue
if(M.stat == 2 && M.client.prefs.toggles & CHAT_GHOSTEARS)
if(M.stat == DEAD && M.get_preference(CHAT_GHOSTEARS))
listening|=M
for(var/mob/M in listening)