Assigning Cargo Elements to a Mission

Take command of air and naval assets from post-WW2 to the near future in tactical and operational scale, complete with historical and hypothetical scenarios and an integrated scenario editor.

Moderator: MOD_Command

Whicker
Posts: 664
Joined: Tue Jun 19, 2018 9:54 pm

RE: Assigning Cargo Elements to a Mission

Post by Whicker »

at some point all of the ground units stopped moving or firing

I noticed this too, I think it is cause all possible targets are gone. It is a strike mission not a patrol mission so I think this is correct. It did feel a little weird though. The cargo mission is separate from the strike mission, so the ship keep unloading, then they just stay there since there is nothing to attack. You could drop in another blue unit and see if they all go after it, I think they would.

There is no extraction, and when they run out of ammo they tend to wander around and are just cannon fodder - if there is any enemy left to shoot them.

I am not sure the AI can extract them, I have been thinking about that. Only thing I can think of is to have them go back to the lz and then after a bit have them disappear via lua? not sure how they could be picked up, eventually I will see if I can sort it out, it would be cool if they could be.

When they run out of ammo I think I could have an event running that would loop thru all the cargo units that landed and check to see if they have any ammo and if not have them leave the mission and then assign them to a course to go back to the LZ. Or somehow group with an ammo truck or something back at the LZ.
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

Whicker,

You did great. I', going to provide some info just in case you want to make this into an actual tutorial--which I think that you should.

Here are just a few more questions/observations:

1.) There were OTHER enemy targets to shoot at, and the helo pad was crippled but not dead when they stopped shooting.

2.) I understand the lua definition concept, but singling out the SAM units obviously involve all of the landed units, and I was wondering how ther other units are being called into play since they aren't mentioned by name.

3.) The battle, as you know, is pretty one-sided (I know it's not a real scenario), so I gave the enemy a much more liberal approach of being able to shoot at anything "not friendly." The defending units were able to wipe out the attackers, so don't do that. <lol>

4.) I see SAR Special Event code contained in the scenario, along with lots of planes. I assume that these were probably not involved in this at all, and were just left over from a previous scenario.

5.) If you desire to have the defenders fire at you, it's best to give them a Land Strike Mission. They wouldn't really fire for me, even though the attackers were sighted, until I gave them an actual Land Strike mission.

6.) After dropping off the second batch of Javelins, I sent the helos to a location where I had sent the first group of Javelins after they had fired their missiles (hence they were no longer armed). I manually picked up the first batch of Javelins and then RTB. Everything worked perfect. Perhaps some kind of Lua code could be created that would instruct the helos to pick up units at a holding spot after they have expended their ammo?

7.) Lastly, the SAM units moved right along with the attacking units and were listed as escorts in the Mission Editor, so that seems to be working as you had hoped.

Extraction would be cool, but could be really involved. It is probably beyond the scope of what the game is supposed to be about.

Thanks again. I'm going to play around with it some more. I will defintely be keeping this scenario as an example reference.

Doug
Whicker
Posts: 664
Joined: Tue Jun 19, 2018 9:54 pm

RE: Assigning Cargo Elements to a Mission

Post by Whicker »

The other targets I think were part of the runway/tarmac and they couldn't attack them? not exactly sure why they stop even though it seems like they could keep trying to attack the airfield stuff.

All units go thru a check to see if they are sams or not - if they are not a sam then they get assigned to the normal strike mission, if they are a sam then they are assigned as an escort to the strike mission. It may look like I am only checking for sams - but it is an if/else thing - so if it is a sam do this, else (all other units) do that.

The scen is using my starter scen - so it has lots of stuff pre loaded. There were ac on the blue side, so if you played as blue you could defend against the incoming invasion. The SAR stuff is not active, just part of the starter scen.

I sort of have a way now to check units to see if they are out of ammo, and if so return them somewhere so they get out of the fight. Extraction is not possible as far as I can tell, there is a way to manually tell an AC to pickup a unit, but it doesn't work for LCACs/ships. I doubt there is lua to support doing it for the AI other than doing it very manually. There is also a 'Tents' facility that can hold cargo, I thought about returning the out of ammo units to that and then add them to that facility as cargo - then there could probably be a cargo mission to return them. Course I don't think you can have a cargo mission go to another cargo facility? ahhhh, maybe they just rtb with the cargo, and then the cargo transfers. I could fake it by putting the LCAC at the dock, and then a cargo mission to take them near the mothership, then lua to RTB to the mothership which would unload the cargo, then reassign them to the cargo mission and they return to the pier/tents. Yuck.

I'd also like to be able to rearm them once they get back to their LZ or where ever I send them when they are out of ammo. But once they have ammo again I'm not sure what I would do with them - could send them out again, or have them just hang out as a defensive unit.
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

I'd also like to be able to rearm them once they get back to their LZ or where ever I send them when they are out of ammo. But once they have ammo again I'm not sure what I would do with them - could send them out again, or have them just hang out as a defensive unit.

FYI......As I said, I did MANUALLY pick up the Javelin teams with the helos that I used to drop off OTHER Javelin teams, and then they RTB to the ship. The Javelin teams (all with ZERO weapons) were added back to the cargo total, so I went from 65 to 71. I realize that this is weapons, but it didn't seem to matter as they appeared to be used on subsequent missions.

Perhaps, until they get it sorted out, it might be better to simply fly/sail the pick up platform, and then just use Lua to remove the cargo/attack detail from the map. They wouldn't be used any longer, but they wouldn't be killed because they had no more ammo.

Just a thought.

Doug
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

One of the most confusing things about the cargo function is the lack of precise knowledge as to what is being carried.

For example, your helos are all carrying 3-man Javelin teams. The cargo loaded is a 3-man Javelin, and if you check the helo while in flight, you will only see a 3-Man Javelin team.

When the helo lands, however, you will see a Landed Detachment unit. If you look at the Landed Detachment unit you will see the weapons associated with a 3-Man Javelin team.

Everything seems fine until you see that the unit is represented by a truck-looking counter, and that the unit travels at 26 kts per hour.

So, what else is in this unit? If it gets killed, it only lists the 3-man Javelin team as being lost, yet it was definitely traveling at 26 kts toward its target.

It can be puzzling sometimes.

Doug
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

  Post #: 1

Whicker,

I have been using your Lua Script and replaying your scenario, with some modifications here or there. It works as it should.

Then, I used your Lua Script for a completely different scenario, but with the same concept, and I receive the message that the Event Action did fire. The first unit takes off, as expected. But, when it fires again, no more units ever start moving. They just stay there. Is there something else in your scenario that governs the actions of my combat cargo units? Any ideas as to why the second units would just sit there?

Doug
Whicker
Posts: 664
Joined: Tue Jun 19, 2018 9:54 pm

RE: Assigning Cargo Elements to a Mission

Post by Whicker »

are you saying a cargo unit arrives as its destination but then the mission does not get assigned to them? if so I have noticed that the drop location is not always within the cargo mission area, sometimes it is a bit outside so the trigger area has to be a little larger than the cargo area.

Also, if it is a sam and the mission is a strike mission it won't move as it won't have any strike weapons, that why I was checking to see if it was a sam and assigning it as an escort.

If you have them assigned to a strike mission change it to a patrol mission as strike missions can be more picky.
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

The cargo units (there are three simple infantry units) arrive at their destination, and is definitely assigned within a much larger area, so that isn't the problem.

There is no SAM unit at all. I didn't believe that they needed one to make it work, so none is included.

The first unit gets an assignment and proceeds toward it an enemy target.

The Event fires again, but no more units ever get assigned. The Event continues to fire, and no other units are ever assigned or ever leave their original location.

I did have them assigned to Strike Missions and there were Auto-Detectable enemy units nearby.

I will re-assign them to a Patrol Mission and see if that works. In the example that you provided to me, you had them assigned to a Strike Mission and had enemy targets listed in the box, so I figured that that was the way to go. I'll test it out and let you know.

Thanks.

Doug



DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

I changed it to a Patrol Mission.

The three helos dropped off their infantry units.

After 8 minutes, the first infantry unit takes off after the enemy.

After another 8 minutes, the Event is fired again, but additional units are assigned to the mission, so the other two just sit there.

The LCACs are arriving, but they have nothing to do with the example. The never get assigned to the mission either.

There has to be a simple explanation that I am overlooking.

Thanks.

EDIT: In subsequent action, some additional units would, on occasion, eventually be assigned to the mission. They would sit through about 10 Event firings and then move. There was no pattern to it. Let the sample run and you should be able to see what I am talking about.

Doug
Attachments
CargoWasp1ab.zip
(101.07 KiB) Downloaded 16 times
Whicker
Posts: 664
Joined: Tue Jun 19, 2018 9:54 pm

RE: Assigning Cargo Elements to a Mission

Post by Whicker »

few things:

- the trigger area needs to be a lot larger than the cargo mission area. I have noticed that the cargo mission area is not really an exact location, it is an initial way point - then if the LCAC doesn't like the terrain it tries another spot nearby that may be outside the cargo mission area, and then it may be outside the trigger area so they never get assigned. That looks like part of the problem. I only think this is an issue with boats/lcacs -i don't think helos have this issue. If you look at some of the terrain where the lcacs go initially it appears to be very steep - they then go to something that looks more like a beach. I have also seen them rtb and say there was no suitable location I think.

- Strike missions seem to be a little weird - if the mission is a ground strike and the unit does not have ground attack weapons (SAMs were the example that I was aware of) then they won't go anywhere unless you assign them as an escort. Looks like unarmed recon units don't have ground attack weapons so they act the same.

- the Unit Remains in Area seems to fixate on a particular unit - in this example one of the units it got to was an unarmed recon unit, that unit was assigned to the strike mission but did not have ground weapons so it did not leave the trigger area. Next time thru it is still there and is still the Unit that Remains in the Area so the script is still assigning that same unit to the strike mission which it won't go on so it gets stuck in a loop. Delete any unit without weapons and I think it would, or use a patrol instead of strike - though I am not actually sure they would go on that either. I think in a later version of that script I figured out that some units got stuck and caused the action to keep assigning the same unit to the same mission and never got to any other units so I added a path to each unit at the same time as I assigned them to the mission, this took them out of the trigger area no matter what.

In playing with this I also learned something else - with WRA ground = tight, if the ground units came across an unidentified contact they just sat down next to it even if there were other hostile units right next to it. I would have thought they would have gone closer and tried to investigate it more and then move on the the next hostile. I may report that as a bug as it could really screw up an AI side if they could not be WRA free for some reason. I wonder if AC would do the same thing? follow an unidentified contact even though there were hostile ones nearby?

I posted a scen after this that was inspired by this thread - King of Alcedo I think? that has all kinds of crazy AI cargo drops with missions. I got a little carried away with it but it ended up pretty neat I think.
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

King of Alcedo

Thanks for the reply, and the tip on the scenario. As I previously stated, I'm no very good with Lua scripts, but I can usually look at them and be able to apply them to MY situation by using the same concept.

Thanks again.

Doug
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

King of Alcedo

Thanks for recommending this scenario. It is perfect. Even if you don't play it as an actual scenario, it is perfect for displaying how cargo missions and attacks can be conducted. I would highly recommend this to everyone.

Cargo, and cargo operations, are extremely important in military operations today, and your scenario brings that to life.

Thank you once again.

Doug
Whicker
Posts: 664
Joined: Tue Jun 19, 2018 9:54 pm

RE: Assigning Cargo Elements to a Mission

Post by Whicker »

you should post that on the thread for that scen so people know you liked it.

I thought it was pretty neat just to watch from the enemy side. If I made the Blue side just have static defenses then it would be more fun to watch the Red side do its thing and attack, but I was really trying to show that the AI side could do a formidable job of taking and holding ground with cargo units against a real player with the same equipment - all with the same cargo mission abilities - ie no teleporting or other lua magic.
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

That's exactly what I intend on doing. I will set up Blue as the defender, giving them a variety of things to work with, and then I will allow Red to attack. I will then watch the whole thing take place.

My initial interest in this came from watching Gunner's H-Hour scenario depicting the attack and then the invasion of Norway. CoW did not exist when the scenario was created, so any invasion forces had to be teleported into the scenario. That works fine, but I thought that since Cow and cargo now do exist, wouldn't it be nice to use them in a massive type of scenario. After I created the framework for my scenario, I reversed the tables and wanted to have the AI be able to conduct and invasion (without teleporting) by using cargo. I didn't know how to do it. But, you did it.

Thank you once again. I know that you didn't make the scenario for me, but it is exactly what I was interested in.

Doug
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

I think in a later version of that script I figured out that some units got stuck and caused the action to keep assigning the same unit to the same mission and never got to any other units so I added a path to each unit at the same time as I assigned them to the mission, this took them out of the trigger area no matter what.

I am back at this again. Everything works great with your scenario, but when I try to implement the same thing with a scenario created by me, I get the one unit to move, and then nothing else. Despite the fact that the Event keeps firing, only one unit ever moves. I was wondering if you had an example of what you described above? I am only using infantry units armed with rifles going against other infantry units, so the weapon thing isn't the problem.

Any ideas? Any other Lua scripts to make this happen?

Thanks.

Doug
Whicker
Posts: 664
Joined: Tue Jun 19, 2018 9:54 pm

RE: Assigning Cargo Elements to a Mission

Post by Whicker »

post it and I'll take a look.

Main things I am aware of are mostly related to strike missions:

- no enemy units to strike
- no weapons compatible - like the sams on a ground strike or even a rifle squad won't move against a runway I think

If you want to assign them to a path to take them out of the trigger area and then assign them to a mission it could be something like:
local u = ScenEdit_UnitX ()
local newCourse = { [1] = { longitude = '-91.5445688355872', latitude = '-0.39626454890968', TypeOf = 'ManualPlottedCourseWaypoint' }}
u.course = newCourse
ScenEdit_AssignUnitToMission (u.name, "your mission name")

just pick a point outside the unit remains in area area and use that instead of my lat/lon. From what I have seen anything with AI cargo should probably do this - assign a path to get them out of the trigger area in addition to assigning them to the mission so that the next unit can become UnitX. UnitX seems to only work on one unit at a time, not sure if that is intended or not.
MagpieS
Posts: 22
Joined: Sun Oct 19, 2008 3:46 am

RE: Assigning Cargo Elements to a Mission

Post by MagpieS »

I tried a similar sort of script and it worked -reasonably- well.

Main issues were that the cargo units being such a small detechment were savagaed by any ground units placed inthe scenario editor and also after a few test runs the AI ust started sending all cargo units off in a random direction and not stopping, rather than patrolling within the reference points.

Why cargo units are different to scenario editor units is beyond me.
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

the next unit can become UnitX. UnitX seems to only work on one unit at a time, not sure if that is intended or not.

Whicker,

You solved it. It would ALWAYS work for the first unit, and then no one else would ever be assigned. In your scenarios, most of the units are fast-moving mobile units. Once assigned, they dart off toward the target at 30 kts. I, however, have only been dealing with Infantry units which can only move at 5 kts. Plus, I seem to have a large Trigger Area so it takes forever (longer than I have patience for) for that first unit to clear the area so that the next one can be assigned. Therefore, I am only getting one unit per game (almost) to be assigned before I give up. I will try it again with smaller areas, or individual units.

I did see that the units that you had assigned using long./lat. coordinates seem to work fine. These coordinates seem very long (numerically speaking). I doubt seriously that you make these up, so how do you designate these locations? Do you click in a spot or what? How does that work?

Thanks again.

Doug
DWReese
Posts: 2429
Joined: Fri Mar 21, 2014 11:40 am
Location: Miami, Florida

RE: Assigning Cargo Elements to a Mission

Post by DWReese »

after a few test runs the AI ust started sending all cargo units off in a random direction and not stopping, rather than patrolling within the reference points.

MagpieS,

I saw this behavior as well, even in the scenario that Whicker sent to me. Perhaps it has to do with running out of ammo. Maybe it's something else. I figure that I need to be able to get multiple units assigned first before I tackle the issue that you brought up. But, yours is a valid one.

The cargo aspect of this game is really good. Plus, it's fun. I hope that these "nuances" can somehow be ironed out.

Thanks again.

Doug
MagpieS
Posts: 22
Joined: Sun Oct 19, 2008 3:46 am

RE: Assigning Cargo Elements to a Mission

Post by MagpieS »

ORIGINAL: DWReese
after a few test runs the AI ust started sending all cargo units off in a random direction and not stopping, rather than patrolling within the reference points.

MagpieS,

I saw this behavior as well, even in the scenario that Whicker sent to me. Perhaps it has to do with running out of ammo. Maybe it's something else. I figure that I need to be able to get multiple units assigned first before I tackle the issue that you brought up. But, yours is a valid one.

The cargo aspect of this game is really good. Plus, it's fun. I hope that these "nuances" can somehow be ironed out.

Thanks again.

Doug

I don't think so as my routine detects when a unit enters the area and then assigns only that unit to the mission. The main issue is that it initially worked and work really well, but at some point something went wrong in the scenario and the landed units went bonkers.

The concept of a cargo module is a good one, however the way it has been implemented is terrible.
There are numerous things it won't do and getting to do even the most simple things is very cumbersome.
It should be just simply picking up in-game items from one area and taking them to another.
Post Reply

Return to “Command: Modern Operations series”