Open source Star Ruler 2 source code!

This commit is contained in:
Lucas de Vries
2018-07-17 14:15:37 +02:00
commit cc307720ff
4342 changed files with 2365070 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
#priority init 1501
import maps;
const int DEFAULT_SYSTEM_COUNT = 60;
const double DEFAULT_SPACING = 6500.0;
const double MIN_SPACING = 6500.0;
void init() {
auto@ mapClass = getClass("Map");
for(uint i = 0, cnt = THIS_MODULE.classCount; i < cnt; ++i) {
auto@ cls = THIS_MODULE.classes[i];
if(cls !is mapClass && cls.implements(mapClass))
cls.create();
}
}
@@ -0,0 +1,16 @@
//Amount of money generated by one money tile-resource
const double TILE_MONEY_RATE = 75.0;
//Amount of energy generated by one energy tile-resource per second
const double TILE_ENERGY_RATE = 0.5;
//Amount of research progress points generated by one
//research tile-resource per second
const double TILE_RESEARCH_RATE = 0.75;
//Amount of labor generation per second by one labor tile-resource
const double TILE_LABOR_RATE = 1.0 / 60.0;
const double LABOR_ACHIEVE_THRESH = 200.0 * TILE_LABOR_RATE;
//Labor's worth of support ships to build per minute with defense
const double DEFENSE_LABOR_PM = 2.0;