A couple questions

I have 2 questions about the game engine.

  1. How do you make a joystick move an object gradually. Right now I have the axis thereshold set to 3 different sensitivities on 3 sensors, this makes it decent, but it would be nice to have it be smooth motion, so as you push the joystick forward, it gradually goes quicker and quicker.

  2. How do you make a sensor where it can detect what a set of crosshairs is over? I’m making a school project where there’s some artifacts in a museum type layout. I originally had it set up to work with a mouse, so when you click on it, a nice HUD with an item description and an image comes up. But using the arrow keys or WASD by itself gave limited motion. So I want to be able to have a sensor detect when a set of crosshairs is over one of the items. Then I can add a button press, and that will open the HUD with the item description.

Bump******

anybody?*****

For question 2: if the crosshair is aligned with the camera, then you can just use a ray sensor to detect a property that the artifact has and then do the action accordingly.

If you do a little python on top of that however you can get the object itself using the hitObject property
(using a line like artifact = raySensor.hitObject), that way you can have the same property on all of the artifacts, but each has a different value for the property and then you can do a different variant of the same event by checking for the different values.

I haven’t used python before, could you either explain it in more depth, or point me to a decent tutorial? I couldn’t find any relatively easy ones last night. I’ve used python before, just not with blender.