I've started rewriting my entire framework from scratch. My current framework was great for quickly testing several aspects of the engine, especially shader effects, processing scene entities, and so forth. My original framework will be kept for that singular purpose.
I have a lot of reasons for creating a new framework from scratch, instead of just rewriting my current one, but it isn't a major deal. My current one isn't exactly very large, and a lot of it was written while I was still very new (using "very" since I'm still new, just not as new) so it isn't structured very well for a full game.
Large class names is one of the reasons. I did it to be organized, but while time went on I realized it was so daunting to type long classes. I was very new (again with the very) to the BlitzMax language and didn't use my familiar language of C#. For example: Game.RenderManager.SetAntialias(True) or Game.CameraManager.Camera.FarRange. All very long, especially when it comes to typing several of them together in a single line; EntityPosition(MyEntity, Vec3(EntityPosition(Game.CameraManager.Camera).x, 0.0, EntityPosition(Game.CameraManager.Camera).z))
Of course, I have plans for something like; EntityPosition(MyEntity, Vec3(EntityPosition(F.Cam.Main).x, 0.0, EntityPosition(F.Cam.Main).z))
Still fairly long, but not nearly as bad, and I can easily change the structure when I really start working on that portion of the framework.
The most important reason is threading. Utilizing threading specifically just to load content during loading times and hopefully dynamically; based on player position and camera far range. Leadwerks has Groups that are shown or hidden based on (my guess) the camera position and far range. I plan to use the same method, but before a group is shown (and given time before the player has positioned themselves close to be shown the group) to dynamically load all the models within that group and neighboring groups, using threads.
I will be doing a lot of testing, but this kind of setup is ideal for a game with very large terrain, and probably wouldn't be bad for small terrain based games. If it was too small of a map I'd just load everything though.
This is my progress and I have no screen-shots to share yet, but I will soon. Actually a video, for this process; Load Application, Developer Splash, Engine Splash, GUI. Multiple GUI actions. GUI New Game. Loading screen. Quick map.
I'll continue to post progress from there.
sounds like your making good progress.
ReplyDeletei know what it's like to just start again, quite often you think modifying a model would save you time. but in reality you spend more time fixing things that weren't right, breaking things that are, and in general starting from scratch gives better results
Yeah man, and it's going fairly well. It's also giving me more time to concentrate and plan out the whole framework instead of adding piece by piece based on what I think I'll need. One of the approaches that will disorganize everything.
ReplyDeleteI looked at my whole framework and basically had that "no way" feeling when thinking about just reorganizing the files and coding. I had a better feeling thinking about planning out the framework and building it correctly.