Browse Source

Merge pull request #563 from Bloodknight/Minor_Module_Fixes

replace new with singleton to fix cannot re-declare object log file …
Brian Roberts 4 years ago
parent
commit
ad5d0b6d1b

+ 6 - 6
Templates/BaseGame/game/core/lighting/scripts/advancedLighting_Shaders.tscript

@@ -75,7 +75,7 @@ singleton shaderData( AL_VectorLightShader )
    pixVersion = 3.0;
 };
 
-new CustomMaterial( AL_VectorLightMaterial )
+singleton CustomMaterial( AL_VectorLightMaterial )
 {
    shader = AL_VectorLightShader;
    stateBlock = AL_VectorLightState;
@@ -149,7 +149,7 @@ singleton shaderData( AL_PointLightShader )
    pixVersion = 3.0;
 };
 
-new CustomMaterial( AL_PointLightMaterial )
+singleton CustomMaterial( AL_PointLightMaterial )
 {
    shader = AL_PointLightShader;
    stateBlock = AL_ConvexLightState;
@@ -186,7 +186,7 @@ singleton shaderData( AL_SpotLightShader )
    pixVersion = 3.0;
 };
 
-new CustomMaterial( AL_SpotLightMaterial )
+singleton CustomMaterial( AL_SpotLightMaterial )
 {
    shader = AL_SpotLightShader;
    stateBlock = AL_ConvexLightState;
@@ -205,7 +205,7 @@ new CustomMaterial( AL_SpotLightMaterial )
 
 /// This material is used for generating deferred 
 /// materials for objects that do not have materials.
-new Material( AL_DefaultDeferredMaterial )
+singleton Material( AL_DefaultDeferredMaterial )
 {
    // We need something in the first pass else it 
    // won't create a proper material instance.  
@@ -219,7 +219,7 @@ new Material( AL_DefaultDeferredMaterial )
 
 /// This material is used for generating shadow 
 /// materials for objects that do not have materials.
-new Material( AL_DefaultShadowMaterial )
+singleton Material( AL_DefaultShadowMaterial )
 {
    // We need something in the first pass else it 
    // won't create a proper material instance.  
@@ -255,7 +255,7 @@ singleton shaderData( AL_ParticlePointLightShader )
    pixVersion = 3.0;
 };
 
-new CustomMaterial( AL_ParticlePointLightMaterial )
+singleton CustomMaterial( AL_ParticlePointLightMaterial )
 {
    shader = AL_ParticlePointLightShader;
    stateBlock = AL_ConvexLightState;

+ 1 - 1
Templates/BaseGame/game/core/rendering/scripts/gfxData/warningTerrainMat.tscript

@@ -1,4 +1,4 @@
-new TerrainMaterial()
+singleton TerrainMaterial()
 {
    diffuseSize = "200";
    detailSize = "10";

+ 1 - 1
Templates/BaseGame/game/tools/assetBrowser/scripts/templateFiles/terrainMaterial.tscript.template

@@ -11,7 +11,7 @@ singleton Material(TerrainFX_@)
    impactSoundId = "0";
 };
 
-new TerrainMaterial(@)
+singleton TerrainMaterial(@)
 {
    internalName = "@";
    diffuseMap = "";

+ 1 - 1
Templates/BaseGame/game/tools/worldEditor/scripts/visibility/shadowViz.tscript

@@ -34,7 +34,7 @@ singleton shaderData( AL_ShadowVisualizeShader )
    pixVersion = 2.0;
 };
 
-new CustomMaterial( AL_ShadowVisualizeMaterial )
+singleton CustomMaterial( AL_ShadowVisualizeMaterial )
 {
    shader = AL_ShadowVisualizeShader;
    stateBlock = AL_DepthVisualizeState;