Translations for our friends around the world.

Author Topic: CMANO - Making Tactical Decision Aids - The Lua Gag Reel Ep1: By JC  (Read 3167 times)

0 Members and 1 Guest are viewing this topic.

Offline Asid

  • HAVOC
  • *
  • Posts: 26361



Monday, September 18, 2017
By: JC
CMANO - Making Tactical Decision Aids - The Lua Gag Reel Episode 1


In my previous entry, I praised WarfareSims for their farsighted decision to extend the CMANO's base code with the wide capabilities, simplicity and memory management benefits of the Lua scripting language.





I deeply appreciate the interest that many of you have expressed for knowing how I did put together my tactical decision aid, but I have to confess that I dread that you will be disappointed. I'm no programmer, and I grabbed pieces of code from here and there to put together this Frankenstein project. I apologize in advance, as you may see improper coding techniques and some inconsistencies in the logic of my entire scenario.

Without further ado, here is what I did.

If you remember from my previous post, the sequence of events was:

1.   The scenario starts
   1.   A counter is initialized. This counter keeps track of a series recursive ship vs sub simulation runs
   2.   Units are added to the scenario
       1.   The US warship is placed in the center and give a course due south, at flank speed
       2.   A DPRK sub is placed 50 miles from the US ship and given a patrol area delineated by the reference points above
   3.   If the US warship remains undetected and reaches an escape area south of the DPRK patrol's area
      1.   All units are deleted
      2.   The counter mentioned in 1.1 is advanced
      3.   New units are generated
         1.   A US warship is placed in the center and give a course due south, at flank speed
         2.   A DPRK sub is placed 50 miles from the US ship and given a patrol area delineated by the reference points above. The DPRK sub initial position is not the same as the one used in the previous simulation run. This initial position is advanced clockwise from the initial position of the US warship
   4.   If the US warship is detected
      1.   A marker reference point is made at the initial position of the DPRK sub. The marker is labelled "Danger" because this an initial sub position that will generate a headache for the US commander.
      2.   All units are deleted
      3.   The counter mentioned in 1.1 is advanced
      4.   New units are generated
         1.   Same as 3.1
         2.   Same as 3.2

The CMANO scenario editor allows the player to glue together special actions within events. Events are triggered by triggers and conditioned by conditions :) . This is because many times, you want an special action (strike hostile nation's port)  to happen when something has happened (i.e. a friendly ship was attacked, a trigger) and a condition is met (i.e. you have the means to strike nearby the target, a condition).

The logical hierarchy goes: Events do happen when Triggers are triggered, Conditions are met. The output is actions.

The beauty of all this is that conditions and actions can be Lua scripts. And when you unleash a Lua script, the world moon is at your feet.

So, let's start with the events.



Read on: Click Here
funny
0
informative
0
Thanks
0
No reactions
No reactions
No reactions

I stand against Racism, Bigotry and Bullying

Offline Asid

  • HAVOC
  • *
  • Posts: 26361
Re: CMANO - Making Tactical Decision Aids - The Lua Gag Reel Ep1: By JC
« Reply #1 on: September 30, 2017, 03:53:41 PM »
CMANO - Making Tactical Decision Aids - The Lua Gag Reel Episode 2: Click Here
funny
0
informative
0
Thanks
0
No reactions
No reactions
No reactions

I stand against Racism, Bigotry and Bullying

Tags:
     

    Popup Dungeon : tactical roguelike RPG

    Started by Asid

    Replies: 3
    Views: 2430
    Last post August 14, 2022, 09:30:00 PM
    by Asid
    Crying Suns Tactical space rogue-lite

    Started by Asid

    Replies: 13
    Views: 5857
    Last post May 12, 2023, 12:17:15 AM
    by Asid
    Unreal Engine Sizzle Reel 2016 - GDC

    Started by Asid

    Replies: 0
    Views: 2787
    Last post March 16, 2016, 07:17:16 PM
    by Asid
    War Battles Tactical free for PC right now! free!

    Started by gameleaper

    Replies: 1
    Views: 1165
    Last post December 02, 2021, 11:43:55 PM
    by Asid
    Cyber Ops : Noir cyberpunk tactical game

    Started by Asid

    Replies: 0
    Views: 2263
    Last post June 07, 2020, 01:33:48 PM
    by Asid