GameMaker getting BSOD when usying async system event for controller detection

F

fabstab

Guest
I'm making my game pause when a controller is detected as disconnected.. I've tried several methods of my own and followed other tutorials. And while the code works (it does pause, and the controller is detected as connected and/or disconnected and I can resume the game) however halfway through testing I'll get a blue screen of death, or when I shut my computer down for the night I'll get a blue screen of death.

Is there something I'm missing?

edit: I believe the last BSOD gave the message stop_error or something along those lines...

System Event:
Code:
switch (async_load[? "event_type"])
      {
case "gamepad lost":
    var pad = async_load[? "pad_index"];
    cursor_sprite = sprcustomcursor1;
    pause = 1;
    instance_deactivate_all(true);
    instance_activate_object(objgamepadmouse);
    if instance_exists(objpause1)
    {
    instance_destroy(objpause1);
    }
    audio_pause_all();
break;
case "gamepad discovered":
        var pad = async_load[? "pad_index"];
        instance_activate_all();
        pause = 0;
    if instance_exists(objblackbars) || instance_exists(objblackbars2)
    {
        instance_deactivate_object(objdrawGUI);
    }
break;
}
 

johnwo

Member
Gonna need the STOP code (32-bit number in hex [ex. 0x000000FF]) in order to troubleshoot this properly.
 
F

fabstab

Guest
Not getting a number, but an error code: SYSTEM_SERVICE_EXCEPTION
 
Top