SteamKit2.SteamID.SetFromUInt64 C# (CSharp) Méthode

SetFromUInt64() public méthode

Sets the various components of this SteamID from a 64bit integer form.
public SetFromUInt64 ( System.UInt64 ulSteamID ) : void
ulSteamID System.UInt64 The 64bit integer to assign this SteamID from.
Résultat void
        public void SetFromUInt64( UInt64 ulSteamID )
        {
            this.steamid.Data = ulSteamID;
        }

Usage Example

        public void checkPeriodically(object sender, DoWorkEventArgs e)
        {
            Thread.Sleep(1000);//Wait 10s for Steambot to fully initialize
            while (true)
            {
                double newConversionRate = getConversionRate();
                if (newConversionRate != -1)
                    conversionRate = newConversionRate;

                DataSet verified_adds = returnQuery("SELECT * FROM add_verification a,users u WHERE verified=1 AND a.userID=u.userID");
                if (verified_adds != null)
                {
                    for (int r = 0; r < verified_adds.Tables[0].Rows.Count; r++)
                    {
                        BotManager.mainLog.Success("Add verified: " + verified_adds.Tables[0].Rows[r][2].ToString() + " DOGE to user " + verified_adds.Tables[0].Rows[r][1].ToString());
                        returnQuery("UPDATE users SET balance = balance + " + verified_adds.Tables[0].Rows[r][2].ToString() + " WHERE userID = " + verified_adds.Tables[0].Rows[r][1].ToString());
                        returnQuery("DELETE FROM add_verification WHERE addID = " + verified_adds.Tables[0].Rows[r][0].ToString());

                        SteamID userID = new SteamID();
                        userID.SetFromUInt64(ulong.Parse(verified_adds.Tables[0].Rows[r][6].ToString()));
                        Bot.SteamFriends.SendChatMessage(userID, EChatEntryType.ChatMsg, verified_adds.Tables[0].Rows[r][2].ToString() + " DOGE was successfully added to your tipping balance.");
                        BotManager.mainLog.Success("Registered user successfully added " + verified_adds.Tables[0].Rows[r][2].ToString() + " DOGE to their balance.");
                    }
                }
                Thread.Sleep(30000);
            }
        }
All Usage Examples Of SteamKit2.SteamID::SetFromUInt64