Minefields... Potential method. Does anyone know how to?

Modders can post their questions on scripting and more.

Moderators: Slitherine Core, BA Moderators

Post Reply
GottaLove88s
Lieutenant-General - Do 217E
Lieutenant-General - Do 217E
Posts: 3151
Joined: Fri Apr 06, 2012 6:18 pm
Location: Palau

Minefields... Potential method. Does anyone know how to?

Post by GottaLove88s »

Gents,

This is probably one for the intelligentsia of Enric, rf900 or Richcat... but does anyone know how to create a minefield for BA? Does this code exist anywhere?

As an approach, I was thinking about this...

1. Create a new unit called Minefield (graphic of a skull & crossbones, no movement, zero firing range, zero AP, zero HE)
2. Add some code that allows engineers to place Minefield units in adjacent squares, or to remove them
3. Add something (to squads.csv? or to terrain.txt? or somewhere else, i'm not sure?) that let's Minefield units hide in any terrain (in the same way that infantry can hide in trees, houses, etc)
4. Enemy scouts would be able to see minefields by piggybacking on the existing BA code (in the same way that scouts can see other hidden units, if they're close enough) but minefields would be invisible to all other enemy units

So now you've got a Minefield icon, that engineers can place/remove, and scouts can see from 2 spaces away. It can't move or fire.

5. Give Minefield units a 1-space HE and AP reaction shot in squads.csv

That would mean, when any enemy unit entered into a square adjacent to the Minefield, it would "defend" itself. The strength and accuracy of a minefield's explosion could be set by the HE min/max and AP min/max, to have different impacts on infantry (low; ie. set to kill 1-2 men) or armour (high; ie. set to knock out a tank).

6. After the Minefield fires its reaction shot, it should automatically "die"

This would mean minefields effectively guard 3x3 areas, so they are mine fields rather than single mines, because I couldn't figure out an easy way to make it work as a single square.

There are problems with this approach, in that by using existing BA code, minefields would always be marked as visible for the home team and would only attack enemy units. Also, enemy engineers would have to suffer one HE attack if they moved into an adjacent square in order to remove a minefield (unless anyone knows how to make the engineer unit type immune to reaction shots from minefields?).

Might this work? Does anyone know how to...?

Thanks for all ideas and suggestions...
:-)
SCENARIO LINKS
Seelow'45 -> www.slitherine.com/forum/viewtopic.php?f=313&t=55132
Normandy'44 -> www.slitherine.com/forum/viewtopic.php?f=87&t=42094
Dieppe'42 -> www.slitherine.com/forum/viewtopic.php?f=87&t=42347
morge4
Brigadier-General - Elite Grenadier
Brigadier-General - Elite Grenadier
Posts: 2114
Joined: Fri Apr 29, 2011 2:56 pm
Location: Penalty Box
Contact:

Re: Minefields... Potential method. Does anyone know how to?

Post by morge4 »

Just my thoughts...would be really great if you could figure it out as a single hex. It would seem more realistic I think, 3x3 can get pretty big if you ahve multiple ones on a single map. But I like the idea... :)
Richcat
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 219
Joined: Sun Nov 07, 2010 10:09 pm

Re: Minefields... Potential method. Does anyone know how to?

Post by Richcat »

GL88's

Links below original done be the incredible Merr, my bro Tim1966 added the mine field sign. J2D did an amended one in his Pacific Campaign.
viewtopic.php?f=87&t=19006 Original mention of Sappers ans mine field by Merr
viewtopic.php?f=105&t=19349&p=174267#p174267 It was used in Rescue Prisoner v1.0 by Merr- The link won't work for me, But I downloaded it some time ago. New link https://docs.google.com/open?id=0BwKJJy ... GtmV0pQRmc
viewtopic.php?f=105&t=19891 J2D used it here in Pacific Campaign 2.

There is also the new object reaction function for say AP and or AT mines or boobytraps , http://www.slitherinebravo.net/GameWiki ... user_value
Cheers
Richcat
GottaLove88s
Lieutenant-General - Do 217E
Lieutenant-General - Do 217E
Posts: 3151
Joined: Fri Apr 06, 2012 6:18 pm
Location: Palau

Re: Minefields... Potential method. Does anyone know how to?

Post by GottaLove88s »

Thanks Richcat!

I certainly like Merr (and your bro's! ;-)) new icon...
Image[/quote]

If I understand these links, this minefield works as a new, non-moving unit, that simply blocks movement... so it has to be removed, in order to open areas for access.

I wonder if it could be coded to "explode" (trigger AP or HE response attack) when another unit "stepped onto it"?

Also, I see Merr left his mines to be added by the map designer, using the BA Editor. I wonder if we could piggyback on Enric's code (that upgrades engineers to lay pontoons and set/remove tank traps) to give them a function to set/remove mines too...? Perhaps that's making engineers a little too omnipotent...?
Last edited by GottaLove88s on Tue Dec 18, 2012 2:27 pm, edited 1 time in total.
SCENARIO LINKS
Seelow'45 -> www.slitherine.com/forum/viewtopic.php?f=313&t=55132
Normandy'44 -> www.slitherine.com/forum/viewtopic.php?f=87&t=42094
Dieppe'42 -> www.slitherine.com/forum/viewtopic.php?f=87&t=42347
GottaLove88s
Lieutenant-General - Do 217E
Lieutenant-General - Do 217E
Posts: 3151
Joined: Fri Apr 06, 2012 6:18 pm
Location: Palau

Re: Minefields... Potential method. Does anyone know how to?

Post by GottaLove88s »

morge4 wrote:Just my thoughts...would be really great if you could figure it out as a single hex. It would seem more realistic I think, 3x3 can get pretty big if you ahve multiple ones on a single map. But I like the idea... :)
Hmm, I know what you mean Al... 3x3 is probably too big an area, because it would be easy to lock off whole sections of map just by laying 2-3 of the buggers... Just can't figure out how to code it for only 1 square? Any ideas?
SCENARIO LINKS
Seelow'45 -> www.slitherine.com/forum/viewtopic.php?f=313&t=55132
Normandy'44 -> www.slitherine.com/forum/viewtopic.php?f=87&t=42094
Dieppe'42 -> www.slitherine.com/forum/viewtopic.php?f=87&t=42347
pk867
Sr. Colonel - Battleship
Sr. Colonel - Battleship
Posts: 1602
Joined: Fri May 08, 2009 3:18 pm

Re: Minefields... Potential method. Does anyone know how to?

Post by pk867 »

hmm what if you make an invisible vehicle? it occupies one hex. It can defend itself. and have a 1 hex attack range.

Plus it can be removed if destroyed. Just because a mine goes off does not mean all of the little buggars are safe to walk on....

One issue is that artillery could take out a mine field or a B17 bombing run. The problem is a infantry unit carrying a vehicle :)
Post Reply

Return to “Battle Academy : Modders Corner ”