Skip to content

Commit 3288ad1

Browse files
committed
Fixes #190.
1 parent 57382e2 commit 3288ad1

File tree

1 file changed

+2
-2
lines changed
  • addons/source-python/packages/source-python/players

1 file changed

+2
-2
lines changed

addons/source-python/packages/source-python/players/helpers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ def uniqueid_from_playerinfo(playerinfo):
163163
:rtype: str
164164
"""
165165
# Is the player a Bot?
166-
if playerinfo.is_fake_client():
166+
if playerinfo.is_fake_client() or 'BOT' in playerinfo.steamid:
167167

168168
# Return the bot's UniqueID
169169
return 'BOT_{0}'.format(playerinfo.name)
@@ -205,7 +205,7 @@ def address_from_playerinfo(playerinfo):
205205
:rtype: str
206206
"""
207207
# Is the player a bot?
208-
if playerinfo.is_fake_client():
208+
if playerinfo.is_fake_client() or 'BOT' in playerinfo.steamid:
209209

210210
# Return an empty string, since using <netinfo>.address crashes
211211
# with bots

0 commit comments

Comments
 (0)