Author Topic: Mouse Interface  (Read 324 times)  Share 

Mouse Interface
« on: 06 Jul 2012, 08:24 »
Sorry for asking..i'm new here..

how to change the mouse interface when the move the cursor out of hotspot & when move from the hotspot,the mouse changing back to default cursor (pointer icon)

Khris

  • Evil Dark Emperor Death-Kill
    • Lifetime Achievement Award Winner
    •  
    • I can help with play testing
    •  
    • I can help with scripting
    •  
    • I can help with translating
    •  
Re: Mouse Interface
« Reply #1 on: 06 Jul 2012, 08:41 »
Open Globalscript.asc, find the repeatedly_execute function, and in there, add:

Code: Adventure Game Studio
  1.   int mm = mouse.Mode;
  2.   int lt = GetLocationType(mouse.x, mouse.y);
  3.   int nm;
  4.   if (lt == eLocationHotspot || lt == eLocationObject) nm = eModeInteract;
  5.   else if (lt == eLocationCharacter) nm = eModeTalkto;
  6.   else nm = eModeWalkto;
  7.   if (nm != mm) mouse.Mode = nm;

edit: corrected code
« Last Edit: 07 Jul 2012, 07:31 by Khris »
http://whathaveyoutried.com/

The other day on yahoo answers:
"Can you print colored images with black ink? If so tell me how please Thanx Kimberly"