\\ and \, the harbingers of doom

All things Desktop Dungeons

\\ and \, the harbingers of doom

Postby Darvin on Tue Jan 22, 2013 7:43 pm

Link to dev blog

Missed this one when it went up and only saw it now (there's also a verbatim post for extra pixels)


Your problem with \n is that you're double-dipping. In your external data file, you're using the "new line" delimiter to represent a new data entry, while once imported you are using the "new line" to represent a new line of text within the same data entry. Because of this you've effectively mandated some sort of arbitrary mapping to resolve the fact that "new line" has a different meaning in the two contexts. You'd need to change the layout of your text file to resolve the issue cleanly, which from the sounds of things is not a box you want to reopen at this point. The best solution would be tags to represent the bounds of text bodies, and then treating new lines as new lines.
User avatar
Darvin
 
Posts: 3129
Joined: Thu Jun 02, 2011 1:44 am

Re: \\ and \, the harbingers of doom

Postby Lujo on Wed Jan 23, 2013 1:56 pm

I whish this forum had the "Like" function, so I can approve both of the devs blog post and you reposting it here without inflating my post count or spamming my name all over the place, but anyway my support is here :)
User avatar
Lujo
 
Posts: 2831
Joined: Tue Aug 02, 2011 8:47 am

Re: \\ and \, the harbingers of doom

Postby dislekcia on Thu Jan 24, 2013 3:54 pm

Yeah, we have a string token system already in place to handle colouring. There's just a new token that looks like "\\n" now :)
User avatar
dislekcia
 
Posts: 1751
Joined: Fri Mar 25, 2011 5:58 pm
Location: Cape Town, South Africa

Re: \\ and \, the harbingers of doom

Postby Aequitas on Mon Jan 28, 2013 11:40 am

@Darvin Oh, I know exactly what the problem is. I just thought you'd all find the tragic tale amusing and maybe slightly enlightening :P
User avatar
Aequitas
Site Admin
 
Posts: 81
Joined: Fri Mar 25, 2011 3:26 pm


Return to Desktop Dungeons

Who is online

Users browsing this forum: Google [Bot] and 2 guests