Quick Battle: Knife Fight in a Phone Booth

Post new mods and scenarios here.

Moderator: MOD_Command

musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

Hi everyone — boogabooga and I have collaborated on a new Quick Battle that's a supercharged version of the Submarine 1v1 Duel, including:

- the ability to add up to 2 allied submarines to each side (for a max 3v3 fight)*
- smarter enemy AI
- detailed and accurate OOBs for two different eras: the 1980s, and the 2020s
- civilian traffic
- biologic activity, including a simple simulation of marine life behavior
- win/loss conditions
- realistic temperature gradation by location
- many additional locations, matching underwater hotspots around the world
- snapping shrimp!!

* You're still only in direct command of a single submarine, but the allied submarines will target the OPFOR—as long as you don't accidentally shoot at them. Make sure you check your targets!

Enjoy! You can find it attached below -- unzip to your CMO/QuickBattle folder.

UPDATE v1.4
-divided into two scenarios by era: 1980s, and 2020s
-completely overhauled OOBs
-added temperature gradation by latitude
-civilian traffic will cavitate
-biologics alter depth
-killer whales and fish will engage in realistic hunting/wander behavior
-enemy AI may go active upon detecting torpedo in the water
-enemy AI will correctly identify and ignore friendly or neutral contacts
-posture toward neutrals will be reset if accidentally triggered hostile
-time of day setting fixed
-sim performance improved

v1.32
-fixed bug related to loading battle from save
-fixed bug related to OPFOR faction name
-allied ID expanded to 3nm

v1.3
-allied submarines will ID each other within 2nm
-time of day setting fixed

v1.2
-can specify class of allied submarines
-can set civilian and biologic traffic levels separately
-fixed bug involving side postures
-added South Atlantic and Mediterranean Sea locations

v1.1:
-improved performance
-fixed bug in penalty conditions for ally casualties
Attachments
KnifeFight_v1.4.zip
(25.58 KiB) Downloaded 56 times
Tom Konczal
Posts: 102
Joined: Mon May 29, 2000 8:00 am
Location: Orland Park, IL

RE: Quick Battle: Knife Fight in a Phone Booth

Post by Tom Konczal »

There doesn't appear to be a scenario file in the folder.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

There doesn't appear to be a scenario file in the folder.

That's correct—it's a Quick Battle, which is entirely generated with Lua code. Unzip it to your (CMO Install)/QuickBattle folder and it will appear in the Quick Battle menu when the game starts. (In other words, do not put it in your /Scenarios folder as you would with a normal scenario file.)

If you've unzipped it properly, it will create its own folder inside the /QuickBattle path. It should look something like this:

Image
Attachments
qb.jpg
qb.jpg (37.81 KiB) Viewed 1271 times
Tom Konczal
Posts: 102
Joined: Mon May 29, 2000 8:00 am
Location: Orland Park, IL

RE: Quick Battle: Knife Fight in a Phone Booth

Post by Tom Konczal »

Got it working - thanks
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

Just updated this to v1.2 (attachment to first post has been updated):

-can now specify class of allied submarines
-can set civilian and biologic traffic levels separately
-fixed bug involving side postures
-added South Atlantic and Mediterranean Sea locations
Tom Konczal
Posts: 102
Joined: Mon May 29, 2000 8:00 am
Location: Orland Park, IL

RE: Quick Battle: Knife Fight in a Phone Booth

Post by Tom Konczal »

I have played this battle several times. There doesn’t seem to be a defeat/ victory/triumph notation at the end of the scenario.
Another question, when I have a submarine with a towed array and I spot a goblin, is it better to approach head-on or perpendicular to gain an identification?
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

I have played this battle several times. There doesn’t seem to be a defeat/ victory/triumph notation at the end of the scenario.

When the scenario ends, do you see your final score expressed in points? You get 150 points for each submarine you kill personally, and lose 100 points for each ally killed. (But I should probably put a more verbose debrief here.)
Another question, when I have a submarine with a towed array and I spot a goblin, is it better to approach head-on or perpendicular to gain an identification?

I'm not an expert, but I usually go closer to perpendicular. My reasoning is as follows:

1) It increases the time it takes to close the distance on the contact, giving me more time to positively identify it as hostile;
2) If there's a launch transient, I'm closer to being able to evade;
3) I'm not sure if this is true in CMO, but in other games (e.g. Dangerous Waters) the towed array has a blind spot in the direction of travel of your submarine.

Again, not an expert, so happy to be corrected on any of these points.
Rory Noonan
Posts: 2418
Joined: Thu Dec 18, 2014 1:53 am
Location: Brooklyn, NY

RE: Quick Battle: Knife Fight in a Phone Booth

Post by Rory Noonan »

ORIGINAL: Tom Konczal

I have played this battle several times. There doesn’t seem to be a defeat/ victory/triumph notation at the end of the scenario.
Another question, when I have a submarine with a towed array and I spot a goblin, is it better to approach head-on or perpendicular to gain an identification?
I haven't tinkered with this scenario, but Submarine Tutorial 2.1: Submarine ASW covers approaching a distant towed array contact. For closer in stuff, towed arrays do not perform very well for contacts directly ahead of their ownship: a modern spherical array is much more suitable.
Image
boogabooga
Posts: 981
Joined: Wed Jul 18, 2018 12:05 am

RE: Quick Battle: Knife Fight in a Phone Booth

Post by boogabooga »

Excellent job!

Question, why do the allied submarines show up as neutral? Is that the keep them from sharing contact info?

What would happen if you consider your allies as friendly, but they consider you as neutral?

Also, I think OPFOR can all be on one side rather than three.
The boogabooga doctrine for CMO: Any intentional human intervention needs to be able to completely and reliably over-ride anything that the AI is doing at any time.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

Thanks, glad you liked it!
Question, why do the allied submarines show up as neutral? Is that the keep them from sharing contact info?

Yeah, that was the idea. I think if you were to consider allies friendly but they consider you as neutral, then the AI would be able to see your position and contacts at all times, which wouldn't be right either. But what I COULD do is mark everyone as out-of-comms so they'll appear friendly if you ID them, but there won't be any information sharing in any direction. I'll try that for the next version.

If I did that for the OPFOR as well, then you're right--I could also move them to the same side, which would simplify things. Thanks!
BDukes
Posts: 2664
Joined: Wed Dec 27, 2017 12:59 pm

RE: Quick Battle: Knife Fight in a Phone Booth

Post by BDukes »

This one is very good. Got to witness a great sub battle south of me.

The only issue is the neutral thing. In my case an LA sub's focus was trying attempting to ID me (Virginia). See test file.

Mike
Attachments
sub.zip
(200.17 KiB) Downloaded 17 times
Don't call it a comeback...
boogabooga
Posts: 981
Joined: Wed Jul 18, 2018 12:05 am

RE: Quick Battle: Knife Fight in a Phone Booth

Post by boogabooga »

I would like to use a late Cold War (1970s-1980s) unit selection. Would it work to just edit the html file, or is your script looking for something specific?

What would happen if I changed to the CWDB? I assume that I would have to change the unit numbers of the neutrals in the script, at least.

P.S. the time of day setting seems a little off...
The boogabooga doctrine for CMO: Any intentional human intervention needs to be able to completely and reliably over-ride anything that the AI is doing at any time.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

New version up -- I've updated the attachment at the top of this thread. See notes below:
The only issue is the neutral thing. In my case an LA sub's focus was trying attempting to ID me (Virginia). See test file.
Thanks for the save file, Mike. This is now fixed.

FYI the apparently simple solutions (changing the side postures or marking units as out of comms) did not work and I had to implement a rather elaborate workaround. All allied sides are still neutral to each other, but when a submarine gets within 3nm of a contact on an allied side, it will mark that contact as friendly and therefore drop it as a target.

As far as I can tell after a lot of testing (and someone please let me know if I've missed something), there is unfortunately no way to mark two sides as friendly (either unidirectionally, or otherwise) without getting position sharing at least. Marking units "out of comms" doesn't help because that setting apparently only applies to units within a side, not to other sides. I may report this in the Tech Support forum because I think there SHOULD be an easy way to get the desired results: sides that are friendly to each other but do not share either positions or contacts.
I would like to use a late Cold War (1970s-1980s) unit selection. Would it work to just edit the html file, or is your script looking for something specific? What would happen if I changed to the CWDB? I assume that I would have to change the unit numbers of the neutrals in the script, at least.

P.S. the time of day setting seems a little off...
As far as I know, you can't change the DB within a Quick Battle because there's no Lua function to do that. You could definitely adapt the underlying code for a standalone scenario, though. However, aren't most Cold War submarines also in the modern DB since many of them are still in use somewhere (aside from the U-Boats)? If you can find what you want in the modern DB, it would be easy enough to edit the script. (Note that the actual DBIDs are NOT defined in the HTML-- for this scenario they're in a table in the Script.lua. Look for "subDBIDs" and "factionDBIDs'.)

Fixed the time of day setting -- thanks for catching that! BTW the time of day code was originally copied from the standard Submarine 1v1 QB included with CMO, so I think that means that the setting is broken there too.
boogabooga
Posts: 981
Joined: Wed Jul 18, 2018 12:05 am

RE: Quick Battle: Knife Fight in a Phone Booth

Post by boogabooga »

Lua script execution error: [string "?"]:614: attempt to concatenate a nil value (local 'factionbase')
The boogabooga doctrine for CMO: Any intentional human intervention needs to be able to completely and reliably over-ride anything that the AI is doing at any time.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

Lua script execution error: [string "?"]:614: attempt to concatenate a nil value (local 'factionbase')

I'm not getting that error. Can you tell me what steps you did to get that so I can reproduce it?
boogabooga
Posts: 981
Joined: Wed Jul 18, 2018 12:05 am

RE: Quick Battle: Knife Fight in a Phone Booth

Post by boogabooga »

So far, any 2-vs-2 battle
The boogabooga doctrine for CMO: Any intentional human intervention needs to be able to completely and reliably over-ride anything that the AI is doing at any time.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

EDIT: Never mind, I see the issue now-- weird it wasn't throwing an error for me, but I see where it would. Will update shortly.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

Okay! Should be fixed now -- updated attachment at the top of the thread.

Let me know if that works for you now. Thanks for catching that.
musurca
Posts: 168
Joined: Wed Jul 15, 2020 10:06 pm
Contact:

RE: Quick Battle: Knife Fight in a Phone Booth

Post by musurca »

Hi everyone -- I'm excited to announce a huge update to this Quick Battle, thanks to boogabooga. He contacted me back in February with some suggestions, and since then we've entirely remastered this scenario under his direction. You can download the new version from the updated first post above. To summarize:

* We've divided this Quick Battle into two separate scenarios: a 1980s version, and a 2020s version, featuring huge and accurate unit lists for both eras.

* We've added a bunch of new locations around the world, with an accurate ambient temperature determined by latitude.

* Enemy AI has been improved, now correctly identifying and ignoring neutral/friendly targets. They may also go active upon detecting a torpedo in the water.

* Biologics now vary their depth, and engage in "realistic" hunting and wandering behavior per this thread. (Thanks to all the experts who shared interesting marine behavior!) Also, in honor of BeirutDude, you may now encounter snapping shrimp if you fight in the Caribbean Sea.

* We've also fixed a bunch of bugs and improved performance.

Give it a shot, and let us know what you think!
boogabooga
Posts: 981
Joined: Wed Jul 18, 2018 12:05 am

RE: Quick Battle: Knife Fight in a Phone Booth

Post by boogabooga »

This scenario is due to musurca's excellent programming skills. I only reported bugs and gave a few suggestions. :)
The boogabooga doctrine for CMO: Any intentional human intervention needs to be able to completely and reliably over-ride anything that the AI is doing at any time.
Post Reply

Return to “Mods and Scenarios”