// File: tewalds[P]morat/hex/agentpns.cpp
// Function: Morat::Hex::AgentPNS::Node::from_s(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
bool AgentPNS::Node::from_s(std::string s) {
	auto dict = parse_dict(s, ", ", " ");

	if(dict.size() == 6){
		move = Move(dict["move"]);
		phi = from_str<uint32_t>(dict["phi"]);
		delta = from_str<uint32_t>(dict["delta"]);
		work = from_str<uint64_t>(dict["work"]);
		// ignore children
		return true;
	}
	return false;
}

// Assembly:
subq $0x1c8, %rsp            # imm = 0x1C8
movq %rsi, 0x60(%rsp)
movq %rdi, 0x1b8(%rsp)
movq %rsi, 0x1b0(%rsp)
movq 0x1b8(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x157(%rsp), %rdi
movq %rdi, 0x70(%rsp)
callq 0x5770
movq 0x70(%rsp), %rdx
leaq 0x212ee(%rip), %rsi     # 0x4e0d5
leaq 0x158(%rsp), %rdi
callq 0x5590
jmp 0x2cdf6
leaq 0x11f(%rsp), %rdi
movq %rdi, 0x58(%rsp)
callq 0x5770
movq 0x58(%rsp), %rdx
leaq 0x23ac3(%rip), %rsi     # 0x508d7
leaq 0x120(%rsp), %rdi
callq 0x5590
jmp 0x2ce23
movq 0x60(%rsp), %rsi
leaq 0x178(%rsp), %rdi
leaq 0x158(%rsp), %rdx
leaq 0x120(%rsp), %rcx
callq 0x48db0
jmp 0x2ce47
leaq 0x120(%rsp), %rdi
callq 0x5260
leaq 0x11f(%rsp), %rdi
callq 0x5450
leaq 0x158(%rsp), %rdi
callq 0x5260
leaq 0x157(%rsp), %rdi
callq 0x5450
leaq 0x178(%rsp), %rdi
callq 0x1a5a0
cmpq $0x6, %rax
jne 0x2d23a
leaq 0xf7(%rsp), %rdi
movq %rdi, 0x50(%rsp)
callq 0x5770
movq 0x50(%rsp), %rdx
leaq 0x236e2(%rip), %rsi     # 0x50592
leaq 0xf8(%rsp), %rdi
callq 0x5590
jmp 0x2cebf
leaq 0x178(%rsp), %rdi
leaq 0xf8(%rsp), %rsi
callq 0x1a5b0
movq %rax, 0x48(%rsp)
jmp 0x2cedb
movq 0x48(%rsp), %rsi
leaq 0x11d(%rsp), %rdi
callq 0x1a5e0
jmp 0x2ceef
movq 0x68(%rsp), %rax
movw 0x11d(%rsp), %cx
movw %cx, 0x12(%rax)
leaq 0xf8(%rsp), %rdi
callq 0x5260
leaq 0xf7(%rsp), %rdi
callq 0x5450
leaq 0xcf(%rsp), %rdi
movq %rdi, 0x40(%rsp)
callq 0x5770
movq 0x40(%rsp), %rdx
leaq 0x21902(%rip), %rsi     # 0x4e83a
leaq 0xd0(%rsp), %rdi
callq 0x5590
jmp 0x2cf47
leaq 0x178(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
callq 0x1a5b0
movq %rax, 0x38(%rsp)
jmp 0x2cf63
movq 0x38(%rsp), %rdi
callq 0x2fff0
movl %eax, 0x34(%rsp)
jmp 0x2cf73
movq 0x68(%rsp), %rax
movl 0x34(%rsp), %ecx
movl %ecx, (%rax)
leaq 0xd0(%rsp), %rdi
callq 0x5260
leaq 0xcf(%rsp), %rdi
callq 0x5450
leaq 0xa7(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x5770
movq 0x28(%rsp), %rdx
leaq 0x21888(%rip), %rsi     # 0x4e83e
leaq 0xa8(%rsp), %rdi
callq 0x5590
jmp 0x2cfc5
leaq 0x178(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0x1a5b0
movq %rax, 0x20(%rsp)
jmp 0x2cfe1
movq 0x20(%rsp), %rdi
callq 0x2fff0
movl %eax, 0x1c(%rsp)
jmp 0x2cff1
movq 0x68(%rsp), %rax
movl 0x1c(%rsp), %ecx
movl %ecx, 0x4(%rax)
leaq 0xa8(%rsp), %rdi
callq 0x5260
leaq 0xa7(%rsp), %rdi
callq 0x5450
leaq 0x7f(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x5770
movq 0x10(%rsp), %rdx
leaq 0x21812(%rip), %rsi     # 0x4e844
leaq 0x80(%rsp), %rdi
callq 0x5590
jmp 0x2d041
leaq 0x178(%rsp), %rdi
leaq 0x80(%rsp), %rsi
callq 0x1a5b0
movq %rax, 0x8(%rsp)
jmp 0x2d05d
movq 0x8(%rsp), %rdi
callq 0x1dc80
movq %rax, (%rsp)
jmp 0x2d06d
movq 0x68(%rsp), %rax
movq (%rsp), %rcx
movq %rcx, 0x8(%rax)
leaq 0x80(%rsp), %rdi
callq 0x5260
leaq 0x7f(%rsp), %rdi
callq 0x5450
movb $0x1, 0x1c7(%rsp)
movl $0x1, 0x78(%rsp)
jmp 0x2d24a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x2d10d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x2d0f3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0x120(%rsp), %rdi
callq 0x5260
leaq 0x11f(%rsp), %rdi
callq 0x5450
leaq 0x158(%rsp), %rdi
callq 0x5260
leaq 0x157(%rsp), %rdi
callq 0x5450
jmp 0x2d275
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x2d156
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0xf8(%rsp), %rdi
callq 0x5260
leaq 0xf7(%rsp), %rdi
callq 0x5450
jmp 0x2d268
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x2d19f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0xd0(%rsp), %rdi
callq 0x5260
leaq 0xcf(%rsp), %rdi
callq 0x5450
jmp 0x2d268
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x2d1e8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0xa8(%rsp), %rdi
callq 0x5260
leaq 0xa7(%rsp), %rdi
callq 0x5450
jmp 0x2d268
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
jmp 0x2d22e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x148(%rsp)
movl %eax, 0x144(%rsp)
leaq 0x80(%rsp), %rdi
callq 0x5260
leaq 0x7f(%rsp), %rdi
callq 0x5450
jmp 0x2d268
movb $0x0, 0x1c7(%rsp)
movl $0x1, 0x78(%rsp)
leaq 0x178(%rsp), %rdi
callq 0x1a890
movb 0x1c7(%rsp), %al
andb $0x1, %al
addq $0x1c8, %rsp            # imm = 0x1C8
retq
leaq 0x178(%rsp), %rdi
callq 0x1a890
movq 0x148(%rsp), %rdi
callq 0x5760
nopw %cs:(%rax,%rax)