Jump to content
Sign in to follow this  
leob

ArmA3 Task system and module

Recommended Posts

Hello, I'm using the TaskModule and some scripting commands for creating task in my misson.

Here my issues:

1. What is the correct variable/name for a task?

When you use the task module to create a task you can give it a name and a taskID.

When you create a simpleTask then, the "createSimpleTask" command asks for a parent task.

Problem is: The "name" you defined in the module is the name of the actual module, not the task.

The taskID seems to be something different from an actual task variable that you get when you use the createTask command.

When I converted an actual task variable (the task itself) to a String, the outut is a combination of the taskID and the task description or something.

So how do I get the task as a variable when using the TaskModule?

2. The TaskDestinationModule also won't work

I have a TaskModule with destiantion set to module position. The TaskDestinationModule is synced to it and is set to module position.

-> Problem: The task destination in the game actually is at the TaskModule position and not at the TaskDestinationModule position.

Any solutions to this?

Leo

Share this post


Link to post
Share on other sites

I use these two BIS_fnc to get tasks done, and makes it easy to work with as well:

BIS_fnc_setTask (return value is the task ID)

and

BIS_fnc_taskSetState (uses a task ID to set that task's state)

examples:

_task = ["HVT", WEST, ["Capture the CSAT Officer", "Capture HVT", _marker], (getPos _unit), "CREATED", 5, true, true] call BIS_fnc_setTask;

while {true} do {

	if (!alive _unit) exitWith {[_task, "Failed", true] call BIS_fnc_taskSetState;};

	if (triggerActivated capPoint) exitWith {[_task, "Succeeded", true] call BIS_fnc_taskSetState;};

	sleep 3;

};

Edited by JShock

Share this post


Link to post
Share on other sites

Guess I will go with those functions then. Thx

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×