The Blog

About Me


Marius Oberholster Hey! I'm having an incredible learning experience, not only learning how Blender works (yes, still learning), but also about Open-Source and the incredible software available. Stick around!

Mouse control

Posted by Marius Oberholster on Monday, January 13, 2014 Under: Quick Blog Tutorial
Good day there everyone!

Today I'm coming at you with another QBT! Still on BGE; that page is really growing! JESUS is so good to us with all this free content! Just amazing!

We are covering, mouse control!

This is a bit of an off-topic of what I thought I was going to do, but this is also quite crucial to some games, so this may just surprise you.
   When using the mouse for control, we can do pretty much anything with it with logic bricks, except use it as a looking point. In other words, there is no MouseLook logic brick just yet. It has been requested though!

For now though, let's focus on what can be done with the mouse:


Let's, for the sake of example, just use Wheel Up (forward) and Wheel Down (backward) as an example for rotating a cube:



As you can see, since these have been separated, unlike mouse movement (counts as a single pulse, it's not an aim-er), you can use this to rotate things. Simply set this up:
Mouse > And > Motion
Mouse: Wheel Up, true pulse mode (gives smoother motion)
And: Leave as per default
Motion: Simple motion, with any axis rotation marked as more than zero

Mouse > And > Motion
Mouse: Wheel Down, true pulse mode
And: Leave as per default
Motion: Simple motion, opposite of first setup


It is truly that simple! Now, if you add some lights and start your game, you literally rotate the object using the scroll wheel. Ta-da! haha

Have a brilliant day and remember to give other controlling sensors a try as well, such as Keyboard. You'll see it differs a little from how Mouse works, and gives you a little bit extra!

Thank YOU!!!!!!!!!

In : Quick Blog Tutorial 


Tags: jesus  controls  mouse  bge  blender  game  engine  new  quick  blog  tutorial  control  scroll  wheel  up  down 
Social
(+27) 073 104 2834   |   marius.oberholster@gmail.com   |   Contact

Make a free website with Yola