mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
Auto kicks AIs that click turfs they shouldnt see(like for example when the camera static bugs out) (#8868)
* Auto kicks AIs that click turfs they shouldnt see(like for example when the camera static bugs out) * Forces reconnect * Update code/_onclick/ai.dm Co-authored-by: Jamie D <993128+JamieD1@users.noreply.github.com>
This commit is contained in:
@@ -43,12 +43,11 @@
|
|||||||
if(!can_see(A))
|
if(!can_see(A))
|
||||||
if(isturf(A)) //On unmodified clients clicking the static overlay clicks the turf underneath
|
if(isturf(A)) //On unmodified clients clicking the static overlay clicks the turf underneath
|
||||||
return //So there's no point messaging admins
|
return //So there's no point messaging admins
|
||||||
message_admins("[ADMIN_LOOKUPFLW(src)] might be running a modified client! (failed can_see on AI click of [A] (Turf Loc: [ADMIN_VERBOSEJMP(pixel_turf)]))")
|
message_admins("[ADMIN_LOOKUPFLW(src)] was kicked because they failed can_see on AI click of [A] (Turf Loc: [ADMIN_VERBOSEJMP(pixel_turf)]))")
|
||||||
var/message = "[key_name(src)] might be running a modified client! (failed can_see on AI click of [A] (Turf Loc: [AREACOORD(pixel_turf)]))"
|
log_admin("[key_name(src)] was kicked because they failed can_see on AI click of [A] (Turf Loc: [AREACOORD(pixel_turf)])")
|
||||||
log_admin(message)
|
to_chat(src, "<span class='reallybig'>You have been automatically kicked because you clicked a turf you shouldn't of been able to see as an AI. You should reconnect automatically. If you do not, you can reconnect using the File --> Reconnect button.</span>")
|
||||||
if(REALTIMEOFDAY >= chnotify + 9000)
|
winset(usr, null, "command=.reconnect")
|
||||||
chnotify = REALTIMEOFDAY
|
QDEL_IN(client, 3 SECONDS) //fallback if the reconnection doesnt work
|
||||||
send2irc_adminless_only("NOCHEAT", message)
|
|
||||||
return
|
return
|
||||||
|
|
||||||
var/list/modifiers = params2list(params)
|
var/list/modifiers = params2list(params)
|
||||||
|
|||||||
Reference in New Issue
Block a user