|
|
|
 |

May 8th, 2001, 10:48 AM
|
Sergeant
|
|
Join Date: Mar 2001
Posts: 249
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
Well depending on pervasive the use of this variable is, if it is the limiting cause... it might be as simple as a global search and replace or more likely it is something much more complex. No way to tell without knowing the source code better.
Now I assuming my guess is actually on the mark about the 8 bit variable, I wonder why he didn't use at least a 16 bit short or just a regular int. Then again I'm not familiar with what language he used and there could be plenty of other considerations that affected his decision to do it this way. That said I'm not sure you could physically fit 65335 star systems onto the current strategic map. I guess he could have used some intermediary number but I can't remember any simple/primitive variable types on most Languages that are between 8 and 16 bits off the top of my head right now.
Actually I guess that makes sense, I'm guessing that he probably didn't think any of us would want over 65k systems. I like playing on a big map too, but I have trouble remembering where stuff is as it is set up now sometimes. 65k star systems.... sheesh I'd be really lost<G> So maybe it was some sort of compromise. Imagine how slow the game would get and how much memory and disk space it would take to play and save it if the galaxy were that big. It'd be interesting but geeze I barely finish games on a large map now <G>
[This message has been edited by jc173 (edited 08 May 2001).]
|

May 8th, 2001, 10:56 AM
|
Corporal
|
|
Join Date: Feb 2001
Location: Vienna, Vienna, Austria
Posts: 170
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
I would also like to have a much bigger game. The number of systems, mapsize and races a SE4 game offers should depend on your PC-system.
Or how about a concept of "galactic sectors". Every sector has the size of a normal huge SE4 game map. But the maps are connected. This means you can jump from one map to the another if you have the appropriate interstellar drive. Each time you jump the game loads the map you choose. (with all its races, wonders, systems etc.)
This means that at the same time is only one galactic sector is active, untill you choose to activate another. (of course you have to have some assets there to do the activation)
Of course this kind of game is not good for a quick MP game over the internet. But it should be good for each long solo game or for a hosted PBEM game too.
The tech cost should be multiplied if such a monster game is played to avoid "running out" of techs in the middle of the game.
Lets see what the map editor and the future in general adds to this topic.
klaus
|

May 8th, 2001, 12:32 PM
|
Second Lieutenant
|
|
Join Date: Mar 2001
Location: Netherlands
Posts: 479
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
i think it's about mem usage
let's do a little math  :
suppose you have 255 systems
each system can have a name, i don't know the max. characters for a name, but i haven't seen them larger than 32, that is 32 bytes for the name
on average a system has about 10 planets, some have no planets, and some have as much as 15
a planet has three resource values, mineral, organics and radioactives, i haven't seen those above 255%, so one byte per resource would be enough, that is 3 bytes.
a planet also has a atmosphere and type, there are three type, Gas, Rock and Ice
and 5 (?) atmospheres, Oxygen, Hydrogen, Methane, Carbon Dioxide and None. thos could be fitted in 1 byte
then there is the population 4 bytes (common int)
population growth 1 byte
the buildings build on a planet, they could be references to an array in which all the buildings are stored, if so, there is a maximum of 25 (?) buildings on a huge world, that would mean 25 indices, or 25 integers, that is 100 bytes,
a sphereworld can hold 200 buildings, but that is an exception
then there are the ships and units and such but i don't have time include them right now
so for just a galaxy with 255 systems with on average 10 planets per system, you would use
287232 bytes = 280 kb
that ain't much, but suppose you use a 16 bit number for the systems instead of an 8 bit number, then it would be
73531392 bytes = about 70 mb
maybe i'll include ships and units later, or someone else could do it..
[This message has been edited by LemmyM (edited 08 May 2001).]
__________________
[Boo!]
|

May 9th, 2001, 01:14 AM
|
Corporal
|
|
Join Date: Dec 2000
Posts: 81
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
I don't get your math, your saying for 8 bit numbers, it's 280KB but for 16bit numbers it's 70MB? Your only doubling the # of bits required so You should be 560KB not 70MB...right?
quote: Originally posted by LemmyM:
i think it's about mem usage
let's do a little math :
suppose you have 255 systems
each system can have a name, i don't know the max. characters for a name, but i haven't seen them larger than 32, that is 32 bytes for the name
on average a system has about 10 planets, some have no planets, and some have as much as 15
a planet has three resource values, mineral, organics and radioactives, i haven't seen those above 255%, so one byte per resource would be enough, that is 3 bytes.
a planet also has a atmosphere and type, there are three type, Gas, Rock and Ice
and 5 (?) atmospheres, Oxygen, Hydrogen, Methane, Carbon Dioxide and None. thos could be fitted in 1 byte
then there is the population 4 bytes (common int)
population growth 1 byte
the buildings build on a planet, they could be references to an array in which all the buildings are stored, if so, there is a maximum of 25 (?) buildings on a huge world, that would mean 25 indices, or 25 integers, that is 100 bytes,
a sphereworld can hold 200 buildings, but that is an exception
then there are the ships and units and such but i don't have time include them right now
so for just a galaxy with 255 systems with on average 10 planets per system, you would use
287232 bytes = 280 kb
that ain't much, but suppose you use a 16 bit number for the systems instead of an 8 bit number, then it would be
73531392 bytes = about 70 mb
maybe i'll include ships and units later, or someone else could do it..
[This message has been edited by LemmyM (edited 08 May 2001).]
------------------
Regards,
KiloOhm
__________________
Regards,
KiloOhm
|

May 9th, 2001, 01:26 AM
|
Second Lieutenant
|
|
Join Date: Mar 2001
Location: Netherlands
Posts: 479
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
quote: Originally posted by KiloOhm:
I don't get your math, your saying for 8 bit numbers, it's 280KB but for 16bit numbers it's 70MB? Your only doubling the # of bits required so You should be 560KB not 70MB...right?
if you have 8 bits then you have 2 to the 8th possible numbers, that is 256
if you have 16 bits, you have 2 to the 16th possible numbers, that is 65535
so it's not just twice as much, the difference in bits is 16 - 8 = 8, so it is 2 to the 8th times as much
and 70 mb is of course the maximum, if you actually have 65536 systems in a map
[This message has been edited by LemmyM (edited 08 May 2001).]
__________________
[Boo!]
|

May 9th, 2001, 01:30 AM
|
Corporal
|
|
Join Date: Jan 2001
Posts: 132
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
Each entry has a size of one system (planets, populations, values etc.)
so the size of a 16 bit system list would be a lot bigger than twice. It's 2 to the power of 8 times larger (in fact 256 squared).
It would be possible to scale up by factors of 2 but this would require a fair bit of coding just to check how big the system list is every time it parses it.
Bearing in mind I get a noticable pause when looking at my shiplist when there's more that 150 or so entries, a larger galaxy could bring the program to a grinding halt.
And yet again while i'm typing, someone else has already answered.
[This message has been edited by jimbob55 (edited 08 May 2001).]
|

May 8th, 2001, 04:03 PM
|
Corporal
|
|
Join Date: Dec 2000
Posts: 81
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: Could someone explain:
I understand that but I don't see how that applies to the argument. Your saying 255 systems takes up X amount of space if you use 8 bit numbers, then you say 16 bit numbers takes up much more than 2X the space.
Your argument hold true if your talking about the number of POSSIBLE combinations, not what the actual memory requirement is. The memory requirement is linear with byte size if you keep the same number of variables for the system, the possible combinations is exponential with byte size since you have twice the number of bits, you have as you said, a lot more combinations.
But we're not talking about combinations, we're talking about straight storage, right? Or did I miss the point entirely?
quote: Originally posted by LemmyM:
if you have 8 bits then you have 2 to the 8th possible numbers, that is 256
if you have 16 bits, you have 2 to the 16th possible numbers, that is 65535
so it's not just twice as much, the difference in bits is 16 - 8 = 8, so it is 2 to the 8th times as much
and 70 mb is of course the maximum, if you actually have 65536 systems in a map
[This message has been edited by LemmyM (edited 08 May 2001).]
__________________
Regards,
KiloOhm
|
Thread Tools |
|
Display Modes |
Hybrid Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is On
|
|
|
|
|