summaryrefslogtreecommitdiff
path: root/src/Main.php
diff options
context:
space:
mode:
authorFBeans <phil@pgburton.com>2022-05-21 19:07:32 +0100
committerFBeans <phil@pgburton.com>2022-05-21 19:07:32 +0100
commit02455892dac1d52914e5702fd8e895d5cee1f083 (patch)
tree5cbafc717c099ee42c32ee21270b569a55089261 /src/Main.php
parent5832634b35b475f607f4c695ccad310ee2467e57 (diff)
Add world, boid and all collision detectionHEADmain
Diffstat (limited to 'src/Main.php')
-rw-r--r--src/Main.php22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/Main.php b/src/Main.php
new file mode 100644
index 0000000..5678111
--- /dev/null
+++ b/src/Main.php
@@ -0,0 +1,22 @@
+<?php
+
+namespace App;
+
+use App\World\Boid;
+use App\World\World;
+
+class Main
+{
+ public function __construct()
+ {
+ }
+
+ public function run()
+ {
+ $world = new World(200, 200);
+ echo "New World Created. `{$world->name()}` ({$world->width()} x {$world->height()})." . PHP_EOL;
+
+ $boid = new Boid(5, 10, 10);
+ echo "New Boid Created. `{$boid->name()}` ({$boid->position()[0]}, {$boid->position()[1]})." . PHP_EOL;
+ }
+}