Without any variations in terrain (ex: your melee front line is at your castle wall, terrain is the same for all front line units) this might be the perfect unit formation:
Each bullet is another layer of the formation.
Lay traps (copyright ACME Dungeon Master supplies) so any enemies that attack your units trigger the traps, for both your outermost melee line and your final protective line
- moat (hard for sappers to remove) and any traps that work in a moat (since they are hard to see underwater
- any traps your own units won't set off (if moat extends into part of this hex the terrain type becomes ground with moat(fortification)), and a melee formation 2 hexes deep consisting of the front hexes being a Phalanx (formation of spearmen with spears so large that multiple Greek soldiers held one spear, and the front guy had a masive shield in front, the guys behind held their shields upwards if arrows came) of spearmen (have firststrike (hit enemy first) in Phalanx formation (spearment get both pushback (spear so huge it can push stack-limit-bonus worth of enemy back to adjacent hex per counterstrike) and shields help protect from attacks not just in front but also from above), and a final protective line of extremely high defense/armor units in the line of hexes behind. Couterstrike ability is essential for all units (be able to hurt attacking melee enemy) ... hey some weird elementals may have no melee attack ... like air elementals ... don't use them here. Both lines of units should have as many defenses against area-effect weapons as possible.
If you want to get fancy, you could add a Bunker (Dungeon Upgrade?) to the ground of the hex adjacent to the castle wall, with an acidic moat in front and poisonous smoke wafting from fire pits somewhere safe inside the castle through pipes and out holes ON TOP of the Bunker! (with geothermal heating using clay pipes (or whatever pipes dirtamancers can produce) ... to move heat from your magma lake to the acidic moat and adding heat damage to the acidic damage (and Parson could break Erfworld physics by shouting "more heat means higher molecule velocity ... higher molecule velcocity means molecules bump into each other more ... molecules bump into each other more equals means the acid moat particles get more attacks this turn ... which means more damage! well not break Erfworld physics but this is something most Erfworlders are probably not aware of) since Gobwin Knob is near lots of magma you know. In that case you have to change your formation a bit:
Note: I am assuming that the stack limit applies like this ... 1 hex has units inside of the hex, units below the hex, units above the hex, and units on all 6 sides. Each of those groups has the stack limit applied to them
Let's talk about how many faces there are above and below the hex.
The problem is there is no such thing as a 3D object with all identical faces, where each face has 6 sides or more. If such a shape existed distances in Erfworld would be the same in all directions (if a unit standed at the center of a hex it would be an equal distance to go any direction at any angle to get to the edge of the hex. The dodecahedron gets it up to 5 but that isn't far enough. Yes I know dodecahedrons (as well as impossible "hexahedrons" since the more perfectly symmetrical faces you get the closer you get to a sphere so obviously the 3D stacking gaps would still hypothetically be there) won't stack in 3D without gaps, but if the dodecahedrons (or impossible "hexahedrons") were stacked as if they were cubes and the empty spaces ignored, and units in Erfworld "teleported" between the gaps to the next hex ... the space the Erfworld units could occupy would still have the same distance traveled (for all practical purposes) going in any direction.
To make 3d hexes in Erfworld the simplest way you could just do what you do when you turn a circle into a cylinder, just add height to the 2d shape. [ The best I can do is say that the hexes turned 3D must either be those cylinder-types with only one face top and bottom OR be hexagonal dipyramids (but that would make hexes above and below each other be 1/2 shifted horizontally from each other, if you drew a vertical line through the middle of the ground hex it would intersect with the boundary of the hex above it then intersect with the middle of the hex above that. The benefit, though, is that hexagonal dipyramids DO stack perfectly in 3D with no gaps.
Ok let's try this again:
[list][*]As many hexes as you want with Vietcong-style revetments (protect against ranged fire even if the enemy somehow sees you) concealed in the waist-high grass (or whatever concealing vegetation that doesn't give too much defense bonus), small ponds with underwater entrances, etc. where every turn a stack-limit number of stealthy skirmisher units can hide behind when ranged fire comes, and when melee units come the skirmishers attack and (since skirmish gives them the ability to attack any units in a stack, not just the stack-limit number that was chosen to defend the stack by being "in front" or whatever) choose whatever's the juiciest target to attack. Then run away, using (if possible) stealth to hide and use any of the hidden entrances to the Bunker/dungeon. There are only a stack-limit number of hidden entrances because they are weak points in the defeneses. If you want to get really fancy these could be units could also have the special ability burrow and they dig into the ground to escape ... and yeah the enemy could do this but they wouldn't know where to dig because the dungeon tunnels are only near the surface in certain areas ... all of your vietcong-style units could also be fliers (especially Ghosts since they have Stealth at least at night so they would strike fear into the enemy).
Please note: This dungeon is NOT connected to your castle's dungeon in any way. And if you want to get really fancy don't let any of these outer defense units into your castle dungeons or even into other areas of your outer defenses so even if the enemy captures them they won't find out much.
[*]Moat with traps (especially bungie sticks, that was done in real life) again (you know ... Stanley thinks that his Lava will protect him from ground units from those directions ... apparently Siege Towers whose upper section falls forward to reach the enemy castle wall don't exist in this game or the Lava is just too wide ...). If you want to get fancy you could have a hot acidic (throw steaming piles of acidic battlecrap into the moat, moat heats up from decomposition of ... that ... and diratamancy helps amplify this decomposition process in ... unspeakable ways whenever the enemy approaches so the moat does get unnaturally hot) moat in front for defensive bonus (so dropping boiling water (boiling pitch is too expensive except maybe for the final protective line for your keep or something ... boiling water is just fine and like free) on them is unnecessary), and crushed glass (made by melting some sand in your magma furnace or magically) glued (or mixed with the semi-solid cooling stone, if you melted the stone in some sort of magma furnace or magic) to the outermost stones so that if the infantry tries to climb the braie from the moat to the castle wall they get damage. If you want to get really fancy you could a corridor of rooms in the Dungeon that are as airtight as possible, with pipes all of the way to glass-covered stones (protect them from the acid) rising from the ground below the moat to the hex the ground troops occupy when they cross the moat (even if they water-walk it or some such special spell was applied) ... so there are these strange bowl-things that appear suspended in the moat when they're really the top of these glass-covered stones. Wanda releases Trioxin into each of the chambers in the dungeon, displacing Trioxin by one hex-volume's worth all along the pipes and it comes out from these stone pillars and trioxins the enemy after they get bogged down in the moat, uncroaking them (Wanda still can't Decrypt unless she's in the same hex as the unit ... anything else would just be unfair). It's still a one-hex spell, it's just been "teleported" for free without any Erfworld rules broken. Ditto for the ground next to the castle wall, but perhaps better hidden in the no-defensive-bonus concealing vegitation (this is How Not to Be Seen).
[*]The melee formation is now 1 hex deep (still behind the moat), consisting of:
At ground level: the same waist-high grass (or whatever concealing vegetation doesn't give ANY defense bonuses even if that's just leaves or moss or gravel) where the flying melee or ranged (you pick, ranged flying might get lucky and attack enemies that can't fight back because have only melee no ranged training at all) skirmish are hidden in concealed revetments (these revetments are open from behind so the flying units can get out and archers from the castle wall can still snipe any enemies that get in them) in a final protective line against enemies trying to scale the castle wall. To protect the Dungeon those melee units have no escape route. Their sole purpose is to surpirse attack ladders or other siege devices, skirmish to do so of course (note: flying units automatically get skirmish against ground units for obvious reasons), and when things get too dangerous they retreat over the castle wall. Try to predict how long your revetments will stay concealed and take that into account for how many you are going to build. Each revetment should only hold one of your units so if it is discovered only one of your units die. Obviously have a mix of high-level and low-level units here. The high-level units come out of their revetments on the first turn the enemy enters the hex, the low-level units come out in the later turns since they are disposable (if the enemy finds them during their turn the enemy might be able to trap them on the ground ... unless they are Ghosts and can just pass through physical objects ... unless some Clerics or somebody prevent them from doing that ... you get the idea.
Below ground level: Ranged units firing through concealed slits which are very long and thin so that multiple archers can shoot through them and have a wider arc through which they can see targets. Each slit has a stack-limit-number of archers manning it and there are slits which extend deeper and deeper underground, which allows the defenders to not only range-attack the enemy from the sky and the city, but also up from below.
Note: if an enemy has some warlord, hero, or other buff in a certain front-line hex, strengthen the units adjacent to that hex as appropriate.
Note: I'm going to discuss how many times a unit can attack and defend in a turn. It would be mean if a unit couldn't defend itself after being attacked too much (and this doesn't happen in real life anyway even if you run out of ammo you can still melee), so I assume here that defenders have unlimited counterstrike and counterbattery moves if the attacked units have those abilities and the ammo to do so. However, a unit can only have so many attack moves. Now if you had a Phalanx (giant ... note spears obviously get firststrike (be the first to melee an enemy since their spear is so long)) which had a "push-back" ability where their spear skewers the enemy and is long enough to push them back to an adjacent hex, that doesn't help at all except in minor skirmishes because the enemy could just rush fresh melee units (with spare move) from behind front lines to battle endlessly and actually this push-back would let MORE enemies attack your front line this way. This would be bad since it would let the enemy kill your spearmen by attrition instead of letting them hold the line until the end of the turn and they could be healed. Unless you had magical traps that never wore out and triggered every time an enemy entered your hex so the enemy force would attack your spearmen more but also get hit by a lot more traps, and the enemy didn't have any sappers that could disable your traps that turn.
So a Phalanx (with firststrike and pushback abilities) and traps that go off when the enemy enters the Phalanx's hex would be the best formation if this wasn't your final protective line (ex: your castle wall is the final protective line, the Phalanx is outside keeping back the Ladder carriers that would storm the castle wall away). If it was your final protective line you should focus on the highest-defense units to hold the enemy off for as long as possible, not using the pushback ability. This juuust might work with poles of magically resized ridiculous longness poked out of the Castle wall. Pushing back enemy units (and ladders) from the relative safety of the castle wall and back a hex is actually a good feature.
[*]Castle Wall Ground level and above attack positions: Spears of magical longness to push back enemies (metal spears would be good as they are fireproof and can be welded back together unlike wood which permanently splinters. Above them are ranged units standing at crenels shotting out of arrow slits, and machicolations from which stones and boiling water or urine can be dropped (boiling fat is too expensive to drop on your enemy). Please note that very tall arrow slits allow multiple archers manning that arrow slit to have overlapping fields of fire, creating a machine-gun like effect if they all target the same area. I wonder if Erfworld reduces Archers' accuracy if they don't direct-fire their weapons and instead do it mortar-style up and over, especially at units they can't see. I say accuracy because critical hits do appear to exist in Erfworld (1 arrow in uncroaked warloard's forhead = 1-hit-kill ... that wouldn't have happened if hit hit an arm, or a leg, or probably even the torso).
[*]Inside of Castle Wall (cannot be attacked by enemies unless they breach the wall: reserves of healers and zillions of melee unit reserves which can reinforce the outermost melee line whenever the units in any of its hexes get low. If the Front line advances this is where the advancing forces comes form, so the damaged front line melee units can take a breather and be healed. When the front line stops advancing the rest of the reserves move up to the hexes right behind the front line. If you aren't rushed for time, let the slowpoke Tanks and Defenders get to the end-of-turn front line and don't try to rush ahead with Calvary. Rinse, repeat.
[*]Parapet of Castle Wall and above: ranged units (counterbattery ability would be awesome for them, some high-level Elvish Archers can probably do it) are behind the healing and melee reserve line, split into groups of 6 so that every archer "counts" and gets counted in the stacks' bonuses. So as the front line advances, the melee reserves that weren't being moved to the front lines could police the enemy dead. Healers, and above that fliers (stacked vertically ... a lot of fliers stacked vertically that way easy to range-attack the enemy without having to worry about friendly fire)
[*]flying units also spread out to occupy the ranged unit areas, since ranged units don't melee well so if any melee flier comes in (ex: Gwiffons) the other fliers can break up their attack runs then quickly land again so the ranged units can take pot-shots if friendly fire is that much of an issue
[*]ranged casters occupy the tower in the center of the city (towers give caster bonus), or the Stonehenge/magical ruin (caster bonus) if it's out in the wilderness[/list]
Assuming the healers can heal units in adjacent hexes (even if they have to move to do it), the healers are close to everybody so they can heal everybody .
Instead of the obvious straight line sometimes this has to be a zig-zag. In that case have high-level high-defense units (and them having poison, area-effect attacks as well as most of the traps given to them - not the trough units - would be great as the tip units fight by attrition in that position) at the tips (adjacent to 3 enemy hexes) and lower-level units (that finish off the enemies next to them that the higher-level nearby units almost killed, so the lower-level troops can gain levels without being too exposed) or otherwise vulnerable units (ex: very low armor melee units) in the troughs (adjacent to only 1 enemy hex). Yes I know the enemy could stuff more than the stack limit of troops in one hex and send that mass to attack, but please note that for the stack bonus limit to mean anything the attacker couldn't just take the extra move of all of the troops in that hex and apply it as attack moves, because then the stack bonus is meaningless because each trooper in that mass gets the stack bonus and gets to attack as well, which is always better than a strike force of 6 units that get the stack bonus, get to attack, but don't have the protection of if lots of them die they will still have the stack bonus. Obviously armies in Erfworld don't try to mass into one stack so it appears that each hex gets only one attack, multiplied by the stack bonus, multiplied by the number of attacks and strength of attacks of the stack-limit-number of troops you choose to attack with from that hex. If Parson picked up a bow and attempted to be the Stack-limit-plus-one bowman ... the arrow he shoots might hit the Hex barrier.
With pockets of high-defense terrain areas
Copy Salvation War: Chapter 9 and set up hedgehogs (with revetment defenses if you can), basically mini-versions of the formation above in the defensible areas. Lay traps (copyright ACME Dungeon Master supplies) everywhere else. For advancing your troops take over enemy revetments as best you can and "island hop" to victory (though that's only if you can overcome the enemy's traps ... if you can't they I hope you can sit back and let the enemy attack you instead ...).
STRIKE FORCES, basically if your units have to be extremely mobile and you don't have time to set up the formations above
Have high-move units. If you are lucky enough to have Monglin Cow-riders (I love Mongolian Beef) that can fire bows while riding, then use your ranged units to pincushion the enemy while staying out of range of their melee units. Unless they have lots of ranged units, then rush them with lancers. And flying units of course.
Applies to all of the formations above:
Interestingly flying units might help you get around the 8-unit stack limit, so 8 ground melee units and 8 flying units and hey 8 ranged units if they all attack in the same hex they should all get stack bonuses because they can all attack the enemy different ways! But then the question what about splitting flying into flying melee and flying ranged and then of course pop up from the ground melee (ex: roots) and ground ranged (ex: thorns shooting from roots). I'm not entirely sure about this. But something has to happen because I'm pretty sure at the very least 8 ground melee 8 ranged aboveground and 8 belowground/trap/whatever should count since they attack from different directions (sides, top, and bottom).