Seaside Studios
HomeOverviewFAQsContactReview
Sprite Shader
Sprite Shader
  • What is All In 1 Sprite Shader
  • Overview
  • First Steps (Must Read)
  • Render Pipeline And Post Processing Setup
  • Asset Component Features
  • Right Click Create Material
  • Asset Window
  • Textures Setup
  • Custom Sort Axis
  • Saving Prefabs
  • Sprite Atlases
  • How to animate effects
  • Scripting
  • How to Enable/Disable Effects at Runtime
  • Random Seed
  • Scaled Time
  • UI Masking
  • 2D Renderer URP Lights
  • 3D Lights
  • Unified Outline
  • Render Material To Image
  • Compatibility with other assets
  • Effects and Properties Breakdown
  • Considerations
  • Running out of Shader Keywords
  • FAQ (Frequently Asked Questions)
Powered by GitBook
On this page

3D Lights

Previous2D Renderer URP LightsNextUnified Outline

Last updated 1 month ago

Version 4.0 introduces a 3D Lit shader that supports all light types across all render pipelines. This shader variant will allow you to create games in the style of Octopath Traveler:

*The feature may have issues in specific render pipelines of specific versions. If you find some error or you have any suggestion please reach out to: Also, keep in mind that all pipelines are supported except the 2D Renderer, where this shader variant makes no sense, there’s a specific 2D Renderer Lit variant

As usual you can add this shader variant by selecting the Lit option in the asset component:

Alternatively you can also manually select it in the Material Inspector:

The feature also has its own Demo that you can find in the following scene: AllIn1SpriteShader\Demo\DemoLitShader

If the shader is added through the asset component the shadow configuration will automatically be done for you. Otherwise you can manually set the following in the Material Advanced Configuration:

And enable cast shadows in the sprite (it needs debug mode to be active):

If you want to add a Normal Map the shader variant has an effect for that:

And the asset component has a button that will activate the normal map effect, create a normal map texture and add it to the material:

This lit shader was created using Better Shaders, a Unity Asset by Jason Booth that simplifies cross-pipeline shader development. This Better Shaders file can be found over at:

AllIn1SpriteShader\Shaders\LitShaders\BetterShaders_AllIn1Sprite.surfshader

You can get Better Shaders here:

If you do own Better Shaders, you are free to open the source file and change whatever you want.

https://assetstore.unity.com/packages/tools/visual-scripting/better-shaders-2022-standard-urp-hdrp-244057?aid=1101l52IjU
seasidegamestudios@gmail.com