Raised This Month: $32 Target: $400
 8% 

StringToInt( Problem.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Dr.Doctor
AlliedModders Donor
Join Date: Feb 2017
Location: Hong Kong
Old 10-29-2017 , 15:16   StringToInt( Problem.
Reply With Quote #1

Since I got a large string "76561198097317941"

I used StringToInt( function to change string to int, but it return -1, I think the reason is the string is too large.

Any methods to change string "76561198097317941" into int ?
__________________
Dr.Doctor is offline
shavit
AlliedModders Donor
Join Date: Dec 2011
Location: Israel
Old 10-29-2017 , 15:31   Re: StringToInt( Problem.
Reply With Quote #2

I can't think of a solution; but it's an issue because that number is a long and int is well.. int.
__________________
retired
shavit is offline
Powerlord
AlliedModders Donor
Join Date: Jun 2008
Location: Seduce Me!
Old 10-29-2017 , 16:16   Re: StringToInt( Problem.
Reply With Quote #3

SourceMod doesn't support 64-bit ints.

That's why you need to store SteamId64 as a string.
__________________
Not currently working on SourceMod plugin development.
Powerlord is offline
Dr.Doctor
AlliedModders Donor
Join Date: Feb 2017
Location: Hong Kong
Old 10-29-2017 , 22:47   Re: StringToInt( Problem.
Reply With Quote #4

Quote:
Originally Posted by Powerlord View Post
SourceMod doesn't support 64-bit ints.

That's why you need to store SteamId64 as a string.
ok, thanks lordpower~
__________________
Dr.Doctor is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 22:59.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode