15.07.2009, 16:00
An error is occurring in my TextDraw ... Enter the area and is a counter. Look:
Код:
new Text:Textdraw1; new Text:Textdraw2; //In OnFilterScriptInit() Textdraw1;= TextDrawCreate(214.000000,384.000000,"Admin: Okey!"); TextDrawAlignment(Textdraw1;,0); TextDrawBackgroundColor(Textdraw1;,0x000000ff); TextDrawFont(Textdraw1;,3); TextDrawLetterSize(Textdraw1;,0.399999,1.000000); TextDrawColor(Textdraw1;,0xff0000cc); TextDrawSetOutline(Textdraw1;,1); TextDrawSetProportional(Textdraw1;,1); TextDrawSetShadow(Textdraw1;,2); Textdraw2 = TextDrawCreate(214.000000,384.000000,"Admin: Not Autorized!"); TextDrawAlignment(Textdraw2,0); TextDrawBackgroundColor(Textdraw2,0x000000ff); TextDrawFont(Textdraw2,3); TextDrawLetterSize(Textdraw2,0.399999,1.000000); TextDrawColor(Textdraw2,0xff0000cc); TextDrawSetOutline(Textdraw2,1); TextDrawSetProportional(Textdraw2,1); TextDrawSetShadow(Textdraw2,2); //IsPlayerInArea //-------------------------------IsPlayerInArea public isPlayerInArea(playerid) { new Float:X, Float:Y, Float:Z; GetPlayerPos(playerid, X, Y, Z); if (X <= 2798.400878 && X >= 2741.916015 && Y <= 4102.590332 && Y >= 3863.605224) { if(IsPlayerAdmin(playerid)) { TextDrawHideForPlayer(playerid,TextDraw2); TextDrawShowForPlayer(playerid,TextDraw1); } else { TextDrawHideForPlayer(playerid,TextDraw1); TextDrawShowForPlayer(playerid,TextDraw2); } } } public isPlayerInArea2(playerid) { new Float:X, Float:Y, Float:Z; { GetPlayerPos(playerid, X, Y, Z); if (X <= 2798.400878 && X >= 2741.916015 && Y <= 4102.590332 && Y >= 3863.605224) { } else { TextDrawHideForPlayer(playerid,TextDraw1); TextDrawHideForPlayer(playerid,TextDraw2); } } }