I am trying to get my stationary monster to shoot at my moving player. Both the player position and the monster position are obtaining the right values and this code is written in a function that is called every second. Right now the projectile shows up but doesn't move away from the monster. Is there something else I should be using besides .applyAngularImpulse?
let deltaX = player.position.x - monster.position.x
let deltaY = player.position.y - monster.position.y
let angle = atan2(deltaY, deltaX)
monProjectile.physicsBody?.applyAngularImpulse(angle)