HTML table........in a game?

BlitzMax Forums/BlitzMax Programming/HTML table........in a game?

slenkar(Posted 2010) [#1]
Do you think it would be easy to code an HTML table into a game?

basically order elements on screen and draw border lines.

Ive used tables before for websites
using them for a game would be enjoyable and a lot easier than placing everything with coords

tables would also solve problems with GUI placement and different screen resolutions.


Czar Flavius(Posted 2010) [#2]
Do you want to draw the tables yourself but just store them using HTML-style syntax, or do you want an actual HTML/browser window in your game? It sounds like you want the former, but doesn't hurt to check.

There are two main options. The first is to write some kind of HTML parser yourself. If you've not written a parser before it might be challenge but certainly doable. Here's a hint - don't get bogged down implementing every part of HTML, just the basic bits you require :P

The second is to dump HTML and look at XML instead. A lot of the GUI modules out there can load interface layouts from XML and this might be something to look into.


slenkar(Posted 2010) [#3]
yes i want to create the table and draw them myself in the game.

XML could be a possibility...

but drawing the table is going to be the most difficult part.


Czar Flavius(Posted 2010) [#4]
That's true. Have you considered a GUI module such as cegui (more powerful) or frygui (much easier) which can draw a table for you?


slenkar(Posted 2010) [#5]
i checked out cegui but it doesnt give much feedback when it crashes,


Czar Flavius(Posted 2010) [#6]
That's why I use frygui :)


slenkar(Posted 2010) [#7]
ill check it out :)