Friday, 23 April 2010

Weapons, pylons and stores

Spent the day working on the Helicopter entity and the sub-classes that handle all the pylons and stores. It's worth spending time automating these things as much as possible now to simply things later.

I broke out UMLet, a nice fast Java based UML editor to look at my structure. What's missing is the store-jett which needs to be a function of [TStore], pass it the pylon number and it will be required to generate the physics object, parent the rail/pod/fuel cell, detach it from the pylon and let Newton take over, thus letting the pod/rail complete with ordnance fall to earth.

And by moving the [SelectedZone] property to the [Pylon] from the [Avionics] class, it allows for the ground-crew loading system to simply add rockets and let the [Pylon] advance the zone so all 3 zones are populated in three clicks. That way it's not dependent on a playing crewing the Helicopter (as [Avionics] are only instantiated when you board a vehicle and destroyed on exit).

This is all part of the process of adding the WEP MFD page which needs access to stores data and it gets it from the [Stores] class, which can be thought of as a black box into which each pylon (4 of them) send signals about what is loaded where. And how to re-load of course.

I'm torn about creating the whole WEP page graphic as a vector, I'd rather do that as textures scaled up can look a bit blurry. Cockpit builders might want a stand alone OpenGL client that doesn't require the 3D engine for displays so going native OpenGL makes adding it a cut and paste job.

No comments:

Post a Comment