[Ajuda] Animaзгo
#1

Aew Galera Tava Aki Tentando Colocar Um Anim No meu sistema de roubos Mais o Problema e que Nгo Esta reproduzindo a animaзгo ate o fim do roubo a gente so digitar /roubar e a animaзгo da dois loop e para!

Vo Mandar o Anim.

PHP Code:
ApplyAnimationEx(playerid"ROB_BANK""CAT_Safe_Rob"4.0100010); 
e Agora o Comando /Roubar
PHP Code:
    if(strcmp(cmd,"/roubar",true)==0)
    {
        if(
PlayerInfo[playerid][pMembro] != && PlayerInfo[playerid][pLider] != 5
        
&& PlayerInfo[playerid][pMembro] != 14 && PlayerInfo[playerid][pLider] != 14
        
&& PlayerInfo[playerid][pMembro] != 17 && PlayerInfo[playerid][pLider] != 17
        
&& PlayerInfo[playerid][pMembro] != 18 && PlayerInfo[playerid][pLider] != 18
        
&& PlayerInfo[playerid][pMembro] != 19 && PlayerInfo[playerid][pLider] != 19
        
&& PlayerInfo[playerid][pMembro] != 20 && PlayerInfo[playerid][pLider] != 20
        
&& PlayerInfo[playerid][pMembro] != 21 && PlayerInfo[playerid][pLider] != 21
        
&& PlayerInfo[playerid][pMembro] != 22 && PlayerInfo[playerid][pLider] != 22
        
&& PlayerInfo[playerid][pMembro] != 23 && PlayerInfo[playerid][pLider] != 23
        
&& PlayerInfo[playerid][pMembro] != 24 && PlayerInfo[playerid][pLider] != 24
        
&& GetPlayerOrg(playerid) != && GetPlayerOrg(playerid) != 8
        
&& GetPlayerOrg(playerid) != && GetPlayerOrg(playerid) != 12
        
&& GetPlayerOrg(playerid) != 13 && GetPlayerOrg(playerid) != 15
        
&& GetPlayerOrg(playerid) != 26 && GetPlayerOrg(playerid) != 29)
        {
            
SendClientMessage(playerid,COLOR_GREY,"Vocк nгo pode assaltar !");
            return 
true;
        }
        if(
roubando[playerid] == 1)
        {
               
SendClientMessage(playeridCOLOR_GRAD5"Vocк ja estб roubando algum lugar.");
            return 
true;
        }
        if(
PlayerToPoint(2.0,playerid2144.4177,1641.5360,993.5761))
        {
            if(
roubobanco == 1)
            {
                   
SendClientMessage(playeridCOLOR_GRAD5"Jб estб tendo uma tentativa de roubo nesse cofre.");
                return 
true;
            }
            if(
temporoubobanco == 1)
            {
                   
SendClientMessage(playerid,COLOR_GREY,"Jб roubaram o cofre do banco espere 3 minutos para roubar de novo !");
                return 
true;
            }
            if (
PlayerInfo[playerid][pDinamite] == 0)
            {
                
SendClientMessage(playeridCOR_VAGOS"Vocк nгo Possui Dinamites Para Roubar!");
                return 
1;
            }
            
GetPlayerName(playeridplayernameMAX_PLAYER_NAME);
            
SendClientMessageToAll(COLOR_WHITE"(=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=({FFD700}Assalto ao Banco{BFC0C2})=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=)");
            
format(stringsizeof(string), "%s e os %s estгo tentando roubar o cofre banco! ID:[%d]"playernameNomeORG(playerid) , playerid);
            
SendClientMessageToAll(GetPlayerColor(playerid), string);
            
SendClientMessage(playeridCOLOR_GRAD5"Espere 90 Segundos para terminar de roubar o banco.");
            
CreateExplosion(2306.5127,-6.1166,26.74221210.0);
            
SetPlayerCriminal(playerid,255"Tentativa de Roubo ao Banco");
            
roubando[playerid] = 1;
            
ProvocoBanco[playerid] = 1;
            
roubobanco 1;
            
temporoubobanco 1;
            
SetTimer("Aroubo"2200000);
            
PlayerInfo[playerid][pDinamite] -= 1;
            
tempobanco SetTimerEx("RouboBanco"900000"i"playerid);
            
SetTimerEx("AnimRouboBanco"9000"i"playerid);
            
ApplyAnimationEx(playerid"ROB_BANK""CAT_Safe_Rob"4.0100010);
            
SetPlayerAttachedObject(playerid0155010.000000, -0.3136110.0210030.44549086.754409355.3702390.9268151.0000001.000000);
             
SetTimerEx("AcabarMochila"1000000"i"playerid);
            
TempoContagem[playerid] = SetTimerEx("ContagemHospital"10001"i"playerid);
            
Contagem[playerid] = 88;
            
GetPlayerHealth(playeridHealth_Roubo);
            
SetPlayerHealth(playerid99999999);
            
SetTimerEx("DarLife"3000false"i"playerid);
            return 
1;
        } 
Reply
#2

Code:
ApplyAnimation(playerid, "ROB_BANK", "CAT_Safe_Rob", 4.0, 1, 0, 0, 0, 1, 0);
Caso nгo for coloque no topo do seu Gamemode:

pawn Code:
static animLibName[MAX_PLAYERS][2][32];

ApplyPlayerAnimation(playerid, animlib[], animname[], Float:fDelta, loop, lockx, locky, freeze, time, forcesync = 0) {

    ApplyAnimation(playerid, animlib, "null", fDelta, loop, lockx, locky, freeze, time, forcesync);

    forcesync = 1;

    ApplyAnimation(playerid, animlib, animname, fDelta, loop, lockx, locky, freeze, time, forcesync);


    format(animLibName[playerid][0], 32, animlib    );
    format(animLibName[playerid][1], 32, animname   );

    return SetTimerEx("PlayerSetAnimation", 273, false, "ifdddddd",  playerid, fDelta, loop, lockx, locky, freeze, time, forcesync);
}

PlayerSetAnimation(playerid, Float:fDelta, loop, lockx, locky, freeze, time, forcesync) ;
public PlayerSetAnimation(playerid, Float:fDelta, loop, lockx, locky, freeze, time, forcesync) {

    return ApplyAnimation(playerid, animLibName[playerid][0], animLibName[playerid][1], fDelta, loop, lockx, locky, freeze, time, forcesync);
}

#define ApplyAnimation ApplyPlayerAnimation
Crйditos do cуdigo acima IpsBruno!
Reply
#3

Jб tentou usar apenas ApplyAnimation ?
Reply
#4

Quote:
Originally Posted by Viniborn
View Post
Jб tentou usar apenas ApplyAnimation ?
Eu Usava ApplyAnimation Mais ficava bugado pq as vezes a animaзгo nгo funcionava! Agora eu Estou Usando a Funзгo de ApplyAnimationEx Que Funciona legal mais o problema e que nun esta repetindo a animaзгo ela so funciona uma vez e para!
Reply
#5

Acho Que Ja Concertei Mais Vlw aew!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)