Posted: Sun May 06, 2018 8:56 pm Post subject:
Campaign AI triggers
Subject description: rrRRAGHAGAHGHGHrghghgg
how do we make ai triggers work in campaign? they apparently dont work like they do in skirmish and the AI refuses to register AITriggers. does anyone have the solution to this? QUICK_EDIT
lets see. [AITriggerTypesEnable] shows them all to be enabled.
[Basic]->IgnoreGlobalAITriggers=no is set to this by default
i see that the campaign maps have premade triggers with actions 3 (production begins), 13 (Autocreate Begins), and 74 (AI triggers begin) set with a 10 second elapsed time event..
if i were to put the team and aitrigger below into a skirmish map with "Available in Skirmish" checked it would be firing automatically. i cant seem to get it working.
- Set Basic -> IgnoreGlobalAITriggers=no.
- Enable production actions 3 and 74 for the needed House. 13 and 30 also if you fancy (not actually needed).
- Provide AI with buildings and credits needed to produce teams
- Uncheck Available in skirmish for local map AITriggers (shouldn't matter even if checked). Define in AITriggerTypesEnable as yes.
- Make enemy action 38 so as to produce attack teams. Base defense teams would be produced even without this. QUICK_EDIT
all of that was good advice, especially E1's mention of trigger action 38, 3, and 74 (skirmish maps are more automatic)
im just going to bump this thread instead of making a new one because this is relevant info; but now ive got another problem.
sometimes, the AI will stop mid script and die, which is a pretty normal thing to happen after extended gameplay, but since i find it annoying
ive been trying to find a solution. i thought that an infrequently repeating trigger with a set of actions that recruit each of the teamtypes units
and send them to generically attack would solve the problem of guys falling asleep at whatever failed script action, but whatever i try, i get
an internal error on trigger fire. these controls are utterly archaic at times, even for me. i hope someone has a solution.
both use the same taskforce: the ai creates the team in the top picture via the AI trigger which works fine, and the
trigger ( which has the same house as the teams ) is supposed to periodically recruit units and send them straight at the enemy but causes IE.
There's no reason your weights should be that high? All the weights of all triggers are held in one total block, and you'll note most ai.ini triggers are weighted around 100, making yours massively over-represented. If you have a dozen scripts firing off with such weirghts, none of the others will get to fire, while yours may fire too often, especially where more than 1 team is allowed. _________________ http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai QUICK_EDIT
Crash happens only when something is wrong or left out. Give the first teamtype its missing veteran level and house. The Recruiter and AutoCreate is not needed in both teamtypes. Priority and AreTeamMembersRecruitable are correct, so it doesn't seem to be a recruitment problem if both have the same house, test only the repeat trigger independently. AITrigger Multi-Side 0 means it is available to be created by any side which is unnecessary, you should keep it to the side for which the units are available.
You could share the relevant text info from the map - taskforce, script, teamtype, AITrigger and map action, event, trigger and tag. Or share the map itself. Sometimes images don't give the complete picture. QUICK_EDIT
All global AITriggerTypes are enabled by default, whether they're defined in [AITriggerTypesEnable] or not. The only use that section has is for disabling individual AITriggerTypes. IIRC it works the same for local AITriggers. Of course, there's no harm in defining them as enabled, it's just redundant. _________________
yup. filling in the missing entries prevented IE, the teams get recruited periodically as planned, though tend to act
stupid and occasionally get stuck anyways. at least it doesnt halt the AI anymore, as im using MAX=1 for most teams.
also i know about trigger weighting, but its a singleplayer map with only a dozen AI triggers. works as i intended it to.
EDIT: now, how to script aircraft to use via AI triggers? _________________ visit my moddb profile for .shp downloads and stuff QUICK_EDIT
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum