Results 1 to 3 of 3
  1. #1
    nucks's Avatar
    Join Date
    Mar 2011
    Gender
    male
    Posts
    191
    Reputation
    6
    Thanks
    85
    My Mood
    Amazed

    May I please get the PrintText function?

    May I please get the PrintText function?
    please im trying to do nubz esp tut

  2. #2
    NOOB's Avatar
    Join Date
    Apr 2010
    Gender
    male
    Posts
    3,843
    Reputation
    425
    Thanks
    8,616

  3. #3
    topblast's Avatar
    Join Date
    Mar 2010
    Gender
    male
    Location
    Far from around you Programmer: C++ | VB | C# | JAVA
    Posts
    3,607
    Reputation
    149
    Thanks
    5,052
    My Mood
    Cool
    Dont give him code he wont understand, besides Acid burns function have a lot of unneeded code in it.

    Go here

    DrawText


    The Formats are what you need to understand. Most these "coder" or people who post hacks dont know what they do. "DT_NOCLIP" means to dont Cut the Text. DT_CENTER means to center the text on X and Y. DT_CALCRECT calculates the text and makes the Rect large enough to fit he text. All of them are explained in the link i give you.

    Code:
    void PrintText(LPD3DXFONT Font, int x, int y, D3DCOLOR fontColor, char *text)
    {   
        if(text=="") return;  
       
        RECT FontRect = { x, y, 0, 0 }; 
        pFont->DrawTextA(NULL, text, -1, &FontRect , DT_CALCRECT | DT_NOCLIP, fontColor); 
        pFont->DrawTextA(NULL, text, -1, &FontRect , DT_NOCLIP, fontColor);  
    }
    I just like programming, that is all.

    Current Stuff:

    • GPU Programmer (Cuda)
    • Client/Server (Cloud Server)
    • Mobile App Development