Word Wrap

Started by DeathCow, March 03, 2007, 08:26:12 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

March 03, 2007, 08:26:12 PM Last Edit: March 03, 2007, 08:27:46 PM by DeathCow
I also dont get whats going on with room and monster descriptions

Monster
Shannon                                                                                   
This plump middle age woman has a robust masculine chin and powerful arms.  She wears a li
ght blue dress with a white apron with her hair tied back and                             
braided.  Although her smile is pleasent she is quite horrible to look at.               
She appears to be unwounded.                                                             


Room
Small Village, General Store
    This is a small store filled with all kinds of useful tools.  A large woman sits quiet
ly snacking on bread and fruits behind the shop's counter.  She
pauses for a momment as you enter to nod, then returns to her meal.  A sign by
the counter says that they'll offer free torches for repeat customers.  The
only exit is the eastern door that you entered from.
Also here: Vitoc, Shannon.


Both monster and room descriptions are stored, at least in my database, line by line.  So the code should have
line1[linebreak]line2[linebreak]line3[linebreak]line4[linebreak]
for rooms and
line1[linebreak]line2[linebreak]line3[linebreak]line4[linebreak][HP desc][linebreak]
for monsters.

Quote from: DeathCow on March 03, 2007, 08:26:12 PM
I also dont get whats going on with room and monster descriptions

Monster
Shannon                                                                                   
This plump middle age woman has a robust masculine chin and powerful arms.  She wears a li
ght blue dress with a white apron with her hair tied back and                             
braided.  Although her smile is pleasent she is quite horrible to look at.               
She appears to be unwounded.                                                             



Room
Small Village, General Store
    This is a small store filled with all kinds of useful tools.  A large woman sits quiet
ly snacking on bread and fruits behind the shop's counter.  She
pauses for a momment as you enter to nod, then returns to her meal.  A sign by
the counter says that they'll offer free torches for repeat customers.  The
only exit is the eastern door that you entered from.
Also here: Vitoc, Shannon.


Both monster and room descriptions are stored, at least in my database, line by line.  So the code should have
line1[linebreak]line2[linebreak]line3[linebreak]line4[linebreak]
for rooms and
line1[linebreak]line2[linebreak]line3[linebreak]line4[linebreak][HP desc][linebreak]
for monsters.

The converter normalizes all those multiline fields into one long text field (and then word wrap determines cr/lf when it's sending the descriptions to the client).  If spacing is important, you can either add cr/lfs into the description fields manually (in your case at the end of each description line) or I can change the converter to insert a line break automatically after every "line" field from the unconverted db.


TGS v1.0 (coming soon)

Note the spacing behind the "." on some lines. most sentences have a single space then you'll get a double space.