- e.SetShape(world.BlockTypes()[1].shape, color);
- e.AngularVelocity(glm::quat(glm::vec3{ 0.00001f, 0.000006f, 0.000013f }));
- controllers.emplace_back(e);
+ skeletons[random.Next<unsigned char>() % skeletons.Size()].Instantiate(e.GetModel());
+ e.AngularVelocity(rot);
+ Controller *ctrl;
+ if (random()) {
+ ctrl = new RandomWalk(e, random.Next<std::uint64_t>());
+ e.Name("spawned walker");
+ } else {
+ ctrl = new Chaser(world, e, reference);
+ e.Name("spawned chaser");
+ }
+ controllers.emplace_back(ctrl);