Sry, dass ichs vergessen habe =(
Code:
WaitUntil
{
_Unit SetVelocity (Velocity _Vehicle);
_Unit SetPos (_Vehicle ModelToWorld [0,-3,-0.5]);
_VUp=VectorUp _Vehicle;
_VDir=VectorDir _Vehicle;
_Unit SetvectorUp _VUp;
if (DegHead > _CurrentDeg) then {_CurrentDeg = _CurrentDeg + 1};
if (DegHead < _CurrentDeg) then {_CurrentDeg = _CurrentDeg - 1};
_Unit SetvectorDir [Sin _CurrentDeg,Cos _CurrentDeg,0];
not alive _Unit || raus == 1;
};
Das hab ich drinnen und das funzt net.
Hab nen Funkauslöser Alpha erstellt, der bei Aktivierung raus auf 1 setzt (raus=1), aber das geht nicht =o
Ganzes Skript schaut atm so aus:
Code:
_Unit=_This Select 0;
_Vehicle=_This Select 1;
_Unit SetPos (_Vehicle ModelToWorld [0,-3,-0.5]);
DegHead = 0;
_CurrentDeg = 0;
publicVariable "DegHead";
WaitUntil
{
_Unit SetVelocity (Velocity _Vehicle);
_Unit SetPos (_Vehicle ModelToWorld [0,-3,-0.5]);
_VUp=VectorUp _Vehicle;
_VDir=VectorDir _Vehicle;
_Unit SetvectorUp _VUp;
if (DegHead > _CurrentDeg) then {_CurrentDeg = _CurrentDeg + 1};
if (DegHead < _CurrentDeg) then {_CurrentDeg = _CurrentDeg - 1};
_Unit SetvectorDir [Sin _CurrentDeg,Cos _CurrentDeg,0];
not alive _Unit || raus==1;
};
MG1 setpos (position h);