Kinect Dodgeball
Kinect Dodgeball
Basic Aim:
Our application is essentially a virtual dodgeball game. The object of the
game is to avoid the balls which will be “thrown” at the player by another
player using an android application. The player will stand in front of the
Microsoft Kinect and be able to see a human avatar following his motion
on a computer screen or on a projector screen. The balls generated will
have the direction and initial coordinates provided by the android app
Ideally, the game will be so simple to setup that the user will not need
any training to play.
Motivation:
We started with the idea of key glove but the project was not approved
because the project was not feasible.
We got this idea after watching videos of people playing games using
Kinect. This application will provide users with a fun game they will be
able to pick up and immediately begin to play with very little, if any,
instruction. This game also promotes exercise by forcing the player to
actually move in order to play.
Theory:
The Kinect is a very useful tool for working with augmented reality as it
provides high quality information about the world around it.
The Kinect is sold as the device that makes “you” the controller. It does
this by introducing a new kind of camera that could view a scene and
measure the “depth” of objects in front of the Kinect sensor bar. This
allows the software in the controlling device to build an image of the
scene in front of the sensor. This can detect the position and orientation
of players in front of the sensor and build a virtual “skeleton” that
describes where they are and how they are standing.
A program can use the depth information from the sensor to detect and
track the shape of the human body. The Kinect SDK will do this for our
programs and provide skeletal position information that can be used in
games and other program. The skeletal tracking in the Kinect SDK can
track six skeletons at the same time. For four of the bodies only simple
location is provided but two will be tracked in detail. For those two
bodies the SDK will provide the position in 3D space of 20 joint
positions. The software will infer the position of joints if it is not able to
view their position exactly, for example of the user is wearing clothing
such as a skirt that obscures their limbs.
Unity 3D
Overview
Firstly ,we need to control the motion of the character. Although the pre
defined script follows the motion in real world but the character was not
moving in space .It was fixed at a point .We need the avatar to move in
space or else we will not be able to dodge the ball.
Moving the avatar by using the position of hip center of the body. We
found out the position of the hip center joint of the body then in the
update function we changed the position of the avatar as per the change
in position of the joint.
The android application sends the initial and final points of the touch. We
find the unit vector of the flick in unity and give the velocity to the ball in
the same script.
We have a character we can control by our motion in the real world and
we can also create the ball from the android app .We used a few
gestures to start and quit the game in the main menu scene.
The simple mesh collider of the unity doesn't work for the avatar. We
added simple sphere collider to the head and capsule collider to other
body parts according to their sizes.
Final Game:
1. When the exe file is opened the main menu appears
2. Raising the right hand starts the game and raising the left hand quits
the application
3. A timer starts with the game as we have made it a one minute game.
Further Development
Useful Links
For C# http://www.robmiles.com/c-yellow-book/
A word of thanks
We would like to thank our mentors Atri Bhattacharya and Rohit Kumar
Jha and Shivendu for their guidance, patience, suggestions and their
belief in us. They inspired us to learn a lot and work on this exciting
project and checked the progress of our project so sincerely that even if ,
sometimes, when we were like, frustrated and hopeless regarding our
project they showed us the way .