diff --git a/src/DtsObject.hx b/src/DtsObject.hx index fb746d4d..e9749c08 100644 --- a/src/DtsObject.hx +++ b/src/DtsObject.hx @@ -366,6 +366,14 @@ class DtsObject extends GameObject { if (flags & 16 > 0) material.blendMode = BlendMode.Sub; + if (flags & 32 > 0) { + var pbrprops = material.mainPass.getShader(h3d.shader.pbr.PropsValues); + pbrprops.emissiveValue = 1; + pbrprops.roughnessValue = 0; + pbrprops.occlusionValue = 0; + pbrprops.metalnessValue = 1; + } + // if (this.isTSStatic && !(flags & 64 > 0)) { // // TODO THIS SHIT // } diff --git a/src/InteriorObject.hx b/src/InteriorObject.hx index 775163ad..b7326143 100644 --- a/src/InteriorObject.hx +++ b/src/InteriorObject.hx @@ -10,7 +10,7 @@ import h3d.scene.Object; class InteriorObject extends GameObject { public var collider:CollisionEntity; public var interiorFile:String; - public var useInstancing = false; + public var useInstancing = true; public function new() { super(); diff --git a/src/MarbleWorld.hx b/src/MarbleWorld.hx index 5a6bcf58..963f2d91 100644 --- a/src/MarbleWorld.hx +++ b/src/MarbleWorld.hx @@ -155,11 +155,12 @@ class MarbleWorld extends Scheduler { var ambientColor = MisParser.parseVector4(sunElement.ambient); var sunDirection = MisParser.parseVector3(sunElement.direction); sunDirection.x = -sunDirection.x; + // sunDirection.z = -sunDirection.z; scene.lightSystem.ambientLight.load(ambientColor); var sunlight = new DirLight(sunDirection, scene); - sunlight.color = directionalColor; + sunlight.color = directionalColor.multiply(2); } // var skyElement:MissionElementSky = cast this.mission.root.elements.filter((element) -> element._type == MissionElementType.Sky)[0]; diff --git a/src/shapes/Gem.hx b/src/shapes/Gem.hx index fcbe298f..5b2083b8 100644 --- a/src/shapes/Gem.hx +++ b/src/shapes/Gem.hx @@ -26,20 +26,6 @@ class Gem extends DtsObject { this.matNameOverride.set('base.gem', color + ".gem"); } - public override function init(level:MarbleWorld) { - super.init(level); - - for (material in this.materials) { - material.mainPass.enableLights = false; - var pbrprops = material.mainPass.getShader(h3d.shader.pbr.PropsValues); - pbrprops.emissiveValue = 1; - pbrprops.roughnessValue = 0; - pbrprops.occlusionValue = 0; - pbrprops.metalnessValue = 1; - // material.mainPass.addShader(new PropsValues(1, 0, 0, 1)); - } - } - public override function setHide(hide:Bool) { if (hide) { this.pickedUp = true; diff --git a/src/shapes/LandMine.hx b/src/shapes/LandMine.hx index 77fd7259..377737da 100644 --- a/src/shapes/LandMine.hx +++ b/src/shapes/LandMine.hx @@ -55,7 +55,7 @@ final landMineSmokeParticle:ParticleEmitterOptions = { new Vector(0.2, 0.2, 0.2, 1), new Vector(0, 0, 0, 0) ], - sizes: [1, 1.5, 2], + sizes: [1.5, 2, 3], times: [0, 0.5, 1] } };