back to scratko.xyz
aboutsummaryrefslogtreecommitdiff
path: root/macro.inc
blob: 42539473cfa143f64574361d679828e6ecf2dce4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
%macro	get_arg 0
		add esi, 4
		mov edi, [esi]
%endmacro
%macro	write_value 0
		mov edx, eax		; count
		mov eax, 4		; syscall write
		mov ebx, [f_discr]
		mov ecx, buffer
		int 80h
%endmacro
%macro	new_line 0
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, nlstr
		mov edx, 1
		int 80h
%endmacro
%macro	vertical 0
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, vert_sep
		mov edx, 3
		int 80h
%endmacro
%macro	border 0
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, some_spaces
		mov edx, 2
		int 80h
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, border_sep
		mov edx, 53
		int 80h
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, some_spaces
		mov edx, 2
		int 80h
%endmacro
%macro	horizontal 0
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, beg_sep
		mov edx, 2
		int 80h
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, hor_sep
		mov edx, hor_length
		int 80h
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, end_sep
		mov edx, 2
		int 80h
%endmacro
%macro	placeholder 0
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, some_spaces
		int 80h
%endmacro
%macro	undefined 0
		mov eax, 4
		mov ebx, [f_discr]
		mov ecx, undef_value
		mov edx, 1
		int 80h
%endmacro