August 14, 2018, 11:18:55 AM

Username
Password

Pages: [1] 2 3 ... 6   Go Down
Print
Author Topic: What's being worked on at the moment?  (Read 36387 times)
0 Members and 1 Guest are viewing this topic.
Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« on: February 12, 2010, 07:21:51 PM »

So I thought I might start to make a post here now and then to tell you what I'm doing right now, and to show you that stuff are happening Smiley

* So currently I'm prototyping for how to represent worlds (that is, battlefields, or "theatres of war" as I prefer to call them, since that allows much more interesting and poetic naming of my classes). This might seem easy, but since WARTBED must accommodate a wide range of various RTT games, it requires a heavy amount of forethought.

* I'm also evaluating audio libraries for the framework. Also a rather arduous aspect since it requires so many trade-offs and will have significant repercussions later for the more stabilised platform.

* I'm unfortunately also trying to handle an apparently autistic editor (Alastairward) that is on a one-man crusade against the RTT genre on Wikipedia. If anyone would care to comment, you can have a look at the RTT article's talk page (he just tried to delete SotHR and recategorise it as RTS(!)), see his lovely correspondence with other people at his own talk pages (there are four archives with people can't believing he's for real), and the wikiquette case raised against him (he raised one against me as revenge for commenting on his).
« Last Edit: February 13, 2010, 01:51:11 PM by Mikademus, Reason: Friggin\' misspelled the title! X-( » Logged


Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #1 on: February 16, 2010, 11:52:26 PM »

Ok, so I've been working on the world representation format and classes. I decided to architect this using good, powerful tools, and since I have been trying out the Boost::multi_index_container storage class I decided that is perfect. For those that don't know, it is a clever storage container that resembles a database in that it contains one set of data, but many predicate-ordered views into it.

As all things Boost, since it is done using pure TMP (template meta-programming) it comes with the prise of longer compile times. I took this, because of the power I'd get. Two days later, I discovered that the complexity I needed pushed the class beyond its capacity (it can only contain 20 views, and a world has many more classes of objects than this), and at that level comilation becomes prohibitively slow, around a minute for about 500 lines of code... Guess how much work is instantiated behind the scenes... O.o Also, the support structures for the Boost solution start to get large, and adding a view requires edits to about five or six different places.

So I've basically thrown away the "clever" way an am now rolling my own world supervisor class. This has halved the code, and the class works very elegantly all by itself without being surrounded by support struts.

Good lesson, in several ways: one the one hand, I learned some very advanced Boost magic, on the other hand, I learned enough to KISS.


Also, that battle against the autistic would-be destroyer of the RTT category at Wikipedia goes on. It is very very frustrating arguing against a person with Asperger's disease and plenty of free time. Also, KDE4.4 was just released: my Linux rig is prettier than ever!
Logged


Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #2 on: February 23, 2010, 11:14:27 AM »

This is a relatively technical post: skip it if you don't care about technical things.

A short talk about architecture, patterns and WARTBED. In "Implementing Patterns" Kent Beck wrote "patterns is where you want to be". Well, I've seen too much pattern-happiness to know that senseless application of patterns can be as destructive to code quality as being cavalier about structuring your work. Still, WARTBED uses patterns selectively and judiciously.

Most core classes that must be created only once are implemented as Singletons, and do so by specialising the wb::Singleton class so they will all have identical interfaces and functionality. The Model-View-Controller architecture is implemented in terms of the Observer pattern. And the classes used when issuing orders can be understood in terms of the Strategy pattern. These are all obvious applications of the patterns and help make the code clear and understandable.

However, due to the nature and intent of WARTBED, a seemingly simple thing such as loading graphics (actually, loading any perceptible resource) it is a little more tricky and messy. WARTBED is intended to work by a Client/Server architecture. Still we will only have one set of data. The server does not care about 3D models or sound effects, yet must have information relevant to it. Therefore, WARTBED defines a Theatre class (from "Theatre of War"), which represents the scene/world/map/level, and the archetypal contents constituting the world (the props in the scene). These props are all abstract (which means they are only descriptions without contents). WARTBED's Theatre module also defines a PropsFactory interface, with creation methods that returns (or rather, should return) scene props of the requested type.

You might be noticing the smell of an Abstract Factory pattern now, if so you've won a cookie. Yeah, this is an abstract factory. It has two implementations: first, the client implementation, which creates actual OGRE 3D (and whatever for sounds etc) objects; it is called the OgrePropsFactory class. Then we have the ServerPropsFactory, which generates objects with only the information the pure simulation cares about. But both the client and the server works through the same Theatre object.

Architectures like this takes longer to plan out and implement than gung-ho, happy-go-lucky coding would, but whereas the latter would be incrementally more costly to expand and maintain over time, a good architecture will possible be easier and faster to build on as time goes on.

I hope that you enjoyed, or at least weren't bored out of your socks, by this little walk-through of some of the design decisions in WARTBED! See you soon! Smiley
Logged


Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #3 on: March 10, 2010, 08:30:19 PM »

So, where are we now? Smiley

I have re-implemented full Dark Omen level loading (with placeholder graphics for particle effects). So Dark Omen maps are loadable and more importantly, manipulable! Basically, the map viewer is now also a potential level editor, though no interface or suchlike for editing has been added.

Unlike the old map viewer, this new one is implemented fully in terms of WARTBED classes, so there is no code waste. The parsers and loaders written will be directly usable both for a direct remake project as well as for the pure WARTBED project (the Bright Portents module).

Have had a few busy days with my job, so coding has been put on a very slow burner during this time. I hope to release something within the next few days, though Wink
Logged


alavet
Orc Shaman
*
Offline Offline

Posts: 1004



View Profile
« Reply #4 on: March 11, 2010, 12:47:50 PM »

can we discuss come points there? good thing to know new map editor will be realised!

are u using open source systems? maybe you should open source your own? or at least use some other guys technologies?

im not familiar with that but think it could help a lot.
there could be a possibilty we're arent alone there with Dark Omen mods :-)

my 2cents
Logged

Battle not with monsters, lest ye become a monster, and if you gaze into the abyss, the abyss gazes also into you.
Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #5 on: March 11, 2010, 11:28:48 PM »

Sure, feel free to ask and discuss. I'm a bit surprised no-one else has yet Smiley

So, to answer your questions: Yes, I am using other people's stuff. The 3D scene graph and rendering is done through OGRE 3D (open source). Audio will (probably) be done using Audiere or OpenAL/cAudio (both open source). Etc. WARTBED will be open sourced when I get to the point where it is meaningful to release the 0.1 "Clausewitz" version. The Dark Omen map viewer (and eventually editor) will be released earlier, but will link to a pre-compiled WARTBED library rather than the source files. All headers will be available.

If you haven't done so already, check our the WARTBED pages on the wiki! The design document in particular will probably answer a lot of your questions. Also, you can add any well through-through suggestions to the WARTBED brainstorming page.
Logged


olly
Global Spokesperson
*
Offline Offline

Posts: 1870



View Profile
« Reply #6 on: March 11, 2010, 11:43:31 PM »

Following all the various aspects of WARTBED on the wiki, is really great for learning how an RTT game engine fits together. Amazing progress, keep up the good work!

Smiley

« Last Edit: March 12, 2010, 11:28:41 PM by olly » Logged

and back in Nuln, the ageing Graf Berhardt smiled his secret smile of pride whenever he heard the latest tales of his eldest son's ever growing chain of glorious victories -(sothr manual)
Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #7 on: March 20, 2010, 07:43:15 PM »

So I have spent the last week ripping out CEGUI v 0.5.2, which was provided by default with OGRE 3D 1.6, and replacing it with the current trunk version 0.7.1. This move was relatively smooth sailing, meaning it only took two days :rolleyes: Which is exactly the very reason I hold to the policy of keeping external dependencies to a minimum. Otherwise I'd have to take punches like this on a regular bases rather than they being exceptions from normal development.

One of the main reasons I needed the new CEGUI version was that the 0.5 series didn't have a Tree widget, which I really really want in the Dark Omen map editor I am working on. So I upgraded and got the control I wanted. Or rather, I got a horrible hack of a control that is more suffering than mere pain. Crazy Eddie himself hates it and wants to replace it (some other guy had mashed a bloody ListBox widget with a mallet until it resembled a Tree control!), and it basically supports none of the functionality I or anyone else need for a proper editor interface. So I spent an additional five days or so trying to coax it into doing what I need. And today I have decided to let it just be decorative and get on with real coding until CEGUI is furbished with a real, usable Tree widget.

So that... slightly annoying distraction... has delayed the editor somewhat. It is coming, though: stay put and stay sharp.
Logged


Flak
Super Moderator
*
Offline Offline

Posts: 1463


Jake Nielsen


View Profile WWW
« Reply #8 on: March 21, 2010, 08:06:33 AM »

so its going well?
Logged

"There is only one way out of hell, thats through it" -- General Patton

"Just because a mage wears the Black Robes, does not make him evil." -- Raislin Magere

"Evil Turns upon it self" -- Paladine
Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #9 on: March 21, 2010, 10:27:59 AM »

It is going well. Because the architecture is now laid down so that all code that is written, even for the Dark Omen editor, also contributes to the goals of the project. That is, though the editor is a Dark Omen-specific tool, it is directly applicable to a Dark Omen remake as well as the Bright Portents WARTBED module.

That said, it is not going tremendously fast, since I'm doing this myself. I expect this to change when I release the source. Speaking of which, I am going to release the editor source along with the editor itself for you to do what you want with Smiley
Logged


Flak
Super Moderator
*
Offline Offline

Posts: 1463


Jake Nielsen


View Profile WWW
« Reply #10 on: March 21, 2010, 08:41:48 PM »

 Grin thanks for spelling it out for me, this sounds very promissing, keep up the good work
Logged

"There is only one way out of hell, thats through it" -- General Patton

"Just because a mage wears the Black Robes, does not make him evil." -- Raislin Magere

"Evil Turns upon it self" -- Paladine
Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #11 on: March 26, 2010, 01:10:36 PM »

As some of you know, the first alpha of the new map editor has been released. It is really a pre-alpha since many features aren't in place yet, but it features full loading of all Dark Omen maps, including animations and particle effects. No sounds or BG music etc are loaded yet, but all things that are part of a map are represented in (what will be) the level editor.

As all WARTBED-based applications, the level editor has a fully customisable input scheme - there's no aspect of the input system that can't be set and configured in the application configuration file. You can of course also set the app to use the input scheme of your preference: FPS controls, RTS controls, DO-style vector acceleration controls, etc etc, you name it.

The released version suffered from some setbacks. First CEGUI--the GUI solution--had to be upgraded so as to get access to a tree widget. Then this widget turned out buggy and almost unusable. Since release a slightly bug-fixed version has been provided by CrazyEddie, though, and the map editor now finally has a reasonably workable tree representation of the scene element hierarchy. Updates are released frequently from now on, and the source code will follow.

With the source code anyone can use this as the bases for a DO-related tool or even a remake project! More info to be had in the IRC channel.
Logged


olly
Global Spokesperson
*
Offline Offline

Posts: 1870



View Profile
« Reply #12 on: March 26, 2010, 11:48:25 PM »

Fantastic! I will look forward to replacing the All Maps pictures with your Map Viewer ones, as yours will be much better.

http://forum.dark-omen.org/maps/all-maps-t155.0.html

Also since work has begun on creating our first Custom Mod Maps, previewing them will be alot easier.

Thanks bro,

Smiley

Logged

and back in Nuln, the ageing Graf Berhardt smiled his secret smile of pride whenever he heard the latest tales of his eldest son's ever growing chain of glorious victories -(sothr manual)
Mikademus
Developer
*
Offline Offline

Posts: 546



View Profile
« Reply #13 on: March 28, 2010, 03:24:32 PM »

Mini-update, just for the kicks of it.

I have always been slightly concerned about the performance of the WARTBED/OGRE code. In the old renderer we saw frame rates of only about 15--30, and even though I knew that was due to the debug mode being extremely slow due to all sanity checks it was still disconcerting.

The new framework is set up so both debug and release builds are made, and the release builds happily steams on at a steady 60Hz, which is the vertical refresh rate of my screen. So today I finally rewrote the initialisation code to allow setting the vsync as well as reading the graphics constraints from a config file, and was pleasantly surprised with a healthy 800 fps in fullscreen 1024x768@32bpp mode Smiley
Logged


Ghabry
Developer
*
Offline Offline

Posts: 1009



View Profile
« Reply #14 on: March 28, 2010, 03:43:50 PM »

And now you have to program a benchmark, that does some nice Camera movements through the map Wink.
Logged

Pages: [1] 2 3 ... 6   Go Up
Print
Jump to: