Hi there! Welcome first of all!

About rotating entity to a specific point, you can do the following:
Code:
// rotate towards specific point:
function turn_towards_target(ENTITY* ent, VECTOR* to){
	// create temp vector:
	VECTOR tempVec;
	// free vector (set XYZ to zero):
	vec_fill(tempVec.x, 0);
	// save target position:
	vec_set(tempVec, to.x);
	// subtract our current position:
	vec_sub(tempVec, ent.x);
	// rotate towards the target (as we've got a direction to rotate at):
	vec_to_angle(ent.pan, tempVec);
}

So in order to use it, you need to find 'target' position, to rotate at, and use it like this:
Code:
// my - entity which will rotate
// targetVec - position for entity to rotate at
turn_towards_target(my, targetVec);


This code will change entitie's tilt angle as well (f.e. when target position will be bellow entities feet, it will rotate downwards), in order to prevent that, reset it's TILT angle to zero after calling this function.

About mouse cursor, you'll have to find the mouse position in the world, there are several solutions for this:
mouse_dir3d
mouse_pos3d

Greets


Looking for free stuff?? Take a look here: http://badcom.at.ua
Support me on: https://boosty.to/3rung