Skip to content

Commit 2315591

Browse files
committed
I really hate people for putting colors IN THE VERSION
1 parent 7ebcaa4 commit 2315591

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

plugins/minecraft_ping.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,16 @@ def mcping(text):
4343
description = format_colors(" ".join(s.description["text"].split()))
4444
else:
4545
description = format_colors(" ".join(s.description.split()))
46+
47+
# I really hate people for putting colors IN THE VERSION
48+
# WTF REALLY THIS IS A THING NOW?
49+
version = format_colors(s.version.name)
4650

4751
if s.latency:
4852
return "{}\x0f - \x02{}\x0f - \x02{:.1f}ms\x02" \
49-
" - \x02{}/{}\x02 players".format(description, s.version.name, s.latency,
53+
" - \x02{}/{}\x02 players".format(description, version, s.latency,
5054
s.players.online, s.players.max).replace("\n", "\x0f - ")
5155
else:
5256
return "{}\x0f - \x02{}\x0f" \
53-
" - \x02{}/{}\x02 players".format(description, s.version.name,
57+
" - \x02{}/{}\x02 players".format(description, version,
5458
s.players.online, s.players.max).replace("\n", "\x0f - ")

0 commit comments

Comments
 (0)