SA-MP Forums Archive
Ok, basic commands, where are they? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Ok, basic commands, where are they? (/showthread.php?tid=87442)



Ok, basic commands, where are they? - Basketboy - 20.07.2009

Ok, I am a beginner. But! If anybody wants to reply on this topic with "go search", dont reply at all then. I searched, and searched, EVERY link, every wiki page, and I found only those complicated commands which I dont need and dont like.

Now I am kindly asking, what is the command code for:

/register
/login
/stats
/me
/pm
/tpm (team pm)
/shout (send message to local players only)


Now please, dont give me any link, dont redirect me anywhere because I cant find anything, I just simply want those codes! I have searched for weeks for those commands and I never found anything helpful! Just some weak and fake tutorials.


Please, I just need the simple code!

starting with this:

~~if (strcmp("/register", cmdtext, true) == 0)



Thanks ahead
Basketboy


Re: Ok, basic commands, where are they? - refshal - 20.07.2009

1. http://forum.sa-mp.com/index.php?topic=94387.765 - Script Request Thread
2. Try to read the Wiki. There are a couple of articles with the "/register" command. And you'll probably need dini or dudb.


Re: Ok, basic commands, where are they? - MadeMan - 20.07.2009

1. /pm and /tpm should be already there, they are SAMP native commands

2. /register /login /stats - with these, like eddy already said, you probably need dini or dudb to save info to a userfile

3. If you are a beginner then I think you should learn how to do things, not others should learn how to make tutorials for you that you like, if you know what I mean


Re: Ok, basic commands, where are they? - Basketboy - 20.07.2009

Cant you guys just paste the /register code here, please? I cant find myself in wiki, its confuzing.

btw I already have dini.


Re: Ok, basic commands, where are they? - James_Alex - 20.07.2009

juste save all the player stats in a file by using the dini include
you can use
dini_IntSet ==> to Set an integer like(money, score...)
dini_Set ==> to set a string like(message, password, name...)
dini_FloatSet ==> to set a float like(health,armour...)
dini_Int ==> to get the integer
dini_Float ==> to get the float
dini_Get == > to get the string



Re: Ok, basic commands, where are they? - Basketboy - 20.07.2009

Dont forget that I am the beginner, I dont understand you, how to make a working cmd, you know, starting with

~~if (strcmp("/stats", cmdtext, true) == 0)




it is all confuzing to me


Re: Ok, basic commands, where are they? - MadeMan - 20.07.2009

I got 1 question to you. If somebody is going to give the commands codes that you do not understand, what are you going to do with these codes then? If you answer this, maybe I can help you.


Re: Ok, basic commands, where are they? - Basketboy - 20.07.2009

Right now, I dont understand them because I dont have them, but if you would give me the example how one of them works, I will start to understand it. I already understand those commands that sends you client message, someone showed them to me and I understood. How should I understand something if I dont even know what it looks like?

Then with this commands I will allow players on server to register, etc.....


Re: Ok, basic commands, where are they? - MadeMan - 20.07.2009

Example /register command:

pawn Code:
dcmd_register(playerid, params[])
{
    new pass[128]; filename[128], playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, MAX_PLAYER_NAME);
    format(filename, sizeof(filename), "%s.ini", playername);
    if(sscanf(params, "s", pass)) SendClientMessage(playerid, COLOR, "USAGE: /register [password]");
    else
    {
        if(!dini_Exists(filename))
        {
            dini_Create(filename);
            dini_IntSet(filename, "Password", udb_hash(pass));
            SendClientMessage(playerid, COLOR, "You are registered!");
        }
    }
    return 1;
}



Re: Ok, basic commands, where are they? - Basketboy - 20.07.2009

thank you