Dialog Doesn't Respond when using colord text. - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Dialog Doesn't Respond when using colord text. (
/showthread.php?tid=438058)
Dialog Doesn't Respond when using colord text. -
JohnTravis - 18.05.2013
pawn Код:
new UbranieG[MAX_PLAYERS][48];
pawn Код:
if(PlayerInfo[playerid][pGang]==1)
{
if(PlayerInfo[playerid][pUbrany]==0) { format(UbranieG[playerid],48,"Disguise (Crips)");
if(PlayerInfo[playerid][pUbrany]==1) { format(UbranieG[playerid],48,"{00CC00}Disguise (Crips)");
}
format(format1[playerid],256,"%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n",Wallet[playerid],UbranieG[playerid]);
pawn Код:
case DIALOG_P:
{
if(response)
{
if(!strcmp(inputtext, UbranieG[playerid], true) && strlen(inputtext) == strlen(UbranieG[playerid]))
{
if(PlayerInfo[playerid][pUbrany]==0)
{
SetPlayerSkin(playerid,PlayerInfo[playerid][pUbranie]);
PlayerInfo[playerid][pUbrany]=1;
ShowPlayerInventory(playerid);
return 1;
}
else if(PlayerInfo[playerid][pUbrany]==1)
{
SetPlayerSkin(playerid,PlayerInfo[playerid][pSkin]);
PlayerInfo[playerid][pUbrany]=0;
ShowPlayerInventory(playerid);
return 1;
}
}
It responds when you click on Disguise (Crips), but when you click on the Green (colored) one, there is no response.
Re: Dialog Doesn't Respond when using colord text. -
JohnTravis - 18.05.2013
I think its since its inputtext and the color is included in the string. Is there a way to fix this?
Re: Dialog Doesn't Respond when using colord text. -
JohnTravis - 18.05.2013
Anyone?
AW: Dialog Doesn't Respond when using colord text. -
Blackazur - 18.05.2013
Work it then without the Green color code?
Re: Dialog Doesn't Respond when using colord text. -
JohnTravis - 18.05.2013
But i want it to turn green to show the player that the option is active, i did it ages ago but cant remember how. Im guessing its something to do with the inputtext and the string has color code in it. There must be a way to do it?