Is it possible to highlight the player/enemies/objects using a muzzle flash or other explosion?

Not favoritedFavorited Favorited 0 favourites
  • 3 posts
From the Asset Store
200+ Unique, Single-Frame Explosion sprites! This is the ultimate explosion sprite bundle!
  • I am tinkering around with a side scrolling shooter and I would like to make some dark areas in the game that are lit up by grenades and muzzle flashes, similar to this photo.

    As the player can rotate their aim in 360 degrees, having a static sprite that has pre-rendered highlights doesn't quite look right: if they are aiming straight up, the muzzle flash wouldn't be on the front.

    I imagine there's something I could do with an overlaid object and blending, like linear dodge or something like that?

  • With 2d sprites you'd have to draw them lit from different sides I suppose.

    It may be enough to just have a gradient sprite over the flash with the additive, screen, or lighten blend mode though. You could even give the impression of a brighter flash by darkening everything underneath first. With more layers, or the drawing canvas you can mix and mask multiple light gradients with a sprite with blend modes. It's just something you'd have to fiddle with. If you find any information about how to do such a thing in photoshop or something the ideas may transfer.

    For more advanced lighting you could look into a normal map lighting effect. There is a built in one where you place the sprite, then a sprite on top to use as a normal map, and give the effect to that and provide the light location as parameters. There is also a third party effect that has more features. Anyways, the busywork to drawing/generating the normal maps of the sprites.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I am tinkering around with a side scrolling shooter and I would like to make some dark areas in the game that are lit up by grenades and muzzle flashes, similar to this photo.

    As the player can rotate their aim in 360 degrees, having a static sprite that has pre-rendered highlights doesn't quite look right: if they are aiming straight up, the muzzle flash wouldn't be on the front.

    I imagine there's something I could do with an overlaid object and blending, like linear dodge or something like that?

    https://necro-dynamic-light.netlify.app/

    https://necro-dynamic-light2.netlify.app/

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