Bump, why isn't this working?
function firePaveStrike(%client, %obj, %target)
{
%pos = vectorAdd(%obj.gettransform(), "0 0 -3");
%bomb = new WheeledVehicle()
{
datablock = CrateVehicle;
initialposition = %pos;
client = %client;
};
missioncleanup.add(%bomb);
}
It used to be this and this one worked fine:
function firePavesrike(%client, %obj, %target)
{
%pos = vectorAdd(%obj.gettransform(), "0 0 -3");
%bomb = new projectile()
{
datablock = Airstrikeprojectile;
initialposition = %pos;
initialvelocity = VectorScale(VectorNormalize(vectorsub(VectorAdd(%target, getRandom(2,-2) SPC getRandom(2,-2) SPC getRandom(2,-1)), %pos)), 40);
client = %client;
};
missioncleanup.add(%bomb);
}
It isn't spawning the crate.