I have setup 3 cubes and a camera ,the camera has 3 set frames on the timeline that move to each of the 3 cubes.

what i want is to be able to use the scroll wheel of the mouse in BGE and toggle between thoughs 3 frames.

how can this be done?


1 Answer 1


Use a mouse sensor to run an action. In the action actuator you can specify the start and end frame to play. You will need a property to track where you are and run a different part of the action for each value.

Personally I wouldn't use the action keyframes, I would use a simple motion for the camera.

enter image description here

When a mouse wheel up event happens and the location property is less than 4, the camera is moved 10 units on X and adds 1 to the location property. Simply repeat for the opposite direction.

  • $\begingroup$ Ok here is my problem with what you said i tried following based off your picture and i dont know how to get the location property you have. $\endgroup$ Apr 17, 2015 at 2:55
  • $\begingroup$ can you please or someone else explain this further? $\endgroup$ Apr 17, 2015 at 2:56
  • $\begingroup$ location is a game property, you can add game properties to the side of the logic editor, if the properties aren't visible press N $\endgroup$
    – sambler
    Apr 18, 2015 at 14:44
  • $\begingroup$ yes but all i see is timer,string ,float,integer,boolean $\endgroup$ Apr 22, 2015 at 3:35
  • $\begingroup$ so is there suppose to be more like location? $\endgroup$ Apr 22, 2015 at 3:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .