osmosacademy / vr-passport

Virtual Reality Campaign
GNU General Public License v3.0
17 stars 10 forks source link

Water Warp Effect #5

Open Zulban opened 8 years ago

Zulban commented 8 years ago

(From Trello, I'm not the author)

Build the Water Warp: movement between coral spaces....kinda like Star Trek or Star Wars, but with coral, fishes, mermaids, etc. zooming by......

peterwilkinson commented 8 years ago

Starting to test out a tunnel idea. screen shot 2016-03-26 at 1 44 46 am

geoffsalmon commented 8 years ago

I've pushed a VisitReefs script that alternates creating tunnels and reefs (only a single coral prefab currently) and moves the player through the tunnel between reefs. The latest version has curved tunnels and movement, although the movement into and out of the tunnel is still a straight lerp and is jarring. Try running the TransitTest scene.

The VisitReefs script could be extended to be the driver of the overall game. It needs a callback or some way to be told when a particular reef is "done" so it can create the next tunnel. Alternatively, the transit and tunnel scripts could be used by something else.

The tunnels are created in Scripts/VisitReefs/Transits/CurvedTunnel.cs running along a bezier curve. I think the visuals can be improved a lot (fixing the shading so the tunnel is lit nicely, placing bubbles along the tunnel, etc.) but I'm struggling with my lack of unity experience.

peterwilkinson commented 8 years ago

Looks cool @geoffsalmon ! Is it possible to make the tunnel and levels spawn when looking up or down as well? Because for some users they will only see the ceiling, which won't allow them to see the levels or even much of the awesome tunnel.

geoffsalmon commented 8 years ago

Yup, can do. Pushed a change that places the tunnel and reef in the direction the player is looking when the timer runs out. The final version should probably place it in some direction we've decided is comfortable for the user and then animate the big fish to swim through the tunnel to draw user's attention.

Just noticed the tunnel generation can freak out and twist or collapse a portion of the tunnel if it's directly up or down though. Not sure the best way to fix that...

peterwilkinson commented 8 years ago

Fantastic! We can't count on the player being able to turn their head well, or have high cognition. Leaving it open to their direction is good.

peterwilkinson commented 8 years ago

@geoffsalmon I'm working on the transitTunnel file, just getting it decorated up for this evenings test ahead of tomorrows big test. It's looking good. Added bubbles, and light to the main camera (for now).

peterwilkinson commented 8 years ago

@geoffsalmon its really moving along now. Do you think you can turn the coral object property into an array that would allow adding a different coral at the end of each tunnel, and then looping back to the first one in the array if a player gets to the last one (until we can get the start and end screen going). @guiji80 is working on different coral prefabs for the different places. It's all looking good.

geoffsalmon commented 8 years ago

Pushed that change. The Reef Prefabs property is now an array, and the TransitTest scene tests it with 3 different prefabs.

geoffsalmon commented 8 years ago

Pushed another change. If any component in the reef prefab hierarchy implements IReefVisitor, it'll be passed a ReefStage object. The player will stay at the current reef and the next tunnel won't be created until all reef visitors have called the finishStage function on their ReefStage object. Scripts/VisitReefs/ReefWait.cs is an example that just waits a set amount of time. A more exciting version would wait for a number of fish to be collected.

peterwilkinson commented 8 years ago

Thanks @geoffsalmon I didn't get time to integrate it in this test, but will right after. The world is working alright, now its just some features like gameplay and optimizations, and we'll have a pretty good framework. Good stuff!