Hi guys, phew it's been like forever since I stopped game development.
Well, I'd go straight to the point. This is a problem that's been bugging me more than it should. I'm making a 3d rpg game for android, right now I've finished designing the game map format (no graphical thing to see yet :p) but it suddenly hit me like a thunder. How would I allow multiple light source to light my game map?
Well I'm using glsl (of course) + forward rendering. I couldn't use the same approach I used for game objects, because each object can only be lit by a maximum of FOUR light sources (I got that implemented already from my previous game). Each object holds a reference to a maximum of four light sources that will affect them most.
Now, I've seen several games using this approach too for their objects (players, npcs, items, props) it had also been mentioned here several times or so if I remember correctly. However, most of the games that use this method somehow could dynamically LIT their terrain/game maps/level with almost no limit of light sources. How would I do this for my game? I don't wanna go back to lightmapping since I'm concerned about storage and, I'd rather have my torches light up my world brilliantly.
NB: all the game I've seen showed like ~32 number of lights. But I'm not sure if it's "hardcoded" to their engine. (I can't imagine looping thru 32 light properties in the shader just to compute 1 pixel's color)