Jump to content

Check out our Community Blogs

Register and join over 40,000 other developers!

Recent Status Updates

View All Updates

- - - - -

Keyboard for car game?

car keyboard control

This topic has been archived. This means that you cannot reply to this topic.
2 replies to this topic

#1 Hamed


    CC Devotee

  • Senior Member
  • PipPipPipPipPipPip
  • 413 posts

Posted 21 April 2013 - 08:53 AM


I want an example which help me to use keyboard to move a car (Like games).

Can anyone give me an example.


(XNA or Windows Application but I prefer windows application)

#2 BlackRabbit


    CodeCall Legend

  • Expert Member
  • PipPipPipPipPipPipPipPip
  • 3871 posts

Posted 26 April 2013 - 01:21 AM

Windows application it is ;)


what about this keyboard input tutorial ?


And how is that simulator going?

#3 AceInfinity


    CC Addict

  • Senior Member
  • PipPipPipPipPip
  • 313 posts

Posted 27 April 2013 - 10:04 PM

For key input in XNA, the keys are checked during the Update() method I believe. Add/Subtract from current vectors for the position of the car, and draw them according the the updated coordinates in the Draw() method. It's simple. :)

Microsoft MVP (2012) - .NET Programming | ®Crestron DMC-T Certified Programmer
Posted Image

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download