Sunday, April 22, 2018

Crossing the Border

Full screen experiment using a test border
So this implementation of the border code is going much more smoothy then I thought it would. I haven't started on the squishy/stretchy bits yet, but I have been able to shim in where to render the background. Even better, this allows the theme to have semi-transparent screens so that the background will show from underneath. I have the (admittingly unoptimized) skybox code functional. I have a "lab" that I develop experiments in. It's a completely different solution then the ROE project. I've used it in the past to work out color tinting, audio mixing issues, and other odds and ends to check if what I'm attempting if feasible. If it looks good, it goes into the main code with a little cleanup. In fact, the options menu was one of the first times I wrote a whole chunk of functionality in situ. Much of that required functions in the game itself

Seam errors
 As far is the skybox code goes, everything rolls in an lazy clockwise corkscrew. I have the camera slowly yawing and pitching to give it a slow precession. I am having a problem with my texture seams that I still have to work out. In Allegro, the textures repeat and so if you have a dark edge on one side and a bright edge on the other, the interpolation will sometimes "bleed" though. What you normally do is clamp the textures so you don't get rendering errors, but I don't seem to have that functionality in Allegro out of the box. There is a OpenGL extension I can use, but I think I can work with that I've got. If anything I can give the edges a little "push" outside the cube to hide that.

Sadly when fading in with the new border, it looks like garbage.  I'm going to need to recode the "fade in from black" function again, making it my 4th rewrite. The original game used a simple CULT fade, but I don't have that in Allegro 5 and instead rely on layers going from opaque to transparent on a timer. I think I may need to "Fix Once and for All" that code once and for all.

No comments:

Post a Comment