For a current weapon I am trying to make it so when you fire you stop moving in the X and Y axis but you are still able to fall at the same speed.
I have tried:
function WeaponImage::onFire(%this,%obj,%slot)
{
%playervelocity = %obj.getvelocity()
%pvX = (getWord(%playervelocity, 0)) * 0.5;
%pvY = (getWord(%playervelocity, 1)) * 0.5;
%pvZ = getword(%playervelocity, 2);
%obj.setvelocity() = (%pvx @ " " @ %pvy @ " " @ %pvz);
}
But obviously I am doing something wrong as I keep getting syntax errors.
Does anyone know what I am doing wrong?