tag mismatch
#1

PHP код:
if(tempdoorobj[playerid]){
        if(
response==EDIT_RESPONSE_FINAL){
            new 
id,m[512],Cache:result;
            
id GetFreeDynamicGateID();
            
DynamicGate[id][door_pos][0] = fX;
            
DynamicGate[id][door_pos][1] = fY;
            
DynamicGate[id][door_pos][2] = fZ;
            
DynamicGate[id][door_rpos][0] = fRotX;
            
DynamicGate[id][door_rpos][1] = fRotY;
            
DynamicGate[id][door_rpos][2] = fRotZ;
            
DynamicGate[id][door_id] = id;
            
DynamicGate[id][door_vw] = GetPlayerVirtualWorld(playerid);
            
DynamicGate[id][door_int] = GetPlayerInterior(playerid);
            
mysql_format(dbhandlemsizeof(m), "INSERT INTO gates (x,y,z,rx,ry,rz,vw,g_int) VALUES ('%f','%f','%f','%f','%f','%f','%i','%i')"DynamicGate[id][door_pos][0],DynamicGate[id][door_pos][1],DynamicGate[id][door_pos][2],DynamicGate[id][door_rpos][0],DynamicGate[id][door_rpos][1],DynamicGate[id][door_rpos][2],DynamicGate[id][door_vw],DynamicGate[id][door_int]);
            
result mysql_query(dbhandlem,true);
            
DynamicDoor[id][door_sqlid]=cache_insert_id();
            
cache_delete(result);
            
SendClientMessageEx(playeridCOLOR_GREY"Gate created successfully, Game ID: %i and SQLID: %i",DynamicGate[id][door_id],DynamicGate[id][door_sqlid]);
            
DestroyObject(tempdoorobj[playerid]);
            
DynamicGate[id][door_object] = CreateDynamicObject(DynamicGate[id][door_model],DynamicGate[id][door_pos][0], DynamicGate[id][door_pos][1], DynamicGate[id][door_pos][2], DynamicGate[id][door_rpos][0], DynamicGate[id][door_rpos][1], DynamicGate[id][door_rpos][2], DynamicGate[id][door_vw], DynamicGate[id][door_int], -1300.0300.0, -10);
        }
    } 
Tag mismatch on this line
PHP код:
result mysql_query(dbhandlem,true);
            
DynamicDoor[id][door_sqlid]=cache_insert_id();
            
cache_delete(result); 
Код:
warning 213: tag mismatch
Reply
#2

I can assure you those lines are not the problem.
Paste your DynamicGate enum here.

Also, you don't need to set use_cache boolean to true because it's the default value. You can simply use mysql_query(dbhandle, m);
Reply
#3

Try
Код:
new Cache:result
instead of
Код:
new result
Reply
#4

Quote:
Originally Posted by Jularra
Посмотреть сообщение
Try
Код:
new Cache:result
instead of
Код:
new result
That's what he has... Show door_sqlid
Reply
#5

Quote:
Originally Posted by TheToretto
Посмотреть сообщение
That's what he has... Show door_sqlid
There you go
PHP код:
enum dynamicdoorenum{
    
door_sqlid,
    
door_id,
    
Float:door_pos[3],
    
Float:door_rpos[3],
    
door_owner,
    
door_faction,
    
door_group,
    
door_object,
    
door_model,
    
door_vw,
    
door_int

Reply
#6

I see nothing wrong.
Reply
#7

Reading your code a second time I noticed this:

pawn Код:
if(response==EDIT_RESPONSE_FINAL)
I am unsure, either response is defined as a boolean or just an integer which has a value of 0 or 1, avoid that as your line of code doesn't make sense, instead use this:

pawn Код:
if(response)
And yes define which specific line.

Edit: if you want to check a condition along with the response, just add another condition:

pawn Код:
if(response && pEditResponse[playerid] > 0)
Reply
#8

Quote:
Originally Posted by TheToretto
Посмотреть сообщение
Reading your code a second time I noticed this:

pawn Код:
if(response==EDIT_RESPONSE_FINAL)
I am unsure, either response is defined as a boolean or just an integer which has a value of 0 or 1, avoid that as your line of code doesn't make sense, instead use this:

pawn Код:
if(response)
And yes define which specific line.

Edit: if you want to check a condition along with the response, just add another condition:

pawn Код:
if(response && pEditResponse[playerid] > 0)
actually EDIT_RESPONSE_FINAL maybe already defined, it not giving me any error,

actual error line is this
PHP код:
DynamicDoor[id][door_sqlid]=cache_insert_id(); 
Reply
#9

Shouldn't it be
Quote:

DynamicGate[id][door_sqlid]=cache_insert_id();

instead of
Quote:

DynamicDoor[id][door_sqlid]=cache_insert_id();

?
Reply
#10

Quote:
Originally Posted by raydx
Посмотреть сообщение
Shouldn't it be instead of ?
ahh...thanks, i didn't saw it :P
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)