[AJUDA/PEDIDO] Comando nгo achados
#28

Quote:
Originally Posted by ViCtOr_Mc
View Post
Ah rjjj, eu testei seu Anti-Caps, so que fico bugado, toda hora que digito:

EAE PESSOAL, ele aparece:

EAE PESSOAl
EAE PESSOal
EAE PESSoal
EAE PESsoal
EAE PEssoal
EAE Pessoal
EAE pessoal
EAe pessoal
Eae pessoal
eae pessoal

Isso tudo aparece no xat, fica muito paia, por que quando tu vai dizer alguma coisa, ele tampa o xat tudo atй fazer a letra do cara ficar minusculo.

, desculpa, coloquei o SendPlayerMessageToAll dentro do Loop sem querer :




Bem, o seu problema do /kick jб foi resolvido por feliperch .




Quanto ao Anti CapsLock, arrumei pra vocк, basta colocar no seu OnPlayerText, o seguinte cуdigo:



pawn Code:
for(new x = 0, y = strlen(text); x != y; x++)
    {
        if(text[x] == '{' && text[x+7] == '}')
        {
            x += 7;
        }
        else
        {
            text[x] = tolower(text[x]);
        }
    }
    SendPlayerMessageToAll(playerid, text);


Lembre-se de trocar todas os return 1; do seu OnPlayerText por return 0; .



Se quiser formatar a mensagem, apenas troque o:



pawn Code:
SendPlayerMessageToAll(playerid, text);


Por:



pawn Code:
format(text,128, "Cor ou Qualquer coisa aqui. Mensagem: %s", text);
SendClientMessageToAll(0xFFFFFFAA, text);


E fazer como o exemplo acima .



Anti CapsLock = Testado e funcionando .






E, quanto ao comando /pintar, como citei antes, o cуdigo que Shadoww postou estб correto (foi testado e funciona perfeitamente ).




Mas troquei a identaзгo do cуdigo para a "identaзгo do new.pwn"




Aqui estб, apenas coloque :



pawn Code:
//No OnPlayerCommandText:


if(!strcmp("/pintar",cmdtext,true,7))
    {
        if(!IsPlayerInAnyVehicle(playerid))
        {
            SendClientMessage(playerid, 0xFF0000FF, "Vocк nгo estб em nenhum veiculo.");
            return 1;
        }
        ShowPlayerDialog(playerid, 171, DIALOG_STYLE_INPUT, "CORES", "Digite o ID da primeira cor:", "Enviar", "Cancelar");
        return true;
    }




//E por fim, no OnDialogResponse:


if(dialogid == 171)
    {
        if(response)
        {
            if(!strlen(inputtext))
            {
                ShowPlayerDialog(playerid, 171, DIALOG_STYLE_INPUT, "CORES", "Digite o ID da primeira cor:", "Enviar", "Cancelar");
                return 1;
            }
            if(strval(inputtext) < 0 || strval(inputtext) > 126)
            {
                ShowPlayerDialog(playerid, 171, DIALOG_STYLE_INPUT, "CORES", "Cor Invбlida.\nDigite o ID da primeira cor novamente:", "Enviar", "Cancelar");
                return 1;
            }
            SetPVarInt(playerid, "Cor", strval(inputtext));
            ShowPlayerDialog(playerid, 172, DIALOG_STYLE_INPUT, "CORES", "Digite o ID da segunda cor:", "Enviar", "Cancelar");
        }
        return true;
    }
    if(dialogid == 172)
    {
        if(response)
        {
            if(!strlen(inputtext))
            {
                ShowPlayerDialog(playerid, 172, DIALOG_STYLE_INPUT, "CORES", "Digite o ID da segunda cor:", "Enviar", "Cancelar");
                return 1;
            }
            if(strval(inputtext) < 0 || strval(inputtext) > 126)
            {
                ShowPlayerDialog(playerid, 172, DIALOG_STYLE_INPUT, "CORES", "Cor Invбlida.\nDigite o ID da segunda cor novamente:", "Enviar", "Cancelar");
                return 1;
            }
            ChangeVehicleColor(GetPlayerVehicleID(playerid), GetPVarInt(playerid, "Cor"), strval(inputtext));
            DeletePVar(playerid, "Cor");
        }
        return true;
    }


Qualquer problema, releia novamente e siga todos os passos citados neste post .



Espero ter ajudado .
Reply


Messages In This Thread
[AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 10.07.2011, 16:05
Re: [AJUDA/PEDIDO] Comando nгo achados - by Macintosh - 10.07.2011, 16:18
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 10.07.2011, 16:54
Re: [AJUDA/PEDIDO] Comando nгo achados - by RockFire - 10.07.2011, 16:58
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 10.07.2011, 17:08
Re: [AJUDA/PEDIDO] Comando nгo achados - by RockFire - 10.07.2011, 17:23
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 10.07.2011, 23:17
Re: [AJUDA/PEDIDO] Comando nгo achados - by RockFire - 10.07.2011, 23:30
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 13:26
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 14:23
Re: [AJUDA/PEDIDO] Comando nгo achados - by Macintosh - 11.07.2011, 15:01
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 16:53
Re: [AJUDA/PEDIDO] Comando nгo achados - by rjjj - 11.07.2011, 17:07
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 17:16
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 17:32
Re: [AJUDA/PEDIDO] Comando nгo achados - by rjjj - 11.07.2011, 17:33
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 17:49
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 11.07.2011, 18:02
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 19:14
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 20:41
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 11.07.2011, 21:09
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 21:13
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 11.07.2011, 21:23
Re: [AJUDA/PEDIDO] Comando nгo achados - by RockFire - 11.07.2011, 21:32
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 21:47
Re: [AJUDA/PEDIDO] Comando nгo achados - by CocaC0la - 11.07.2011, 21:59
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 11.07.2011, 22:05
Re: [AJUDA/PEDIDO] Comando nгo achados - by rjjj - 12.07.2011, 03:34
Re: [AJUDA/PEDIDO] Comando nгo achados - by [S]trong - 12.07.2011, 04:20
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 12.07.2011, 12:43
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 12.07.2011, 14:22
Re: [AJUDA/PEDIDO] Comando nгo achados - by [S]trong - 12.07.2011, 14:48
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 12.07.2011, 15:10
Re: [AJUDA/PEDIDO] Comando nгo achados - by [S]trong - 12.07.2011, 15:34
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 12.07.2011, 15:35
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 12.07.2011, 16:13
Re: [AJUDA/PEDIDO] Comando nгo achados - by Shadoww5 - 13.07.2011, 12:45
Re: [AJUDA/PEDIDO] Comando nгo achados - by ViCtOr_Mc - 13.07.2011, 14:23

Forum Jump:


Users browsing this thread: 12 Guest(s)