Turret/Gun tracking player

Hi, for a game I am working on I want to have a weapon track the player as he jumps and moves around. I have been having some trouble with this so I’m wondering if anyone can give me some help on this.

Say the empty is the turret/Gun and the cube is the player.


Attachments


Your object “turret” does not track anything it just adds an object called “bullet”.
You need an Edit Object actuator in TrackTo mode for tracking.

I suggest to parent a visible object to the object “turret”. Make it “no collision” that it does not influence other objects (e.g. the ray).
It will help you to see the orientation of the object.

Hi, I have a little question about this. Will this work if i make the turret object as a linked group in another scene? I tried to do that a few years ago and I had some problems. So, will this work now without any problems?

P.S. I would try to do it myself but i am not on PC that is able to handle blender now… truly old machine

You can’t track objects in another scene. There is no relationship between scenes.

If you mean a group instance please read TrackTo and added Objects.

Hes is the most basic of tracking. EditObject>Trackobject then click 3D and done.

Nice reading for me, Monster… thanks a lot