You can use
mouse_ent to get the entity touched by the mouse pointer.
If you typify all your entites (e.g. set skill1 to a typedefined id) you can change the
mouse_map when touching an entity.
function auto_mousecursor(){
while(1){
if(mouse_ent){
switch(mouse_ent.skill1){
case gc_typid_enemy: mouse_map=bmp_sword; break;
case gc_typid_gold: mouse_map=bmp_hand; break;
case gc_typid_food: mouse_map=bmp_bag; break;
case gc_typid_citizen: mouse_map=bmp_talk; break;
deafult: mouse_map=bmp_cursor; break;
}
}else{
mouse_map=bmp_cursor;
}
}
}
got it?