SA-MP Forums

Go Back   SA-MP Forums > Non-English > Languages > Português/Portuguese

Reply
 
Thread Tools Display Modes
Old 19/07/2012, 05:09 PM   #1
Fire_Hell
Big Clucker
 
Join Date: Oct 2011
Posts: 103
Reputation: 0
Default Batercartao travando

Gente, queria saber porque que quando a pessoa bate cartao apertando F ela fica travada, no /batercartao ela fica normal...

Aqui ta o código de o Cop batendo cartão com o F.

pawn Code:
if(newkeys == 16 && GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        if(IsACop(playerid))
        {
            OnPlayerCommandText(playerid,"/entrar");
            OnPlayerCommandText(playerid,"/sair");
            OnPlayerCommandText(playerid,"/beber");
            OnPlayerCommandText(playerid,"/menucop");
            if(PlayerToPoint(3,playerid,229.7267,165.0443,1003.0234) || PlayerToPoint(2, playerid,255.3,77.4,1003.6) || PlayerToPoint(2,playerid,-1616.1294,681.1594,7.1875) || PlayerToPoint(2,playerid,230.1107,165.2237,1003.0234) || PlayerToPoint(2, playerid,240.7396,112.9709,1003.2188)
            || PlayerToPoint(2, playerid,1530.5187,-1702.5320,6.2252) || PlayerToPoint(2, playerid,302.7606,-1529.7537,24.9219) || PlayerToPoint(2, playerid,-1345.8823,492.5301,11.2027) || PlayerToPoint(2, playerid,326.4911,307.0710,999.1484) || PlayerToPoint(2, playerid,-2022.5831,-114.2501,1035.1719) && IsACop(playerid))
            {
                if(OnDuty[playerid]==0)
                {
                    format(string, sizeof(string), "O Oficial %s do Governo bateu o cartão e está em serviço", PlayerName(playerid));
                    OOCNews(COLOR_LIGHTBLUE,string);
                    SetPlayerArmour(playerid, 100);
                    SetPlayerHealth(playerid, 100);
                    OnDuty[playerid] = 1;
                    EmpregoDuty[playerid] = 2;
                    Copsronda += 1;
                }
                else if(OnDuty[playerid]==1)
                {
                    format(string, sizeof(string), "O Oficial %s do Governo está de folga", PlayerName(playerid));
                    OOCNews(COLOR_LIGHTBLUE,string);
                    OnDuty[playerid] = 0;
                    EmpregoDuty[playerid] = 0;
                    Copsronda -= 1;
                    }
            }
        }

Vlw.
__________________
_ _ _ _ _ _ _ _ _ _|INICIANTE EM PAWNO|_ _ _ _ _ _ _ _ _ _ _

Ajudei? Da um agradecer, não cai o dedo!
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
Fire_Hell is offline   Reply With Quote
Old 19/07/2012, 05:11 PM   #2
WaGnerLiima
Huge Clucker
 
WaGnerLiima's Avatar
 
Join Date: Sep 2011
Location: Brazil
Posts: 224
Reputation: 4
Default Re: Batercartao travando

tenta
pawn Code:
if(newkeys == 16 && GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
    {
        GetPlayerName(playerid, sendername, sizeof(sendername));
        if(IsACop(playerid))
        {
            OnPlayerCommandText(playerid,"/entrar");
            OnPlayerCommandText(playerid,"/sair");
            OnPlayerCommandText(playerid,"/beber");
            OnPlayerCommandText(playerid,"/menucop");
            if(PlayerToPoint(3,playerid,229.7267,165.0443,1003.0234) || PlayerToPoint(2, playerid,255.3,77.4,1003.6) || PlayerToPoint(2,playerid,-1616.1294,681.1594,7.1875) || PlayerToPoint(2,playerid,230.1107,165.2237,1003.0234) || PlayerToPoint(2, playerid,240.7396,112.9709,1003.2188)
            || PlayerToPoint(2, playerid,1530.5187,-1702.5320,6.2252) || PlayerToPoint(2, playerid,302.7606,-1529.7537,24.9219) || PlayerToPoint(2, playerid,-1345.8823,492.5301,11.2027) || PlayerToPoint(2, playerid,326.4911,307.0710,999.1484) || PlayerToPoint(2, playerid,-2022.5831,-114.2501,1035.1719) && IsACop(playerid))
            {
                if(OnDuty[playerid]==0)
                {
                    format(string, sizeof(string), "O Oficial %s do Governo bateu o cartão e está em serviço", PlayerName(playerid));
                    OOCNews(COLOR_LIGHTBLUE,string);
                    SetPlayerArmour(playerid, 100);
                    SetPlayerHealth(playerid, 100);
                    OnDuty[playerid] = 1;
                    EmpregoDuty[playerid] = 2;
                    Copsronda += 1;
                }
                else if(OnDuty[playerid]==1)
                {
                    format(string, sizeof(string), "O Oficial %s do Governo está de folga", PlayerName(playerid));
                    OOCNews(COLOR_LIGHTBLUE,string);
                    OnDuty[playerid] = 0;
                    EmpregoDuty[playerid] = 0;
                    Copsronda -= 1;
                    }
            return 1;
        }
__________________
Instituto Federal de Ciência e Tecnologia do Maranhão - Informática
WaGnerLiima is offline   Reply With Quote
Old 19/07/2012, 05:37 PM   #3
Fire_Hell
Big Clucker
 
Join Date: Oct 2011
Posts: 103
Reputation: 0
Default AW: Batercartao travando

Deu um monte de erro -.-
__________________
_ _ _ _ _ _ _ _ _ _|INICIANTE EM PAWNO|_ _ _ _ _ _ _ _ _ _ _

Ajudei? Da um agradecer, não cai o dedo!
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
Fire_Hell is offline   Reply With Quote
Old 19/07/2012, 07:54 PM   #4
Fire_Hell
Big Clucker
 
Join Date: Oct 2011
Posts: 103
Reputation: 0
Default AW: Batercartao travando

Up...
__________________
_ _ _ _ _ _ _ _ _ _|INICIANTE EM PAWNO|_ _ _ _ _ _ _ _ _ _ _

Ajudei? Da um agradecer, não cai o dedo!
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
Fire_Hell is offline   Reply With Quote
Old 20/07/2012, 04:27 AM   #5
Fire_Hell
Big Clucker
 
Join Date: Oct 2011
Posts: 103
Reputation: 0
Default AW: Batercartao travando

Up...²
__________________
_ _ _ _ _ _ _ _ _ _|INICIANTE EM PAWNO|_ _ _ _ _ _ _ _ _ _ _

Ajudei? Da um agradecer, não cai o dedo!
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
Fire_Hell is offline   Reply With Quote
Old 20/07/2012, 03:11 PM   #6
Fire_Hell
Big Clucker
 
Join Date: Oct 2011
Posts: 103
Reputation: 0
Default AW: Batercartao travando

Alguem me ajuda plz...
__________________
_ _ _ _ _ _ _ _ _ _|INICIANTE EM PAWNO|_ _ _ _ _ _ _ _ _ _ _

Ajudei? Da um agradecer, não cai o dedo!
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
Fire_Hell is offline   Reply With Quote
Old 20/07/2012, 03:13 PM   #7
Lucas Carneiro™
Big Clucker
 
Lucas Carneiro™'s Avatar
 
Join Date: Jul 2012
Location: São Paulo - Capital
Posts: 67
Reputation: 2
Default Re: Batercartao travando

Travando como? Nã se meche?

Coloca:

TogglePlayerControllable(playerid, true);

debaixo da mensagem de bater cartao ^^
__________________
Scripter e Mapper Lucas Carneiro™.

___________________


Projetos:


TUTORIAL: Agilizando o processo de criação do seu GameMode ou FilterScript.

FILTERSCRIPT: [LC-GMX] GMX Automático com tempo definido !


Lucas Carneiro™ is offline   Reply With Quote
Old 20/07/2012, 03:21 PM   #8
Fire_Hell
Big Clucker
 
Join Date: Oct 2011
Posts: 103
Reputation: 0
Default AW: Batercartao travando

Perfeito vlw
__________________
_ _ _ _ _ _ _ _ _ _|INICIANTE EM PAWNO|_ _ _ _ _ _ _ _ _ _ _

Ajudei? Da um agradecer, não cai o dedo!
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
Fire_Hell is offline   Reply With Quote
Old 20/07/2012, 04:36 PM   #9
Lucas Carneiro™
Big Clucker
 
Lucas Carneiro™'s Avatar
 
Join Date: Jul 2012
Location: São Paulo - Capital
Posts: 67
Reputation: 2
Default Re: AW: Batercartao travando

Quote:
Originally Posted by Fire_Hell View Post
Perfeito vlw


Denada
__________________
Scripter e Mapper Lucas Carneiro™.

___________________


Projetos:


TUTORIAL: Agilizando o processo de criação do seu GameMode ou FilterScript.

FILTERSCRIPT: [LC-GMX] GMX Automático com tempo definido !


Lucas Carneiro™ 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
[AJUDA] SAMP TRAVANDO PC Markos Português/Portuguese 2 25/02/2012 11:37 PM
[Duvida]Travando servidor keller012 Português/Portuguese 0 27/09/2010 10:50 PM


All times are GMT. The time now is 01:36 AM.


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