Text rewriter in the works (I18N on the table)

#2
Crap!

For the past few days I've been thinking something was wrong with the way I was hooking the DrawText/TextOut routines, because it seemed like they were being called twice in a row. I gotta admit I'm a total ditz. I even registered in the Easyhook forums to make sure I was doing things right...

Well!! Turns out SOM was actually drawing a drop shadow under the text. It took me a couple days to realize this (well not like I was thinking about it 24 -- or at all obviously)

I thought maybe I remembered a drop shadow under the dialogue text, which lead me to realize what was up. But it turns out there is actually a drop shadow on the menu text as well. It's just one pixel though, no matter how huge the fonts are, and if you're like me, on a 1920x1200 portable display then you'd just about never notice it.

Anyway, aside from my usual thankless blog style of posting... it's definitely possible to make this drop shadow bigger based on the display resolution or whatever -- or hell change the angle, or take it out for style/performance altogether. Might be an interesting option / add a little pizazz to SOM on modern hardware. Truth is it's really amazing just how nice SOM still holds up on modern hardware. Really it looks just fine on a widescreen HD display. Even in 16bit paletted mode with the trilinear filtering going on. We could even tweak the colour of the text and shadow and probably even the font to a large extent. We could change where text is displayed on the screen if you ever wanted to do a totally custom Menu system. Add pseudo stats etc.


Caveat: One thing that does make text substitution a little more problematic, is the numbers and the text for some reason tend to be displayed separately. So instead of seeing "Fire? 113" or whatever you see "Fire" then several text drawing routines later just " 113". Like I say, it's trickier, but I don't think it would stop you if you really wanted your game to do something. You could also edit the text in the exe at runtime so the print format string adds like a symbol to certain numbers to make them easier to pick out... like how I added % to my HP/MP numbers. You can hexedit the exe to do this. But you can also use the same memory management system I have setup to do this when the game starts up in the loaded program's memory (this way you don't have to vandalize the original exe)

Reply



Messages In This Thread
Re: Text rewriter in the works (I18N on the table) - by HolyDiver - 2009-10-13, 11:20 PM



Users browsing this thread:
1 Guest(s)