Cursor over character/object q

Started by M, Fri 13/06/2003 11:31:49

Previous topic - Next topic

M

Yeah, I really hate to ask for help at this stage coz I've worked out so much stuff myself but this one's killing me...

Basically, when the cursor is over a hotspot - it changes its appearance to a highlighted sprite. If its not on a hotspot, it changes its appearance to an unhighlighted sprite thats just plain. I've got all that working in the repeatedly execute part of the global script.

The thing is I don't know how to do this for when the cursor is over characters and objects. Is there a function to test whether the mouse is over objects and characters?

AJA lost in space

I believe this should work (in the repeatedly_execute):

if (GetLocationType(mouse.x,mouse.y)>0){
 SetCursorGraphic(...);  //Can't remember if this is the function coz I don't have AGS on this computer
}

Check the manual for more info on those functions..

AJA...

correction:

if (GetLocationType(mouse.x,mouse.y)>0){    // highlighted
 ...
} else   // Not highlighted
 ...
}

M


Ah great. Thanks. I'll just check it in a sec....

M

Damn, thats a lot easier than what I was doing. Cheers, AJA. Thats very useful. Progress continues.

And CJ, that context-sensitive help is really helpful  ;D

SMF spam blocked by CleanTalk