Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: norbertice on Sat 17/07/2010 01:35:28

Title: SOLVED Possible problem in script that blocks on mouse click?
Post by: norbertice on Sat 17/07/2010 01:35:28
Whenever I click in my game the cursor just turns to the watch and won't do anything, this happens on the all cursor options.  Can anyone see any problems here?

function on_mouse_click(MouseButton button) {
 // called when a mouse button is clicked. button is either LEFT or RIGHT
 if (IsGamePaused() == 1) {
   // Game is paused, so do nothing (ie. don't allow mouse click)
 }
 else if (button == eMouseLeft) {
   ProcessClick(mouse.x, mouse.y, mouse.Mode);
 }
 else if (button == eMouseRight || button == eMouseWheelSouth){
   // right-click our mouse-wheel down, so cycle cursor
   mouse.SelectNextMode();


I'm new to this so any help would be appreciated
Title: Re: Possible problem in script that blocks on mouse click?
Post by: Creator on Sat 17/07/2010 05:17:12
There's no problems I can see there, but maybe you have code in your room scripts or repeatedly_execute that block the game when the mouse is clicked on something, or just clicked in general?
By the watch cursor, do you mean wait mode (the one that resembles the little watch/clock)?
Title: Re: Possible problem in script that blocks on mouse click?
Post by: norbertice on Sat 17/07/2010 17:04:50
it's ok i figured it out, i'd set walk to points but i don't have a visible character so there was nothing to walk to those points. I reset them to 0 and it works just fine now