[Ajuda] /abrirhospital
#1

boas criei um hospital e tipo criei este comando

pawn Код:
if(!strcmp(cmdtext, "/abrirhospital", true)) // By Ellis
{
    if(PlayerInfo[playerid][pLeader] == 4 || PlayerInfo[playerid][pLeader] == 4 || PlayerInfo[playerid][pLeader] == 4 || PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 3)
    {
     else if (PlayerToPoint(15, playerid,1544.700317,-1630.735717,13.096980))
        {
            DestroyObject( hospitalgate );
            hospitalgate1 = CreateObject(968,2276.48144531,-51.65429688,27.59509277,0.00000000,90.00000000,0.00000000);
            SetTimer("GateClose5", 6000, 0);
            SendClientMessage(playerid, COLOR_BLUE,"O portгo й aberto e serб encerrado em 6 segundos.");
            GetPlayerName(playerid, sendername, sizeof(sendername));
            format(string, sizeof(string), "* %s pega no seu remoto e abre o portгo.", sendername);
            ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
e dame estes erros :S

Quote:

C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(1732) : error 004: function "SafeGivePlayerMoney" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(1761) : error 004: function "SafeGivePlayerMoney" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(1797) : error 004: function "SafeResetPlayerWeapons" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(179 : error 004: function "SafeGivePlayerWeapon" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(1825) : error 004: function "SafeResetPlayerWeapons" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2299) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2310) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2322) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2326) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(233 : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2342) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2346) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2350) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2354) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(235 : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2362) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2366) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(237 : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2382) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2386) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2390) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2394) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2406) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2410) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2414) : error 004: function "PlayerToPoint" is not implemented
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(2426) : error 004: function "PlayerToPoint" is not implemented

Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


26 Errors.

algum me ajuda ? agradeзo
Reply
#2

PHP код:
stock SafeGivePlayerMoneyplayeridcash )
{
    
PlayerInfoplayerid ][ pCash ] += cash;
    return 
1;
}
PlayerToPointFloat:radiusplayeridFloat:XFloat:YFloat:)
{
  new 
Float:oldpos], Float:temppos];
  
GetPlayerPosplayeridoldpos], oldpos], oldpos] );
  
temppos] = ( oldpos] -);
  
temppos] = ( oldpos] -);
  
temppos] = ( oldpos] -);
  if( ( ( 
temppos] < radius ) && ( temppos] > -radius ) ) && ( ( temppos] < radius ) && ( temppos] > -radius ) ) && ( ( temppos] < radius ) && ( temppos] > -radius ) ) )
  {
    return 
true;
  }
  return 
false;

Reply
#3

o que ? nao persevi :S
Reply
#4

tenta
pawn Код:
if(strcmp(cmdtext, "/abrirhospital", true)) // By Ellis
{
    if(PlayerInfo[playerid][pLeader] == 4 || PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 3)
    {
     if (PlayerToPoint(playerid, 15,1544.700317,-1630.735717,13.096980))
        {
            DestroyObject( hospitalgate );
            hospitalgate1 = CreateObject(968,2276.48144531,-51.65429688,27.59509277,0.00000000,90.00000000,0.00000000);
            SetTimer("GateClose5", 6000, 0);
            SendClientMessage(playerid, COLOR_BLUE,"O portгo й aberto e serб encerrado em 6 segundos.");
            GetPlayerName(playerid, sendername, sizeof(sendername));
            format(string, sizeof(string), "* %s pega no seu remoto e abre o portгo.", sendername);
            ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        return 1;
}
Reply
#5

nao deu.. fica com os mesmos erros
Reply
#6

pawn Код:
if(!strcmp(cmdtext, "/abrirhospital", true)) // By Ellis
{
    if(PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 3)
    {
        if(IsPlayerInRangeOfPoint(playerid, 5.0, 1544.700317,-1630.735717,13.096980))
        {
            DestroyObject( hospitalgate );
            hospitalgate1 = CreateObject(968,2276.48144531,-51.65429688,27.59509277,0.00000000,90.00000000,0.00000000);
            SetTimer("GateClose5", 6000, 0);
            SendClientMessage(playerid, COLOR_BLUE,"O portгo й aberto e serб encerrado em 6 segundos.");
            GetPlayerName(playerid, sendername, sizeof(sendername));
            format(string, sizeof(string), "* %s pega no seu remoto e abre o portгo.", sendername);
            ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
    }
    return true;
}
@EDIT

esse cуdigo o lider/membro da org 1 2 3 poderб usar.

Vlw trans...
Reply
#7

Esses erros sгo geralmente causados pela falta de alguma chave. Tenta isso:

PHP код:
if(strcmp(cmdtext"/abrirhospital"true)) // By Ellis
{
    if(
PlayerInfo[playerid][pLeader] == || PlayerInfo[playerid][pLeader] == || PlayerInfo[playerid][pLeader] == || PlayerInfo[playerid][pMember] == || PlayerInfo[playerid][pMember] == || PlayerInfo[playerid][pMember] == 3)
    {
        if (
PlayerToPoint(15playerid,1544.700317,-1630.735717,13.096980))
        {
            
DestroyObjecthospitalgate );
            
hospitalgate1 CreateObject(968,2276.48144531,-51.65429688,27.59509277,0.00000000,90.00000000,0.00000000);
            
SetTimer("GateClose5"60000);
            
SendClientMessage(playeridCOLOR_BLUE,"O portгo й aberto e serб encerrado em 6 segundos.");
            
GetPlayerName(playeridsendernamesizeof(sendername));
            
format(stringsizeof(string), "* %s pega no seu remoto e abre o portгo."sendername);
            
ProxDetector(30.0playeridstringCOLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
            }
        return 
1;
    }
    return 
1;

Reply
#8

APARECE ME ESTES ERROS AGORA:

Quote:

C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(3356) : warning 219: local variable "string" shadows a variable at a preceding level
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(10083) : error 017: undefined symbol "hospitalgate"
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(10084) : error 017: undefined symbol "hospitalgate1"
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(17471) : error 017: undefined symbol "hospitalgate"
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(17472) : error 017: undefined symbol "hospitalgate1"
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(4385 : warning 219: local variable "alarme" shadows a variable at a preceding level
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(4385 : warning 219: local variable "portas" shadows a variable at a preceding level
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(4385 : warning 219: local variable "capo" shadows a variable at a preceding level
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(4385 : warning 219: local variable "portamalas" shadows a variable at a preceding level
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(43882) : warning 203: symbol is never used: "SetWorld"
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(42076) : warning 204: symbol is assigned a value that is never used: "roadblocktimer"
C:\Users\Ricardo Moreira\Desktop\RedContry\RP-NossaComunidade 0.3c.1\gamemodes\RP-NossaComunidade.pwn(10085) : warning 204: symbol is assigned a value that is never used: "tugate"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


4 Errors.

Mas axo que foi de alguma coisa mal que eu fiz eu meti isto vejam

Quote:

hospitalgate = CreateObject(968,2278.73876953,-51.65792465,27.59509277,0.00000000,9.00000000,0.00 000000);
hospitalgate1 = CreateObject(968,2276.48144531,-51.65429688,27.59509277,0.00000000,90.00000000,0.0 0000000);

mas axo que fiz bem xD
Reply
#9

pawn Код:
new hospitalgate1;
new hospitalgate;
Reply
#10

Nуs nгo podemos adivinhar porque estб dando erro, entгo mande-nos as linhas.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)