Skip to content

Commit

Permalink
Even more finishing touches
Browse files Browse the repository at this point in the history
  • Loading branch information
vampcat committed May 30, 2017
1 parent 7f282df commit 760a60e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions main/res/assets/configs/planetsConfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"minGrav": 0.4,
"maxGrav": 0.6,
"groundTexs": "rocky",
"decoTexs": "rocky",
"decorationTexs": "rocky",
"cloudTexs": "skies/cloud",
"rowCount": 4,
"smoothLandscape": true,
Expand All @@ -14,7 +14,7 @@
"dayColor": "hsb 216 40 100",
},

"deco": {
"decorations": {
"grass": {
"density": 0.3,
"szMin": 0.1,
Expand Down Expand Up @@ -89,7 +89,7 @@
"minGrav": 0.6,
"maxGrav": 0.8,
"groundTexs": "desert",
"decoTexs": "desert",
"decorationTexs": "desert",
"cloudTexs": "skies/cloud",
"rowCount": 3,
"smoothLandscape": true,
Expand All @@ -99,7 +99,7 @@
"dayColor": "hsb 200 40 100",
},

"deco": {
"decorations": {
"tree": {
"density": 0.25,
"szMin": 0.5,
Expand Down Expand Up @@ -187,15 +187,15 @@
"rowCount": 4,
"smoothLandscape": true,
"groundTexs": "frozen",
"decoTexs": "frozen",
"decorationTexs": "frozen",
"cloudTexs": "skies/cloud",

"sky": {
"dawnColor": "hsb 50 50 100",
"dayColor": "hsb 125 40 100",
},

"deco": {
"decorations": {
"tree": {
"density": 0.4,
"szMin": 0.7,
Expand Down
4 changes: 2 additions & 2 deletions main/src/org/destinationsol/game/planet/DecoConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,13 @@ public DecoConfig(float density, float szMin, float szMax, Vector2 orig, boolean

static List<DecoConfig> load(JsonValue planetConfig, TextureManager textureManager) {
ArrayList<DecoConfig> res = new ArrayList<DecoConfig>();
for (JsonValue deco : planetConfig.get("deco")) {
for (JsonValue deco : planetConfig.get("decorations")) {
float density = deco.getFloat("density");
float szMin = deco.getFloat("szMin");
float szMax = deco.getFloat("szMax");
Vector2 orig = SolMath.readV2(deco, "orig");
boolean allowFlip = deco.getBoolean("allowFlip");
String texName = planetConfig.getString("decoTexs") + "/" + deco.name;
String texName = planetConfig.getString("decorationTexs") + "/" + deco.name;
ArrayList<TextureAtlas.AtlasRegion> texs = textureManager.getPack("decorations/" + texName);
DecoConfig c = new DecoConfig(density, szMin, szMax, orig, allowFlip, texs);
res.add(c);
Expand Down

0 comments on commit 760a60e

Please sign in to comment.