3D Sprite Shadows and Animation

SCRIPT: Use animated sprites in a 3D environment by simply dropping one script on your object.


SHADER: Cast shadows from sprites onto your 3D environment with proper shadow cut outs.


The shadows are true projected shadows based on the lights in the scene, not just masked sprites projected onto the ground.


All you need is a quad object and a sprite or sprite sheet. The shader and animation scripts can be used independently or combined for animated sprites with shadows.


Main features include:

  • Full sample project created in URP to demonstrate the asset
  • Shader created in Shader Graph for easy editing
  • 3 separate shaders verified in all pipelines - URP, HDRP, built-in pipelines
  • Properly cut out shadows from sprites
  • Static or moving animated sprites in a 3D environment with shadows
  • Works on a simple quad object with sprite sheet material
  • Sprite sheets can contain multiple animations or just the one you will be using
  • Animated character example script that moves an NPC around
  • Instructions on how to use the shader in all pipelines
  • Total number of sprite frames can be set for the script in the UI
  • Optional HDR based emissive glow can be added to sprites through the existing shader

Support:

  • All of my templates and assets will have continuous support
  • Support, feedback, or questions: alpasun.games@gmail.com

Check out my other assets:


https://assetstore.unity.com/publishers/60903