summaryrefslogtreecommitdiffhomepage
path: root/app/factories/ships/osprey.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/factories/ships/osprey.rb')
-rw-r--r--app/factories/ships/osprey.rb22
1 files changed, 22 insertions, 0 deletions
diff --git a/app/factories/ships/osprey.rb b/app/factories/ships/osprey.rb
new file mode 100644
index 0000000..1f57cb1
--- /dev/null
+++ b/app/factories/ships/osprey.rb
@@ -0,0 +1,22 @@
+class Factory
+ class Osprey
+ def self.new(x: x, y: y)
+ sprite = FF::Cmp::Sprite.new
+ sprite.props[:path] = 'sprites/kenny/Ships/Osprey.png'
+ FF::Ent.new(
+ FF::Cmp::Boid.new(x: x, y: y, vx: 25, vy: 25, w: 32, h: 32),
+ sprite,
+ FF::Cmp::BoidBounds.new(strength: 0.6),
+ FF::Cmp::BoidsAlignment.new(strength: 1),
+ FF::Cmp::BoidsSeparation.new(distance: 150, strength: 0.001),
+ FF::Cmp::BoidsCohesion.new(strength: 10000),
+ FF::Cmp::Hp.new(health: 100),
+ FF::Cmp::CollisionDamage.new(damage: 100),
+ FF::Cmp::Hitcircle.new(r: 12),
+ FF::Cmp::DebugVectorArrow[0],
+ FF::Cmp::SingletonCamera[0],
+ )
+ end
+ end
+end
+