/programs/other/planet_v/planet_v.asm |
---|
55,29 → 55,21 |
start: |
load_libraries l_libs_start,load_lib_end |
;¯à®¢¥àª ᪮«ìª® ã¤ ç® § £ã§¨« áì è «¨¡ |
mov ebp,lib0 |
cmp dword [ebp+ll_struc_size-4],0 |
jz @f |
mcall -1 ;exit not correct |
;¯à®¢¥àª ᪮«ìª® ã¤ ç® § £ã§¨«¨áì ¡¨¡«¨®â¥ª¨ |
cmp dword [lib0+ll_struc_size-4],0 |
jnz @f |
cmp dword [lib1+ll_struc_size-4],0 |
jnz @f |
cmp dword [lib2+ll_struc_size-4],0 |
jnz @f |
cmp dword [lib3+ll_struc_size-4],0 |
jnz @f |
jmp .lib |
@@: |
mov ebp,lib1 |
cmp dword [ebp+ll_struc_size-4],0 |
jz @f |
mcall -1 ;exit not correct |
@@: |
mov ebp,lib2 |
cmp dword [ebp+ll_struc_size-4],0 |
jz @f |
mcall -1 ;exit not correct |
@@: |
mov ebp,lib3 |
cmp dword [ebp+ll_struc_size-4],0 |
jz @f |
mcall -1 ;exit not correct |
@@: |
.lib: |
copy_path ini_name,sys_path,file_name,0x0 |
copy_path ini_name,sys_path,file_name,0 |
stdcall dword[ini_get_str],file_name,ini_sec,ini_k_cache,dword[edit1.text],dword[edit1.max],ini_def_cache |
stdcall [str_len],dword[edit1.text],dword[edit1.max] |
mov dword[edit1.size],eax |
93,7 → 85,7 |
stdcall dword[ini_get_str],file_name,ini_sec,ini_ext,txt_tile_type_0,dword[tree1.info_capt_len],ini_ext.def |
cmp byte[txt_tile_type_0],0 |
je @f |
stdcall dword[tl_node_add], txt_tile_type_0, 0, tree1 |
stdcall dword[tl_node_add], tree1, 0, txt_tile_type_0 |
jmp @b |
@@: |
mov byte[ini_ext.number],'0' ;áç¨âë¢ ¥¬ ¯ à ¬¥âà ®â ext0 ª®â®àë© ¡ã¤¥â ¢ë¡à ¢ ᯨ᪥ |
102,7 → 94,7 |
jne @f |
mov dword[txt_tile_type_0],'.bmp' ;¥á«¨ ¢ *.ini ä ©«¥ ¨ç¥£® ¥â ¤®¡ ¢«ï¥¬ à áè¨à¥¨¥ .bmp |
@@: |
stdcall dword[tl_node_add], txt_tile_type_0, 0, tree1 |
stdcall dword[tl_node_add], tree1, 0, txt_tile_type_0 |
; init bmp file |
stdcall mem.Alloc, dword RGB_TILE_SIZE+300 ;300 - § ¯ áë¥ ¡ ©âë á ãç¥â®¬ § £®«®¢ª bmp ä ©« |
117,8 → 109,7 |
stdcall mem.Alloc, dword TREE_ICON_NOD16_BMP_SIZE |
mov [tree_nod_icon],eax |
copy_path fn_icon1,sys_path,file_name,0x0 |
mov eax,70 ;load icon file |
copy_path fn_icon1,sys_path,file_name,0 |
mov [run_file_70.Function], 0 |
mov [run_file_70.Position], 0 |
mov [run_file_70.Flags], 0 |
126,8 → 117,7 |
m2m [run_file_70.Buffer], [tree_sys_icon] |
mov byte[run_file_70+20], 0 |
mov [run_file_70.FileName], file_name |
mov ebx,run_file_70 |
int 0x40 |
mcall 70,run_file_70 |
cmp ebx,0xffffffff |
je @f |
stdcall dword[img_decode], dword[tree_sys_icon],ebx,0 |
140,12 → 130,10 |
@@: |
copy_path fn_icon2,sys_path,file_name,0x0 |
mov eax,70 ;load icon file |
copy_path fn_icon2,sys_path,file_name,0 |
mov [run_file_70.Count], TREE_ICON_NOD16_BMP_SIZE |
m2m [run_file_70.Buffer], [tree_nod_icon] |
mov ebx,run_file_70 |
int 0x40 |
mcall 70,run_file_70 |
cmp ebx,0xffffffff |
je @f |
stdcall dword[img_decode], dword[tree_nod_icon],ebx,0 |
178,8 → 166,7 |
align 4 |
still: |
mov eax,10 |
mcall |
mcall 10 |
cmp al,0x1 ;¨§¬. ¯®«®¦¥¨¥ ®ª |
jz red_win |
188,14 → 175,10 |
cmp al,0x3 |
jz button |
push dword ch2 |
call [check_box_mouse] |
push dword ch1 |
call [check_box_mouse] |
stdcall [check_box_mouse],ch2 |
stdcall [check_box_mouse],ch1 |
stdcall [edit_box_mouse], edit1 |
stdcall [edit_box_mouse], edit2 |
stdcall [tl_mouse], tree1 |
stdcall [tl_mouse], tree2 |
208,10 → 191,8 |
stdcall [edit_box_key], edit1 |
stdcall [edit_box_key], edit2 |
push dword tree1 |
call [tl_key] |
push dword tree2 |
call [tl_key] |
stdcall [tl_key],tree1 |
stdcall [tl_key],tree2 |
mov ebx,dword[el_focus] ;çâ®-¡ë ª àâ ¥ ¤¢¨£ « áì ¥á«¨ ®ª treelist ¢ 䮪ãᥠ|
cmp ebx, dword tree1 |
272,12 → 253,10 |
mcall 12,1 |
xor eax,eax |
mov ebx,20*65536+min_window_w |
mov ecx,20*65536+min_window_h |
mov edx,[sc.work] |
or edx,0x33000000 |
mov edi,hed |
mcall |
mcall ,20*65536+min_window_w,20*65536+min_window_h |
mcall 9,procinfo,-1 |
293,7 → 272,7 |
mov eax,dword[tree2.box_left] ;¤¢¨£ ¥¬ áªà®««¨£ |
add eax,dword[tree2.box_width] |
mov ebx,dword[tree2.p_scrol] |
mov ebx,dword[tree2.p_scroll] |
mov word[ebx+2],ax |
mov dword[edit2.left],edi |
304,17 → 283,10 |
mov dword[wScrMetki.all_redraw],1 |
stdcall [scrollbar_ver_draw], dword wScrMetki |
mov eax,8 ;ª®¯ª |
mov ebx,145*65536+20 |
mov ecx,5*65536+25 |
mov edx,6 |
mov esi,[sc.work_button] |
int 0x40 |
mcall 8,145*65536+20,5*65536+25,6 ;ª®¯ª |
mov ebx,100*65536+20 |
mov ecx,5*65536+25 |
mov edx,5 |
int 0x40 |
mcall ,100*65536+20,5*65536+25,5 |
mov ebx,170*65536+40 ;ª®¯ª ¢ë§®¢ ¤¨ «®£ OpenDial |
;mov ecx,5*65536+25 |
503,14 → 475,17 |
cmp ah,5 |
jne @f |
call but_ZoomM |
jmp still |
@@: |
cmp ah,6 |
jne @f |
call but_ZoomP |
jmp still |
@@: |
cmp ah,7 |
jne @f |
call but_Refresh |
jmp still |
@@: |
cmp ah,9 |
521,18 → 496,22 |
cmp ah,10 |
jne @f |
call but_met_up |
jmp still |
@@: |
cmp ah,11 |
jne @f |
call but_met_dn |
jmp still |
@@: |
cmp ah,12 |
jne @f |
call fun_goto_met |
jmp still |
@@: |
cmp ah,13 ;¤¨ «®£ OpenDialog ¤«ï ¯®¨áª ¯ ¯ª¨ |
jne @f |
call fun_opn_dlg |
jmp still |
@@: |
cmp ah,1 |
jne still |
557,8 → 536,7 |
;data_rgb - pointer to rgb data |
;size - count img pixels (size img data / 3(rgb) ) |
align 4 |
proc img_rgb_wdiv2 data_rgb:dword, size:dword |
push eax ebx ecx edx |
proc img_rgb_wdiv2 uses eax ebx ecx edx, data_rgb:dword, size:dword |
mov eax,dword[data_rgb] |
mov ecx,dword[size] ;ecx = size |
imul ecx,3 |
596,8 → 574,6 |
add eax,3 |
add ebx,6 |
loop @b |
pop edx ecx ebx eax |
ret |
endp |
676,8 → 652,7 |
;data_rgb - pointer to rgb data |
;size - count img pixels (size img data / 3(rgb) ) |
align 4 |
proc img_rgb_wmul2, data_rgb:dword, size:dword |
push eax ebx ecx edx |
proc img_rgb_wmul2 uses eax ebx ecx edx, data_rgb:dword, size:dword |
;eax - source |
;ebx - destination |
mov ecx,dword[size] ;ecx = size |
697,7 → 672,6 |
sub eax,3 |
sub ebx,6 |
loop @b |
pop edx ecx ebx eax |
ret |
endp |
754,9 → 728,7 |
;size - count img pixels (size img data / 3(rgb) ) |
;size_w - width img in pixels |
align 4 |
proc img_rgb_hoffs, data_rgb:dword, size:dword, size_w:dword, hoffs:dword |
push eax ebx ecx edx esi |
proc img_rgb_hoffs uses eax ebx ecx edx esi, data_rgb:dword, size:dword, size_w:dword, hoffs:dword |
mov esi,dword[size_w] |
lea esi,[esi+esi*2] ;esi = width * 3(rgb) |
imul esi,dword[hoffs] |
779,7 → 751,6 |
sub eax,3 |
sub ebx,3 |
loop @b |
pop esi edx ecx ebx eax |
ret |
endp |
824,26 → 795,22 |
endp |
align 4 |
proc mem_copy, source:dword, destination:dword, len:dword |
push ecx esi edi |
proc mem_copy uses ecx esi edi, source:dword, destination:dword, len:dword |
cld |
mov esi, dword[source] |
mov edi, dword[destination] |
mov ecx, dword[len] |
rep movsb |
pop edi esi ecx |
ret |
endp |
align 4 |
proc mem_clear, mem:dword, len:dword |
push eax ecx edi |
proc mem_clear uses eax ecx edi, mem:dword, len:dword |
cld |
xor al,al |
mov edi, dword[mem] |
mov ecx, dword[len] |
repne stosb |
pop edi ecx eax |
ret |
endp |
897,38 → 864,7 |
el_focus, wScrMetki,fun_goto_met |
align 4 |
wScrMetki: |
.x: |
.size_x dw 16 ;+0 |
.start_x dw 0 ;+2 |
.y: |
.size_y dw 100 ;+4 |
.start_y dw 0 ;+6 |
.btn_high dd 15 ;+8 |
.type dd 1 ;+12 |
.max_area dd 100 ;+16 |
.cur_area dd 30 ;+20 |
.position dd 0 ;+24 |
.bckg_col dd 0xeeeeee ;+28 |
.frnt_col dd 0xbbddff ;+32 |
.line_col dd 0 ;+36 |
.redraw dd 0 ;+40 |
.delta dw 0 ;+44 |
.delta2 dw 0 ;+46 |
.run_x: |
.r_size_x dw 0 ;+48 |
.r_start_x dw 0 ;+50 |
.run_y: |
.r_size_y dw 0 ;+52 |
.r_start_y dw 0 ;+54 |
.m_pos dd 0 ;+56 |
.m_pos_2 dd 0 ;+60 |
.m_keys dd 0 ;+64 |
.run_size dd 0 ;+68 |
.position2 dd 0 ;+72 |
.work_size dd 0 ;+76 |
.all_redraw dd 0 ;+80 |
.ar_offset dd 1 ;+84 |
wScrMetki scrollbar 16,0, 100,0, 15, 100, 30,0, 0xeeeeee, 0xbbddff, 0, 1 |
ed_buffer: ;òåêñò äëÿ edit |
.2: rb 32 |
997,19 → 933,21 |
align 4 |
tile_00 rb size_tile_struc * max_tiles_count |
;íâ®â ª®¤ ¥ ¬®©, ® ¯à¥®¡à §ã¥â ç¨á«® ¢ áâபã |
;input: |
; eax = value |
; edi = string buffer |
; eax - ç¨á«® |
; edi - ¡ãä¥à ¤«ï áâப¨ |
; len - ¤«¨ ¡ãä¥à |
;output: |
; edi = |
align 4 |
tl_convert_to_str: |
proc convert_int_to_str, len:dword |
pushad |
mov dword[edi+1],0;0x20202020 |
mov esi,[len] |
add esi,edi |
dec esi |
call .str |
popad |
ret |
endp |
align 4 |
.str: |
1024,19 → 962,23 |
call .str;¯¥à¥©â¨ á ¬ã ᥡï â.¥. ¢ë§¢ âì á ¬ã á¥¡ï ¨ â ª ¤® ⮣® ¬®¬¥â ¯®ª ¢ eax ¥ á⠥⠬¥ìè¥ ç¥¬ ¢ ecx |
pop eax |
@@: ;cmp al,10 ;¯à®¢¥à¨âì ¥ ¬¥ìè¥ «¨ § 票¥ ¢ al 祬 10 (¤«ï á¨á⥬ë áç¨á«¥ï 10 ¤ ï ª®¬ ¤ - «¨è ï)) |
cmp edi,esi |
jge @f |
or al,0x30 ;¤ ï ª®¬ ¤ ª®à®ç¥ 祬 ¤¢¥ ¢ëè¥ |
stosb ;§ ¯¨á âì í«¥¬¥â ¨§ ॣ¨áâà al ¢ ï祪㠯 ¬ï⨠es:edi |
ret ;¢¥àãâìáï ç¥ì ¨â¥à¥áë© å®¤ â.ª. ¯®ª ¢ á⥪¥ åà ¨âìáï ª®«-¢® ¢ë§®¢®¢ â® á⮫쪮 à § ¬ë ¨ ¡ã¤¥¬ ¢ë§ë¢ âìáï |
mov byte[edi],0 ;¢ ª®¥æ áâப¨ áâ ¢¨¬ 0, çâ®-¡ë ¥ ¢ë« §¨« ¬ãá®à |
@@: |
ret ;¯®ª ¢ á⥪¥ åà ¨âìáï ª®«-¢® ¢ë§®¢®¢ â® á⮫쪮 à § ¬ë ¨ ¡ã¤¥¬ ¢ë§ë¢ âìáï |
hed db 'Planet viewer 16.01.13',0 ;¯®¤¯¨áì ®ª |
hed db 'Planet viewer 09.11.15',0 ;¯®¤¯¨áì ®ª |
sc system_colors ;á¨áâ¥¬ë¥ æ¢¥â |
mouse_dd dd 0 ;㦮 ¤«ï Shift- ¢ editbox |
align 16 |
i_end: |
procinfo process_information |
rb 1024 |
align 16 |
procinfo process_information |
stacktop: |
sys_path rb 4096 |
file_name: |
/programs/other/planet_v/tile_fun.inc |
---|
63,9 → 63,9 |
; load_new_tile (¢¥àåïï ª à⨪ ) |
;??? |
;¯¥à¥¤¢¨£ ¥¬ ª®®à¤¨ âã ªãàá®à ¢¯à ¢® |
align 4 |
CursorMoveRight: ;¯¥à¥¤¢¨£ ¥¬ ª®®à¤¨ âã ªãàá®à ¢¯à ¢® |
CursorMoveRight: |
push ebx ecx |
xor ebx,ebx |
xor ecx,ecx |
87,9 → 87,9 |
pop ecx ebx |
ret |
;??? |
;¯¥à¥¤¢¨£ ¥¬ ª®®à¤¨ âã ªãàá®à ¢¨§ |
align 4 |
CursorMoveDown: ;¯¥à¥¤¢¨£ ¥¬ ª®®à¤¨ âã ªãàá®à ¢¨§ |
CursorMoveDown: |
push ebx ecx |
xor ebx,ebx |
xor ecx,ecx |
111,24 → 111,23 |
pop ecx ebx |
ret |
;??? |
;¯¥à¥¬¥é¥¨¥ ¬¥âª¨ ¢¢¥àå, ¯® ᯨáªã |
align 4 |
but_met_up: ;¯¥à¥¬¥é¥¨¥ ¬¥âª¨ ¢¢¥àå, ¯® ᯨáªã |
but_met_up: |
stdcall dword[tl_node_move_up], tree2 |
ret |
;??? |
;¯¥à¥¬¥é¥¨¥ ¬¥âª¨ ¢¨§, ¯® ᯨáªã? |
align 4 |
but_met_dn: ;¯¥à¥¬¥é¥¨¥ ¬¥âª¨ ¢¨§, ¯® ᯨáªã |
but_met_dn: |
stdcall dword[tl_node_move_down], tree2 |
ret |
;??? |
;¬¥ï¥¬ à áè¨à¥¨¥ ¤«ï ª àâë |
align 4 |
fun_new_map_type: ;¬¥ï¥¬ à áè¨à¥¨¥ ¤«ï ª àâë |
fun_new_map_type: |
push eax |
stdcall dword[tl_node_get_data], tree1 |
pop eax |
cmp eax,0 |
je @f |
mov dword[txt_tile_type],eax |
138,8 → 137,7 |
;§ ¤ ¥¬ à ᯮ«®¦¥¨¥ â ©«®¢ ¯® á¥âª¥ |
align 4 |
proc tiles_init_grid, beg_tiles:dword, count:dword, cols:dword |
push eax ebx ecx edx edi |
proc tiles_init_grid uses eax ebx ecx edx edi, beg_tiles:dword, count:dword, cols:dword |
xor eax,eax |
xor ebx,ebx |
mov edi,[beg_tiles] |
156,7 → 154,6 |
inc bx |
.old_lin: |
loop @b |
pop edi edx ecx ebx eax |
ret |
endp |
165,8 → 162,7 |
;â ©«ë ¢ ¯à®â¨¢®¯®«®¦ãî áâ®à®ã, ¢ १ã«ìâ ⥠ª®®à¤¨ âë ¡®«ìè¨á⢠⠩«®¢ ¥ ¬¥ïîâáï |
; § ç¨â ¯à®£à ¬¬ ¥ ¡ã¤¥â ¯¥à¥ç¨âë¢ âì ¨å § ®¢®, 祬 ¨ ¤®á⨣ ¥âáï ®¯â¨¬¨§ æ¨ï |
align 4 |
proc tiles_grid_move_left, beg_tiles:dword, count:dword, cols:dword |
push eax ebx ecx edx edi |
proc tiles_grid_move_left uses eax ebx ecx edx edi, beg_tiles:dword, count:dword, cols:dword |
xor eax,eax |
xor ebx,ebx |
mov edi,[beg_tiles] |
180,7 → 176,6 |
dec tile_delta_x |
add edi,size_tile_struc |
loop @b |
pop edi edx ecx ebx eax |
ret |
endp |
187,8 → 182,7 |
;ᤢ¨£ ¥¬ á¥âªã ¢¯à ¢®, ¢ë«¥§è¨¥ á⮫¡æë ¡ã¤ãâ ¯¥à¥ª¨ãâë «¥¢ãî áâ®à®ã |
;¤¥« ¥â ⮦¥ çâ® ¨ tiles_grid_move_left ⮫쪮 ¤¢¨£ ¥â ª®®à¤¨ âë ¢ ¤àã£ãî áâ®à®ã |
align 4 |
proc tiles_grid_move_right, beg_tiles:dword, count:dword, cols:dword |
push eax ebx ecx edx edi |
proc tiles_grid_move_right uses eax ebx ecx edx edi, beg_tiles:dword, count:dword, cols:dword |
xor eax,eax |
xor ebx,ebx |
mov edi,[beg_tiles] |
202,13 → 196,11 |
.no_jump: |
add edi,size_tile_struc |
loop @b |
pop edi edx ecx ebx eax |
ret |
endp |
align 4 |
proc tiles_grid_move_up, beg_tiles:dword, count:dword, rows:dword |
push eax ebx ecx edx edi |
proc tiles_grid_move_up uses eax ebx ecx edx edi, beg_tiles:dword, count:dword, rows:dword |
xor eax,eax |
xor ebx,ebx |
mov edi,[beg_tiles] |
222,13 → 214,11 |
dec tile_delta_y |
add edi,size_tile_struc |
loop @b |
pop edi edx ecx ebx eax |
ret |
endp |
align 4 |
proc tiles_grid_move_down, beg_tiles:dword, count:dword, rows:dword |
push eax ebx ecx edx edi |
proc tiles_grid_move_down uses eax ebx ecx edx edi, beg_tiles:dword, count:dword, rows:dword |
xor eax,eax |
xor ebx,ebx |
mov edi,[beg_tiles] |
242,13 → 232,11 |
.no_jump: |
add edi,size_tile_struc |
loop @b |
pop edi edx ecx ebx eax |
ret |
endp |
align 4 |
proc array_tile_function, beg_tiles:dword, count:dword, funct:dword |
push ecx edi |
proc array_tile_function uses ecx edi, beg_tiles:dword, count:dword, funct:dword |
mov edi,[beg_tiles] |
mov ecx,[count] |
@@: |
255,7 → 243,6 |
stdcall [funct],edi |
add edi,size_tile_struc |
loop @b |
pop edi ecx |
ret |
endp |
262,15 → 249,11 |
align 4 |
draw_tiles: |
pushad |
mov eax,47 |
mov ebx,0x20000 |
xor ecx,ecx |
mov cl,byte[map.zoom] |
mov edx,128*65536+13 |
movzx ecx,byte[map.zoom] |
mov esi,[sc.work_text] |
or esi,0x40000000 |
mov edi,[sc.work] |
int 0x40 |
mcall 47,0x20000,, (128 shl 16)+13 |
stdcall array_tile_function, tile_00,max_tiles_count,draw_tile |
popad |
466,40 → 449,35 |
@@: |
ret |
;??? |
;á®åà ¥¨¥ ä ©« á ¬¥âª ¬¨ |
align 4 |
but_MetSave: ;á®åà ¥¨¥ ä ©« á ¬¥âª ¬¨ |
stdcall dword[tl_save_mem], TREE_ICON_SYS16_BMP_SIZE,[bmp_icon],0,tree2 |
but_MetSave: |
stdcall dword[tl_save_mem], tree2,0,[bmp_icon],TREE_ICON_SYS16_BMP_SIZE |
copy_path fn_metki,sys_path,file_name,0 |
push eax ebx ecx edi |
copy_path fn_metki,sys_path,file_name,0x0 |
stdcall dword[tl_get_mem_size], tree2,[bmp_icon] |
inc eax ;¤«ï § ¯¨á¨ ¢ ä ©« § ¢¥àè î饣® ã«ï |
stdcall dword[tl_get_mem_size], [bmp_icon],tree2 |
pop ecx |
inc ecx ;¤«ï § ¯¨á¨ ¢ ä ©« § ¢¥àè î饣® ã«ï |
mov eax,70 |
m2m [run_file_70.Buffer], [bmp_icon] |
mov [run_file_70.Function], 2 |
mov [run_file_70.Position], 0 |
mov [run_file_70.Flags], 0 |
mov [run_file_70.Count], ecx |
mov [run_file_70.Count], eax |
mov byte[run_file_70+20], 0 |
mov [run_file_70.FileName], file_name |
mov ebx,run_file_70 |
int 0x40 |
mcall 70,run_file_70 |
pop edi ecx ebx eax |
jmp still |
;??? |
;áç¨âë¢ ¥¬ ä ©« á ¬¥âª ¬¨ |
align 4 |
but_MetLoad: ;áç¨âë¢ ¥¬ ä ©« á ¬¥âª ¬¨ |
but_MetLoad: |
cmp byte[met_fr_opn],0 |
jne .end_f |
copy_path fn_metki,sys_path,file_name,0 |
pushad |
mov byte[met_fr_opn],1 |
copy_path fn_metki,sys_path,file_name,0x0 |
mov eax,70 ;load icon file |
mov [run_file_70.Function], 0 |
mov [run_file_70.Position], 0 |
mov [run_file_70.Flags], 0 |
507,15 → 485,12 |
mov byte[run_file_70+20], 0 |
mov [run_file_70.FileName], file_name |
m2m [run_file_70.Buffer], [bmp_icon] |
mov eax,70 |
mov ebx,run_file_70 |
int 0x40 |
mcall 70,run_file_70 |
cmp ebx,0xffffffff |
je @f |
stdcall [tl_load_mem], TREE_ICON_SYS16_BMP_SIZE,dword[bmp_icon],0,tree2 |
stdcall [tl_cur_beg], tree2 ;? |
stdcall [tl_draw], tree2 ;? |
pop eax |
stdcall [tl_load_mem], tree2,0,[bmp_icon],TREE_ICON_SYS16_BMP_SIZE |
stdcall [tl_cur_beg], tree2 |
stdcall [tl_draw], tree2 |
@@: |
mov byte[file_name],0 ;clear file name |
popad |
522,9 → 497,9 |
.end_f: |
ret |
;??? |
;¤®¡ ¢«¥¨¥ ¬¥âª¨ |
align 4 |
but_MetAdd: ;¤®¡ ¢«¥¨¥ ¬¥âª¨ |
but_MetAdd: |
push eax |
mov eax,dword[bmp_icon] |
m2m dword[eax], dword[map.coord_x] |
532,17 → 507,16 |
m2m word[eax+8], word[map.zoom] |
add eax,12 |
stdcall dword[str_copy], eax,30,dword[edit2.text],30 |
stdcall dword[tl_node_add], dword[bmp_icon], 0, tree2 |
stdcall dword[tl_node_add], tree2, 0, dword[bmp_icon] |
stdcall dword[tl_draw], tree2 |
pop eax |
jmp still |
;??? |
;¯¥à¥å®¤ ª ¢ë¡à ®© ¬¥âª¥ |
align 4 |
fun_goto_met: ;¯¥à¥å®¤ ª ¢ë¡à ®© ¬¥âª¥ |
fun_goto_met: |
push eax |
stdcall dword[tl_node_get_data], tree2 |
pop eax |
cmp eax,0 |
je @f ;ªãàá®à ¥ á⮨⠬¥âª¥ |
m2m dword[map.coord_x],dword[eax] |
563,38 → 537,27 |
ret |
align 4 |
proc tile_init, tile:dword |
push eax edi |
proc tile_init uses eax edi, tile:dword |
mov edi,[tile] |
push dword RGB_TILE_SIZE+300 |
call mem.Alloc |
stdcall mem.Alloc, RGB_TILE_SIZE+300 |
mov tile_rgb_icon,eax |
push dword RGB_TILE_SIZE |
call mem.Alloc |
stdcall mem.Alloc, RGB_TILE_SIZE |
mov tile_drobn_icon,eax |
pop edi eax |
ret |
endp |
align 4 |
proc tile_destroy, tile:dword |
push edi |
proc tile_destroy uses edi, tile:dword |
mov edi,[tile] |
push tile_rgb_icon |
call mem.Free |
push tile_drobn_icon |
call mem.Free |
pop edi |
stdcall mem.Free,tile_rgb_icon |
stdcall mem.Free,tile_drobn_icon |
ret |
endp |
;??? |
align 4 ;§ £à㦠¥â â ©«ë, ¢ ®¯à¥¤¥«¥®© ®¡« á⨠|
proc load_tile, tile:dword |
push eax ebx ecx edi |
;§ £à㦠¥â â ©«ë, ¢ ®¯à¥¤¥«¥®© ®¡« á⨠|
align 4 |
proc load_tile uses eax ebx ecx edi, tile:dword |
mov edi,dword[tile] ;ª®¯¨à㥬 㪠§ ⥫ì áâàãªâãàã â ©« , çâ®-¡ë à ¡®â «¨ ª®áâ âë |
stdcall mem_copy, map,edi, 9 ;ª®¯¨à㥬 ª®®à¤¨ âë ªãàá®à ¢ áâàãªâãàã â ©« |
748,7 → 711,6 |
jmp .zoom |
@@: |
pop edi ecx ebx eax |
ret |
endp |
798,7 → 760,6 |
proc load_new_tile, tile:dword |
pushad |
mov eax,70 ;load icon file |
mov [run_file_70.Function], 0 |
mov [run_file_70.Position], 0 |
mov [run_file_70.Flags], 0 |
806,8 → 767,7 |
m2m [run_file_70.Buffer], [bmp_icon] |
mov byte[run_file_70+20], 0 |
mov [run_file_70.FileName], file_name |
mov ebx,run_file_70 |
int 0x40 |
mcall 70,run_file_70 |
mov edi,[tile] |
; cmp ebx,0xffffffff |
; je .no_load |
844,8 → 804,7 |
;äãªæ¨ï £¥¥à¨àã¥â ç áâì ¯ã⨠ª ä ©«ã ¢ ¢¨¤¥: \z?\?\x?\?\y? |
align 4 |
proc get_tile_path, tile:dword |
push eax ecx edi esi |
proc get_tile_path uses eax ecx edi esi, tile:dword |
mov ecx,300 |
mov edi,txt_tile_path |
@@: |
869,7 → 828,7 |
inc edi |
xor eax,eax |
mov al,byte[esi+8] ;+8 = zoom |
call tl_convert_to_str |
stdcall convert_int_to_str, 300 |
inc edi |
cmp byte[esi+8],9 ;+8 = zoom |
883,7 → 842,7 |
cmp eax,ecx |
jge .out_of_rang ;coord_x ¡®«ìè¥ ¤®¯ãá⨬®£® § ç¥¨ï ¯à¨ § ¤ ®¬ ¬ áèâ ¡¥ |
shr eax,10 |
call tl_convert_to_str |
stdcall convert_int_to_str, 300 |
@@: |
inc edi |
895,7 → 854,7 |
inc edi |
mov eax,[esi] ;coord_x |
call tl_convert_to_str |
stdcall convert_int_to_str, 300 |
@@: |
inc edi |
914,7 → 873,7 |
cmp eax,ecx |
jge .out_of_rang ;coord_y ¡®«ìè¥ ¤®¯ãá⨬®£® § ç¥¨ï ¯à¨ § ¤ ®¬ ¬ áèâ ¡¥ |
shr eax,10 |
call tl_convert_to_str |
stdcall convert_int_to_str, 300 |
@@: |
inc edi |
926,11 → 885,10 |
inc edi |
mov eax,[esi+4] ;coord_y] |
call tl_convert_to_str |
stdcall convert_int_to_str, 300 |
.out_of_rang: |
call get_all_path |
pop esi edi ecx eax |
ret |
endp |
/programs/other/t_edit/t_button.inc |
---|
272,8 → 272,8 |
cmp ted_panel_id,TED_PANEL_SYNTAX |
jne @f |
stdcall dword[tl_node_get_data], tree1 |
pop dword[fn_col_option] |
mov ebx,dword[fn_col_option] |
mov [fn_col_option],eax |
mov ebx,eax |
call open_unpac_synt_file |
cmp ebx,-1 |
je @f |
/programs/other/t_edit/t_data.inc |
---|
/programs/other/t_edit/t_edit.asm |
---|
51,24 → 51,22 |
db 0 |
@@: |
;32 - áâ ¤ àâë© ¤à¥á ¯® ª®â®à®¬ã ¤®«¦¥ ¡ëâì ¡ãä¥à á á¨áâ¥¬ë¬ ¯ã⥬ |
copy_path .path_str,[32],file_name,0x0 |
copy_path .path_str,[32],file_name,0 |
else |
copy_path path,[32],file_name,0x0 ;ä®à¬¨à㥬 ¯®«ë© ¯ãâì ª ä ©«ã ¨§®¡à ¦¥¨ï, ¯®¤à §ã¬¥¢ ¥¬ çâ® ® ¢ ®¤®© ¯ ¯ª¥ á ¯à®£à ¬¬®© |
copy_path path,[32],file_name,0 ;ä®à¬¨à㥬 ¯®«ë© ¯ãâì ª ä ©«ã ¨§®¡à ¦¥¨ï, ¯®¤à §ã¬¥¢ ¥¬ çâ® ® ¢ ®¤®© ¯ ¯ª¥ á ¯à®£à ¬¬®© |
end if |
stdcall mem.Alloc, dword size ;¢ë¤¥«ï¥¬ ¯ ¬ïâì ¤«ï ¨§®¡à ¦¥¨ï |
mov [buf],eax |
mov eax,70 ;70-ï äãªæ¨ï à ¡®â á ä ©« ¬¨ |
mov [run_file_70.Function], 0 |
mov [run_file_70.Position], 0 |
mov [run_file_70.Flags], 0 |
mov [run_file_70.Count], dword size |
m2m [run_file_70.Buffer], [buf] |
m2m [run_file_70.Buffer], eax |
mov byte[run_file_70+20], 0 |
mov [run_file_70.FileName], file_name |
mov ebx,run_file_70 |
int 0x40 ;§ £à㦠¥¬ ä ©« ¨§®¡à ¦¥¨ï |
mcall 70,run_file_70 ;§ £à㦠¥¬ ä ©« ¨§®¡à ¦¥¨ï |
cmp ebx,0xffffffff |
je @f |
;®¯à¥¤¥«ï¥¬ ¢¨¤ ¨§®¡à ¦¥¨ï ¨ ¯¥à¥¢®¤¨¬ ¥£® ¢® ¢à¥¬¥ë© ¡ãä¥à image_data |
210,14 → 208,11 |
mov eax,dword[icon_tl_sys] |
mov dword[tree1.data_img],eax |
;------------------------------------------------------------------------------ |
copy_path fn_syntax_dir,sys_path,file_name,0x0 ;¡¥à¥¬ ¯ãâì ª ¯ ¯ª¥ á ä ©« ¬¨ á¨â ªá¨á |
mov eax,70 |
mov ebx,tree_file_struct |
int 0x40 |
copy_path fn_syntax_dir,sys_path,file_name,0 ;¡¥à¥¬ ¯ãâì ª ¯ ¯ª¥ á ä ©« ¬¨ á¨â ªá¨á |
mcall 70,tree_file_struct |
cmp ebx,-1 |
je .end_dir_init |
mov eax,dir_mem |
add eax,32+4+1+3+4*6+8 |
mov ecx,ebx |
225,8 → 220,7 |
cmp byte[eax],'.' ;䨫ìâà㥬 ä ©«ë á ¨¬¥ ¬¨ '.' ¨ '..' |
je .filter |
;0x10000 ;1*2^16 - £¤¥ 1 ®¬¥à ¨ª®ª¨ á ª¨£®© |
stdcall dword[tl_node_add], eax,0x10000, tree1 |
stdcall dword[tl_node_add], tree1,0x10000,eax |
stdcall dword[tl_cur_next], tree1 |
.filter: |
add eax,304 |
326,12 → 320,9 |
mov edi,tedit0 ;§ 票¥ edi 㦮 ¤«ï EvSize ¨ ted_wnd_t |
call EvSize |
mov eax,13 ;¢¥à娩 ¯àאַ㣮«ì¨ª, ¤«ï ®ç¨á⪨ ¢¥à奩 ¯ ¥«¨ |
xor ebx,ebx |
mov ecx,ted_wnd_t |
mov bx,word[procinfo.client_box.width] |
movzx ebx,word[procinfo.client_box.width] |
inc bx |
int 0x40 |
mcall 13,,ted_wnd_t ;¢¥à娩 ¯àאַ㣮«ì¨ª, ¤«ï ®ç¨á⪨ ¢¥à奩 ¯ ¥«¨ |
call draw_but_toolbar |
361,14 → 352,12 |
;output: |
; ah = symbol |
align 4 |
proc KeyConvertToASCII, table:dword |
push ebx |
proc KeyConvertToASCII uses ebx, table:dword |
mov ebx,dword[table] ;convert scan to ascii |
ror ax,8 |
xor ah,ah |
add bx,ax |
mov ah,byte[ebx] |
pop ebx |
ret |
endp |
541,7 → 530,7 |
@@: |
stdcall [ted_delete], tedit0 |
stdcall dword[tl_data_clear], tree1 |
stdcall [tl_data_clear], tree1 |
mcall -1 ;¢ë室 ¨§ ¯à®£à ¬¬ë |
edit2 edit_box TED_PANEL_WIDTH-1, 0, 20, 0xffffff, 0xff80, 0xff0000, 0xff, 0x4080, 300, buf_find, mouse_dd, 0 |
/programs/other/t_edit/wnd_k_words.inc |
---|
153,7 → 153,7 |
stdcall str_instr, ebx,[edit3.text] |
test al,al |
jnz .end_add |
stdcall dword[tl_node_add], ebx, (0 shl 16), tree3 |
stdcall dword[tl_node_add], tree3, (0 shl 16), ebx |
stdcall dword[tl_cur_next], tree3 |
.end_add: |
add ebx,MAX_COLOR_WORD_LEN+8 ;sizeof.TexColViv |
166,9 → 166,9 |
jne @f |
;ª®¯¨à®¢ âì ¢ ¡ãä¥à |
stdcall [tl_node_get_data],tree3 |
pop esi |
or esi,esi |
or eax,eax |
jz .no_select_0 |
mov esi,eax |
mov edi,[tedit0.buffer] |
mov dword[edi],MAX_COLOR_WORD_LEN |
mov dword[edi+4],0 ;text data |
199,19 → 199,4 |
string1 rb MAX_COLOR_WORD_LEN |
align 4 |
w_scr_t3: |
.size_x dw 16 ;+0 |
rb 2+2+2 |
.btn_high dd 15 ;+8 |
.type dd 1 ;+12 |
.max_area dd 100 ;+16 |
rb 4+4 |
.bckg_col dd 0xeeeeee ;+28 |
.frnt_col dd 0xbbddff ;+32 |
.line_col dd 0 ;+36 |
rb 4+2+2 |
.run_x: |
rb 2+2+2+2+4+4+4+4+4+4 |
.all_redraw dd 0 ;+80 |
.ar_offset dd 1 ;+84 |
w_scr_t3 scrollbar 16,0, 3,0, 15, 100, 0,0, 0xeeeeee, 0xbbddff, 0, 1 |
/programs/other/t_edit_synt/te_syntax.asm |
---|
38,24 → 38,22 |
db 0 |
@@: |
;32 - áâ ¤ àâë© ¤à¥á ¯® ª®â®à®¬ã ¤®«¦¥ ¡ëâì ¡ãä¥à á á¨áâ¥¬ë¬ ¯ã⥬ |
copy_path .path_str,[32],file_name,0x0 |
copy_path .path_str,[32],file_name,0 |
else |
copy_path path,[32],file_name,0x0 ;ä®à¬¨à㥬 ¯®«ë© ¯ãâì ª ä ©«ã ¨§®¡à ¦¥¨ï, ¯®¤à §ã¬¥¢ ¥¬ çâ® ® ¢ ®¤®© ¯ ¯ª¥ á ¯à®£à ¬¬®© |
copy_path path,[32],file_name,0 ;ä®à¬¨à㥬 ¯®«ë© ¯ãâì ª ä ©«ã ¨§®¡à ¦¥¨ï, ¯®¤à §ã¬¥¢ ¥¬ çâ® ® ¢ ®¤®© ¯ ¯ª¥ á ¯à®£à ¬¬®© |
end if |
stdcall mem.Alloc, dword size ;¢ë¤¥«ï¥¬ ¯ ¬ïâì ¤«ï ¨§®¡à ¦¥¨ï |
mov [buf],eax |
mov eax,70 ;70-ï äãªæ¨ï à ¡®â á ä ©« ¬¨ |
mov [run_file_70.Function], 0 |
mov [run_file_70.Position], 0 |
mov [run_file_70.Flags], 0 |
mov [run_file_70.Count], dword size |
m2m [run_file_70.Buffer], [buf] |
mov [run_file_70.Buffer], eax |
mov byte[run_file_70+20], 0 |
mov [run_file_70.FileName], file_name |
mov ebx,run_file_70 |
int 0x40 ;§ £à㦠¥¬ ä ©« ¨§®¡à ¦¥¨ï |
mcall 70,run_file_70 ;§ £à㦠¥¬ ä ©« ¨§®¡à ¦¥¨ï |
cmp ebx,0xffffffff |
je @f |
;®¯à¥¤¥«ï¥¬ ¢¨¤ ¨§®¡à ¦¥¨ï ¨ ¯¥à¥¢®¤¨¬ ¥£® ¢® ¢à¥¬¥ë© ¡ãä¥à image_data |
92,9 → 90,8 |
load_libraries l_libs_start,load_lib_end |
;¯à®¢¥àª ᪮«ìª® ã¤ ç® § £ã§¨« áì è «¨¡ |
mov ebp,lib0 |
cmp dword [ebp+ll_struc_size-4],0 |
;¯à®¢¥àª ᪮«ìª® ã¤ ç® § £ã§¨« áì ¡¨¡«¨®â¥ª |
cmp dword [lib0+ll_struc_size-4],0 |
jz @f |
mcall -1 ;exit not correct |
@@: |
126,11 → 123,7 |
@@: |
cmp byte[eax],'.' ;䨫ìâà㥬 ä ©«ë á ¨¬¥ ¬¨ '.' ¨ '..' |
je .filter |
push dword tree1 |
push dword 0x10000 ;1*2^16 - £¤¥ 1 ®¬¥à ¨ª®ª¨ á ª¨£®© |
push dword eax |
call dword[tl_node_add] |
stdcall dword[tl_node_add],tree1,0x10000,eax ;1*2^16 - £¤¥ 1 ®¬¥à ¨ª®ª¨ á ª¨£®© |
stdcall dword[tl_cur_next],tree1 |
.filter: |
add eax,304 |
330,9 → 323,11 |
align 4 |
but_OpenSyntax: |
push eax |
stdcall [tl_node_get_data],tree1 |
pop dword [fn_col_option] |
mov [fn_col_option],eax |
call InitColText |
pop eax |
ret |
align 4 |
378,7 → 373,7 |
;@@: |
ret |
hed db 'TextEditor syntax file converter 01.07.14',0 ;¯®¤¯¨áì ®ª |
hed db 'TextEditor syntax file converter 10.11.15',0 ;¯®¤¯¨áì ®ª |
conv_tabl rb 128 ; â ¡«¨æ ¤«ï ª®¢¥àâ¨à®¢ ¨ï scan-ª®¤ ¢ ascii-ª®¤ |
txt122 db ' £à. ä ©«',0 |
402,10 → 397,10 |
load_lib_end: |
align 16 |
i_end: |
procinfo process_information |
rb 1024 |
align 16 |
procinfo process_information |
thread: |
rb 1024 |
stacktop: |