#define scr_mb_release /* Mouse_release this code returns 1 if the mouse was pressed over the object that executed this code when the mouse is released over the same object argument0 should be the mouse button, mb_left, middle, right, any, or none place in step event in any object's create event, initialize with the following code: with all { for (i = -1; i < 4; i += 1) { press[i+1] = 0 release[i+1] = 1 press_meet[i+1] = 0 } } */ if mouse_check_button(argument0) { if position_meeting(mouse_x,mouse_y,self) && press[argument0+1] = 0 { press_meet[argument0+1] = 1 } if press[argument0+1] = 0 { press[argument0+1] = 1 } release[argument0+1] = 0 } else { if release[argument0+1] = 0 { release[argument0+1] = 1 } press[argument0+1] = 0 if position_meeting(mouse_x,mouse_y,self) && release[argument0+1] = 1 { if press_meet[argument0+1] = 1 { return 1 } } else { press_meet[argument0+1] = 0 } } return 0