Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- .text:08048694 UseSkill proc near ; CODE XREF: main:loc_804868D↑p
- .text:08048694
- .text:08048694 var_10 = dword ptr -10h
- .text:08048694 var_C = dword ptr -0Ch
- .text:08048694 var_4 = dword ptr -4
- .text:08048694
- .text:08048694 push ebp
- .text:08048695 mov ebp, esp
- .text:08048697 push ebx
- .text:08048698 sub esp, 14h
- .text:0804869B sub esp, 0Ch
- .text:0804869E push offset format ; "User Skill:\n 1. No\n 2. Kick\n 3. Punc"...
- .text:080486A3 call _printf
- .text:080486A8 add esp, 10h
- .text:080486AB sub esp, 0Ch
- .text:080486AE push 5
- .text:080486B0 call read_int
- .text:080486B5 add esp, 10h
- .text:080486B8 cdq
- .text:080486B9 mov [ebp+var_10], eax
- .text:080486BC mov [ebp+var_C], edx
- .text:080486BF mov eax, [ebp+var_10]
- .text:080486C2 xor eax, 1
- .text:080486C5 or eax, [ebp+var_C]
- .text:080486C8 test eax, eax
- .text:080486CA jnz short loc_80486E1
- .text:080486CC sub esp, 0Ch
- .text:080486CF push offset s ; "OKAY!"
- .text:080486D4 call _puts
- .text:080486D9 add esp, 10h
- .text:080486DC jmp loc_80487BD
- .text:080486E1 ; ---------------------------------------------------------------------------
- .text:080486E1
- .text:080486E1 loc_80486E1: ; CODE XREF: UseSkill+36↑j
- .text:080486E1 mov eax, [ebp+var_C]
- .text:080486E4 imul edx, eax, 0F4523F22h
- .text:080486EA mov eax, [ebp+var_10]
- .text:080486ED imul eax, -1
- .text:080486F0 lea ecx, [edx+eax]
- .text:080486F3 mov eax, 0F4523F22h
- .text:080486F8 mul [ebp+var_10]
- .text:080486FB add ecx, edx
- .text:080486FD mov edx, ecx
- .text:080486FF mov ecx, ds:MANA
- .text:08048705 mov ebx, ds:dword_804B064
- .text:0804870B add eax, ecx
- .text:0804870D adc edx, ebx
- .text:0804870F test edx, edx
- .text:08048711 js loc_80487AD
- .text:08048717 test edx, edx
- .text:08048719 jg short loc_8048724
- .text:0804871B cmp eax, 0
- .text:0804871E jbe loc_80487AD
- .text:08048724
- .text:08048724 loc_8048724: ; CODE XREF: UseSkill+85↑j
- .text:08048724 sub esp, 0Ch
- .text:08048727 push offset aSkillAttacked ; "Skill Attacked!"
- .text:0804872C call _puts
- .text:08048731 add esp, 10h
- .text:08048734 mov eax, [ebp+var_C]
- .text:08048737 imul edx, eax, 0F4523F22h
- .text:0804873D mov eax, [ebp+var_10]
- .text:08048740 imul eax, -1
- .text:08048743 lea ecx, [edx+eax]
- .text:08048746 mov eax, 0F4523F22h
- .text:0804874B mul [ebp+var_10]
- .text:0804874E add ecx, edx
- .text:08048750 mov edx, ecx
- .text:08048752 mov ecx, BOSSHP
- .text:08048758 mov ebx, dword_804B054
- .text:0804875E add eax, ecx
- .text:08048760 adc edx, ebx
- .text:08048762 mov BOSSHP, eax
- .text:08048767 mov dword_804B054, edx
- .text:0804876D mov eax, [ebp+var_C]
- .text:08048770 imul edx, eax, 0F4523F22h
- .text:08048776 mov eax, [ebp+var_10]
- .text:08048779 imul eax, -1
- .text:0804877C lea ecx, [edx+eax]
- .text:0804877F mov eax, 0F4523F22h
- .text:08048784 mul [ebp+var_10]
- .text:08048787 add ecx, edx
- .text:08048789 mov edx, ecx
- .text:0804878B mov ecx, ds:MANA
- .text:08048791 mov ebx, ds:dword_804B064
- .text:08048797 add eax, ecx
- .text:08048799 adc edx, ebx
- .text:0804879B mov ds:MANA, eax
- .text:080487A0 mov ds:dword_804B064, edx
- .text:080487A6 call CheckHP
- .text:080487AB jmp short loc_80487BD
- .text:080487AD ; ---------------------------------------------------------------------------
- .text:080487AD
- .text:080487AD loc_80487AD: ; CODE XREF: UseSkill+7D↑j
- .text:080487AD ; UseSkill+8A↑j
- .text:080487AD sub esp, 0Ch
- .text:080487B0 push offset aNotEnoughMana ; "Not enough mana!"
- .text:080487B5 call _printf
- .text:080487BA add esp, 10h
- .text:080487BD
- .text:080487BD loc_80487BD: ; CODE XREF: UseSkill+48↑j
- .text:080487BD ; UseSkill+117↑j
- .text:080487BD mov ebx, [ebp+var_4]
- .text:080487C0 leave
- .text:080487C1 retn
Add Comment
Please, Sign In to add comment