Here’s a screenshot of a sketch I am currently working on.
On the upper left corner is a minimap of the dungeon (only tiles that have been seen are shown). The little green arrow there represents the player (technically, the camera).
In the middle of the screen there is a black spot: Processing seems to stop rendering anything more distant than (in my calculations) about 20000 pixels away from the screen.
(The calculation is as follows: each tile in the dungeon is 256×256 pixels; the minimap’s tile size is 4×4 pixels, and the ray seems to partly touch that distant wall which is seen through the open door) (I hope I make myself clear enough, just make sure to take a thorough look at the picture)
So here is my 1st question: can anyone tell the exact distance that Processing considers too far to render?
And the 2nd questions (the main one) is this: how can I make up lights so that anything so far (or maybe a little less than that) would dissolve into darkness?
I tried to arrange a pointLight() in the same place where the camera() is but it doesn’t seem to make it the way I’d like.
Any hint would be appreciated!