Singularity wrote:
Anyway, I wanted to get a discussion going on how to best restructure game text.
When dealing with a single planet, I can't see how the information as is provided could be structured in a better way --aside from abreaviating Text to get shorter lines, and omitting 'Ship Amont' data.
I can visualize many possibilities generating a 'Report' type structure for several planets any given sector, or sectors.
I've have yet to use arrays beyond 3 dimensions so I'm not sure what the limit is, if any. However. I somtimes use a method that involves assigning context to Row in an array, so for example, using a top down approach:
Code:
SetArray $PMatrix SECTORS $nPlanets $Datum
setVar $Sec CURRENTSECTOR
setVar $PMatrix $TotalPlanets
setVar $PMatrix[$Sec] $SectorPlanetCount
setVar $PMatrix[$Sec][1] $PlanetNumber
setVar $PMatrix[$Sec][1][1] $Class
setVar $PMatrix[$Sec][1][2] $COLS_ORE
setVar $PMatrix[$Sec][1][3] $COLS_ORE_divisor
setVar $PMatrix[$Sec][1][4] $COLS_ORE_Amount
setVar $PMatrix[$Sec][1][5] $COLS_ORE_MAX
...same for Organics & Equipment
setVar $PMatrix[$Sec][1][14] $Level
setVar $PMatrix[$Sec][1][15] $Creds
setVar $PMatrix[$Sec][1][16] $Planet_Figs
setVar $PMatrix[$Sec][1][17] ..and so on
The above's probably more complex than it needs to be, but I feel it would lend itself nicely to all kinda of data *ysis. Constants could be utilized as pointers, in place of numeric values ie SetVar $PLANET_LVL 14