X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?p=laserbrain_demo;a=blobdiff_plain;f=src%2Fexhibit.cc;h=b598b75426322c1117ca529d6d895c119fb7ca5a;hp=2e818540258c98c52774c0f0ff6cd007f2037a96;hb=6ecd4ecfa020964e4250bf9322c1a26ac4073b76;hpb=794a378d5c8e07c815814324da8142be137406d0 diff --git a/src/exhibit.cc b/src/exhibit.cc index 2e81854..b598b75 100644 --- a/src/exhibit.cc +++ b/src/exhibit.cc @@ -61,7 +61,13 @@ ExSelection Exhibit::select(const Ray &ray) const ExSelection Exhibit::select(const Sphere &sph) const { - return ExSelection(0); // TODO + ExSelection sel; + if(collision_sphere_aabox(sph, get_aabox())) { + sel.ex = (Exhibit*)this; + sel.selsphere = sph; + sel.validmask = EXSEL_SPHERE; + } + return sel; } void Exhibit::update(float dt)