Basicly, I have made a script that moves an AI unit (OFpilot1) to an Su-34 (OFplane1), mounts and takes off. The script then checks the to see if fuel is under 90% and if so, orders the unit to land at pita airstrip.
I have tried lots of things but the main error I am getting is on the lines of "type boolean, expected number, string, int... etc" but all my data types appear to be correct.
[color="Gray"]//ai unit moves to and gets in plane[/color]
OFpilot1 doMove position OFplane1;
OFpilot1 assignAsDriver OFplane1;
[OFpilot1] orderGetIn true;
_landed = false;
while{_landed == false}do
{
if(fuel OFpilot1 < 8)then
{
OFpilot1 landAt 2;
[color="gray"]//checks to see if unit has landed[/color]
_playerStatus = unitReady OFpilot1;
if(_playerStatus == true)then
{
[color="gray"]//exit loop[/color]
_landed = true;
}
}
}
note.
The first 3 lines of code work fine, the unit moves to the plane and takes off.
Thanks in advance.