// File: /workspace/github_cpp_makefile_star2_O1/patxitron[P]BattleyeRconToolLinux/a3s.cpp
// Function: patxi::a3s::a3s(boost::asio::io_context&, unsigned short, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::function<void (char const*, unsigned long)>, std::function<void (bool)>)
a3s::a3s(boost::asio::io_service& io_service, uint16_t port
        ,std::string const& addr, on_data_func on_data, on_login_func on_login)
		:loged_in_(false)
		,listening_(false)
		,sequence_(0)
		,on_data_(on_data)
		,on_login_(on_login)
		,socket_(io_service, udp::endpoint(udp::v4(), 0))
		,input_(io_service, ::dup(STDIN_FILENO))
		,console_data_(MAX_COMMAND_LENGTH)
{
	stringstream str_port;
	str_port << port;
	udp::resolver resolver(io_service);
	endpoint_ = *resolver.resolve({udp::v4(), addr, str_port.str()});
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x298, %rsp            # imm = 0x298
movq %r9, %r13
movq %rcx, %r14
movl %edx, %r12d
movq %rsi, %r15
movq %rdi, %rbx
movw $0x0, (%rdi)
movb $0x0, 0x2(%rdi)
addq $0x8, %rdi
movq %rdi, 0x10(%rsp)
movq %r8, %rsi
callq 0x84ae
leaq 0x28(%rbx), %rbp
movq %rbp, %rdi
movq %r13, %rsi
callq 0x8514
leaq 0x48(%rbx), %rdi
xorps %xmm0, %xmm0
leaq 0x110(%rsp), %rdx
movaps %xmm0, (%rdx)
movups %xmm0, 0xc(%rdx)
movq $0x2, (%rdx)
movq %rdi, 0x18(%rsp)
movq %r15, %rsi
xorl %ecx, %ecx
movq %rbp, 0x8(%rsp)
callq 0xb8e4
leaq 0x98(%rbx), %r13
xorl %edi, %edi
callq 0x6530
leaq 0x110(%rsp), %rdx
movl %eax, (%rdx)
movq %r13, %rdi
movq %r15, %rsi
xorl %ecx, %ecx
callq 0xf5ba
leaq 0xe0(%rbx), %rbp
leaq 0x110(%rsp), %rdx
movl $0x100, %esi            # imm = 0x100
movq %rbp, %rdi
callq 0x857a
xorps %xmm0, %xmm0
movups %xmm0, 0x140(%rbx)
movups %xmm0, 0x14c(%rbx)
movq $0x2, 0x140(%rbx)
leaq 0x110(%rsp), %rdi
callq 0x6260
leaq 0x120(%rsp), %rdi
movzwl %r12w, %esi
callq 0x6240
leaq 0xc8(%rsp), %rdi
movq %r15, %rsi
xorl %edx, %edx
callq 0xf822
movl $0x2, 0x4(%rsp)
leaq 0x128(%rsp), %rsi
leaq 0x20(%rsp), %rdi
callq 0x6570
leaq 0x58(%rsp), %rdi
leaq 0x4(%rsp), %rsi
leaq 0x20(%rsp), %rcx
movq %r14, %rdx
movl $0x20, %r8d
callq 0x870e
leaq 0x40(%rsp), %rdi
leaq 0xc8(%rsp), %rsi
leaq 0x58(%rsp), %rdx
callq 0x864c
addq $0x140, %rbx            # imm = 0x140
movq 0x40(%rsp), %rax
movq 0x50(%rsp), %rcx
movq (%rax), %rax
leaq (%rcx,%rcx,2), %rcx
shlq $0x5, %rcx
movups (%rax,%rcx), %xmm0
movq 0x10(%rax,%rcx), %rdx
movl 0x18(%rax,%rcx), %eax
movl %eax, 0x18(%rbx)
movq %rdx, 0x10(%rbx)
movups %xmm0, (%rbx)
movq 0x48(%rsp), %rdi
testq %rdi, %rdi
je 0x6a93
callq 0x8cbc
leaq 0xb8(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6ab4
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x6390
leaq 0x98(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6ad5
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x6390
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6af0
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6390
leaq 0xc8(%rsp), %rdi
callq 0xff1e
movq 0x14484(%rip), %rsi     # 0x1af88
leaq 0x110(%rsp), %rdi
callq 0x62a0
leaq 0x190(%rsp), %rdi
callq 0x6120
addq $0x298, %rsp            # imm = 0x298
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
leaq 0x58(%rsp), %rdi
callq 0x87c8
jmp 0x6b42
movq %rax, %r14
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x6b62
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6390
jmp 0x6b62
movq %rax, %r14
leaq 0xc8(%rsp), %rdi
callq 0xff1e
jmp 0x6b76
jmp 0x6b73
movq %rax, %r14
movq 0x1440b(%rip), %rsi     # 0x1af88
leaq 0x110(%rsp), %rdi
callq 0x62a0
leaq 0x190(%rsp), %rdi
callq 0x6120
movq %rbp, %rdi
callq 0x8800
movq %r13, %rdi
callq 0x949c
movq 0x18(%rsp), %rdi
callq 0xbb9c
movq 0x38(%rbx), %rax
testq %rax, %rax
je 0x6be2
movq 0x8(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x6be2
movq %rax, %r14
jmp 0x6b97
movq %rax, %r14
jmp 0x6b9f
movq %rax, %r14
jmp 0x6ba7
movq %rax, %r14
jmp 0x6bb1
movq %rax, %r14
movq 0x18(%rbx), %rax
testq %rax, %rax
je 0x6bfa
movq 0x10(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq %r14, %rdi
callq 0x65e0
jmp 0x6c04
movq %rax, %rdi
callq 0x83b5