2006-12-29 17:50:24 +03:00
|
|
|
;---------------------------------------------
|
|
|
|
;-----------panel BUTTONS---------------------
|
|
|
|
;---------------------------------------------
|
|
|
|
buttons:
|
|
|
|
|
|
|
|
cmp [Current_instrument],21
|
2016-03-21 20:29:30 +03:00
|
|
|
jne @f
|
2006-12-29 17:50:24 +03:00
|
|
|
cmp [instrument_used],1
|
2016-03-21 20:29:30 +03:00
|
|
|
jne @f
|
2006-12-29 17:50:24 +03:00
|
|
|
cmp [Activate_instrument],0
|
2016-03-21 20:29:30 +03:00
|
|
|
jne @f
|
2006-12-29 17:50:24 +03:00
|
|
|
cmp [crossing],1
|
2016-03-21 20:29:30 +03:00
|
|
|
jne @f
|
|
|
|
mov [finishing_crossing],1
|
|
|
|
call TakeButtonInstruments
|
2016-03-22 17:12:51 +03:00
|
|
|
jmp still
|
2016-03-21 20:29:30 +03:00
|
|
|
@@:
|
2006-12-29 17:50:24 +03:00
|
|
|
|
2016-03-21 20:29:30 +03:00
|
|
|
mcall SF_GET_BUTTON
|
2006-12-29 17:50:24 +03:00
|
|
|
|
|
|
|
shr eax,8
|
|
|
|
|
|
|
|
cmp eax,1
|
|
|
|
jne no_exit
|
2016-03-21 20:29:30 +03:00
|
|
|
mov eax,CursorsID
|
|
|
|
call delete_cursors
|
|
|
|
mcall SF_TERMINATE_PROCESS
|
2006-12-29 17:50:24 +03:00
|
|
|
no_exit:
|
|
|
|
|
|
|
|
mov [Current_instrument],eax
|
2016-03-21 20:29:30 +03:00
|
|
|
call button_handler_main_menu
|
2006-12-29 17:50:24 +03:00
|
|
|
|
|
|
|
cmp eax,10
|
|
|
|
jl still
|
|
|
|
|
|
|
|
;save instrumnets 10-40
|
|
|
|
cmp eax,40
|
|
|
|
jae no_save_last_instrument
|
|
|
|
|
|
|
|
mov [Last_instrument],eax
|
|
|
|
|
|
|
|
no_save_last_instrument:
|
|
|
|
|
|
|
|
cmp eax,10
|
|
|
|
je still
|
|
|
|
|
|
|
|
cmp eax,14
|
|
|
|
je still
|
|
|
|
|
|
|
|
cmp eax,11
|
|
|
|
je still
|
|
|
|
|
|
|
|
cmp eax,13
|
|
|
|
je still
|
|
|
|
|
|
|
|
cmp eax,12
|
|
|
|
je still
|
|
|
|
|
|
|
|
cmp eax,51
|
|
|
|
jne no_palette_
|
|
|
|
|
|
|
|
call TakeButtonInstruments
|
|
|
|
jmp still
|
|
|
|
|
|
|
|
no_palette_:
|
|
|
|
|
|
|
|
cmp eax,17
|
|
|
|
je still
|
|
|
|
|
|
|
|
cmp eax,21
|
|
|
|
jne no_allocation__
|
|
|
|
|
|
|
|
and [Activate_instrument],0
|
|
|
|
jmp still
|
|
|
|
|
|
|
|
no_allocation__:
|
|
|
|
|
|
|
|
cmp eax,20
|
|
|
|
jne no_kontur__
|
|
|
|
|
|
|
|
and [instrument_used],0
|
|
|
|
jmp still
|
|
|
|
|
|
|
|
no_kontur__:
|
|
|
|
|
|
|
|
call TakeButtonInstruments
|
|
|
|
jmp still
|