• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Legacy GM [SOLVED] Question about Ambient 3D Lighting against 2D sprites/HUDs

S

SilverTom93

Guest
The 3D game I'm making so far has a really nice light effect to it, and at the moment I'm testing how it looks by toggling it on and off. (See the attached image.) It gives objects and blocks shading, which looks awesome :cool:

but...

...There's a slight problem: when the lighting effects are turned on, it makes the HUD overlay, background and 2D sprites slightly darker. :(
I sorta know why this is happening though: the lighting effects I've coded are an ambient grey light, then an ambient orange light point, so I'm guessing that any 2D sprites here are in the grey light and therefore appear darker.

I don't want to change that lighting code I have (because it makes the walls + blocks look really nice) but is there a way I can make it so that some objects aren't affected by lighting, and some other objects are?

Here's a comparison image of my game, showing how stuff looks different when the lighting is turned on:
IB5 lighting problem.jpg

It'd be awesome if there was a quick simple solution to this, but as always, any help with this is appreciated :D
 
S

SilverTom93

Guest
UPDATE: Never mind, I found a fix! I figured out that if I disabled the lighting effects in my Draw GUI event, then put the code in to display the HUD, then enabled the lighting effects after that, it would keep the HUD's original colour and makes it so that it ignores the ambient lighting that the level has! :D
 
Top