Script Question
#1

My imagination as an example:

I want: if a player connect and the name of the Player is in a text document in the folder Groups(The folder groups is in the folder sciptfiles) than should the player become a yellw Color
Reply
#2

You cant make folder Groups inside folder filterscripts. Make Folder Groups inside scriptfiles folder and use any File manager include to check and use files.
Reply
#3

oh sorry i mean sciptfiles
Reply
#4

Quote:
Originally Posted by ******
Посмотреть сообщение
It sounds like you are trying to get special people without going to all the effort of developing a full user system. While this aim does seem to have advantages you need to remember that in SA:MP anyone can change their name to anything. If you don't have the password protection of a user system anyone can set their name to say "CWollinger", join your server and become yellow (assuming that being yellow is desirable, if not, no-one will do it, not even those listed people).

I would urge you to look in to getting a proper user system (there are plenty already made) and store if the user is yellow or not in their user data.
And in relation to ******' post, might I recommend YSI? Not only does it contain a powerful and extensive file writer and reader, it has other useful libraries as well which can make tasks easier.

YSI - https://sampforum.blast.hk/showthread.php?tid=61548

PHP код:
#define gvar_colors[MAX_PLAYERS];
public OnPlayerConnnect(playerid)
{
    if(
gvar_colors[playerid] == 1)
    {
        
SetPlayerColor(playerid0xFFFF00AA);
    }

I wouldn't do it this way in particular but, this is a simple example of how it can be done i guess.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)