callbacks.pwn(1213) : warning 213: tag mismatch callbacks.pwn(1217) : warning 213: tag mismatch callbacks.pwn(1221) : wa
#1

Code:
callbacks.pwn(1213) : warning 213: tag mismatch
callbacks.pwn(1217) : warning 213: tag mismatch
callbacks.pwn(1221) : warning 213: tag mismatch
callbacks.pwn(1225) : warning 213: tag mismatch
callbacks.pwn(1229) : warning 213: tag mismatch
callbacks.pwn(1242) : error 001: expected token: "]", but found ")"
callbacks.pwn(1243) : error 001: expected token: "]", but found ")"
callbacks.pwn(1244) : error 001: expected token: "]", but found ")"
callbacks.pwn(1245) : error 001: expected token: "]", but found ")"
callbacks.pwn(1246) : error 001: expected token: "]", but found ")"
callbacks.pwn(1247) : error 001: expected token: "]", but found ")"
callbacks.pwn(1248) : error 001: expected token: "]", but found ")"
callbacks.pwn(1249) : error 001: expected token: "]", but found ")"
callbacks.pwn(1250) : error 001: expected token: "]", but found ")"
callbacks.pwn(1251) : error 001: expected token: "]", but found ")"
callbacks.pwn(1252) : error 001: expected token: "]", but found ")"
callbacks.pwn(1253) : error 001: expected token: "]", but found ")"
This is my code https://pastebin.com/raw/vE8SHR1b
Ctrl F: line 1213 and line 1253

https://pastebin.com/raw/bCNRnsKd

EDIT:

Now only bug
Code:
./includes/callbacks.pwn(1211) : warning 213: tag mismatch
./includes/callbacks.pwn(1215) : warning 213: tag mismatch
./includes/callbacks.pwn(1219) : warning 213: tag mismatch
./includes/callbacks.pwn(1223) : warning 213: tag mismatch
./includes/callbacks.pwn(1227) : warning 213: tag mismatch
from
Code:
	if(_:clickedid != INVALID_TEXT_DRAW) 
	{
		if(clickedid == GUI_HuongDan[playerid][1]) // nhan cong viec 
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
		}
		else if(clickedid == GUI_HuongDan[playerid][2])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]);
		}
		else if(clickedid == GUI_HuongDan[playerid][3])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]);
		}
		else if(clickedid == GUI_HuongDan[playerid][5])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
		}
		else if(clickedid == GUI_HuongDan[playerid][13])
		{
Reply
#2

pretty sure you had to use OnPlayerClickPlayerTextDraw callback.
about the errors I really couldn't find anything which would make them, are you missing bracket or smth?
Reply
#3

Can you show us the declaration of GUI_HuongDan ?
Reply
#4

Quote:
Originally Posted by Dutheil
View Post
Can you show us the declaration of GUI_HuongDan ?
https://pastebin.com/raw/bCNRnsKd
Reply
#5

at this you can use for(..


Quote:

else if(clickedid == GUI_HuongDan[playerid][13])
{
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][0]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][1]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][2]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][3]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][4]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][5]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][6]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][7]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][8]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][9]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][10]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][11]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][12]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][13]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][14]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][15]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][16]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][17]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][18]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][19]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][20]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][21]);
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][22]); // line 1253
}

Quote:

else if(clickedid == GUI_HuongDan[playerid][13])
{
for(new i = 0; i < 23; i++) {
PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
}
}

Reply
#6

Ok you have to use the OnPlayerClickPlayerTextDraw callback
Reply
#7

Quote:
Originally Posted by Dutheil
View Post
Can you show us the declaration of GUI_HuongDan ?
Quote:
Originally Posted by Florin48
View Post
at this you can use for(..
Thank you I'm noob
Reply
#8

Quote:
Originally Posted by Dutheil
View Post
Ok you have to use the OnPlayerClickPlayerTextDraw callback
I dont know what wrong here
https://pastebin.com/H3NTdzjx
Reply
#9

You don't use the good callback, look this code :
Code:
public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
	if(_:playertextid != INVALID_TEXT_DRAW)
	{
		if(playertextid == GUI_HuongDan[playerid][1]) // line 1213
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
		}
		else if(playertextid == GUI_HuongDan[playerid][2])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]);
		}
		else if(playertextid == GUI_HuongDan[playerid][3])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]);
		}
		else if(playertextid == GUI_HuongDan[playerid][5])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
		}
		else if(playertextid == GUI_HuongDan[playerid][13])
		{
			for(new i = 0; i < 23; i++)
			{
				PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
			}
		}
	}
}
Reply
#10

Quote:
Originally Posted by Dutheil
View Post
Ok you have to use the OnPlayerClickPlayerTextDraw callback
Quote:
Originally Posted by Dutheil
View Post
You don't use the good callback, look this code :
Code:
public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
	if(_:playertextid != INVALID_TEXT_DRAW)
	{
		if(playertextid == GUI_HuongDan[playerid][1]) // line 1213
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
		}
		else if(playertextid == GUI_HuongDan[playerid][2])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]);
		}
		else if(playertextid == GUI_HuongDan[playerid][3])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]);
		}
		else if(playertextid == GUI_HuongDan[playerid][5])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
		}
		else if(playertextid == GUI_HuongDan[playerid][13])
		{
			for(new i = 0; i < 23; i++)
			{
				PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
			}
		}
	}
}
Do you have ******** or Discord?
When I /guihuongdan TextDraw will show, but my mouse not show to click TextDraw
How to show both, TextDraw + mouse to click
Sorry my English pretty weak
Reply
#11

you need SelectTextDraw(playerid, 0xFFFFFFFF);
i think
Reply
#12

Quote:
Originally Posted by Dutheil
Посмотреть сообщение
You don't use the good callback, look this code :
Код:
public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
	if(_:playertextid != INVALID_TEXT_DRAW)
	{
		if(playertextid == GUI_HuongDan[playerid][1]) // line 1213
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
		}
		else if(playertextid == GUI_HuongDan[playerid][2])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]);
		}
		else if(playertextid == GUI_HuongDan[playerid][3])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]);
		}
		else if(playertextid == GUI_HuongDan[playerid][5])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
		}
		else if(playertextid == GUI_HuongDan[playerid][13])
		{
			for(new i = 0; i < 23; i++)
			{
				PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
			}
		}
	}
}
error 025: function heading differs from prototype
Reply
#13

Код HTML:
public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
	if(playertextid == GUI_HuongDan[playerid][1]) // line 1213
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][10]);
		}
		else if(playertextid == GUI_HuongDan[playerid][2])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][6]);
		}
		else if(playertextid == GUI_HuongDan[playerid][3])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][9]);
		}
		else if(playertextid == GUI_HuongDan[playerid][5])
		{
			PlayerTextDrawShow(playerid, GUI_HuongDan[playerid][11]);
		}
		else if(playertextid == GUI_HuongDan[playerid][13])
		{
			for(new i = 0; i < 23; i++)
			{
				PlayerTextDrawDestroy(playerid, GUI_HuongDan[playerid][i]);
			}
		}
}
try now
Reply
#14

Ok textdraw already ok
But how to use TextDrawSetSelectable or PlayerTextDrawSetSelectable ?
To set clickable GUI_HuongDan[playerid][1]
Reply
#15

https://sampwiki.blast.hk/wiki/PlayerTextDrawSetSelectable
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)