Requesting an update: ShadowCaster2D using sprite pixel data

It’s been about a year since the team acknowledged that there have been office discussions about this feature. Can we get an update? I’ve been a huge fan of these features since day one, but the lack of sprite support for shadows is starting to feel more and more conspicuous.

We’re sort of locked out of doing anything involving sprites with an animator on them which feels extremely weird for a 2D feature.

EDIT: Just want to clarify I appreciate how few people are on the team and that the last year has been a nightmare of bugs changes to the 2D package. If this is firmly on the backburner right now, at least we’d know.

1 Like

I agree with you on this. Unfortunately, there were a lot of other things that needed to be fixed first and shadows didn’t get needed attention. I am, however, working on this very thing at the moment and hopefully, I’ll be able to say more about this soon.

1 Like

Just knowing work is being done on this when there’s time is a great news. Appreciate the communication and how diligently you check the forums. Soon! :wink:

2 Likes

If it helps, we’re also working on support for all 2D colliders in the future too:

Here’s some in-development videos just for fun:

1 Like

Thank you for the secondary update! The video is great to see. I realize this is a work in progress, but if you could clear something up.

In the past I’ve hacked together solutions that look like the above by accessing the ShadowCaster2D via reflection and settings the vertices to the collider outline/physics shape. The weight and the round objects are giving me some idea. Example of my code here.

This is super handy. And I’m glad you’re working on it. But per pixel data is a separate thing and also being worked on, yes? The reason I want to clarify is because physics shapes aren’t practical for animated sprites or for very complex shapes (even though they’d be much less expensive).

1 Like

Hello! I just wanted to chime in and say I have been looking out for this since the last thread came up, so I greatly appreciate the small updates.

My use case is essentially: I have to load all of my art assets from sprite sheets at runtime, and I would really love to have shadow casting. Unfortunately, it means that I can’t hand define any colliders, and most of the auto-generated stuff will be unusable for sprites of any complexity.
My only other option seems to be hand coding something that might be able to intelligently create a path for the shadowcaster. I am not optimistic at my ability to do that.

Thanks!

1 Like