@Armored_Blob It looks like @Simonrazer beat you to it:
About your code, though, I’ll go through as quick as I can:
Force Is Not the Same as Impulse
Force is a, well, force applied to an object that will result in the object increasing in speed in the direction that the force is pushing. Gravity is an example of a force applied to an object, it will make the object go faster and faster down towards the earth. A force applied in Armory will do the same thing.
An impulse on the other hand is the result of a force applied for a period of time, even if that time is extremely small. A baseball bat hitting a baseball is an example of an impulse. The baseball bat applies an impulse to the baseball. Unlike a force, an impulse won’t make the ball go faster and faster. It will accelerate the ball to a certain speed in an instant and then stop. Like a player jump.
Getting the Local Direction
The way that you are thinking of getting the direction of the impulse is not correct, though the code you wrote to achieve what you were thinking seems to be well formed.
So force ( and impulse ) is a vector. Vectors are a value made up of a direction and a magnitude that can be represented in 3D space with three scalar ( or 1 dimensional ) values ( And we use Vec4’s to represent 3 dimensional values in Armory. See comment. )
In this particular instance, you want to apply a force with specific magnitude that represents how hard you want to push the object. For this instance lets just say that the magnitude is 5. Then you want to apply this force in the direction that the object is looking.
object.transform.world.look() gives you a vector with a magnitude of 1 and a direction in the object’s look direction. This is nearly what we want, all we have to do is get the magnitude right. We do this by multiplying the vector by our desired magnitude, 5.
var magnitude = 5;
var impulse = object.transform.world.look().mult(magnitude);
var rb:RigidBody = object.getTrait(RigidBody);
Hope that helps!