// File: KellerMartins[P]PDS2-Pacman/source/game/pacman.cpp
// Function: Pacman::Pacman(int, int)
Pacman::Pacman(int x, int y) : _modelo("assets/models/pacman/idle/player_idle_0.obj", {255,211,0,255}),
							   _andando("assets/models/pacman/walk/player_walk", 6, true),
							   _parado("assets/models/pacman/idle/player_idle", 1, true),
							   _morrendo("assets/models/pacman/die/player_die", 18, false)
{
	_andando.Preload();
	_parado.Preload();
	_morrendo.Preload();
	_modelo.position = (Vector3){(float)x, 0, (float)y};
	_x = x;
	_y = y;
	_direcaoY = 0;
	_direcaoX = 0;
	_vivo = true;
	_vidas = 3;
	_velocidade = PACMAN_SPEED_DEFAULT;
	_timerAnimacao = 0.0;
	_timerScared = 0.0;
	_scaredTime = 6;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x110, %rsp            # imm = 0x110
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0xe0(%rbp)
callq 0xe620
movq -0xe0(%rbp), %rax
leaq 0xd4325(%rip), %rcx     # 0xe7b08
movq %rcx, (%rax)
addq $0x8, %rax
movq %rax, -0xd8(%rbp)
leaq -0x31(%rbp), %rdi
movq %rdi, -0xd0(%rbp)
callq 0x9f60
movq -0xd0(%rbp), %rdx
leaq 0x91c21(%rip), %rsi     # 0xa5430
leaq -0x30(%rbp), %rdi
callq 0x9b20
jmp 0x1381a
movq -0xd8(%rbp), %rdi
movb $-0x1, -0x48(%rbp)
movb $-0x2d, -0x47(%rbp)
movb $0x0, -0x46(%rbp)
movb $-0x1, -0x45(%rbp)
movl -0x48(%rbp), %edx
leaq -0x30(%rbp), %rsi
callq 0x15d20
jmp 0x1383f
leaq -0x30(%rbp), %rdi
callq 0x9530
leaq -0x31(%rbp), %rdi
callq 0x9960
movq -0xe0(%rbp), %rax
movl $0x0, 0x2c8(%rax)
addq $0x2f0, %rax            # imm = 0x2F0
movq %rax, -0xf0(%rbp)
leaq -0x69(%rbp), %rdi
movq %rdi, -0xe8(%rbp)
callq 0x9f60
movq -0xe8(%rbp), %rdx
leaq 0x91bcf(%rip), %rsi     # 0xa545c
leaq -0x68(%rbp), %rdi
callq 0x9b20
jmp 0x13898
movq -0xf0(%rbp), %rdi
leaq -0x68(%rbp), %rsi
movl $0x6, %edx
movl $0x1, %ecx
callq 0x14950
jmp 0x138b4
leaq -0x68(%rbp), %rdi
callq 0x9530
leaq -0x69(%rbp), %rdi
callq 0x9960
movq -0xe0(%rbp), %rax
addq $0x320, %rax            # imm = 0x320
movq %rax, -0x100(%rbp)
leaq -0x91(%rbp), %rdi
movq %rdi, -0xf8(%rbp)
callq 0x9f60
movq -0xf8(%rbp), %rdx
leaq 0x91b87(%rip), %rsi     # 0xa5482
leaq -0x90(%rbp), %rdi
callq 0x9b20
jmp 0x13909
movq -0x100(%rbp), %rdi
leaq -0x90(%rbp), %rsi
movl $0x1, %ecx
movl %ecx, %edx
callq 0x14950
jmp 0x13925
leaq -0x90(%rbp), %rdi
callq 0x9530
leaq -0x91(%rbp), %rdi
callq 0x9960
movq -0xe0(%rbp), %rax
addq $0x350, %rax            # imm = 0x350
movq %rax, -0x110(%rbp)
leaq -0xb9(%rbp), %rdi
movq %rdi, -0x108(%rbp)
callq 0x9f60
movq -0x108(%rbp), %rdx
leaq 0x91b36(%rip), %rsi     # 0xa54a8
leaq -0xb8(%rbp), %rdi
callq 0x9b20
jmp 0x13980
movq -0x110(%rbp), %rdi
leaq -0xb8(%rbp), %rsi
movl $0x12, %edx
xorl %ecx, %ecx
callq 0x14950
jmp 0x1399c
leaq -0xb8(%rbp), %rdi
callq 0x9530
leaq -0xb9(%rbp), %rdi
callq 0x9960
movq -0xe0(%rbp), %rdi
addq $0x2f0, %rdi            # imm = 0x2F0
callq 0x149d0
jmp 0x139c9
movq -0xe0(%rbp), %rdi
addq $0x320, %rdi            # imm = 0x320
callq 0x149d0
jmp 0x139de
movq -0xe0(%rbp), %rdi
addq $0x350, %rdi            # imm = 0x350
callq 0x149d0
jmp 0x139f3
movq -0xe0(%rbp), %rax
cvtsi2ssl -0xc(%rbp), %xmm0
movss %xmm0, -0xc8(%rbp)
xorps %xmm0, %xmm0
movss %xmm0, -0xc4(%rbp)
cvtsi2ssl -0x10(%rbp), %xmm0
movss %xmm0, -0xc0(%rbp)
movq -0xc8(%rbp), %rcx
movq %rcx, 0x18(%rax)
movl -0xc0(%rbp), %ecx
movl %ecx, 0x20(%rax)
cvtsi2ssl -0xc(%rbp), %xmm0
movss %xmm0, 0x2d4(%rax)
cvtsi2ssl -0x10(%rbp), %xmm0
movss %xmm0, 0x2d8(%rax)
movl $0x0, 0x2cc(%rax)
movl $0x0, 0x2d0(%rax)
movb $0x1, 0x2c0(%rax)
movl $0x3, 0x2c4(%rax)
movss 0x9197e(%rip), %xmm0    # 0xa53f8
movss %xmm0, 0x2dc(%rax)
xorps %xmm0, %xmm0
movss %xmm0, 0x2e0(%rax)
xorps %xmm0, %xmm0
movss %xmm0, 0x2e4(%rax)
movl $0x6, 0x2e8(%rax)
addq $0x110, %rsp            # imm = 0x110
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13ace
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x9530
leaq -0x31(%rbp), %rdi
callq 0x9960
jmp 0x13bb1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13aff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x9530
leaq -0x69(%rbp), %rdi
callq 0x9960
jmp 0x13ba5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13b33
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x90(%rbp), %rdi
callq 0x9530
leaq -0x91(%rbp), %rdi
callq 0x9960
jmp 0x13b99
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
jmp 0x13b67
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0xb8(%rbp), %rdi
callq 0x9530
leaq -0xb9(%rbp), %rdi
callq 0x9960
jmp 0x13b8d
movq -0x110(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
callq 0x14830
movq -0x100(%rbp), %rdi
callq 0x14830
movq -0xf0(%rbp), %rdi
callq 0x14830
movq -0xd8(%rbp), %rdi
callq 0x15e30
movq -0xe0(%rbp), %rdi
callq 0xe660
movq -0x40(%rbp), %rdi
callq 0x9f50
nopw %cs:(%rax,%rax)