SA-MP Forums Archive
[HELP] TextDraw position check - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [HELP] TextDraw position check (/showthread.php?tid=251260)



[HELP] TextDraw position check - kakalakamakapaka - 26.04.2011

Hi guys....Can u help me about new function like: CheckTxtDrawPos(txtdrawid,x,y)...i tryed a lot of things, but i cant do it....Can u help me PLEASE guys


Re: [HELP] TextDraw position check - Bilawal2050 - 26.04.2011

Use best way to text draw editer i do this 100% but i am already busy!
http://forum.sa-mp.com/showthread.ph...42#post1181142 for this stats text draw


Re: [HELP] TextDraw position check - kakalakamakapaka - 26.04.2011

i dont need this....i need to make function who check txtdraw x,y cords.....can u help ?


Re: [HELP] TextDraw position check - xDeadlyBoy - 26.04.2011

not possible.


AW: [HELP] TextDraw position check - Nero_3D - 26.04.2011

Why do you even need that ?

pawn Код:
//somewhere above the first TextDrawCreate or put it in an include file
stock Float: TextDrawCoords[Text: (MAX_TEXT_DRAWS * 2)] = {-1.0, ...};
#define TextDrawCoords[%0][%1] TextDrawCoords[(%0) + Text: (MAX_TEXT_DRAWS * (%1))]
stock Text: TextDrawCreateEx(Float:x, Float:y, text[])
{
    new Text: gtext = TextDrawCreate(x, y, text);
    if(gtext != Text: INVALID_TEXT_DRAW) {
        TextDrawCoords[gtext][0] = x;
        TextDrawCoords[gtext][1] = y;
    }
    return gtext;
}
#define TextDrawCreate TextDrawCreateEx
stock TextDrawDestroyEx(Text:text)
{
    if(TextDrawDestroy(text)) {
        TextDrawCoords[text][0] = TextDrawCoords[text][1] = -1.0;
        return true;
    }
    return false;
}
#define TextDrawDestroy TextDrawDestroyEx
stock TextDrawGetPos(Text:text, &Float:x, &Float:y)
{
    if(TextDrawCoords[text][0] != -1.0) {
        x = TextDrawCoords[text][0];
        y = TextDrawCoords[text][1];
        return true;
    }
    return false;
}



Re: [HELP] TextDraw position check - kakalakamakapaka - 26.04.2011

thank u man so much