Create your first pong game-challenge: improve your pong game

Source: Internet
Author: User
Challenge: improve your pong game

Now it's your turn to make some improvements to the game; maybe you can change the picture or sound, or adjust the gameplay. If you have a gamepad controller, you can also try to add rumble support to it. And if you read this book, you should indeed have a gamepad, even if you do not have Xbox 360; many xNa examples require the Xbox 360 controller, in addition, some games use an Xbox 360 controller, which is more fun than a keyboard.

Here is how to add rumble support to gamepad:

Gamepad. setvibration (playerindex. One, leftrumble, rightrumble );

When the ball hits the racket, use the aboveCodeIt will shake the Controller for a while (left rumble and right rumble use the same value, so that the entire controller will vibrate ). When a player loses his or her life, he or she can also shake it. This Shake takes a longer time and is more intense.

You can view the project in this chapter to see the solutions to the challenges. Your solution does not have to be the same, but it may be helpful or even a shortcut to solve a specific problem.

Enjoy the xNa pong game!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.