Skip to content

Blog 2: Virtual Reality Card Game

Jackson Montgomery edited this page May 2, 2016 · 3 revisions

#Creating a Virtual World

One of the most time consuming parts of making a game is creating a detailed world. When making a game world for Virtual Reality it must be much more detailed than a world for a conventional game. Virtual Reality gives the player depth perception which exposes a lot of the common tricks in game development. Many of these tricks were developed to increase rendering performance. Now that they cannot be used to the same extent we have multiple decreases in performance when we include the overhead incurred by the VR headset. The performance reduction can be substantial depending on the nature of the game and the environments being created. This poses a real problem considering the realtime nature of games. Smooth realtime performance is very important in VR games to reduce the chance of the user getting motion sick.

##Performance We encountered a problem involving one of these tricks recently while developing our game. It relates to the rendering of grass in our world. Most modern games render large amounts of grass using "billboards." Billboards are flat planes with images applied to them. In this case it is just a plane with an image of blades of grass on it with the background removed. Usually, many of these billboards spread out across a landscape is sufficient to create the illusion of a field of grass. However, now that the user has depth perception the field will just look like many 2D planes sitting on top of the landscape.

Here is what a typical image applied to a billboard might look like: http://vterrain.org/Hawaii/Flora/textures/fgrass1_v2_256.png http://vterrain.org/Hawaii/Flora/textures/fgrass1_v2_256.png

Here is what the image looks like applied to a billboard:

The solution we decided on was to create a clump of grass by modeling each blade of grass then spreading that clump across the landscape much like the billboards. Since these grass clumps are actually 3D, the problem with depth perception is no longer present.

Here is what a single clump looks like:

Here is a how the grass looks when used with Unity's foliage system to apply it to the landscape:

Obviously our grass does not look as photo-realistic as the grass used on the billboard but that is more due to our stylistic choice than technical limitations. There is however, a problem with this new system. The clumps are slightly more expensive to render than the billboards due to the increased number of faces on the model. This slight impact is multiplied by the thousands of copies of the grass clump creating a somewhat significant performance hit. Currently, the reduction in performance does not impact the realtime speed of our game but as we expand it could be an area to focus optimization.

##Time Another problem we ran into regarding art was time. Creating detailed models is very time consuming. We originally wanted to have 60 models each representing a different card from the card game Yugioh. We rather quickly realized that at the pace we were going it that would be difficult. We decided to go with a more cartoon style than a realistic one to save on the time we would have to put into each model. We also decided to start inventing our own simple monsters than using the more complex ones from Yugioh. We currently have 5 monster models that are ready with 4-5 more nearly complete. Once those are done we plan on either making a few more or just making small variations on the ones we already have depending on how much time we have left.

The current models we have done are:

###The Arena

###Cloud

###From left to right, Boxy, Sunny, Dragon, Drill, Wizard:

At the end of the project we hope to have at least 15 unique models with 2 variations each totaling 30 total monster models. With our current progress this seems like an achievable goal.

#Project Update and closing remarks:

Since the writing of the previous piece, about a month has passed. We've been able to complete many of our pieces and have integrated even more of our changes. To start with, we have decorated the arena more. We have a scoreboard. We also have an info pane that gives card details that the player can bring up whenever they want. We also have a finished version of the Deck Builder application we've been building.

###Drill and Lanceman on the field:

###Scoreboard:

###Info Pane for monsters:

###Island with waterfall off in the distance:

###Deck Builder application:

##Work done by the team

Jackson - Handled most of the overhead, such as the equipment for the team, the project proposal, this blog post, and the yet-to-come technical report. Also built the Deck Builder application. We decided at the very end to release the Deck Builder as a separate piece right now, as it is a 2D menu and would feel very strange to interact with it in a 3D environment.

John - Handled all of the networking. Designed our major models including the arena, scoreboard, surrounding area, the Wizard and Black Dragon model, and the info pane. John also wrote the first half of the blog, made the end of the year video, and did many more housekeeping details.

Chris - Worked a lot on the rules and mechanics of how the game works. The way that the player interacts with the cards, ranging from drawing, to playing, to attacking, was handled by Chris.

Xi - Xi became our main modeler after John switched hats. Xi made the remaining 10+ monsters that we currently have to play with. Xi also implemented our magic and trap cards effects.

Through it all, even though we didn't meet all of our yearly goals, we still have a game that provides a fun experience for all to enjoy. If we had more time after this, we would expand the content to include all of the monsters we wanted along with our magic/trap cards. We'd probably also make Deck Builder be included into the main project and find a way to fit it into a 3D environment. Along with that, we would streamline networking with a network manager that matched people up automatically so that IPs don't have to be handled by players.

With all that said, we still have a pretty complete game, just somewhat unpolished and somewhat lacking in content, but it has met all of our basic goals that we set out to do, along with a couple stretch goals.