switch (global.spawn) { case -1 : x = 48; y = room_height / 2; break; case 2 : x = room_width / 2; y = 48; break; case 3 : x = room_width - 48; y = room_height / 2; break; case 0 : x = room_width / 2; y = room_height - 48; break; case 1 : x = 48; y = room_height / 2; break; }