Jump to content

Values of the married shadow map are not stored in game execution.


Go to solution Solved by Josh,

Recommended Posts

Posted

Currently, this is considered a quality setting. I am planning to move it into the world settings, at which point it would make sense to store this in the scene file, but I did not want to make too many changes too quickly.

  • Like 1

My job is to make tools you love, with the features you want, and performance you can't live without.

Posted
23 minutes ago, Josh said:

Actualmente, esto se considera un entorno de calidad. Estoy planeando moverlo a la configuración del mundo, momento en el que tendría sentido almacenar esto en el archivo de escena, pero no quería hacer demasiados cambios demasiado rápido.

Can those values be modified in lua script?

 

 

Astrocuco.thumb.png.c76e0fb3de2d6e437e7dca099625e11e.png

  • Solution
Posted

Yes. The command is DirectionalLight:SetShadowCascadeDistance(f0, f1, f2, f3)

I went ahead and moved this into world properties and it will get saved in the map, in the next update.

  • Like 1

My job is to make tools you love, with the features you want, and performance you can't live without.

Posted
On 22/4/2025 at 21:30, Josh said:

It doesn't work here.

 

image.thumb.png.8a816c73f60be2e1d7503f817ccf1d59.png

 

 this.sun = self:FindSun()
            self.sun:AddTag("SUN")
            self.sun:SetCascadeDistance(256) -- Error.

 

   if level == "Level01" then
 
            this.sun = self:FindSun()
            self.sun:AddTag("SUN")
         
            this.x = self:FindLight("SUN") --Sun Map.
            self.x:SetColor(1,0,0,1) -- Ok Change Color.
            self.x:SetCascadeDistance(256,512,1024,2048)
   
        end

 

 

Astrocuco.thumb.png.c76e0fb3de2d6e437e7dca099625e11e.png

Posted
 if level == "Level01" then
 
            this.sun = self:FindSun()
            self.sun:AddTag("SUN")
           
            if self.sun.AddTag then
                Print("YESSSSS TAG") -- Print on  Console.
            end
 
       
       
         
            this.x = self:FindLight("SUN") --Sun Map.
            self.x:SetColor(1,0,0,1) -- Ok Change Color.
       
                if self.x.SetCascadeDistance then
                    Print("Yes SetCascadeDistance") --Not print on console
            end
        end

 

 

Astrocuco.thumb.png.c76e0fb3de2d6e437e7dca099625e11e.png

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...