Monday, June 8, 2015

WFMC - Implementing the Options for Rotation [Part 8/11]

The last three weeks has been busy with real life, so trying to find the time to squeeze in a little bit of coding has been quite the struggle; and to add salt to the wound, the majority of the work that I've been working toward accomplishing has been refactoring code within the Business Logic Layer of the Application, which is non-functional - paying back my Technical Debt over the last two months or so … Long story short - I've gotten some work done on features that are necessary but not super "flashy", but hopefully it will be enough to keep everyone interested until I can unveil more fun and exciting features.

WHERE WE LEFT OFF WITH PART 7/11

Here is what the application looked like on the 20th May 2015.


We had added the zoom in/out capability (in the top right of the OpenGL View. We had also added the code to ensure that the checkboxes for Hornblowers, Difficult Terrain, Enemy Upon Us, At the Double, and Heroic Move were all adjusting the Remaining Move Value to allow them to be fully functional.

MORE PROGRESS THAT HAS BEEN MADE

The first thing that you should notice is the newly enabled feature and the placeholder for a new future feature.





We have enabled the Rotation Radio Button Options in the Center on the Left and added the Clear All placeholder button to the bottom right of the Application. You may have noticed that the Radio Buttons for the Translation Sliders have also been renamed to the function that they are appropriately performing. As of right now, all Translation is Vector Based, so that is the default selected Radio Button.




I had originally intended to also include the functionality for the "Use Vanilla WotR Move Limit Rules" Checkbox in this update, but alas - I had run out of time and that feature is requiring more Non-Functional Refactoring and effort than I had originally anticipated. Perhaps it was the 20-hour SmallWorld ©, Star Wars Epic Duels ®,  & Diablo III © XBox One © Extravaganza I had with my brother over the weekend that consumed all my time … NAH! That couldn't be it.




The first thing I want to show is the changed availability of the Hornblower Checkbox. Previously, it was enabled and disabled only by the selected Desired Formation and Desired Unit's availability.




We have changed it so that once a formation is Baselined, the state of the Hornblower Checkbox is committed and persisted for the formation. That is to say, there is no way to remove a Hornblower from a formation after it is in play - so why should the checkbox be enabled after the formation is baselined. With leaving it enabled, I was able to check and uncheck the checkbox at my leisure round-after-round (effectively allowing me to add +1" Move whenever I wanted extra Move Value). This defeats the intent of the Application, so it has been locked down once the formation is Baselined. If you then make a change to the Desired Unit, it will re-enable allowing the new formation to be selected for Hornblower availability.


As mentioned earlier, We have also turned on the Radio Buttons for the Rotation Options.

Recall back to previous posts about Rotating via Spinning (which occurs about the center of the formation) and Rotating via Wheeling (which occurs about a specified corner of the formation).
The way that the Application up to this point has been using a combination of the two above, because the formation was rotating about the Origin of the crosshairs (which is actually located at the bottom-center of the Command Company within the Formation. Furthermore, the Expended Move Value for the Rotation had no bearing in reality - and didn't take into consideration the width or length of the Formation for calculating cost. So, basically, we were letting everyone "Get Away with Murder" and not calculating realistic rotation costs! The Translation Costs were accurate and as of today's incarnation, now the Rotation Costs are correct, as well.

The Expended Move Value is still not "compounded" until the Formation is baselined; so any Rotation or Translation or Reconfiguration to orient and place the Formation before Baselining will not occur Expended Move Value Cost (just like before).

Now, this is actually going to be rather difficult to show with static images. I guess I'll just have to give it a shot and see how it goes. I'll start with the rotating about the center option, first. It is the "Rotate via Spinning" Radio Button Option.

Here is the Formation that we were just playing with for the Hornblower. It is a Formation of Minas Tirith Archers in 2x3 Configuration with the "Rotate via Spinning" Option selected. The formation has been Baselined (so it will start to accrue Expended Move Value based upon the dimension of the Formation).

Here we go, I'll move the Rotation Slider and watch how it rotates about the center of the Formation, which is 1 Company in from the left/right sides and 1.5 Companies in from the front/bottom sides.

Hopefully that is enough to give the idea of how it works for Rotating via Spinning about the Center of the Formation. I'm going to Reset the Round (for Round 1) to get the Formation back in its original location and then I'll do the same for Rotating via Wheeling.


Once the Radio Button is changed from "Rotating via Spinning" to "Rotating via Wheeling" the drop down ComboBox under the Radio Button is also enabled (since you have to select a corner via which the wheeling will be applied).




When you select the drop down for the ComboBox, it right now only has the option for the two front corners of the formation. I plan to add the back corners, but I need to think about a cleaver way to do that for non-rectangular Formations.

So, let's start with Rotating via Wheeling for the Front-Right Corner of the Formation:


Here is a Cavalry Formation of Elves in a 5x2 Configuration Wheeling about the Front-Left Corner of the Formation:


A few other minor fixes included the fact that the Zoom Buttons were not working for Cavalry Formation. It was a happenstance that I stumbled upon while testing the Rotation functionality. So, there we go. I guess it wasn't as small of a change as I had originally thought - in fact this filled up a post quite nicely.

Any thoughts or feedback? It's getting close to my original "Definition of Ready" that I had created for myself!!








    LINKS TO OTHER PARTS OF THE WFMC PROGRESS SERIES


      LINKS TO OTHER PARTS OF MOVEMENT TYPES AND LIMITS SERIES




      • Movement Types and Limits Series - Reconfiguration Movement of Cavalry Formations Comprised of 2-3 Companies [Part 11/23]
      • Movement Types and Limits Series - Reconfiguration Movement of Cavalry Formations Comprised for 4 Companies [Part 12/23]
      • Movement Types and Limits Series - Reconfiguration Movement of Cavalry Formations Comprised of 5 Companies [Part 13/23]
      • Movement Types and Limits Series - Reconfiguration Movement of Cavalry Formations Comprised of 6 Companies [Part 14/23]
      • Movement Types and Limits Series - Reconfiguration Movement of Cavalry Formations Comprised of 7 Companies [Part 15/23]
      • Movement Types and Limits Series - Reconfiguration Movement of Cavalry Formations Comprised of 8 Companies [Part 16/23]
      • Movement Types and Limits Series - Reconfiguration Movement of Infantry Formations Comprised of 9 Companies [Part 17/23]
      • Movement Types and Limits Series - Cavalry Movement Example 1 from Page 33 of WotR Rulebook Analysis [Part 18/23]
      • Movement Types and Limits Series - Cavalry Movement Example 2 from Page 33 of WotR Rulebook Analysis [Part 19/23]
      • Movement Types and Limits Series - Cavalry Movement Example 3 from Page 33 of WotR Rulebook Analysis [Part 20/23]
      • Movement Types and Limits Series - Reconfiguration Summary of Cavalry Formations by Company Size [Part 21/23]
      • Movement Types and Limits Series - Cavalry Restrictions of Reconfiguration by Formation Name Summary [Part 22/23]
      • Using WFMC to Verify Movement Examples [Part 23/23]


      No comments:

      Post a Comment