Platform Masters Title
Platform Masters - Will you be the world's next platform master?






Sky darkening - early star visibility


Date: September 10, 2013
Screenshot #441: Before, it required about 200,000 feet of height to first see the stars in the dusk sky, about 500,000 for the day sky. I've now changed this so that the stars appear considerably earlier, especially for the dusk sky. With the dusk sky being too bright to see the stars at sea level, but much darker than the daytime sky, it makes sense to make the stars become visible at a much lower altitude. This is due to the thinner atmosphere scattering the light less, allowing the sky to appear darker. After all, get 500 miles above the ground and you have practically no atmosphere to scatter light and thus you can clearly see the stars, even if it was high noon over the equator. If you look closely just above the debug panel and just to the right of the lives indicator, you'll see 2 stars present. You can see more though.

Unfortunately, due to changing the fog color, the ground decals, which have the fog preprocessed in the image itself instead upon load time, looks odd. This is what the odd dark areas are between the mountains - the ground decals. Fortunately, the fix for this is quite quick. For best results, since I no longer need to deal with the memory allocation issue, I can better and far more easily set the zoning for the ground decals.




Sky darkening - dynamic star magnitude limit


Date: September 10, 2013
Screenshot #442: In the previous case of the sky darkening effect, I used a single fixed magnitude for the stars. Due to technical limitations of pure 2D and transparency, since I can't draw transparency on transparency without making something more opaque than intended and there are multiple transitions with the sky darkening effect available, I have a few transition points with the stars available. So, I thought, since I have them available, why not make the magnitude visibility limit change as well?

From checking Wikipedia, I saw that the human eye, under perfect conditions, can see magnitude 8. Originally, I thought magnitude 6.5 was the about the typical limit. When away from bright lights, and out of the light-scattering atmosphere, I thought that would be the case for magnitude 8 being used and that's what I did. Near the ground, the magnitude limit is very low. The dusk sky upon the Sun just going below the horizon (you can no longer see the disk) may be -3 or something. The day sky at high noon (when the Sun is the highest overhead) is probably -12. The lower the value (bigger negative), the brighter. Planet Uranus is around +7.

Given this, the higher you get, the more stars you'll see and more clearly.




Sky darkening - day sky updated


Date: September 10, 2013
Screenshot #443: The day time sky was also updated as well, primarily for optimization, but I made it a stronger blue at the topmost portion, a slightly stronger blue. As usual, the stars have been updated so that they appear much earlier though I think they appear too early for the day time sky and may be changed. Instead of stage 5 for them first being visible (and just barely), it'll be stage 6 (and more noticeably than stage 5). Test 9 in the debug panel shows the stage of the sky darkening effect (test 10 is the opacity of the next stage's image).

For sure, there is one other change I need to make - the ground part. With the stars coming in much earlier with the dusk/dawn sky, the very bright ground is just, well, too bright. I'm considering changing the drawing method for this, doing it much like the solid ground layers, just with huge scaling values (if you thought the 1792 for the farthest of the Sentus Mountains was far, that's quite close compared to how far the farthest parts will be - that's over 20,000S (the fade may start at 4096 SU).




Sky darkening - Carnivalesta at ground level


Date: September 10, 2013
Screenshot #444: Carnivalesta's night sky has also been enhanced. Near the ground, the numerous lights pretty much drown out the stars so that they can't be seen. Get away from those lights and the now darker scene makes seeing the stars much easier. Far from the lights, the stars are easily visible. This muting of the sky is only seen with Carnivalesta. Everywhere else, since there aren't any significant light sources, this all-black sky case doesn't apply.

I've decided to set Barugan Islands at night and Musan Swamp at dusk. Barugan Islands, thus, will have the truly starry dark sky, an even darker one than Carnivalesta even though it's at sea level when Carnivalesta is not. Because I don't have the transition for Barugan Islands done, and it will take quite a while to do (and it's a hidden world), I left that out.




Sky darkening - Carnivalesta above the lights


Date: September 10, 2013
Screenshot #445: Higher up, Carnivalesta looks like the Carnivalesta you know, just without as many stars visible. This is due to all those lights visible on the Sentus Mountains drowning out a good chunk of the stars.




Sky darkening - extra starry Carnivalesta


Date: September 10, 2013
Screenshot #446: If you want stars, you'll want to reach great heights. From this very high position, about 14 or so times higher than the highest point you'll reach in Carnivalesta through the use of platform levels (upgrading jumping and/or using leviburst is the only way to get higher).

I know of a few things I have yet to change. The ground needs a new drawing algorithm. The sky darkens too quickly when the stars come in. The daytime sky has the stars coming in too early. The water for the dusk/dawn worlds needs to change colors for the orange parts (these are intended as reflection from the Sun). The ground decals need the fog color adjusted to account for the new fog color. There's probably a few others, but these are the main ones needed as a consequence to the incomplete change.

Mixed in with this was the redoing of the air taxis to standardize them. More details on this are in later screenshots.




Ronnis - ground level changes


Date: October 20, 2013
Screenshot #447: Although the redesigned air taxis were done a while ago, there was one aspect that made getting them added in quite a hassle. For example, if I wanted to add in an object into Ronnis at 128 SU, I'd have to change the layer ID numbers (in the form of an array index) for every single layer that's closer, including that of the commonly set parameters like X offsets, Y offsets, and speeds. It's a lot of work for something that could be done in only about 5 minutes, if even that much. To fix this, I decided to do a fairly major overhaul on the way scenery is loaded and set up. Doing this has some major advantages:

1. It's much easier and faster to add in, move, or delete scenery objects. It now only takes about 3 minutes to add in a new scenery object instead of about 15 - set the basic parameters (the scaling, X and Y offsets, speeds, draw mode, and prepare for the multiple X offsets system if needed), call the loading function to load the image and do the usual processing (which, thanks to discovering that CreateDIBitmap allocates the memory, I don't have to set the handles and stuff any more), and put in the draw itself which automatically determines which drawing routine to use due to setting this in the basic parameters. 3 things I can just copy and paste. When I tried adding in the benches, aside from forgetting to add in the file loading part, it was a sinch to do. Knowing the actual X position to set them took longer than it takes to add in the new objects (though less time than the previous system would have). The same was repeated with the new traffic lights It's just so amazingly simple now and it's another one of those "why didn't I do that earlier" moments.

2. It cuts down on significantly on the line count. Although loops were used to automate as much as I could, many things are just too inconsistent to reliably use loops. By throwing the setting of all these parameters into a single function call, leaving out only the very rarely used things like setting up animation or the drawing start point, I could potentially save about 3000 or so lines (which would carry out even more once every world is finished).

3. Even defining animation is now improved. Each object can now get an assigned behavior and with the way things are now set up, it's completely independent of the array index the scenery layer uses. The new system even allows more objects to get the same behavior and much more easily.

Of course, I've only done Ronnis. I have every other world to process in the same way as well. It's mostly just copy paste that's needed or just copying the old details I had. This screenshot shows the new benches (on both sides of the river, 1/4 SU from the edge) and the pair of extra traffic lights on the other side of the river. They're so far away that they're hard to make out.




Ronnis - dense air taxis


Date: October 20, 2013
Screenshot #448: Improving the air taxis took a long time as well, as I had to make a lot of changes to the code. In a way, it's similar to the loading of the scenery, but this time, like the setting up of the scenery, they are completely independent of scenery layer array indexes. After plenty of bug fixing, including finding a memory leak I wasn't expecting with the clouds (something I haven't messed with at all during this and for quite a while now), I got the new air taxi system set up. There are now 16 total flight levels and I can fully control how many to use with a single function parameter. Even the X axis density is fully adjustable. Flight levels are based on city blocks - 2048 CU. The list is as follows: 4, 5, 6, 7, 8, 10, 12, 16, 20, 24, 32, 48, 64, 96, 128, and 256. The closer the spacing with the air taxis, the slower their speeds are. The 2 highest ones always go the speed of sound or twice the speed of sound. In Ronnis, the lowest ones go a puny 30 mph (about 48 km/h) though they hover very near the buildings.

In this screenshot, you can see the very high density of air taxis. You can also see them being even closer than the closest ones with numerous new Z positions, 16 in total. The farthest visible ones are 96 SU away, 2 Kbl. Each closer layer is 6 SU (1/8 Kbl or 2 city blocks) closer until at 6 SU. The Y spacing varies. Higher up, the speeds get faster, the air taxis get spaced apart more, and there's fewer in general. In a way, this really makes Ronnis look like a futuristic city.




Ronnis - air taxis in the clouds


Date: October 20, 2013
Screenshot #449: Until now, you've only seen air taxis in the clouds in the Sentus Mountains world. Not any more. With flight level 12, you can see air taxis going in and out of the clouds. This screenshot provides a great example of this. If you ever get infinite time unlocked and obtain leviburst, spend a while near the clouds and watch the air taxis going in and out of them.




Ronnis - reduced draw count


Date: October 31, 2013
Screenshot #450: Before this moment, Ronnis was regularly exceeding my 2000 draw count limit, peaking at almost 2300 draws. After I finished "upgrading" the scenery set up, loading, and drawing, I began reworking the ground decals for various reasons. With the water texture changed to something far more realistic looking, and the water color itself changing as well, the water in the ground decals needs to be changed accordingly. In addition to that, since I now no longer have the array size restrictions, I can freely zone the ground decals. By rezoning them, I can make them more efficient with memory (and resulting disk space). While doing Ronnis, I noticed one thing that explained why I was getting almost 2300 draws at the peak - each row of pixels needed 2 or 3 draws at all times. Now, it's only 1 or 2 draws. When as much of the scene as possible is covered with ground decals, this reduces the total draws by about 350. The difference is very significant. Reworking the many ground decals will take a long time to do but will be worth it in the end as even they have plenty of room for optimization.






Footnotes:
None.