[Ajuda] [Warn] warning 213: tag mismatch
#1

BOMBER FILTERSCRIPT 0.97

pawn Код:
//============Includes================//
#include <a_samp>
#include <mapandreas>

forward OnBombExplode(playerid, num, Float:x, Float:y, Float:z);

enum bombEnum {
    bombName[32],
    expID,
    Float:expRadius,
    Float:accuracy,
    bombModel,
    bombModelRot,
    expDelay,
    reloadTime,
    dropAtOnce,
    dropAtOnceDelay
}

new gBombTypes[][bombEnum] = {
{"Nothing", 0, 0.0, 0.0, 0, 0, 0, 0, 0, 0},
{"Normal bombs", 11, 2.8, 6.0, 1636, 270, 500, 150, 1, 0},
{"Fire bombs", 1, 4.0, 8.0, 1636, 270, 0, 200, 1, 0},
{"Big bombs", 7, 4.5, 10.0, 3790, 270, 0, 750, 1, 0},
{"Laser-guided Bombs", 6, 5.0, 25.0, 1636, 270, 0, 1500, 1, 0},
{"Heavy bombs", -1, 5.0, 15.0, 345, 270, 0, 10000, 1, 0},
{"Anti-Missile Flares", -2, 150.0, 35.0, 354, 0, 5000, 10000, 1, 0},
{"Nuclear Bombs", -3, 4.0, 10.0, 3790, 270, 0, 10000, 1, 0},
{"Clusterbombs", 11, 2.5, 3.0, 1636, 270, 0, 15000, 12, 0},
{"Carpetbombs", 11, 2.5, 5.5, 1636, 270, 0, 15000, 12, 100}
};

public OnBombExplode(playerid, num, Float:x, Float:y, Float:z)
{
        for(new i = 0; i < MAX_PLAYERS; i ++)
        {
            if(GetPlayerDistanceToPoint(i, x, y, z) < 2)
//========================Linha abaixo que dб o Warning=========================
            if(gBombTypes[btype[playerid][num]][2]) //FSbomber.pwn(369) : warning 213: tag mismatch
            {
                SetPVarInt(i, "nearExp", playerid);
                SetTimerEx("ResetNearExp", 15000, 0, "i", i);
            }
        }
        return 1;
}
Axo que isto que postei dб para entender!
O Warn consiste e piora quando tento mexer '--'. (4 Dias tentando consertar error)...
Reply
#2

pawn Код:
public OnBombExplode(playerid, num, Float:x, Float:y, Float:z)
{
    for(new i = 0; i < MAX_PLAYERS; i ++)
    {
        if(GetPlayerDistanceToPoint(i, x, y, z) < 2 gBombTypes[btype[playerid][num]][2])
        {
            SetPVarInt(i, "nearExp", playerid);
            SetTimerEx("ResetNearExp", 15000, 0, "i", i);
        }
    }
    return 1;
}
Troque a sua antiga Callback, por esta.
Reply
#3

Mais Erros!!
pawn Код:
FSbomber.pwn(369) : error 001: expected token: ")", but found "-identifier-"
FSbomber.pwn(369) : warning 213: tag mismatch
FSbomber.pwn(369) : warning 215: expression has no effect
FSbomber.pwn(369) : error 001: expected token: ";", but found ")"
FSbomber.pwn(369) : error 029: invalid expression, assumed zero
FSbomber.pwn(369) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
Se eu fizer isso funfa mas n solta bombas!

pawn Код:
public OnBombExplode(playerid, num, Float:x, Float:y, Float:z)
{
        for(new i = 0; i < MAX_PLAYERS; i ++)
        {
            if(GetPlayerDistanceToPoint(i, x, y, z) < 2)
            if(gBombTypes[btype[playerid][num]][expID]) /* o 2 mudei pra isto! a bombenum "expID" */
            {
                SetPVarInt(i, "nearExp", playerid);
                SetTimerEx("ResetNearExp", 15000, 0, "i", i);
            }
        }
        return 1;
}
Assim compila Mas quando testo nгo funfa nada! Eu aperto Espase ou proxima bomba na bolinha do mouse nada aconteзe! Nill tenta resolver pelo jeito ke tu fez!
Reply
#4

Tente
pawn Код:
public OnBombExplode(playerid, num, Float:x, Float:y, Float:z)
{
        for(new i = 0; i < MAX_PLAYERS; i ++)
        {
            if(GetPlayerDistanceToPoint(i, x, y, z) < 2)
            {
                SetPVarInt(i, "nearExp", playerid);
                SetTimerEx("ResetNearExp", 15000, 0, "i", i);
            }
        }
        return 1;
}
Reply
#5

pawn Код:
public OnBombExplode(playerid, num, Float:x, Float:y, Float:z) {
    for(new i; i != MAX_PLAYERS; i++) {
        if(GetPlayerDistanceToPoint(i, x, y, z) < 2) {
            if(gBombTypes[btype[playerid][num]][2]) {
                SetPVarInt(i, "nearExp", playerid);
                SetTimerEx("ResetNearExp", 15000, false, "i", i);
            }
        }
    }
    return 1;
}
Reply
#6

Quote:

Tente
pawn Code:

public OnBombExplode(playerid, num, Float: x, Float: y, Float: z)
{
for(new i = 0; i < MAX_PLAYERS; i ++)
{
if(GetPlayerDistanceToPoint(i, x, y, z) < 2)
{
SetPVarInt(i, "nearExp", playerid);
SetTimerEx("ResetNearExp", 15000, 0, "i", i);
}
}
return 1;
}

Vai dar certo! Mas nгo irб soltas as bombas!
Quote:

public OnBombExplode(playerid, num, Float: x, Float: y, Float: z) {
for(new i; i != MAX_PLAYERS; i++) {
if(GetPlayerDistanceToPoint(i, x, y, z) < 2) {
if(gBombTypes[btype[playerid][num]][2]) {
SetPVarInt(i, "nearExp", playerid);
SetTimerEx("ResetNearExp", 15000, false, "i", i);
}
}
}
return 1;
}

O que vocк mudou? Acho que nada pois o warning ainda consiste.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)