Skirmish Battles with Random Enemy
Moderators: Slitherine Core, BA Moderators
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
I ran a few tests with
1 KT 170 Panther 140 Wespe 100 team 0 510 pt allowed 200
3 KT 3 panther 3 wespe team 1 allowed 600
First run, team 0 picked a wespe, team 2 3 panthers and 1 wespe. After that it seemed to mix it up with an occasional KT.
Too bad the limit is 7 teams. I think we have to go with the team 1 example. Unless we don't use the points system.
1 KT 170 Panther 140 Wespe 100 team 0 510 pt allowed 200
3 KT 3 panther 3 wespe team 1 allowed 600
First run, team 0 picked a wespe, team 2 3 panthers and 1 wespe. After that it seemed to mix it up with an occasional KT.
Too bad the limit is 7 teams. I think we have to go with the team 1 example. Unless we don't use the points system.
You can call me junk - and type that with one hand.
Actually, you have 8 teams .... 0 - 7 inclusive.
If you want to add a small random deploy, I wrote a simple script for Panzer Attack (normandy2) below. The team functions are in the functions.bsf ...
It's self explanitory... it randomly selects an AI team from 0-5 and randomly moves them from 0-10 tiles, with a 100% to do it.
The comment in the code explains the parameters ... create a normandy2.bsf and paste the code in.
You can mess around a bit. I tried it a few times, adds a bit of uncertainty.
If you're curoius about other variants let me know, I can post them.
If you want to add a small random deploy, I wrote a simple script for Panzer Attack (normandy2) below. The team functions are in the functions.bsf ...
It's self explanitory... it randomly selects an AI team from 0-5 and randomly moves them from 0-10 tiles, with a 100% to do it.
The comment in the code explains the parameters ... create a normandy2.bsf and paste the code in.
You can mess around a bit. I tried it a few times, adds a bit of uncertainty.
If you're curoius about other variants let me know, I can post them.
Code: Select all
include "functions.bsf"
FUNCTION StartTurn(side)
{
int r ;
int t ;
if( GetTurn() == -1 )
{
r = Rand(0,10) ;
t = Rand(0,5) ;
// TeamReposition(side, team, radius, chance)
TeamReposition(1, t, r, 100) ;
}
}
Last edited by Merr on Mon Nov 22, 2010 1:42 am, edited 1 time in total.
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
nope ... it doesn't care about the teams deployment status ... the code simply moves them if it meets the conditions in the TeamReposition code.junk2drive wrote:I assume I need to set deploy in the editor?
It's simple ... drop the code in a normandy2.bsf and play... yeah, plug and play.
Actually, I wish the PLUGIN's acted like that, you know, a few buttons to activate/deactivate variants when you start the scenario, to add some flavor.
EDIT ... As you know, there isn't a BSF for the Panzer Attack skirmish ... so the above code is all you need in the new normandy2.bsf, simple few lines.
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
Ok maybe tomorrow. I burned out today trying to get the VP tool to work for defend flags.
BTW I found that deployment is limited to the LOS area. I had a battle where I had to change some numbers to get a LOS spot off the middle of my map. Somewhere in some file you can set a LOS area big enough to give the player some room to deploy.
BTW I found that deployment is limited to the LOS area. I had a battle where I had to change some numbers to get a LOS spot off the middle of my map. Somewhere in some file you can set a LOS area big enough to give the player some room to deploy.
You can call me junk - and type that with one hand.
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
Here it is, you change the last set of numbers to the x,y numbers on the map.
//include "Functions.BSF"
// This function is called at the start of every turn (both player and enemy turns).
// You would tend to use this for events that happen at the start of a turn
FUNCTION StartTurn(side)
{
// GetTurn() returns the current turn number,
// -1 is a special "turn" that is called in the beginning when the scenario is loaded.
if (GetTurn() == -1 )
{
// Setup VPs
PreBattleSetup() ;
}
else
{
// Check if any victory conditions are met
VictoryConditions() ;
}
SetBriefingScreen("munda3_map", "Anim3", "IDS_M3_INTRO");
if (GetTurn() == -1 )
{
// Setup VPs, damaged tiled, ...
PreBattleSetup() ;
SkipFirstPlayerTurn() ;
}
else
{
if(side == 0)
{
// Check if any victory conditions are met
VictoryConditions() ;
}
}
if(side == 0)
{
// intro message
if(GetTurn() == 0)
{
ClearAreaLOS(50, 50, 16, 16, 0) ;
ShowBriefing() ;
}
}
}
You can call me junk - and type that with one hand.
-
- Sergeant - 7.5 cm FK 16 nA
- Posts: 246
- Joined: Mon Mar 08, 2010 1:50 am
- Location: devon u.k.
- Contact:
the replayability value of the game would be sooo much more if you could select your own forces (or majority of) and map in multiplayer!! this was suggested months ago (and dismissed!) but at least the review(s ) i've read have marked B.A. down on this very point.. pPLEEEEEZZZE consider it, junk old chap, and i typed your name (and the rest of this!) with one finger!
ps when o when is blitz france out!! ?

-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
Here is a one scen campaign with random Germans and you get US with deploy.
I made the map from a Slith map with the Y key (after removing all the units first), removed the hedgerows, set the flags, AI teams, points, aggression and Random, all with the tools.
The Germans have a choice of StuGs, Panthers, PZIVs, and 251/2s.
Enjoy, I didn't test it all the way through.
http://dl.dropbox.com/u/6754176/Random_Deploy.zip
I made the map from a Slith map with the Y key (after removing all the units first), removed the hedgerows, set the flags, AI teams, points, aggression and Random, all with the tools.
The Germans have a choice of StuGs, Panthers, PZIVs, and 251/2s.
Enjoy, I didn't test it all the way through.
http://dl.dropbox.com/u/6754176/Random_Deploy.zip
You can call me junk - and type that with one hand.
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
Good!junk2drive wrote: I didn't try Merr's random enemy deploy yet.

BTW ... I had a look at the code for the random enemy generation. Works something like this ..
1. It selects the available units on the team piecemeal as long as there are points available.
2. If it selects a unit that costs too much then it will search again to fill in the last remaining points.
Now, what this means is that you may end up with almost the same force everytime IF you don't have a large variance in price cost.
Also, the quantity comparision between the forces selected make a huge difference.
For example ; This is the contents of team 1 ....
5 Panthers ... total cost 695
5 PzIVg ... total cost 540
Total sum .... 1235
Buy points set to 695 ... I chose this because this guarentee's me 5 tanks on team 1 no matter what the mix.
Ok, lets work out the odds as we go ... As you can see, there is a 50-50 chance it will select a Panther or a PzIVg as the first unit.
Lets say it chose a Panther ... Now the odds are in favor of a PzIVg being selected ... 5 vs 4.
For discussion sake, the second unit it chose was another Panther ... odds greatly lean to a PziVg again for the third ... 5 vs 3.
Lets stop here and tally the points remaining ...
2 x Panther = 278 .... 695-278=417 ... It can still buy another Panther but again, odds favor PzIVg.
I'll end the example here because you get the picture.
I figured if you are eventually going to write a tut I thought that I would make it clear how it's generating the forces.
Merr
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
-
- Site Admin
- Posts: 9876
- Joined: Wed Mar 23, 2005 10:35 pm
-
- BA Moderator
- Posts: 1478
- Joined: Sun May 23, 2010 4:47 pm
- Location: Arizona USA -7GMT
-
- Sergeant - 7.5 cm FK 16 nA
- Posts: 246
- Joined: Mon Mar 08, 2010 1:50 am
- Location: devon u.k.
- Contact:
just play tested your random skirmish junk.. brilliant.. but the forces were not varied enough.. needs to be a selective choice rather than a .. wildcat or 76 ? although i do understand that u r just trying to inspire others to do this 'kind of thing'
.. i ended up with a handful of units inc 2 tanks, but that's cos i made an all out effort for the panther in the beginning, and infantry assaulted it
.. this type of 'force buying at the start is where the game is heading i think , and it's great that ones like you are leading by example... p.s. don't worry about you tube users who say they wouldn't buy this game because of the graphics, i think the graphics make this game , and give it a unique 'charm'. people who worry about graphics, just move on after 5 mins when a newer more 'realistic graphic' comes out regardless of whether the game is any good or not!
cant wait for panzer corps now lol!! .. wont stop me playing this though! 




-
- Staff Sergeant - Kavallerie
- Posts: 300
- Joined: Sat Nov 14, 2009 1:08 pm
Re: Skirmish Battles with Random Enemy
YES DAMN STRAIGHT IT IS. I need more random MAPS or rather more MAPS with the capability of making more random battles from those maps. So get to drawing and editing. Want desert, trees, hills, villiages, towns, cities, outposts, river crossings, fjords all the good stuff from Combat Mission or Steel Panthers or Panzer Command will do.junk2drive wrote:I spent the evening playing the Normandy Skirmish D-Day battle. 1 turn short of taking enough flags to win, grrrr.
I found it to be entertaining and look forward to trying again, knowing that the enemy will have a different makeup next time.
Has anyone else tried these random battles?
Is it worth my time to put together more of these for you to play?

Re: Skirmish Battles with Random Enemy
I'm working on a random scenario as I type .... You like Airborne Drop missions ?Igorputski wrote:YES DAMN STRAIGHT IT IS. I need more random MAPS or rather more MAPS with the capability of making more random battles from those maps. So get to drawing and editing. Want desert, trees, hills, villiages, towns, cities, outposts, river crossings, fjords all the good stuff from Combat Mission or Steel Panthers or Panzer Command will do.
If not ... oh well
