Pomoc

Započeo HOB1x, Decembar 11, 2012, 15:37:44 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 3 gostiju pregledaju ovu temu.

Skripta koju koristim: DREAMWORLD
Detaljan opis problema:Pa napravio sam i kad kucam /on i nece da mi pokaze onduty sa zelenim bukvama mogu mi srediti ova neko?
if (strcmp(cmd, "/admins", true) == 0)
{
        if(IsPlayerConnected(playerid))
    {
SendClientMessage(playerid, COLOR_LIGHTBLUE, "_______________DreamWorld Adminâ,,¢_______________");
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
    if(PlayerInfo[i][pAdmin] == 1)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 1 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 1 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 2)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 2 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 2 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 3)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 3 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 3 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
    if(PlayerInfo[i][pAdmin] == 4)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 4 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 4 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 5)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 5 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 5 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 1337)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Z.Head | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Z.Head | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 1338)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Head Admin | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Head Admin | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
}
}
}
return 1;

Dio skripte:
Neke slike/video za lakse dobivanje pomoci(neobavezno):

if (strcmp(cmd, "/admins", true) == 0)
{
        if(IsPlayerConnected(playerid))
    {
SendClientMessage(playerid, COLOR_GREEN, "_______________[cenzura] Adminâ,,¢_______________");
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
    if(PlayerInfo[i][pAdmin] == 1)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 1 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 1 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 2)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 2 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 2 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 3)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 3 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 3 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
    if(PlayerInfo[i][pAdmin] == 4)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 4 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 4 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 5)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 5 | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Level: 5 | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 1337)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Z.Head | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Z.Head | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
if(PlayerInfo[i][pAdmin] == 1338)
    {
if(AdminDuty[playerid] == 1)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Head Admin | {37F906}On Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
else if(AdminDuty[playerid] == 0)
{
GetPlayerName(i, sendername, sizeof(sendername));
format(string, 256, "Administrator: %s | Head Admin | "COL_RED"Off Duty", sendername);
SendClientMessage(playerid, COLOR_WHITE, string);
}
}
}
}
}
return 1;
}
ako sam te dobro razumeo?

pa brate nece mi OFf duty sam i kad kucam /on i kad sam /off to je bag nekakov kako mogu rjesiti?

mnogo manjom komandom mozes to napraviti,  if (strcmp(cmd, "/admini", true) == 0) //
{
        SendClientMessage(playerid, -1, " ");
        SendClientMessage(playerid, -1, "-| ADMIN ONLINE |-");
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
    if(PlayerInfo[i][pAdmin] >= 1 && PlayerInfo[i][pAdmin] < 1338)
    {
        new admtext[64];
        else if(PlayerInfo[i][pAdmin] == 1338) { admtext = "Owner; }
        else if(PlayerInfo[i][pAdmin] == 1337) { admtext = "HeadAdmin"; }
else if(PlayerInfo[i][pAdmin] == 4) { admtext = "Admin level:5"; }
        else if(PlayerInfo[i][pAdmin] == 4) { admtext = "Admin level:4"; }
else if(PlayerInfo[i][pAdmin] == 3) { admtext = "Admin level:3"; }
else if(PlayerInfo[i][pAdmin] == 2) { admtext = "Admin level:2"; }
else if(PlayerInfo[i][pAdmin] ==1) { admtext = "Admin level:1"; }
else { admtext = "niko"; }
GetPlayerName(i, sendername, sizeof(sendername));
if(AdminDuty[i] == 0)
{
format(string, 256, "[ - ]:%s ( %s )", sendername, admtext);
SendClientMessage(playerid, -1, string);
}
else
{
    format(string, 256, "[ NA DUZNOSTI ]%s ( %s )", sendername, admtext);
SendClientMessage(playerid, -1, string);
}
}
}
}
}
return 1;
}



Greska moja ne dava erori nego pravi dont'send pawno....