• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Windows Cool text in a box [SOLVED]

rogonow

Member
I have problems to limit my text width with my transformed code.

I have a code to convert html text style to GMS2, for the tags:
<I><B><U><BR>
it starts with 1 user text string in object o_cooltext.
Example of my code result:
B U I BR.png
It converts it to an array, with as text style for example:
<B>this is bold
<http://roelaro21.twentyone.axc.nl/press/HTML-style_to_GMS.zip
I tried to box it automaticly, but I had problems with it to limit the width size:
function draw_text_ext removes the leading spaces. Could a "tiny space" be a solution? It doesn't work for me as far as I tried.
function string_width gave me loop problems.
adding <BR> to user source I had problems with the insert positions. with my code, <BR> itself works fine as an alternative for the next line.

Suggestions? I wasted some time unfortunately.

UPDATE: I had to be careful to watch out for the different situations for next line. It was mixed. I have at least 3.
 
Last edited:
Top