How do you make a glowing effect?

Hi, I was wondering how to make a glow effect?

I know there’s a sprite you can use that’s a white circle that fades out that works really well. I know a few users had used it for games and used the blending behavior to make it fade with the art of other objects, and thus adding a glowing effect.
For example:
image
Except there wouldn’t be a black background, just transparent. You could run it through a website to remove the background, but it wouldn’t make it transparent, just a grey fade.

I tried asking one of these users if I could use this sprite from one of their games, since I’m sure it had to be either found via the internet or generated by a website, but they told me to use another method that didn’t even work.

Using the ones on the internet is hit or miss since it’s very difficult trying to find transparent images that have the same fading structure and uses the correct size for your game.

And since the new flowlab update prevents you from using other users sprites (which is mostly a good thing) it’s hard to utilize example games that require specifically generated sprites for it to work.

I don’t know of any easy ways, but it might be best if you tried drawing your own to better fit the game you’re working on, using another pixel drawing software to see if this shape can be recreated, or try to find a website or image online which is very difficult to do.

3 Likes

I was actually looking online to find something that would help and just about most Gradient generation websites should be able to create radial gradients for exactly what you need.

I used:

And I was able to create:
image

I’m sure it’s easier to do on computer, I just threw this together on my phone, but using this outline, you can use various colors to give objects different hues and glowing effects. Plus change the solidity of the gradient or the radius. I’m actually going to save this post since it took me hours trying to figure this out and I found it on my phone super easily.

Anyway, I believe you just make this an object in your game, attack it to the object you want to have a glowing effect and use the blend behavior. It has an input that requires a number and I forgot the exact one, but I think you use add or multiply (the behavior should explain what each number means which function) on this object for it to blend with objects around it. You may have to fidget around with it since I haven’t used it in while and I don’t know it off the top of my head.

4 Likes

Think you can make a example?

Here’s a screenshot for an example I put together real quick.

Basically you have a sprite as something similar as the image I posted above, then using the code below, you can mess around with how transparent you want it, how large, etc.
You can even use the Color behavior to change the different hue on a white sprite, so it can be reused for many different colors on the same object.

Using the light source object, which I have a set of blue lights in the game, you just add an attacher to attach this object onto it and it should work. It may not look good in my game, but it’s because I slapped it together really quick to demonstrate.

I wouldn’t copy the code exactly, but that’s about what you want to aim for. The only reason I advise you from copying it exactly, is because you can edit the numbers, size, etc to better have the glow fit for whatever light source you plan to add in your game.

3 Likes