PDA

View Full Version : Two utterly unrelated questions...



dclare4
01-26-2006, 13:36
What exactly IS the ground scale for the battles? Like when it says throw javelins at range 45 what does 45 mean?

Next, one for Epistolary Richard probably... is it possible in a battle for victory to depend on the survival of one or two specific units AND their reaching a certain spot? Like for example if these units are racing for an Oasis in the middle of the desert and whoever gets there first ALIVE wins.

Hopefully it's possible (please, please, please, please)
Clare (Harlechman ZTW Team)

Epistolary Richard
01-27-2006, 18:33
For your first question, have a look over at Ludus Magna, those chaps are interested in equating RTW figures with real-life distances.

For the second one, is this for a historical battle? It certainly wouldn't be possible for anything else. I actually know remarkably little battle scripting (as opposed to campaign scripting) as to whether its possible. Hopefully someone else can lend their thoughts here.

dclare4
01-29-2006, 07:20
Yes it is, as a matter of fact. I looked at the battles file and there seem to be some instructions and options there. Being mainly a texturer I'm still trying to figure out how to even get into the battle editor or whatever but we're set to release our first 'alpha release' of our mod and to utilize the existing models I found a really interesting historic engagement - the thing is, victory is dependent upon a certain unit (representing the flag) reaching a certain location on the battlemap while running the gauntlet of enemy forces.

Just wondering if it's possible, anyone?

Thanks,
Clare (Harlechman ZTW Team)

Epistolary Richard
01-29-2006, 12:36
You get into the Battle editor by putting -enable_editor into your command line in your shortcut (same place as the -show_err). The Battle Editor then appears in the options menu. There should be documents on the .com website to help out if you don't already have them.

Your best resource for this is the Prologue campaign, in the first battle there are several points where you're required to move a unit from one point to another and then the next part of the script is triggered when they reach there. The battle scripting's all contained within the prologue campaign script. As far as I can tell the condition you'll want to use is I_UnitDistanceFromPosition. Make sure you have the docudemon (https://forums.totalwar.org/vb/showthread.php?t=54299) files that tell you what all the conditions etc. mean and their correct syntax.

My advice would be to use I_UnitDistanceFromPosition in a monitor_conditions (you have to anyway) and then when that occurs use the unit_set_morale command for all the enemy units to rout them, which will fulfil the rout all units victory condition.


As I say, I've never done any battle scripting but the tools (monitors, iifs, etc.) are used in the same way even though the commands and set-up are different so have a look at the Intermediate Scripting guide for a conceptual understanding, though remember it's campaign scripting not battle scripting. And then replay the Prologue and go through the campaign script to understand how the code impacts the game. In all our stuff we pretty much have to do look at what CA did to understand how it works.

dclare4
01-31-2006, 05:40
Thanks very much Epistolary Richard. I spent the weekend just looking at the prologue battle but now I think I'll be able to tinker with it thanks to your short and sweet tutorial here. If it routs all enemy units will the game end immediately though? (guess I'll have to test it out).

Thanks very much,
Harlechman (Clare)

Epistolary Richard
01-31-2006, 09:49
Destroy and/or rout all enemy units is a pretty standard victory condition, I think it can be set in the battle editor. Have a look in the descr_battle files within the historical battle folders and you see the victory conditions there.

Let me know how you get on and give us a shout if you have any problems.

dclare4
01-31-2006, 11:42
I think there's a workaround - Lets say there are two armies, your player army and an allied army like the prologue's Captain Decius. You only have like two weak cavalry units and Decius has some badly shaken infantry but the barbarians have a truckload of baddies. If the 'barbarian' army kills all of captain Decius then he is triggered to automatically rout (ie. leave the field in 'victory') and if you survive till then, then you win the game.

Sounds possible, I hope it IS.

Thanks very much,
Clare (Harlechman)