How do I create a bitmap flashlight that uses shadows

0 favourites
  • 5 posts
From the Asset Store
With this template you will learn how to use the GooglePlay Games native plugin
  • Well, I'm looking at some tutorials and forum posts and I know that this question arise from time to time. But I really want to give Construct a chance and even young Godot got this covered with little effort. I want to make a flashlight for a top-down shooter.

    It requires:

    • To cast shadows (duh)
    • To have a nice cone shape (bitmapped preferably)
    • Occlude stuff that shouldn't be seen in the night (may be with the help of a line of sight behaviour)
    • Show scenery when ambient light is starting to gain strength, keeping the cone masked by the shadow caster

    And as simple as this sounds, it is hard to do it with just the shadow caster. I found a way tough that requires two layers, one for the shadows and one for the flashlight (with destination atop blending, also Destination in works).

    Check it out: https://goo.gl/bK32yp

    Question is: could you improve it? It would be nice if I could control the opacity of the "Flashlights" layer so when is morning you could se more than just the flashlight cone. Regards

  • construct.net/en

    I saw and implemented that, please let me know if I'm not explaining myself. Also, see the project, that's why I attached it.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Sorry I don't download random zips, and a capx in a zip worrisome.

  • Sorry I don't download random zips, and a capx in a zip worrisome.

    Ok, so if you know someone that can provide a meaningful answer please send them this forum thread, thanks in advance.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)