Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / sprite text

Author
Message
A Tea Spoon
17
Years of Service
User Offline
Joined: 23rd Apr 2007
Location: good ol USA!
Posted: 23rd Feb 2008 23:46
ok, iv been trying to figure out how to make my text appear over my sprites, I'v done tons of searches, and have found nothing. all i know is that some guy mentioned a code that turns text to sprites. please help!

Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 24th Feb 2008 06:29 Edited at: 24th Feb 2008 06:38
have you looked into bitmap fonts? i know there are a number of fonts (and dll's and code examples of how to use them) floating around the forums here. (doing a forum search for "bitmap font" will prove fruitfull)

also, using set sprite priority could help once you decide on/create your font set (assuming you'd like to use sprites for the text). utilizing priorities will get your "text" sprites to draw on top of all other "game" sprites of lower priority (for that matter, carefull attention to sprite numbers/sequence can achieve the same results).

and, to respond directly to "turning text into sprites", some folks use print or text to get letters/numbers/words on screen and then get image(s) of them for use with sprites. i think it would be a little tricky to get clean letters/digits that way and keep transparency, etc, but i suppose its possible (and the common "media-less" approach).

Virtual Nomad
AMD XP 1800+ (~1.6 Ghz) / 1.5 GB RAM
ATI Radeon 8700LE 128 MB / Windows XP
Vesper103
16
Years of Service
User Offline
Joined: 21st Feb 2008
Location: Beloit WI
Posted: 25th Feb 2008 19:32
heres how i would do it probably



im just coming up with that off my head and it hasnt been debugged but thats what I would try atm.

Your signature has been erased by a mod - please limit your signature to 600x120

Login to post a reply

Server time is: 2024-09-27 10:26:19
Your offset time is: 2024-09-27 10:26:19