[FIXED] D3DXCreateFontA Problem [D3D9 EndScene() Hook]
Posted: Wed Jun 19, 2013 11:18 pm
Hi, i want to create an overlay for a program therefore i hook the D3D9 device of that program...
The problem is i just cant get the Text drawing to work :S
If anyone could help me or point me in the right direction i would be really happy
- PureBasic 4.51
- Windows x86
(sorry about my bad english...)
The problem is i just cant get the Text drawing to work :S
If anyone could help me or point me in the right direction i would be really happy

- PureBasic 4.51
- Windows x86
Code: Select all
Global *amefont.ID3DXFont
Global *amesprite.ID3DXSprite
Procedure D3D_Text(x, y, text.s, color.l) ;<- WORKS USE RGBA!!!!
textrect.RECT
textrect\left= x
textrect\top= y
*amesprite\Begin(#D3DXSPRITE_ALPHABLEND | #D3DXSPRITE_SORT_TEXTURE)
*amefont\DrawTextA(*amesprite, text, -1, @textrect, #DT_CALCRECT|#DT_LEFT,0)
*amefont\DrawTextA(*amesprite, text, -1, @textrect, #DT_LEFT, color)
*amesprite\End()
EndProcedure