Real-time lighting + solar system rendering

This commit is contained in:
Anuken
2020-02-29 11:58:10 -05:00
parent f0857fa22d
commit 7a01719816
20 changed files with 491 additions and 356 deletions

View File

@@ -1,6 +1,8 @@
package mindustry.content;
import arc.graphics.*;
import mindustry.ctype.*;
import mindustry.graphics.g3d.*;
import mindustry.maps.planet.*;
import mindustry.type.*;
@@ -11,14 +13,31 @@ public class Planets implements ContentList{
@Override
public void load(){
sun = new Planet("sun", null, 3, 1){{
detail = 6;
generator = new TestPlanetGenerator();
sun = new Planet("sun", null, 0, 2){{
bloom = true;
//lightColor = Color.valueOf("f4ee8e");
meshLoader = () -> new SunMesh(this, 3){{
setColors(
Color.valueOf("ff7a38"),
Color.valueOf("ff9638"),
Color.valueOf("ffc64c"),
Color.valueOf("ffc64c"),
Color.valueOf("ffe371"),
Color.valueOf("f4ee8e")
);
scale = 1f;
speed = 1000f;
falloff = 0.3f;
octaves = 4;
spread = 1.2f;
magnitude = 0f;
}};
}};
starter = new Planet("TODO", sun, 3, 1){{
detail = 6;
generator = new TestPlanetGenerator();
meshLoader = () -> new HexMesh(this, 6);
}};
}
}