Carim123 Posted August 6, 2011 Author Share Posted August 6, 2011 Yet again, I've decided to release something that I decided was gonna be for Iron Prelude. xD![](http://www.freemmorpgmaker.com/files/imagehost/pics/24c9477d77e93068c69adcde19a2c28b.png)I only made this, to make the text more readable. If you have the same issue as me, where you feel the text is not very readable. Post with a screeny and your FPS!No credit required, but no claiming as own, either. <3* * *Before starting, I ~~recommend~~ want you to put in [Lightning's Text Rendering Fix](http://www.touchofdeathforums.com/smf/index.php/topic,71691.0.html).Not really a tutorial, more of a copy and paste, as all you must do is simply replace Sub DrawText in modText with this:```' GDI text drawing onto bufferPublic Sub DrawText(ByVal hdc As Long, ByVal X, ByVal Y, ByVal text As String, color As Long) ' If debug mode, handle error then exit out Dim OldFont As Long ' HFONT If Options.Debug = 1 Then On Error GoTo errorhandler Call SetFont(FONT_NAME, FONT_SIZE) OldFont = SelectObject(hdc, GameFont) Call SetBkMode(hdc, vbTransparent) Call SetTextColor(hdc, 0) Call TextOut(hdc, X + 1, Y, text, Len(text)) Call TextOut(hdc, X, Y + 1, text, Len(text)) Call TextOut(hdc, X - 1, Y, text, Len(text)) Call TextOut(hdc, X, Y - 1, text, Len(text)) Call TextOut(hdc, X + 1, Y + 1, text, Len(text)) Call TextOut(hdc, X - 1, Y - 1, text, Len(text)) Call TextOut(hdc, X + 1, Y - 1, text, Len(text)) Call TextOut(hdc, X + 1, Y - 1, text, Len(text)) Call SetTextColor(hdc, color) Call TextOut(hdc, X, Y, text, Len(text)) Call SelectObject(hdc, OldFont) Call DeleteObject(GameFont) ' Error handler Exit Suberrorhandler: HandleError "DrawText", "modText", Err.Number, Err.Description, Err.Source, Err.HelpContext Err.Clear Exit SubEnd Sub```And, you're done. Already. xD**_Will there be any implications on my FPS?_**Not much, provided you've done as I told you, and put in Lightning's Text Fix.Previously, my FPS was averaging 160 (Yes, I know, it's crap.), now, it averages 150, so, not that much of a problem here.Of course, that's just my laptop, and not much of a difference for me, so if you want to help me out, post your FPS before and after adding the fix! Link to comment Share on other sites More sharing options...
RyokuHasu Posted August 6, 2011 Share Posted August 6, 2011 AWSOME!!!! =D this will help SOO MUCH! >.< Thanks 7P.S. this makes the text look less flat too =D Link to comment Share on other sites More sharing options...
Carim123 Posted August 6, 2011 Author Share Posted August 6, 2011 @Ryoku:> AWSOME!!!! =D this will help SOO MUCH! >.< Thanks 7> > P.S. this makes the text look less flat too =DIKR, I was needing this. Glad you liked it.Just comment with your FPS before, and after, please! Link to comment Share on other sites More sharing options...
tsuki Posted August 8, 2011 Share Posted August 8, 2011 after I did both tutorials (your and lightning's) my fps still the same (64) Link to comment Share on other sites More sharing options...
Carim123 Posted August 8, 2011 Author Share Posted August 8, 2011 @Jimmy:> after I did both tutorials (your and lightning's) my fps still the same (64)Did you unlock the fps?As in, do /fpslock? Link to comment Share on other sites More sharing options...
tsuki Posted August 8, 2011 Share Posted August 8, 2011 @7:> Did you unlock the fps?> As in, do /fpslock?Sorry, sometimes I'm a retard.Now I unlock the fps before and after and the results are:before: 136after:140 Link to comment Share on other sites More sharing options...
erkro1 Posted August 8, 2011 Share Posted August 8, 2011 Lol, the FPS is increased :p Link to comment Share on other sites More sharing options...
Antisora Posted September 11, 2011 Share Posted September 11, 2011 It doesn't work for me. And yes, I did lightnings tutorial. Link to comment Share on other sites More sharing options...
Robin Posted September 11, 2011 Share Posted September 11, 2011 It's called 'stroke'. Before I started working on the engine text was rendered with a stroke. I'm the one who replaced it with a shadow. Link to comment Share on other sites More sharing options...
Carim123 Posted September 11, 2011 Author Share Posted September 11, 2011 @Robin:> It's called 'stroke'. Before I started working on the engine text was rendered with a stroke. I'm the one who replaced it with a shadow.Stroke, that's the word…couldn't remember the word. ;pI'm guessing you replaced it with a shadow purely for FPS reasons? If so, it did occur to me, but I personally prefer being able to read the drawn text over slightly higher FPS...buuuut, just my opinion.@Kermit:> It doesn't work for me. And yes, I did lightnings tutorial.You can't've followed Lightning's tutorial properly, this is simply a copy+paste…go back to it, carefully read it, and so on. Link to comment Share on other sites More sharing options...
Robin Posted September 11, 2011 Share Posted September 11, 2011 I did it for image. The stroke looks silly on a lot of things. What you really need is an outer effect which makes it visible on similar colours but doesn't draw attention to itself.I wasn't able to realise that system till I switch to DX8, though. Link to comment Share on other sites More sharing options...
Antisora Posted September 11, 2011 Share Posted September 11, 2011 @7:> Stroke, that's the word…couldn't remember the word. ;p> > I'm guessing you replaced it with a shadow purely for FPS reasons? If so, it did occur to me, but I personally prefer being able to read the drawn text over slightly higher FPS...buuuut, just my opinion.> > You can't've followed Lightning's tutorial properly, this is simply a copy+paste...go back to it, carefully read it, and so on.Wait, is it a seperate feature to have the text off to the side, instead of in the box? Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now