Page MenuHomeFeedback Tracker

Broken/Unresponsive Direct AI Commanding
New, NormalPublic

Description

Scripted commanding easily leads to totally broken/unresponsive direct AI commanding. I assume this is a systematic problem with priorities (direct commanding > scripted commanding > FSM commanding; see wiki for setUnitPosWeak for example), and might even be the real reason for some other tickets (e.g. problems with high command, but I'm not sure about that...). Anyways, this bug is critical enough on its own.

tl;dr: Direct commanding should have the highest priority, alas it doesn't.

Details

Severity
Major
Resolution
Open
Reproducibility
Always
Operating System
Windows 7
Category
AI Control / Commanding
Steps To Reproduce

Two very simple cases are presented here, but I assume there are more. Both scenarios require the player to be the leader of a group of a bunch of more units. That's it.

Case 1: doStop and doFollow

  1. doStop all units by script.
  2. Try to make the follow you again (1-1 Return to formation). They wont.
  3. make all units doFollow player by script again. They will.

Clearly, direct commanding should take uttmost priority, or a script that doStops a unit of the player's group will be essentially deadlocked.

Case 2: setUnitPos

  1. setUnitPos your units to "DOWN".
  2. Try to make them go back to normal with direct commanding (7-9 Automatic stance). They will stay down and comfy. You can force them to "UP", but upon issueing 7-9 again, they're back to the scripted thing, which is wrong.
  3. Issue all units to setUnitPos "AUTO" by script. Notice how things are back to normal/responsive again.

7-9 is the direct commanding equivalent to setUnitPos "AUTO" (althought it comes with a "funny" description). It doesn't work any more with a script taking precedence, which is clearly wrong.

Additional Information

A simple setup as follows (and with a group and the player as leader) will do for a reproduction mission:

THE_GROUP = group player;
THE_LEADER = leader THE_GROUP;
THE_UNITS = units THE_GROUP;

DO_STOP = {
	{
		doStop _x;
	} forEach THE_UNITS;
};

DO_FOLLOW = {
	{
		_x doFollow THE_LEADER;
	} forEach THE_UNITS;
};

DO_DOWN = {
	{
		_x setUnitPos "DOWN";
	} forEach THE_UNITS;
};

DO_AUTO = {
	{
		_x setUnitPos "AUTO";
	} forEach THE_UNITS;
};

Event Timeline

ruebe created this task.Mar 26 2018, 1:08 AM