Skip to content

Commit

Permalink
changes the fallback code (#4446)
Browse files Browse the repository at this point in the history
need to check if this fixes the status on
https://spacestation13.com/play/quick
  • Loading branch information
harryob authored Sep 20, 2023
1 parent 09ac4fc commit 972bead
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/game/world.dm
Original file line number Diff line number Diff line change
Expand Up @@ -185,8 +185,8 @@ var/world_topic_spam_protect_time = world.timeofday
if(logging)
log_topic("(NON-JSON) \"[topic_decoded]\", from:[addr], master:[master], key:[key]")
// Fallback check for spacestation13.com requests
if(topic_decoded == "ping")
return length(GLOB.clients)
if(topic_decoded == "status")
return list2params(list("players" = length(GLOB.clients)))
response["statuscode"] = 400
response["response"] = "Bad Request - Invalid JSON format"
return json_encode(response)
Expand Down

0 comments on commit 972bead

Please sign in to comment.