Player abilities
I’ve been working on the player ships’ abilities and got the tractor and repulsor beams working. The tractor beam acts like an (intentionally) clumsier version of the HL2 Gravity Gun and can hold an object at a set distance in front of the player, as seen with the asteroid in the gif. It works by constantly sending pairs of projectiles (the glowing green things, which hopefully I’ll have time to replace with something smoother looking) forwards; the left projectile moves whatever it hits to the right and towards to the player, while the right projectile moves whatever it hits to the left and towards the player. If they hit when they’ve only just been created, they push the object away instead so it stays at a safe distance. The repulsor beam works similarly, but always pushes away from the player.

I still haven’t done the cloaking device though, because I have yet to make enemies that would be affected by it. Enemies, levels, and UI are my next steps.
Tags: javascript, progress