SA-MP Forums Archive
admin help - 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: admin help (/showthread.php?tid=93858)



admin help - sggassasin - 27.08.2009

how do i make it so i can make it so that if i level 5 i can do level 1-5


plz help


Re: admin help - .::: Ecko :::. - 27.08.2009

Download an admin fs,and there you go.

Ecko


Re: admin help - James_Alex - 27.08.2009

if(aAdmin[playerid] <= 5)

you need to to use <=


Re: admin help - sggassasin - 27.08.2009

thank you


Re: admin help - .::: Ecko :::. - 27.08.2009

Quote:
Originally Posted by ► James_Alex
if(aAdmin[playerid] <= 5)

you need to to use <=
Didn't he asked about /setlevel ?

Ecko


Re: admin help - sggassasin - 27.08.2009

just 1 other thing how could i make this work....



Код:
dcmd_detail(playerid, params[])
{
if (strlen(params))
	{
		if (IsPlayerConnected(playerid))
		{
  new string[48];
  format(string, sizeof(string), "-- You Have %s In Your Bank --", gPlayerInfo[playerid][PLAYER_BANK]);
  SendClientMessage(0xAAAAAAAA, "--------------------------);
  SendClientMessage(0xAAAAAAAA, string);
  SendClientMessage(0xAAAAAAAA, "--------------------------");
		}
	}

	return 1;
}



Re: admin help - M4S7ERMIND - 27.08.2009

You are not using any params there..

pawn Код:
dcmd_detail(playerid, params[])
{
  #pragma unused params
  new string[48];
  format(string, sizeof(string), "-- You Have %s In Your Bank --", gPlayerInfo[playerid][PLAYER_BANK]);
  SendClientMessage(0xAAAAAAAA, "--------------------------);
  SendClientMessage(0xAAAAAAAA, string);
  SendClientMessage(0xAAAAAAAA, "
--------------------------");
  return 1;
}
Edit: It should be -- You Have %d In Your Bank --


Re: admin help - sggassasin - 27.08.2009

k thanks


Re: admin help - sggassasin - 27.08.2009

just one little thing how would i make it so a player can go .....


/announce blah blah


then on the screen in the middle it says "blah blah"


Re: admin help - James_Alex - 27.08.2009

try
pawn Код:
if(strcmp(cmd, "/announce", true) == 0)
    {
        new length = strlen(cmdtext);
        while ((idx < length) && (cmdtext[idx] <= ' '))
        {
            idx++;
        }
        new offset = idx;
        new result[64];
        while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
        {
            result[idx - offset] = cmdtext[idx];
            idx++;
        }
        result[idx - offset] = EOS;
        if(!strlen(result))
        {
            SendClientMessage(playerid, COLOR_WHITE, "USAGE: /anounce [text]");
            return 1;
        }
        GameTextForAll(result, 5000, 5);
        return 1;

    }