/// @description Insert description here
selected=-1

if mouse_x>60 and mouse_x<60+4*string_width("Играть") and mouse_y>200 and mouse_y<248 then selected=0
if mouse_x>60 and mouse_x<60+4*string_width("Настройки") and mouse_y>280 and mouse_y<328 then selected=1
if mouse_x>60 and mouse_x<60+4*string_width("Выход") and mouse_y>360 and mouse_y<408 then selected=2
if mouse_check_button_pressed(mb_left) then 
 {
 if selected=0 then section="hero_select"
 if selected=1 then section="settings"
 if selected=2 then game_end()
 }
if section="hero_select" and mouse_check_button_pressed(mb_left) then
{
if mouse_x>680 and mouse_x<780 and mouse_y>250 and mouse_y<350 then {hero=1 instance_create_depth(0,0,-1,obj_training) instance_destroy()}
if mouse_x>800 and mouse_x<900 and mouse_y>250 and mouse_y<350 then {hero=2 instance_create_depth(0,0,-1,obj_training) instance_destroy()}
}
if section="settings" then
{
if keyboard_check(ord("A")) then sound_volume-=0.005
if keyboard_check(ord("D")) then sound_volume+=0.005
if sound_volume>1 then sound_volume=1
if sound_volume<0 then sound_volume=0
audio_master_gain(sound_volume)
}
