SA-MP Forums

Go Back   SA-MP Forums > Non-English > Languages > Português/Portuguese > Lançamentos/Releases

Reply
 
Thread Tools Display Modes
Old 21/01/2012, 08:14 PM   #1
Jorge_Braz
Big Clucker
 
Join Date: Jul 2011
Posts: 112
Reputation: 4
Default Sistema de Racha

Venho aqui postar mais um trabalho meu !
Sistema de Racha para 2 player ( Claro é racha rs)
Façam bom Uso !

pawn Code:
#include <a_samp>

new carroDU[2];
new correndo[MAX_PLAYERS];
new corrida = 0;
new cashp = 0;
new desafiante;
new colocado = 0;
new correndos[MAX_PLAYERS];
stock PlayerName(playerid)
{
    new Name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, Name, MAX_PLAYER_NAME);
    return Name;
}
new Float:carroe[2][4] = //4 = 4 coordenadas | 3 = 3 "valores" (X,Y,Z)
{
    {2062.4832,-1810.0673,13.0877,91.2496},
    {2059.8037,-1815.0095,13.0877,90.4774}
};
new Float:racha[5][3] = //4 = 4 coordenadas | 3 = 3 "valores" (X,Y,Z)
{
     {1965.8903,-1812.1543,13.0874},
     {1960.6847,-1918.1187,13.0883},
     {1961.8507,-2163.1030,13.0868},
     {1823.5540,-2165.9551,13.0879},
     {1822.8104,-2026.0538,13.0867}
};
public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Blank Filterscript by your name here");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}

stock strtok(const string[], &index)
{
    new length = strlen(string);
    while ((index < length) && (string[index] <= ' '))
    {
        index++;
    }
    new offset = index;
    new result[20];
    while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
    {
        result[index - offset] = string[index];
        index++;
    }
    result[index - offset] = EOS;
    return result;
}
stock strtokEx(const string[], &index)
{
    new length = strlen(string);
    while ((index < length) && (string[index] <= ' '))
    {
        index++;
    }
    new offset = index;
    new result[64];
    while ((index < length) && ((index - offset) < (sizeof(result) - 1)))
    {
        result[index - offset] = string[index];
        index++;
    }
    result[index - offset] = EOS;
    return result;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
    new cmd[128];
    new tmp[128];
    new string[128];
    new idx;
    cmd = strtok(cmdtext, idx);
    if(strcmp(cmd, "/duelarc", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            tmp = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                SendClientMessage(playerid, 0xFFFFFFAA, "USE: /duelarc [id] [Aposta]");
                return 1;
            }
            new playa;
            new money;
            playa = ReturnUser(tmp);
            tmp = strtok(cmdtext, idx);
            money = strval(tmp);
            if(GetPlayerMoney(playerid) < money)
            {
                SendClientMessage(playerid,0xFFFFFFAA,"Você não tem Dinheiro Suficiente");
                return 1;
            }
            if(corrida == 1)
            {
                SendClientMessage(playerid,0xFFFFFFAA,"Está tendo um Racha");
                return 1;
            }
            if(IsPlayerConnected(playa))
            {
                if(playa != INVALID_PLAYER_ID)
                {
                    correndo[playerid] = 1;
                    carroDU[0] = CreateVehicle(434,carroe[0][0],carroe[0][1],carroe[0][2],carroe[0][3],1,0,60000);
                    cashp = money;
                    desafiante = playerid;
                    PutPlayerInVehicle(playerid, carroDU[0], 0);
                    TogglePlayerControllable(playerid, 0);
                    format(string,sizeof(string),"O Jogador %s Desafiou Você para uma Corrida , Aposta %d Cash !",PlayerName(playerid),money);
                    ShowPlayerDialog(playa,10,DIALOG_STYLE_MSGBOX,"Duelo",string,"Aceitar","Fechar");

                }
            }
        }
        return 1;
    }
    return 0;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
    switch(correndos[playerid])
    {
        case 1:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 0, racha[1][0], racha[1][1], racha[1][2], racha[2][0], racha[2][1], racha[2][2], 10);
            correndos[playerid] = 2;
        }
        case 2:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 0, racha[2][0], racha[2][1], racha[2][2], racha[3][0], racha[3][1], racha[3][2], 10);
            correndos[playerid] = 3;
        }
        case 3:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 0, racha[3][0], racha[3][1], racha[3][2], racha[4][0], racha[4][1], racha[4][2], 10);
            correndos[playerid] = 4;
        }
        case 4:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 1, racha[4][0], racha[4][1], racha[4][2], racha[4][0], racha[4][1], racha[4][2]-5, 10);
            correndos[playerid] = 5;
        }
        case 5:
        {
            new strev[256];
            DisablePlayerRaceCheckpoint(playerid);
            colocado++;
            switch(colocado)
            {
                case 1:
                {
                    format(strev,sizeof(strev),"{ffffff}Você Chegou em {037b00}Primeiro {ffffff}Lugar no {037b00}Racha{ffffff} e Ganhou {037b00}%d Cash",cashp*2);
                    SendClientMessage(playerid,0xFFFFFFAA,strev);
                    format(strev,sizeof(strev),"{ffffff}O Jogador {037b00}%s{ffffff}Venceu o Racha e faturou {037b00}%d Cash",PlayerName(playerid),cashp*2);
                    SendClientMessageToAll(0xFFFFFFAA,strev);
                    DestroyVehicle(GetPlayerVehicleID(playerid));
                    correndo[playerid] = 0;
                    correndos[playerid] = 0;
                    corrida = 0;
                    GivePlayerMoney(playerid, cashp*2);
                }
                case 2:
                {
                    format(strev,sizeof(strev),"{ffffff} Você {ff080e}perdeu {ffffff}o Racha ");
                    SendClientMessage(playerid,0xFFFFFFAA,strev);
                    cashp = 0;
                    correndo[playerid] = 0;
                    DestroyVehicle(GetPlayerVehicleID(playerid));
                    colocado = 0;
                    correndos[playerid] = 0;
                    desafiante = 0;
                    return 1;
                }
            }
        }
    }
    return 1;
}

ReturnUser(text[], playerid = INVALID_PLAYER_ID)
{
    new pos = 0;
    while (text[pos] < 0x21) // Strip out leading spaces
    {
        if (text[pos] == 0) return INVALID_PLAYER_ID; // No passed text
        pos++;
    }
    new userid = INVALID_PLAYER_ID;
    if (IsNumeric(text[pos])) // Check whole passed string
    {
        // If they have a numeric name you have a problem (although names are checked on id failure)
        userid = strval(text[pos]);
        if (userid >=0 && userid < MAX_PLAYERS)
        {
            if(!IsPlayerConnected(userid))
            {
                /*if (playerid != INVALID_PLAYER_ID)
                {
                    SendClientMessage(playerid, 0xFF0000AA, "User not connected");
                }*/

                userid = INVALID_PLAYER_ID;
            }
            else
            {
                return userid; // A player was found
            }
        }
        /*else
        {
            if (playerid != INVALID_PLAYER_ID)
            {
                SendClientMessage(playerid, 0xFF0000AA, "Invalid user ID");
            }
            userid = INVALID_PLAYER_ID;
        }
        return userid;*/

        // Removed for fallthrough code
    }
    // They entered [part of] a name or the id search failed (check names just incase)
    new len = strlen(text[pos]);
    new count = 0;
    new name[MAX_PLAYER_NAME];
    for (new i = 0; i < MAX_PLAYERS; i++)
    {
        if (IsPlayerConnected(i))
        {
            GetPlayerName(i, name, sizeof (name));
            if (strcmp(name, text[pos], true, len) == 0) // Check segment of name
            {
                if (len == strlen(name)) // Exact match
                {
                    return i; // Return the exact player on an exact match
                    // Otherwise if there are two players:
                    // Me and MeYou any time you entered Me it would find both
                    // And never be able to return just Me's id
                }
                else // Partial match
                {
                    count++;
                    userid = i;
                }
            }
        }
    }
    if (count != 1)
    {
        if (playerid != INVALID_PLAYER_ID)
        {
            if (count)
            {
                SendClientMessage(playerid, 0xFF0000AA, "Multiple users found, please narrow earch");
            }
            else
            {
                SendClientMessage(playerid, 0xFF0000AA, "No matching user found");
            }
        }
        userid = INVALID_PLAYER_ID;
    }
    return userid; // INVALID_USER_ID for bad return
}
public OnVehicleStreamOut(vehicleid, forplayerid)
{
    return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == 10)
    {
    if(response)
    {
        TogglePlayerControllable(playerid, 0);
        correndo[playerid] = 1;
        GivePlayerMoney(desafiante, - cashp);
        SetVehicleToRespawn(carroDU[1]);
        carroDU[1] = CreateVehicle(434,carroe[1][0],carroe[1][1],carroe[1][2],carroe[1][3],1,0,60000);
        PutPlayerInVehicle(playerid, carroDU[1], 0);
        GivePlayerMoney(playerid, - cashp);
        corrida = 1;
        SetTimer("InicioCorrida", 1000, false);
    }
    else
    {
        TogglePlayerControllable(desafiante, 1);
        cashp = 0;
        SendClientMessage(desafiante,0xFFFF00AA," O Desafiado Recusou, Saia do Veiculo ");
        return 1;
    }
    }
    return 1;
}
forward InicioCorrida();
forward InicioCorrida2();
forward InicioCorrida3();
forward InicioCorrida4();
forward InicioCorrida5();
forward InicioCorridaGo();
public InicioCorrida()
{
    for(new i = 0; i<MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            if(correndo[i] == 1)
            {
                GameTextForPlayer(i, "5", 1001, 5);
                PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
            }
        }
    }
    SetTimer("InicioCorrida2", 1000, false);
    return 1;
}

public InicioCorrida2()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "4", 1001, 5);
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                }
            }
        }
        SetTimer("InicioCorrida3", 1000, false);
        return 1;
}
public InicioCorrida3()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "3", 1001, 5);
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                }
            }
        }
        SetTimer("InicioCorrida4", 1000, false);
        return 1;
}

public InicioCorrida4()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "2", 1001, 5);
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                }
            }
        }
        SetTimer("InicioCorrida5", 1000, false);
        return 1;
}

public InicioCorrida5()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                    GameTextForPlayer(i, "1", 1001, 5);
                }
            }
        }
        SetTimer("InicioCorridaGo", 1000, false);
        return 1;
}
IsNumeric(const string[])
{
    for (new i = 0, j = strlen(string); i < j; i++)
    {
        if (string[i] > '9' || string[i] < '0') return 0;
    }
    return 1;
}
public InicioCorridaGo()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "~r~VALENDO!", 1001, 5);
                    TogglePlayerControllable(i, 1);
                    correndos[i] = 1;
                    SetPlayerRaceCheckpoint(i, 0, racha[0][0], racha[0][1], racha[0][2], racha[1][0], racha[1][1], racha[1][2], 10);
                }
            }
        }
        return 1;
}
__________________

GameMode
Brasil Revolution City
Tutorial
SetTimer
Criar Uma TextDraw
FilterScript
Sistema de Racha

Brasil Life RPG Venha Já !

Last edited by Jorge_Braz; 21/01/2012 at 09:49 PM.
Jorge_Braz is offline   Reply With Quote
Old 21/01/2012, 08:17 PM   #2
dPlaYer_
High-roller
 
dPlaYer_'s Avatar
 
Join Date: Jul 2011
Location: Salvador
Posts: 1,743
Reputation: 179
Default Re: Sistema de Racha

pawn Code:
#include <a_samp>

new carroDU[2];
new correndo[MAX_PLAYERS];
new corrida = 0;
new cashp = 0;
new desafiante;
new colocado = 0;
new correndos[MAX_PLAYERS];
stock PlayerName(playerid)
{
    new Name[MAX_PLAYER_NAME];
    GetPlayerName(playerid, Name, MAX_PLAYER_NAME);
    return Name;
}
new Float:carroe[2][4] = //4 = 4 coordenadas | 3 = 3 "valores" (X,Y,Z)
{
    {2062.4832,-1810.0673,13.0877,91.2496},
    {2059.8037,-1815.0095,13.0877,90.4774}
};
new Float:racha[5][3] = //4 = 4 coordenadas | 3 = 3 "valores" (X,Y,Z)
{
     {1965.8903,-1812.1543,13.0874},
     {1960.6847,-1918.1187,13.0883},
     {1961.8507,-2163.1030,13.0868},
     {1823.5540,-2165.9551,13.0879},
     {1822.8104,-2026.0538,13.0867}
};
public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Blank Filterscript by your name here");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}

stock strtok(const string[], &index)
{
    new length = strlen(string);
    while ((index < length) && (string[index] <= ' '))
    {
        index++;
    }
    new offset = index;
    new result[20];
    while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
    {
        result[index - offset] = string[index];
        index++;
    }
    result[index - offset] = EOS;
    return result;
}
stock strtokEx(const string[], &index)
{
    new length = strlen(string);
    while ((index < length) && (string[index] <= ' '))
    {
        index++;
    }
    new offset = index;
    new result[64];
    while ((index < length) && ((index - offset) < (sizeof(result) - 1)))
    {
        result[index - offset] = string[index];
        index++;
    }
    result[index - offset] = EOS;
    return result;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
    new cmd[128];
    new tmp[128];
    new string[128];
    new idx;
    cmd = strtok(cmdtext, idx);
    if(strcmp(cmd, "/duelarc", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            tmp = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                SendClientMessage(playerid, 0xFFFFFFAA, "USE: /duelarc [id] [Aposta]");
                return 1;
            }
            new playa;
            new money;
            playa = ReturnUser(tmp);
            tmp = strtok(cmdtext, idx);
            money = strval(tmp);
            if(GetPlayerMoney(playerid) < money)
            {
                SendClientMessage(playerid,0xFFFFFFAA,"Você não tem Dinheiro Suficiente");
                return 1;
            }
            if(corrida == 1)
            {
                SendClientMessage(playerid,0xFFFFFFAA,"Está tendo um Racha");
                return 1;
            }
            if(IsPlayerConnected(playa))
            {
                if(playa != INVALID_PLAYER_ID)
                {
                    correndo[playerid] = 1;
                    carroDU[0] = CreateVehicle(434,carroe[0][0],carroe[0][1],carroe[0][2],carroe[0][3],1,0,60000);
                    cashp = money;
                    desafiante = playerid;
                    PutPlayerInVehicle(playerid, carroDU[0], 0);
                    TogglePlayerControllable(playerid, 0);
                    format(string,sizeof(string),"O Jogador %s Desafiou Você para uma Corrida , Aposta %d Cash !",PlayerName(playerid),money);
                    ShowPlayerDialog(playa,10,DIALOG_STYLE_MSGBOX,"Duelo",string,"Aceitar","Fechar");

                }
            }
        }
        return 1;
    }
    return 0;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
    switch(correndos[playerid])
    {
        case 1:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 0, racha[1][0], racha[1][1], racha[1][2], racha[2][0], racha[2][1], racha[2][2], 10);
            correndos[playerid] = 2;
        }
        case 2:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 0, racha[2][0], racha[2][1], racha[2][2], racha[3][0], racha[3][1], racha[3][2], 10);
            correndos[playerid] = 3;
        }
        case 3:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 0, racha[3][0], racha[3][1], racha[3][2], racha[4][0], racha[4][1], racha[4][2], 10);
            correndos[playerid] = 4;
        }
        case 4:
        {
            DisablePlayerRaceCheckpoint(playerid);
            SetPlayerRaceCheckpoint(playerid, 1, racha[4][0], racha[4][1], racha[4][2], racha[4][0], racha[4][1], racha[4][2]-5, 10);
            correndos[playerid] = 5;
        }
        case 5:
        {
            new strev[256];
            DisablePlayerRaceCheckpoint(playerid);
            colocado++;
            switch(colocado)
            {
                case 1:
                {
                    format(strev,sizeof(strev),"{ffffff}Você Chegou em {037b00}Primeiro {ffffff}Lugar no {037b00}Racha{ffffff} e Ganhou {037b00}%d Cash",cashp*2);
                    SendClientMessage(playerid,0xFFFFFFAA,strev);
                    format(strev,sizeof(strev),"{ffffff}O Jogador {037b00}%s{ffffff}Venceu o Racha e faturou {037b00}%d Cash",PlayerName(playerid),cashp*2);
                    SendClientMessageToAll(0xFFFFFFAA,strev);
                    DestroyVehicle(GetPlayerVehicleID(playerid));
                    correndo[playerid] = 0;
                    correndos[playerid] = 0;
                    corrida = 0;
                    GivePlayerMoney(playerid, cashp*2);
                }
                case 2:
                {
                    format(strev,sizeof(strev),"{ffffff} Você {ff080e}perdeu {ffffff}o Racha ");
                    SendClientMessage(playerid,0xFFFFFFAA,strev);
                    cashp = 0;
                    correndo[playerid] = 0;
                    DestroyVehicle(GetPlayerVehicleID(playerid));
                    colocado = 0;
                    correndos[playerid] = 0;
                    desafiante = 0;
                    return 1;
                }
            }
        }
    }
    return 1;
}

ReturnUser(text[], playerid = INVALID_PLAYER_ID)
{
    new pos = 0;
    while (text[pos] < 0x21) // Strip out leading spaces
    {
        if (text[pos] == 0) return INVALID_PLAYER_ID; // No passed text
        pos++;
    }
    new userid = INVALID_PLAYER_ID;
    if (IsNumeric(text[pos])) // Check whole passed string
    {
        // If they have a numeric name you have a problem (although names are checked on id failure)
        userid = strval(text[pos]);
        if (userid >=0 && userid < MAX_PLAYERS)
        {
            if(!IsPlayerConnected(userid))
            {
                /*if (playerid != INVALID_PLAYER_ID)
                {
                    SendClientMessage(playerid, 0xFF0000AA, "User not connected");
                }*/

                userid = INVALID_PLAYER_ID;
            }
            else
            {
                return userid; // A player was found
            }
        }
        /*else
        {
            if (playerid != INVALID_PLAYER_ID)
            {
                SendClientMessage(playerid, 0xFF0000AA, "Invalid user ID");
            }
            userid = INVALID_PLAYER_ID;
        }
        return userid;*/

        // Removed for fallthrough code
    }
    // They entered [part of] a name or the id search failed (check names just incase)
    new len = strlen(text[pos]);
    new count = 0;
    new name[MAX_PLAYER_NAME];
    for (new i = 0; i < MAX_PLAYERS; i++)
    {
        if (IsPlayerConnected(i))
        {
            GetPlayerName(i, name, sizeof (name));
            if (strcmp(name, text[pos], true, len) == 0) // Check segment of name
            {
                if (len == strlen(name)) // Exact match
                {
                    return i; // Return the exact player on an exact match
                    // Otherwise if there are two players:
                    // Me and MeYou any time you entered Me it would find both
                    // And never be able to return just Me's id
                }
                else // Partial match
                {
                    count++;
                    userid = i;
                }
            }
        }
    }
    if (count != 1)
    {
        if (playerid != INVALID_PLAYER_ID)
        {
            if (count)
            {
                SendClientMessage(playerid, 0xFF0000AA, "Multiple users found, please narrow earch");
            }
            else
            {
                SendClientMessage(playerid, 0xFF0000AA, "No matching user found");
            }
        }
        userid = INVALID_PLAYER_ID;
    }
    return userid; // INVALID_USER_ID for bad return
}
public OnVehicleStreamOut(vehicleid, forplayerid)
{
    return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == 10)
    {
    if(response)
    {
        TogglePlayerControllable(playerid, 0);
        correndo[playerid] = 1;
        GivePlayerMoney(desafiante, - cashp);
        SetVehicleToRespawn(carroDU[1]);
        carroDU[1] = CreateVehicle(434,carroe[1][0],carroe[1][1],carroe[1][2],carroe[1][3],1,0,60000);
        PutPlayerInVehicle(playerid, carroDU[1], 0);
        GivePlayerMoney(playerid, - cashp);
        corrida = 1;
        SetTimer("InicioCorrida", 1000, false);
    }
    else
    {
        TogglePlayerControllable(desafiante, 1);
        cashp = 0;
        SendClientMessage(desafiante,0xFFFF00AA," O Desafiado Recusou, Saia do Veiculo ");
        return 1;
    }
    }
    return 1;
}
forward InicioCorrida();
forward InicioCorrida2();
forward InicioCorrida3();
forward InicioCorrida4();
forward InicioCorrida5();
forward InicioCorridaGo();
public InicioCorrida()
{
    for(new i = 0; i<MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            if(correndo[i] == 1)
            {
                GameTextForPlayer(i, "5", 1001, 5);
                PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
            }
        }
    }
    SetTimer("InicioCorrida2", 1000, false);
    return 1;
}

public InicioCorrida2()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "4", 1001, 5);
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                }
            }
        }
        SetTimer("InicioCorrida3", 1000, false);
        return 1;
}
public InicioCorrida3()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "3", 1001, 5);
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                }
            }
        }
        SetTimer("InicioCorrida4", 1000, false);
        return 1;
}

public InicioCorrida4()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "2", 1001, 5);
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                }
            }
        }
        SetTimer("InicioCorrida5", 1000, false);
        return 1;
}

public InicioCorrida5()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
                    GameTextForPlayer(i, "1", 1001, 5);
                }
            }
        }
        SetTimer("InicioCorridaGo", 1000, false);
        return 1;
}
IsNumeric(const string[])
{
    for (new i = 0, j = strlen(string); i < j; i++)
    {
        if (string[i] > '9' || string[i] < '0') return 0;
    }
    return 1;
}
public InicioCorridaGo()
{
        for(new i = 0; i<MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(correndo[i] == 1)
                {
                    GameTextForPlayer(i, "~r~VALENDO!", 1001, 5);
                    TogglePlayerControllable(i, 1);
                    correndos[i] = 1;
                    SetPlayerRaceCheckpoint(i, 0, racha[0][0], racha[0][1], racha[0][2], racha[1][0], racha[1][1], racha[1][2], 10);
                }
            }
        }
        return 1;
}
Tirei as publics q vc nao usou no fs ._.'
__________________

Last edited by dPlaYer_; 21/01/2012 at 09:25 PM.
dPlaYer_ is offline   Reply With Quote
Old 21/01/2012, 09:21 PM   #3
Falcon.
High-roller
 
Falcon.'s Avatar
 
Join Date: Jul 2010
Location: Brazil
Posts: 1,754
Reputation: 155
Default Re: Sistema de Racha

Quote:
Originally Posted by [LF]PlaYer View Post
Tirei as publics q vc nao usou no fs ._.'
faltou isto:

pawn Code:
main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}
__________________

em desenvolvimento...


mais informações: [Off] Novo modo de RP/RPG - Esqueça orgs, líderes, blah blah...
Falcon. is offline   Reply With Quote
Old 21/01/2012, 09:25 PM   #4
dPlaYer_
High-roller
 
dPlaYer_'s Avatar
 
Join Date: Jul 2011
Location: Salvador
Posts: 1,743
Reputation: 179
Default Re: Sistema de Racha

Tirei já '-'
__________________
dPlaYer_ is offline   Reply With Quote
Old 21/01/2012, 09:33 PM   #5
.Skool_.
Huge Clucker
 
.Skool_.'s Avatar
 
Join Date: Aug 2011
Posts: 229
Reputation: 12
Default Respuesta: Sistema de Racha

Tem certeza que este FILTERSCRIPT foi você que fez?
__________________
> Midnight Knights & Drift Hobby
Drifting 4ever.
IP: 189.1.171.83:7786

Youtuber channel: www.youtube.com/user/SkoolDrift
.Skool_. is offline   Reply With Quote
Old 21/01/2012, 09:44 PM   #6
Jorge_Braz
Big Clucker
 
Join Date: Jul 2011
Posts: 112
Reputation: 4
Default Re: Sistema de Racha

Fui eu sim !
Criei a pouco tempo, cara não sou de copiar nada de ninguem !
__________________

GameMode
Brasil Revolution City
Tutorial
SetTimer
Criar Uma TextDraw
FilterScript
Sistema de Racha

Brasil Life RPG Venha Já !
Jorge_Braz is offline   Reply With Quote
Old 21/01/2012, 09:49 PM   #7
Jorge_Braz
Big Clucker
 
Join Date: Jul 2011
Posts: 112
Reputation: 4
Default Re: Sistema de Racha

Atualizado !
[LF]PlaYer Brigadao cara, ! era preguiça mesmo rs!
__________________

GameMode
Brasil Revolution City
Tutorial
SetTimer
Criar Uma TextDraw
FilterScript
Sistema de Racha

Brasil Life RPG Venha Já !
Jorge_Braz is offline   Reply With Quote
Old 21/01/2012, 09:58 PM   #8
dPlaYer_
High-roller
 
dPlaYer_'s Avatar
 
Join Date: Jul 2011
Location: Salvador
Posts: 1,743
Reputation: 179
Default Re: Sistema de Racha

Nadz '
__________________
dPlaYer_ is offline   Reply With Quote
Old 21/01/2012, 10:29 PM   #9
Bolinha_ProJogos
Big Clucker
 
Join Date: Aug 2011
Posts: 136
Reputation: 7
Default Re: Sistema de Racha

Sistema de Racha a cabeça isso sim,kkkkkk
Legal gostei
__________________
Cisco Asa 5520 em ação!
Sorteio de Host para SA:MP Clique aqui!
GTA SA:MP HOST:
Processador Intel Bi Xeon E5606 2.53Ghz
UpLink: 10 Gbps
Ping: 180 ~ 220
Proteção Firewall APF
Proteção Cisco ASA 5520
Data Center OVH Europa
Painel de Controle GameCP
Acesso FileZilla(FTP)
Atendimento 24Horas

PlayGame Hosting
Bolinha_ProJogos is offline   Reply With Quote
Old 21/01/2012, 11:02 PM   #10
RNT
Huge Clucker
 
RNT's Avatar
 
Join Date: Jan 2012
Posts: 472
Reputation: 5
Default Re: Sistema de Racha

da proxima vez tira printscr do seu Fs e posta junto fica bem melhor !

Last edited by RNT; 22/01/2012 at 03:27 PM.
RNT is offline   Reply With Quote
Reply

Thread Tools
Display Modes

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
[FilterScript] Sistema de Clanes + Sistema de Administracion <Actualizado> ConecCionMex Lanzamientos/Releases 25 02/10/2014 08:49 PM
[Tutorial] Sistema de Registro + Profissão + Sistema de Administração Nake01 Lançamentos/Releases 19 02/03/2012 10:30 PM
Sistema de Clanes + Sistema de Administracion ConecCionMex Lanzamientos/Releases 20 23/10/2011 02:29 AM
[Pedido]Sistema de Corridas [Racha] dPlaYer_ Português/Portuguese 9 29/09/2011 01:15 AM


All times are GMT. The time now is 07:41 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.