Sign in to follow this  
dpadam450

print variables with drawtext

Recommended Posts

If you notice, the basic text-drawing functions involve strings, which are text.
Convert your variables to strings in order to draw them.
[If that isn't the answer, then please elaborate]

Share this post


Link to post
Share on other sites
Include the windows header file into your app and use wsprintf like this:

int score = 8;
char text[32];
wsprintf(text,"The Score Is %d",score);

Then when your printing the text using DrawText() put text as the first parameter.

Hope that helped and good luck.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this