OCL_Improved
Great!
By the way, do you by any chance know if the offsets are known for any of the following?
* scanner ranges
* scanner missile defense penalties
* terraforming results ("terraforming climate X yields climate Y")
* restrictions on which climates can be terraformed (toxic, terran, gaia are normally excluded)
* marine, armor generation rates
* marine, armor maximum caps
By the way, do you by any chance know if the offsets are known for any of the following?
* scanner ranges
* scanner missile defense penalties
* terraforming results ("terraforming climate X yields climate Y")
* restrictions on which climates can be terraformed (toxic, terran, gaia are normally excluded)
* marine, armor generation rates
* marine, armor maximum caps
Hi,
the money race picks are bugged when OCL_improved was used.
if you start the game with +0,5 BC you actually get +2,5 BC. Likewise if you take +1,0 BC you actually get +4,0 BC and if you get -0,5 BC you get -2,0 BC.
The programm saves the wrong data to the exe file. Instead of reading the bonus/penalty column and saving it, it reads the cost column and saves -4, 5 or 8.
the money race picks are bugged when OCL_improved was used.
if you start the game with +0,5 BC you actually get +2,5 BC. Likewise if you take +1,0 BC you actually get +4,0 BC and if you get -0,5 BC you get -2,0 BC.
The programm saves the wrong data to the exe file. Instead of reading the bonus/penalty column and saving it, it reads the cost column and saves -4, 5 or 8.
unable to duplicate that on my systemHi,
the money race picks are bugged when OCL_improved was used.
if you start the game with +0,5 BC you actually get +2,5 BC. Likewise if you take +1,0 BC you actually get +4,0 BC and if you get -0,5 BC you get -2,0 BC.
The programm saves the wrong data to the exe file. Instead of reading the bonus/penalty column and saving it, it reads the cost column and saves -4, 5 or 8.
***uploaded new versions,has a few new offsets added
Nirran
Fastest way for evil to triump is for good people to do nothing
meaning i selected one of the money race picks then saved and looked the save file,it was as expected,ie i could not duplicate the bugHuh? I had to edit the patched exe with a hex editor to fix the money pick bug. Should i send you my patch text file?unable to duplicate that on my system
always both(should upload them in one zip i guess)Nice do i need to update the gui only, or both?***uploaded new versions,has a few new offsets added
Nirran
Fastest way for evil to triump is for good people to do nothing
-
- Posts:3
- Joined:Wed Jun 20, 2012 3:32 pm
Great to see you're still working on this.
While I was deciphering some of the formats of the tables from 001FBD50 (_class_to_num_satellites) to 001FBED2 (_star_class_table), I noticed that OCL_Improved already modified a few of them, so I was wondering whether there's some kind of documentation you could share? I'm especially interested in any offsets that determine star colours as well as planet size or resources in relation to climate or orbit index; I've got the gravity table figured out already.
Any light you could shed on this?
BTW, I think you should add star spacing; it's just one value per galaxy size and it has such a huge impact. Offsets are 001125D0, 00112607, 0011263E, 00112675; with lower values leading to a more randomly scattered galaxy.
While I was deciphering some of the formats of the tables from 001FBD50 (_class_to_num_satellites) to 001FBED2 (_star_class_table), I noticed that OCL_Improved already modified a few of them, so I was wondering whether there's some kind of documentation you could share? I'm especially interested in any offsets that determine star colours as well as planet size or resources in relation to climate or orbit index; I've got the gravity table figured out already.
Any light you could shed on this?
BTW, I think you should add star spacing; it's just one value per galaxy size and it has such a huge impact. Offsets are 001125D0, 00112607, 0011263E, 00112675; with lower values leading to a more randomly scattered galaxy.
thank you for the offsets
Siron's goodmaps are what inspired me to make that section in OCL_Improved
i looked at what he did and these following threads,i did not add mineral, gravity, climate or planet size because if you make any of the table's 100% any specific value,moo2 will crash(i believe due to homeworld rich/poor heavy/light gravity and aquatic race picks),hope this helps
Orbit vs Satellite Types Table
Star Class vs Number of Satellites table
Planet Mineral Class vs the Star Stellar Class Table
Planet Gravity table
hope all this helps
Nirran
Siron's goodmaps are what inspired me to make that section in OCL_Improved
i looked at what he did and these following threads,i did not add mineral, gravity, climate or planet size because if you make any of the table's 100% any specific value,moo2 will crash(i believe due to homeworld rich/poor heavy/light gravity and aquatic race picks),hope this helps
Orbit vs Satellite Types Table
Star Class vs Number of Satellites table
Planet Mineral Class vs the Star Stellar Class Table
Planet Gravity table
hope all this helps
Nirran
Fastest way for evil to triump is for good people to do nothing
-
- Posts:3
- Joined:Wed Jun 20, 2012 3:32 pm
Thanks, you're a big help. Seems like it was a mistake not to look on the very last page as well.
So that's four tables down, 16 to go:
_gravity_to_atmosphere (001FBDD7..001FBDF4)
Random table probably describing "atmosphere" depending on gravity; I guess this is ignored as I couldn't see any effect in game and I have no idea what "amosphere" would refer to anyway.
_class_to_group (001FBDF5..001FBE12)
Probably something with star colours. Couldn't see any effects in-game; no idea what a "group" is supposed to be.
_climate_roll_table (001FBE13..001FBE3A)
_normal_gal_climate_roll_table (001FBE3B..001FBE62)
_old_gal_climate_roll_table (001FBE63..001FBE8A)
Judging by the names, these should determine the climates for the different galaxy ages. Can't figure out how, though. Mineral rich and average are identical?
_planet_size_table (001FBE8B..001FBE8F)
Percentage times 10 for the planet sizes. This works as follows:
1. 10% are tiny.
2. 30% of the rest are small (=27%)
3. 70% of the rest are medium (=44.1%)
... and so on. One value should always be 10; if a value before the last is 10 then no larger planets will spawn. Orion, starting planets and some gaia specials aren't affected by this formula.
_planet_max_farms (001FBE90..001FBE94)
Probably obsolete version of _food_per_farmer_table, but depending on size?
_planet_max_mines (001FBE95..001FBE99)
As above, probably obsolete version of _minerals_extracted_table.
_planet_max_population (001FBE9A..001FBE9E)
Base maximum planet population depending on planet size. This is further modified by climate.
_spectral_class_table (001FBE9F..001FBEA5)
Probably obsolete; seems to have no effect and I can't even get the game to crash. I guess this was supposed to determine the probability of star colours including black holes.
_minerals_extracted_table (001FBEA6..001FBEAA)
Not sure what this is... It's not the production per worker. Obsolete?
_climate_modifier_table (001FBEAB..001FBEAF)
?
_food_per_farmer_table (001FBEB0..001FBEB9)
Base food per farmer, depending on planet climate.
_planet_special (001FBEBA..001FBEC5)
Probably just a conversion of references to indices.
_planet_special_weighted_chance (001FBEC6..001FBED1)
Since these add up to 100, they should correspond to the relative frequency of the specials in the table above.
_star_class_table (001FBED2..00IFBEE6)
I have no idea, but the 1..6 at the bottom might serve a special role or not be part of the table at all.
I'm still not seeing anything where I could change the distribution of star classes/colours, or minerals depending on climate. That isn't completely random, is it? At least that brown stars and black holes are uncommon must be specified somewhere. Any ideas where to look?
So that's four tables down, 16 to go:
_gravity_to_atmosphere (001FBDD7..001FBDF4)
Code: Select all
grav?
0 0 1 10%
0 0 1 10%
0 0 1 10%
0 1 1 10%
0 1 1 10%
0 1 1 10%
1 1 1 10%
1 2 1 10%
1 2 2 10%
2 2 2 10%
_class_to_group (001FBDF5..001FBE12)
Code: Select all
? ? ? ? ?
0 0 0 0 1 b?
0 0 1 2 3 w?
0 1 2 2 3 y?
1 2 2 2 3 o?
1 2 3 3 3 r?
0 0 1 2 3 br?
_climate_roll_table (001FBE13..001FBE3A)
_normal_gal_climate_roll_table (001FBE3B..001FBE62)
_old_gal_climate_roll_table (001FBE63..001FBE8A)
Code: Select all
0F 0F 0A 14 37 32 0F 00
19 19 0A 46 05 0A 0A 00
00 05 0A 08 00 00 0A 02
00 00 0B 00 00 00 0B 00
00 00 0B 00 00 00 02 00
0F 0F 0A 14 37 32 0F 00
19 19 0A 46 05 0A 0A 00
00 05 0A 08 00 00 0A 02
00 00 0B 00 00 00 0B 00
00 00 0B 00 00 00 02 00
0F 05 05 14 28 1E 08 00
14 14 08 32 19 19 0D 00
00 14 0D 1E 00 00 0D 00
00 00 0D 00 00 00 0D 00
00 00 0A 00 00 00 04 00
_planet_size_table (001FBE8B..001FBE8F)
Code: Select all
t s m l h
1 3 7 9 10 10%
1. 10% are tiny.
2. 30% of the rest are small (=27%)
3. 70% of the rest are medium (=44.1%)
... and so on. One value should always be 10; if a value before the last is 10 then no larger planets will spawn. Orion, starting planets and some gaia specials aren't affected by this formula.
_planet_max_farms (001FBE90..001FBE94)
Code: Select all
2 4 5 7 10
_planet_max_mines (001FBE95..001FBE99)
Code: Select all
2 4 6 9 12
_planet_max_population (001FBE9A..001FBE9E)
Code: Select all
t s m l h
5 10 15 20 25 max pop
_spectral_class_table (001FBE9F..001FBEA5)
Code: Select all
10 20 30 45 92 96 100
_minerals_extracted_table (001FBEA6..001FBEAA)
Code: Select all
1 2 3 4 5
_climate_modifier_table (001FBEAB..001FBEAF)
Code: Select all
0 0 0 246 236
_food_per_farmer_table (001FBEB0..001FBEB9)
Code: Select all
t r b d t o s a t g
0 0 0 1 1 2 2 1 2 3 food
_planet_special (001FBEBA..001FBEC5)
Code: Select all
64 69 71 72 75 77 87 90 93 97 101 101
_planet_special_weighted_chance (001FBEC6..001FBED1)
Code: Select all
64 5 3 2 3 2 9 4 3 0 5 0
_star_class_table (001FBED2..00IFBEE6)
Code: Select all
20 10 05
25 15 05
10 16 30
10 16 21
32 37 40
01 02 03
02 04 06
I'm still not seeing anything where I could change the distribution of star classes/colours, or minerals depending on climate. That isn't completely random, is it? At least that brown stars and black holes are uncommon must be specified somewhere. Any ideas where to look?
We are also interested in changing the built-in map generator, so we'll start looking into it shortly.I'm still not seeing anything where I could change the distribution of star classes/colours, or minerals depending on climate. That isn't completely random, is it? At least that brown stars and black holes are uncommon must be specified somewhere. Any ideas where to look?
TBH I am not the one that researched the offsets,most of them come from tf8 and Andrey Tyukov,without the contributions they made(through Overlord2,passed on to me) most of the offsets in this program would not exist,sorry i coulnt be more helpI'm still not seeing anything where I could change the distribution of star classes/colours, or minerals depending on climate. That isn't completely random, is it? At least that brown stars and black holes are uncommon must be specified somewhere. Any ideas where to look?
edit : new version uploaded,added A.I. ship design and a couple offsets from Overlord2,moved hardshields to shields section,added a command line switch to turn the debug file off and on to the gui(finnaly)
edit : added evolutionary mutation bonus offsets,uploaded
edit : cybernetic repair added in racepick section and some jammer tech updates(some of the offsets were only cosmetic i.e. ship design screen),uploaded
edit : some new offsets added,changed the section selection page,uploaded
edit : new release,defensive antaran ships added,some of the antaran attack variables are now editible,antaran starfortress weapons are now editible,uploaded
edit : added avenger weapons/specials etc offsets,uploaded
edit : more offsets added to antaran fleet rates,uploaded
edit : added new offsets/sections,fleshed Antaran Build Rates section,bumped versions to .50,uploaded
Nirran
Fastest way for evil to triump is for good people to do nothing
-
- Posts:2
- Joined:Fri Dec 21, 2012 1:09 pm
- Location:United States
Been investigating Andrei's question by trial and error.
It appears the '_climate_roll_table' table is just completely ignored. Organic Rich uses the _old_gal_climate_roll_table while Average and Mineral Rich use _normal_gal_climate_roll_table. The reason these last two don't generate identical galaxies is that group depends on spectral class, and spectral class depends on galaxy age (as i'll get to).
Home worlds will get changed to terran/aquatic, obviously.
Orion, and some stars with monsters, will override these results and can either upgrade or downgrade planets in their systems.
This is what i believe the code looks something like:
There appears to be some sort of routine running after this that changes some stars to spectral class 4 (red). Stars that get changed to red always seem to be within 6 parsecs of a home star, so i believe this may be the game trying to ensure that every race has nearby star that can be colonized.
The game does not seem to like blue stars as home stars either. For example, if you set the first byte in this table to 0xFF, the 7th byte to 0x01, the 4th, 10th, 13th, 16th, and 19th bytes to 0x00, and finally start a new mineral rich game, then the home stars should all be yellow, with the rest being blue. If you then set the 7th byte to 0x00, restart the game, and start another game as mineral rich, it should hang infinitely on the 'Placing Home Worlds' step.
Here's a short bit of code to describe what, as far as i can tell, the game is doing:
The code for both these may actually be using char instead of short. Also not sure if they're signed or unsigned. I don't really feel like testing since there is still plenty of granularity keeping the sum of each column under 128.
Group is used to determine planet climate. Your assumption that the rows are star color is correct. I believe that the columns are planet orbit. This process takes place before home systems, orion, and monster systems are assigned and modified, so those systems may override what is set here._class_to_group (001FBDF5..001FBE12)
...
Probably something with star colours. Couldn't see any effects in-game; no idea what a "group" is supposed to be.
You had the dimensions of these tables incorrect. They're actually suppose to be 4 columns (group number from the previous table) by 10 rows (each type of planet climate)._climate_roll_table (001FBE13..001FBE3A)
_normal_gal_climate_roll_table (001FBE3B..001FBE62)
_old_gal_climate_roll_table (001FBE63..001FBE8A)
...
Judging by the names, these should determine the climates for the different galaxy ages. Can't figure out how, though. Mineral rich and average are identical?
It appears the '_climate_roll_table' table is just completely ignored. Organic Rich uses the _old_gal_climate_roll_table while Average and Mineral Rich use _normal_gal_climate_roll_table. The reason these last two don't generate identical galaxies is that group depends on spectral class, and spectral class depends on galaxy age (as i'll get to).
Home worlds will get changed to terran/aquatic, obviously.
Orion, and some stars with monsters, will override these results and can either upgrade or downgrade planets in their systems.
This is what i believe the code looks something like:
Code: Select all
char galaxy_age; // this is either 0,1, or 2 for mineral rich,average, and organic rich respectively
struct planet p; //set to the current planet
struct star s; //set to the current star
char* climate_table = game_type == 2 ? _climate_roll_table : normal_gal_climate_roll_table;
char group = _class_to_group[s.spectral_class*5+p.orbit_number];
short total = 0;
for(int i = 0;i<10;i++) short += climate_table[i*4+group];
short rand = rand(total);
short sum = climate_table[group];
p.climate_type = 0;
while(sum < rand) {
p.climate_type++;
sum += climate_table[p.climate_type*4+group];
}
This table is what you need to change the generation of different colors of stars/black hole. The column is the galaxy age . The row is the spectral_class, 0-6. The value at each set of coordinates represents the weighting._star_class_table (001FBED2..00IFBEE6)
...
I have no idea, but the 1..6 at the bottom might serve a special role or not be part of the table at all.
There appears to be some sort of routine running after this that changes some stars to spectral class 4 (red). Stars that get changed to red always seem to be within 6 parsecs of a home star, so i believe this may be the game trying to ensure that every race has nearby star that can be colonized.
The game does not seem to like blue stars as home stars either. For example, if you set the first byte in this table to 0xFF, the 7th byte to 0x01, the 4th, 10th, 13th, 16th, and 19th bytes to 0x00, and finally start a new mineral rich game, then the home stars should all be yellow, with the rest being blue. If you then set the 7th byte to 0x00, restart the game, and start another game as mineral rich, it should hang infinitely on the 'Placing Home Worlds' step.
Here's a short bit of code to describe what, as far as i can tell, the game is doing:
Code: Select all
char galaxy_age; // this is either 0,1, or 2 for mineral rich,average, and organic rich respectively
struct star s; // set to the current star
short total = 0;
for(int i=0;i<7;i++) total += _star_class_table[i*3+galaxy_age];
short rand = rand(total);
short sum = _star_class_table[galaxy_age];
s.spectral_class = 0;
while(sum < rand) {
s.spectral_class++;
sum += _star_class_table[s.spectral_class*3+galaxy_age];
}
Return to “Game Modifications”
Who is online
Users browsing this forum: No registered users and 6 guests