*DELETED*

All other Source.Python topics and issues.
Sam
Senior Member
Posts: 100
Joined: Tue Jul 03, 2018 3:00 pm
Location: *DELETED*
Contact:

[Q] SteamID mismatch

Postby Sam » Wed Apr 08, 2020 1:38 am

Syntax: Select all

from players.entity import Player
pl = Player(1) # STEAM_0:0:176325977
pl.raw_steamid.to_steamid2() # STEAM_1:0:176325977


It is right?
Last edited by Sam on Wed Apr 08, 2020 1:38 am, edited 1 time in total.
Reason: Original post version
User avatar
L'In20Cible
Project Leader
Posts: 1533
Joined: Sat Jul 14, 2012 9:29 pm
Location: Québec

Re: [Q] SteamID mismatch

Postby L'In20Cible » Wed Apr 08, 2020 1:34 pm

That number is the Steam Universe. Every games supported by SP will correctly returns 1, some old games that run on older engines will returns 0 but that was a bug that was fixed and unified since at least most HL2's based game got ported over to OB.
Sam
Senior Member
Posts: 100
Joined: Tue Jul 03, 2018 3:00 pm
Location: *DELETED*
Contact:

Re: [Q] SteamID mismatch

Postby Sam » Wed Apr 08, 2020 3:09 pm

Maybe there is some unique player identifier? In tf2 and l4d2 SteamID64 do not match
Last edited by Sam on Wed Apr 08, 2020 3:09 pm, edited 1 time in total.
Reason: Original post version
User avatar
L'In20Cible
Project Leader
Posts: 1533
Joined: Sat Jul 14, 2012 9:29 pm
Location: Québec

Re: [Q] SteamID mismatch

Postby L'In20Cible » Wed Apr 08, 2020 3:19 pm

Sam wrote:Maybe there is some unique player identifier? In tf2 and l4d2 SteamID64 do not match

The steamid64 should be consistent, why do you think they aren't? And why not simply using pl.steamid, or pl.uniqueid for that matter? What exactly are you trying to do?
Sam
Senior Member
Posts: 100
Joined: Tue Jul 03, 2018 3:00 pm
Location: *DELETED*
Contact:

Re: [Q] SteamID mismatch

Postby Sam » Thu Apr 09, 2020 12:58 pm

L'In20Cible wrote:
Sam wrote:Maybe there is some unique player identifier? In tf2 and l4d2 SteamID64 do not match

The steamid64 should be consistent, why do you think they aren't? And why not simply using pl.steamid, or pl.uniqueid for that matter? What exactly are you trying to do?


A very long time ago I was going to make a plugin exclusively for one person on all servers. If `.steamid` in TF2 worked fine, then in L4D2 it did not work and I had to use `.raw_steamid` (`.uniqueid` is not good for me and my projects)

Maybe a lot of time has passed and everything has changed. I'll check `.steamid` later (Quarantine spoils everything >:c)
Last edited by Sam on Thu Apr 09, 2020 1:00 pm, edited 1 time in total.
User avatar
L'In20Cible
Project Leader
Posts: 1533
Joined: Sat Jul 14, 2012 9:29 pm
Location: Québec

Re: [Q] SteamID mismatch

Postby L'In20Cible » Thu Apr 09, 2020 1:23 pm

Player.steamid can be either steamid2 or steamid3 depending of the game. However, they should be consistent across all games. For example, Player.raw_steamid.to_steamid2() should be the same everywhere, same as to_steamid3(), or to_uint64(). If you want to be able to determine if a player matches a specific format across any games, then just pick a format and be consistent in how your authenticate the player. I would recommend steamid64, because they are the link to your profile (e.g steamcommunity.com/profiles/<steamid64>).

Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 16 guests