Raised This Month: $ Target: $400
 0% 

Read from a file


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
shadow728988
Member
Join Date: Sep 2017
Old 07-10-2019 , 10:14   Re: Read from a file
Reply With Quote #1

Quote:
Originally Posted by fysiks View Post
A client doesn't have a valid SteamID until after client_authorized() so you should use that instead of client_connect().
i did tried this but no luck.
shadow728988 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-10-2019 , 06:37   Re: Read from a file
Reply With Quote #2

You can simply use users.ini.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
shadow728988
Member
Join Date: Sep 2017
Old 07-10-2019 , 09:59   Re: Read from a file
Reply With Quote #3

Quote:
Originally Posted by OciXCrom View Post
You can simply use users.ini.
cant add all the 100 players you know..thank you for replying
shadow728988 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-10-2019 , 10:58   Re: Read from a file
Reply With Quote #4

Quote:
Originally Posted by shadow728988 View Post
cant add all the 100 players you know..thank you for replying
Nevermind, I misread the request.
__________________

Last edited by OciXCrom; 07-10-2019 at 10:58.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Relaxing
AlliedModders Donor
Join Date: Jun 2016
Location: White Plains
Old 07-10-2019 , 06:50   Re: Read from a file
Reply With Quote #5

... or just sv_password.
__________________
Relaxing is offline
Fuck For Fun
Veteran Member
Join Date: Nov 2013
Old 07-10-2019 , 09:57   Re: Read from a file
Reply With Quote #6

Quote:
Originally Posted by OciXCrom View Post
You can simply use users.ini.
You are wrong, through users.ini that comes in with certain approaches and does not want it. It is therefore requested to load the ID for some players that can enter
Quote:
Originally Posted by Relaxing View Post
... or just sv_password.
What's the point of having to write a password every time?
Fuck For Fun is offline
Send a message via Skype™ to Fuck For Fun
thEsp
BANNED
Join Date: Aug 2017
Old 07-11-2019 , 05:43   Re: Read from a file
Reply With Quote #7

Yes it does.
thEsp is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-11-2019 , 07:28   Re: Read from a file
Reply With Quote #8

So, is this a request for a plugin or request for help with creating it yourself? If it's the first one, this is not the right section for the thread. Here you do things by yourself and we guide you through the process.
If you want somebody else to make the plugin for you, use the plugin requests section.
__________________

Last edited by OciXCrom; 07-11-2019 at 07:28.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
shadow728988
Member
Join Date: Sep 2017
Old 07-11-2019 , 09:09   Re: Read from a file
Reply With Quote #9

Quote:
Originally Posted by OciXCrom View Post
So, is this a request for a plugin or request for help with creating it yourself? If it's the first one, this is not the right section for the thread. Here you do things by yourself and we guide you through the process.
If you want somebody else to make the plugin for you, use the plugin requests section.
i guess help me with this then please
Code:
public logplayers(id)
{
	new  szAuthID[32], szName[32];
	get_user_name(id, szName, 31);
	get_user_authid(id, szAuthID, charsmax(szAuthID));
	log_to_file(g_szFileName, "Name %s | AuthID %s | ", szName, szAuthID)
}
what will be the condition to not duplicate the entries if the player retries?
shadow728988 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 07-11-2019 , 09:28   Re: Read from a file
Reply With Quote #10

You need to read the file to check if the SteamID is already in the list. My advice is reading the file once on map start and store all the SteamIDs in a trie, then simply check if the SteamID is in the trie when the user connects.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
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 17:26.


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