// File: /workspace/github_cpp_makefile_star2_O2/lotuskip[P]yuxtapa/client/settings.cpp
// Function: Config::read_config(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
void Config::read_config(const string &servername)
{
	// figure out config  directory of current user:
	string s;
	confdir_str = s = get_conf_dir();
	s += "client.conf";

	ifstream file(s.c_str());
	string keyw;
	char ch;
	string first_server = "";
	while(file)
	{
		// This is very crude parsing; if the file is not right it probably is read all wrong
		getline(file, s);
		if(s.empty() || s[0] == '#')
			continue;
		stringstream ss(s, ios_base::in);
		ss >> keyw;
		if(keyw == "nick")
		{
			keyw = s;
			keyw.erase(0, keyw.find(' '));
			trim_str(keyw);
			if(!keyw.empty())
			{
				if(num_syms(keyw) > MAX_NICK_LEN)
				{
					del_syms(keyw, MAX_NICK_LEN);
					cerr << "Warning: nick given in config file is too long.";
				}
				nick = keyw;
				continue;
			}
		}
		else if(keyw == "server")
		{
			ss >> keyw; // server name
			string tmp = "";
			ss >> tmp; // server IP
			if(!keyw.empty() && !tmp.empty())
			{
				/* if a server was given, we only match against it;
				 * otherwise pick first server */
				if(first_server.empty())
					first_server = tmp;
				if(serverip.empty() && servername == keyw)
					serverip = tmp;
				continue;
			}
		}
		else if(keyw == "key")
		{
			keyw = ss.str();
			if(keyw.size() < 6) // must be at least "key XY"
			{
				cerr << "Faulty line in config: \'" << keyw << "\'." << endl;
				continue;
			}
			keyw = keyw.substr(4); // drop "key "; leaving keyw.size() >= 2
			// Check for ^[x]: ("^XA", for instance)
			if(keyw[0] == '^' && keyw.size() > 2)
			{
				if(!isalpha(keyw[1]))
				{
					cerr << str_ctrl_error << endl;
					continue;
				} // else:
				ch = toupper(keyw[1]) - CTRL_ADD;
				keyw.erase(0,1); // remove '^', forcing the replacement to be at index 1
			}
			else
				ch = keyw[0];
			e_Key_binding kb = convert_key(ch);
			if(kb != MAX_KEY_BINDING)
			{
				// The replacement could also be ^[x]:
				if(keyw[1] == '^' && keyw.size() > 2)
				{
					if(!isalpha(keyw[2]))
					{
						cerr << str_ctrl_error << endl;
						continue;
					} // else:
					ch = toupper(keyw[2]) - CTRL_ADD;
				}
				else if((ch = keyw[1]) == '?')
				{
					// '?' is reserved for help view!
					cerr << "Config error: key '?' is reserved!" << endl;
					continue;
				}
				key_bindings[kb] = ch;
			}
			else
			{
				fill_kph(ch);
				cerr << "Unknown original keybinding \'"
					<< keyplaceholder << "\' in config." << endl;
			}
			continue;
		}
		else if(keyw == "anim")
		{
			keyw = s;
			keyw.erase(0, keyw.find(' '));
			if(!keyw.empty())
				keyw.erase(0, 1);
			if(num_syms(keyw) < MIN_ANIM_LEN || num_syms(keyw) > MAX_ANIM_LEN)
				cerr << "Warning, an animation of invalid length ignored." << endl;
			else
				anim = keyw;
			continue;
		}
		else if(keyw == "alias")
		{
			ss >> keyw; // alias string
			string tmps = s;
			tmps.erase(0, tmps.find(' ', 6)); // get rid of "alias [key]"
			if(!tmps.empty())
			{
				tmps.erase(0,1);
				aliases[keyw] = tmps;
				continue;
			}
		}
		else if(keyw == "qshout")
		{
			short sh;
			ss >> sh;
			if(sh < 1 || sh > MAX_QUICK_SHOUTS)
				cerr << "Invalid quick shout index: " << sh << endl;
			else
			{
				qshout[sh-1] = ss.str();
				qshout[sh-1].erase(0, 8 + int(sh > 9)); // 8 if sh is single-digit, 9 if not
				if(qshout[sh-1].empty())
				{
					cerr << "Config warning: empty \'qshout " << sh << "\'?" << endl;
					continue;
				}
				qshout[sh-1].erase(0,1); // remove ' '
				if(num_syms(qshout[sh-1]) > MSG_WIN_X-3) // -3 is for the "!: " prefix
				{
					cerr << "Quick shout " << sh << " is too long!" << endl;
					del_syms(qshout[sh-1], MSG_WIN_X-3);
				}
			}
			continue;
		}
		else if(keyw == "ouch")
		{
			ouch_str = ss.str();
			if(ouch_str.size() < 5)
			{
				cerr << "Config warning: \'ouch\' without content?" << endl;
				continue;
			}
			ouch_str.erase(0, 5); // erase "ouch "
			if(num_syms(ouch_str) >= MSG_WIN_X)
			{
				cerr << "The ouch string in the config is too long!" << endl;
				del_syms(ouch_str, MSG_WIN_X);
			}
			continue;
		}
		else if(keyw == "ouch_on")
		{
			ss >> ouching;
			continue;
		}
		else if(keyw == "stored_chat_msgs")
		{
			ss >> stored_msgs;
			if(stored_msgs < 0 || stored_msgs > 1000)
			{
				cerr << "Warning: invalid stored_chat_msgs setting." << endl;
				stored_msgs = DEFAULT_STORED_MSGS;
			}
			continue;
		}
		else if(keyw == "actperturn")
		{
			ss >> actperturn;
			continue;
		}
		// if here, not all is okay:
		cerr << "Warning, could not parse the following line in config file:"
			<< endl << "\"" << s << "\"" << endl;
	}
	file.close();

	// everything extracted (or failed altogether), check:
	if(serverip.empty()) // no match for desired server
	{
		if(!servername.empty()) // some server *was* requested
			serverip = servername; // try to connect to it "as-is"
		else if(first_server.empty()) // no server given in file, either?
		{
			cerr << "Warning, no server given in config, defaulting to localhost!" << endl;
			serverip = "127.0.0.1:12360";
		}
		else // No server requested; use first one found in config
			serverip = first_server;
	}
	// check for key-binding conflicts:
	keyw = key_bindings; // tmp copy
	sort(keyw.begin(), keyw.end());
	unique(keyw.begin(), keyw.end());
	if(keyw.size() < key_bindings.size())
	{
		cerr << "Config resulted in key binding conflicts; reverting to original keys." << endl;
		key_bindings = default_key_bds;
	}
	// check that ouching is off if ouch string is empty:
	if(ouch_str.empty() && ouching)
	{
		ouching = false;
		cerr << "Config error: the ouch feature requires you to define a non-empty message!" << endl;
	}
	// Read stored messages to prev_strs if file exists
	ifstream cmfile((confdir_str + "chatmemory").c_str());
	if(cmfile)
	{
		while(getline(cmfile, s) && !s.empty())
			prev_strs.push_back(s);
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x4a8, %rsp            # imm = 0x4A8
movq %rdi, %r12
leaq -0x88(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq -0x4d0(%rbp), %rdi
callq 0xd1d4
leaq -0x98(%rbp), %rdi
leaq -0x4d0(%rbp), %rsi
callq 0x4480
leaq 0xd85c(%rip), %rdi      # 0x18540
movq %rax, %rsi
callq 0x4220
leaq -0x4d0(%rbp), %rdi
callq 0x4748
leaq 0x3b81(%rip), %rsi      # 0xe880
leaq -0x98(%rbp), %rdi
callq 0x46c0
movq -0x98(%rbp), %rsi
leaq -0x4d0(%rbp), %rdi
pushq $0x8
popq %rdx
callq 0x4680
leaq -0x60(%rbp), %rax
movq %rax, -0x10(%rax)
andq $0x0, -0x8(%rax)
movb $0x0, (%rax)
leaq 0x3751(%rip), %rsi      # 0xe489
leaq -0xc0(%rbp), %rdi
leaq -0x2c8(%rbp), %rdx
callq 0x69bc
leaq -0x4d0(%rbp), %r14
leaq -0x2c8(%rbp), %r15
leaq -0x70(%rbp), %rbx
movq -0x4d0(%rbp), %rax
movq -0x18(%rax), %rax
testb $0x5, -0x4b0(%rbp,%rax)
jne 0xb57f
movq %r14, %rdi
leaq -0x98(%rbp), %rsi
callq 0x4090
cmpq $0x0, -0x90(%rbp)
je 0xad5d
movq -0x98(%rbp), %rax
cmpb $0x23, (%rax)
je 0xad5d
movq %r15, %rdi
leaq -0x98(%rbp), %rsi
pushq $0x8
popq %rdx
callq 0x45e0
movq %r15, %r13
movq %r15, %rdi
movq %rbx, %rsi
callq 0x44b0
movq %rbx, %rdi
leaq 0x3ac7(%rip), %rsi      # 0xe88c
callq 0x795b
testb %al, %al
je 0xae55
movq %rbx, %rdi
leaq -0x98(%rbp), %rsi
callq 0x4220
movq %rbx, %rdi
pushq $0x20
popq %rsi
xorl %edx, %edx
callq 0x4500
movq %rbx, %rdi
xorl %esi, %esi
movq %rax, %rdx
callq 0x40e0
movq %rbx, %rdi
callq 0xd4c2
cmpq $0x0, -0x68(%rbp)
je 0xb0a8
movq %rbx, %rdi
callq 0xd028
leaq 0xd4fb(%rip), %rdi      # 0x18318
cmpw $0xb, %ax
jl 0xae48
movq %rbx, %rdi
pushq $0xa
popq %rsi
callq 0xd0da
movq 0xb1bb(%rip), %rdi      # 0x15ff0
leaq 0x3a55(%rip), %rsi      # 0xe891
callq 0x4390
leaq 0xd4d0(%rip), %rdi      # 0x18318
movq %rbx, %rsi
callq 0x4220
jmp 0xb0f8
movq %rbx, %rdi
leaq 0x3a62(%rip), %rsi      # 0xe8c1
callq 0x795b
testb %al, %al
je 0xaeff
movq %r13, %rdi
movq %rbx, %rsi
callq 0x44b0
leaq -0x50(%rbp), %r15
movq %r15, %rdi
leaq 0x3604(%rip), %rsi      # 0xe489
leaq -0x2a(%rbp), %rdx
callq 0x69bc
movq %r13, %rdi
movq %r15, %rsi
callq 0x44b0
cmpq $0x0, -0x68(%rbp)
je 0xb09f
cmpq $0x0, -0x48(%rbp)
je 0xb09f
cmpq $0x0, -0xb8(%rbp)
jne 0xaec9
leaq -0xc0(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x4220
cmpq $0x0, 0xd4af(%rip)      # 0x18380
jne 0xb094
movq %r12, %rdi
movq %rbx, %rsi
callq 0x84f3
testb %al, %al
je 0xb094
leaq 0xd487(%rip), %rdi      # 0x18378
leaq -0x50(%rbp), %rsi
callq 0x4220
jmp 0xb094
movq %rbx, %rdi
leaq 0x39bf(%rip), %rsi      # 0xe8c8
callq 0x795b
testb %al, %al
je 0xaf6d
leaq -0x50(%rbp), %r15
movq %r15, %rdi
leaq -0x2b0(%rbp), %rsi
callq 0x45d0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4480
movq %r15, %rdi
callq 0x4748
cmpq $0x5, -0x68(%rbp)
ja 0xb108
movq 0xb0a6(%rip), %rdi      # 0x15ff0
leaq 0x397b(%rip), %rsi      # 0xe8cc
callq 0x4390
movq %rax, %rdi
movq %rbx, %rsi
callq 0x4340
leaq 0x397d(%rip), %rsi      # 0xe8e5
jmp 0xb0e8
movq %rbx, %rdi
leaq 0x39bf(%rip), %rsi      # 0xe936
callq 0x795b
testb %al, %al
je 0xb011
movq %rbx, %rdi
leaq -0x98(%rbp), %rsi
callq 0x4220
movq %rbx, %rdi
pushq $0x20
popq %rsi
xorl %edx, %edx
callq 0x4500
movq %rbx, %rdi
xorl %esi, %esi
movq %rax, %rdx
callq 0x40e0
cmpq $0x0, -0x68(%rbp)
je 0xafc1
movq %rbx, %rdi
xorl %esi, %esi
pushq $0x1
popq %rdx
callq 0x40e0
movq %rbx, %rdi
callq 0xd028
movl %eax, %ecx
movq 0xb01e(%rip), %rax      # 0x15ff0
leaq 0x3962(%rip), %rsi      # 0xe93b
cmpw $0x2, %cx
jl 0xb0e8
movq %rbx, %rdi
callq 0xd028
movl %eax, %ecx
leaq 0xd344(%rip), %rdi      # 0x18338
movq 0xaff5(%rip), %rax      # 0x15ff0
leaq 0x3939(%rip), %rsi      # 0xe93b
cmpw $0xf, %cx
jle 0xae48
jmp 0xb0e8
movq %rbx, %rdi
leaq 0x3951(%rip), %rsi      # 0xe96c
callq 0x795b
testb %al, %al
movq %r13, %r15
je 0xb1ca
movq %r15, %rdi
movq %rbx, %rsi
callq 0x44b0
leaq -0x50(%rbp), %r15
movq %r15, %rdi
leaq -0x98(%rbp), %rsi
callq 0x4520
movq %r15, %rdi
pushq $0x20
popq %rsi
pushq $0x6
popq %rdx
callq 0x4500
movq %r15, %rdi
xorl %esi, %esi
movq %rax, %rdx
callq 0x40e0
cmpq $0x0, -0x48(%rbp)
je 0xb09f
leaq -0x50(%rbp), %rdi
xorl %esi, %esi
pushq $0x1
popq %rdx
callq 0x40e0
leaq 0xd4e0(%rip), %rdi      # 0x18560
movq %rbx, %rsi
callq 0xbae0
movq %rax, %rdi
leaq -0x50(%rbp), %rsi
callq 0x4220
leaq -0x50(%rbp), %rdi
callq 0x4748
jmp 0xb0f8
leaq -0x50(%rbp), %rdi
callq 0x4748
movq 0xaf41(%rip), %rdi      # 0x15ff0
leaq 0x39b5(%rip), %rsi      # 0xea6b
callq 0x4390
movq %rax, %rdi
callq 0x41f0
movq %rax, %rdi
leaq 0x39da(%rip), %rsi      # 0xeaa7
callq 0x4390
movq %rax, %rdi
leaq -0x98(%rbp), %rsi
callq 0x4340
leaq 0x39bf(%rip), %rsi      # 0xeaa7
movq %rax, %rdi
callq 0x4390
movq %rax, %rdi
callq 0x41f0
movq %r13, %r15
movq %r13, %rdi
callq 0x42c0
jmp 0xad5d
movq %r12, -0x78(%rbp)
movq %r15, %rdi
movq %rbx, %rsi
pushq $0x4
popq %rdx
pushq $-0x1
popq %rcx
callq 0x43c0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4480
movq %r15, %rdi
callq 0x4748
movq -0x70(%rbp), %rax
movb (%rax), %r15b
cmpb $0x5e, %r15b
jne 0xb178
movb $0x5e, %r15b
cmpq $0x3, -0x68(%rbp)
jb 0xb178
movsbl 0x1(%rax), %r15d
movl %r15d, %edi
callq 0x4600
testl %eax, %eax
je 0xb48f
movl %r15d, %edi
callq 0x46a0
movl %eax, %r15d
movq %rbx, %rdi
xorl %esi, %esi
pushq $0x1
popq %rdx
callq 0x40e0
addb $-0x40, %r15b
movsbl %r15b, %r12d
movl %r12d, %edi
callq 0xb81d
cmpl $0x1b, %eax
jne 0xb222
movl %r12d, %edi
callq 0xb83d
movq 0xae54(%rip), %rdi      # 0x15ff0
leaq 0x3768(%rip), %rsi      # 0xe90b
callq 0x4390
movq -0x78(%rbp), %r12
movq %rax, %rdi
leaq 0xb212(%rip), %rsi      # 0x163c8
callq 0x4390
movq %rax, %rdi
leaq 0x3764(%rip), %rsi      # 0xe929
jmp 0xb288
movq %rbx, %rdi
leaq 0x379e(%rip), %rsi      # 0xe972
callq 0x795b
testb %al, %al
je 0xb29a
movq %r15, %rdi
leaq -0x2a(%rbp), %rsi
callq 0x4060
movzwl -0x2a(%rbp), %eax
addl $-0xd, %eax
cmpw $-0xd, %ax
ja 0xb378
movq 0xadeb(%rip), %rdi      # 0x15ff0
leaq 0x376d(%rip), %rsi      # 0xe979
callq 0x4390
movswl -0x2a(%rbp), %esi
movq %rax, %rdi
callq 0x4360
jmp 0xb537
movl %eax, %r15d
movq -0x70(%rbp), %rcx
movzbl 0x1(%rcx), %eax
movq 0xadbc(%rip), %rdi      # 0x15ff0
leaq 0x36ad(%rip), %rsi      # 0xe8e8
cmpl $0x3f, %eax
movq -0x78(%rbp), %r12
je 0xb288
cmpl $0x5e, %eax
jne 0xb276
movb $0x5e, %al
cmpq $0x3, -0x68(%rbp)
jb 0xb276
movsbl 0x2(%rcx), %edi
movl %edi, -0x9c(%rbp)
callq 0x4600
testl %eax, %eax
je 0xb567
movl -0x9c(%rbp), %edi
callq 0x46a0
addb $-0x40, %al
movl %r15d, %ecx
movq 0xd0d8(%rip), %rdx      # 0x18358
movb %al, (%rdx,%rcx)
jmp 0xb0f8
callq 0x4390
movq %rax, %rdi
callq 0x41f0
jmp 0xb0f8
movq %rbx, %rdi
leaq 0x3720(%rip), %rsi      # 0xe9c4
callq 0x795b
testb %al, %al
je 0xb34d
leaq -0x50(%rbp), %r15
movq %r15, %rdi
leaq -0x2b0(%rbp), %rsi
callq 0x45d0
leaq 0xd255(%rip), %rdi      # 0x18520
movq %r15, %rsi
callq 0x4480
movq %r15, %rdi
callq 0x4748
cmpq $0x5, 0xd245(%rip)      # 0x18528
movq 0xad06(%rip), %rax      # 0x15ff0
leaq 0x36d8(%rip), %rsi      # 0xe9c9
jb 0xb0e8
leaq 0xd222(%rip), %rdi      # 0x18520
xorl %esi, %esi
pushq $0x5
popq %rdx
callq 0x40e0
leaq 0xd211(%rip), %rdi      # 0x18520
callq 0xd028
cmpw $0x39, %ax
jl 0xb0f8
movq 0xaccb(%rip), %rdi      # 0x15ff0
leaq 0x36c5(%rip), %rsi      # 0xe9f1
callq 0x4390
movq %rax, %rdi
callq 0x41f0
leaq 0xd1e0(%rip), %rdi      # 0x18520
pushq $0x39
popq %rsi
callq 0xd0da
jmp 0xb0f8
movq %rbx, %rdi
leaq 0x36c5(%rip), %rsi      # 0xea1c
callq 0x795b
leaq 0xd22d(%rip), %rsi      # 0x18590
testb %al, %al
je 0xb4ab
movq %r13, %rdi
callq 0x4320
jmp 0xb0f8
leaq -0x50(%rbp), %r15
movq %r15, %rdi
leaq -0x2b0(%rbp), %rsi
callq 0x45d0
movswq -0x2a(%rbp), %rax
shlq $0x5, %rax
leaq 0xd005(%rip), %rcx      # 0x183a0
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
movq %r15, %rsi
callq 0x4480
movq %r15, %rdi
callq 0x4748
movswq -0x2a(%rbp), %rax
xorl %edx, %edx
cmpq $0xa, %rax
setge %dl
shlq $0x5, %rax
leaq 0xcfd4(%rip), %rcx      # 0x183a0
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
orq $0x8, %rdx
xorl %esi, %esi
callq 0x40e0
movswq -0x2a(%rbp), %rax
shlq $0x5, %rax
leaq 0xcfb1(%rip), %rcx      # 0x183a0
cmpq $0x0, -0x18(%rax,%rcx)
je 0xb509
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
xorl %esi, %esi
pushq $0x1
popq %rdx
callq 0x40e0
movswq -0x2a(%rbp), %rax
shlq $0x5, %rax
leaq 0xcf83(%rip), %rcx      # 0x183a0
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
callq 0xd028
cmpw $0x37, %ax
jl 0xb0f8
movq 0xabb5(%rip), %rdi      # 0x15ff0
leaq 0x3575(%rip), %rsi      # 0xe9b7
callq 0x4390
movswl -0x2a(%rbp), %esi
movq %rax, %rdi
callq 0x4360
movq %rax, %rdi
leaq 0x35b1(%rip), %rsi      # 0xea0e
callq 0x4390
movq %rax, %rdi
callq 0x41f0
movswq -0x2a(%rbp), %rax
shlq $0x5, %rax
leaq 0xcf26(%rip), %rcx      # 0x183a0
leaq (%rax,%rcx), %rdi
addq $-0x20, %rdi
pushq $0x36
popq %rsi
callq 0xd0da
jmp 0xb0f8
movq 0xab5a(%rip), %rdi      # 0x15ff0
leaq 0xce5b(%rip), %rsi      # 0x182f8
callq 0x4340
movq -0x78(%rbp), %r12
jmp 0xb0f0
movq %rbx, %rdi
leaq 0x356f(%rip), %rsi      # 0xea24
callq 0x795b
testb %al, %al
je 0xb544
movq %r13, %rdi
leaq 0xaf00(%rip), %rsi      # 0x163cc
callq 0x4060
cmpw $0x3e9, 0xaef2(%rip)    # imm = 0x3E9
jb 0xb0f8
movq 0xab09(%rip), %rdi      # 0x15ff0
leaq 0x3547(%rip), %rsi      # 0xea35
callq 0x4390
movq %rax, %rdi
callq 0x41f0
movw $0x64, 0xaec8(%rip)     # 0x163cc
jmp 0xb0f8
movq 0xaae0(%rip), %rdi      # 0x15ff0
leaq 0x347e(%rip), %rsi      # 0xe995
callq 0x4390
movswl -0x2a(%rbp), %esi
movq %rax, %rdi
callq 0x4360
movq %rax, %rdi
leaq 0x3482(%rip), %rsi      # 0xe9b4
callq 0x4390
movq %rax, %rdi
callq 0x41f0
jmp 0xb0f8
movq %rbx, %rdi
leaq 0x3512(%rip), %rsi      # 0xea60
callq 0x795b
leaq 0xd037(%rip), %rsi      # 0x18591
testb %al, %al
je 0xb0a8
jmp 0xb36b
movq 0xaa82(%rip), %rdi      # 0x15ff0
leaq 0xcd83(%rip), %rsi      # 0x182f8
callq 0x4340
jmp 0xb28d
leaq -0x4d0(%rbp), %rdi
callq 0x40a0
cmpq $0x0, 0xcded(%rip)      # 0x18380
jne 0xb5c1
cmpq $0x0, 0x8(%r12)
jne 0xb5b2
cmpq $0x0, -0xb8(%rbp)
leaq -0xc0(%rbp), %r12
je 0xb73d
leaq 0xcdbf(%rip), %rdi      # 0x18378
movq %r12, %rsi
callq 0x4220
leaq 0xcd90(%rip), %rsi      # 0x18358
leaq -0x70(%rbp), %rdi
callq 0x4220
movq -0x70(%rbp), %rdi
movq -0x68(%rbp), %rsi
addq %rdi, %rsi
callq 0xc032
movq -0x70(%rbp), %rdi
movq -0x68(%rbp), %rsi
addq %rdi, %rsi
callq 0xc460
movq -0x68(%rbp), %rax
cmpq 0xcd64(%rip), %rax      # 0x18360
jae 0xb62c
movq 0xa9eb(%rip), %rdi      # 0x15ff0
leaq 0x34ea(%rip), %rsi      # 0xeaf6
callq 0x4390
movq %rax, %rdi
callq 0x41f0
leaq 0xcd38(%rip), %rdi      # 0x18358
leaq 0xcc71(%rip), %rsi      # 0x18298
callq 0x4220
cmpq $0x0, 0xcef4(%rip)      # 0x18528
jne 0xb661
cmpb $0x1, 0xcf53(%rip)      # 0x18590
jne 0xb661
movb $0x0, 0xcf4a(%rip)      # 0x18590
movq 0xa9a3(%rip), %rdi      # 0x15ff0
leaq 0x34e8(%rip), %rsi      # 0xeb3c
callq 0x4390
movq %rax, %rdi
callq 0x41f0
leaq 0xced8(%rip), %rsi      # 0x18540
leaq 0x3518(%rip), %rdx      # 0xeb87
leaq -0x50(%rbp), %rdi
callq 0xbb49
movq -0x50(%rbp), %rsi
leaq -0x2c8(%rbp), %rdi
pushq $0x8
popq %rdx
callq 0x4680
leaq -0x50(%rbp), %rdi
callq 0x4748
movq -0x2c8(%rbp), %rax
movq -0x18(%rax), %rax
testb $0x5, -0x2a8(%rbp,%rax)
je 0xb6f4
leaq -0x2c8(%rbp), %rdi
callq 0x4110
leaq -0xc0(%rbp), %rdi
callq 0x4748
leaq -0x70(%rbp), %rdi
callq 0x4748
leaq -0x4d0(%rbp), %rdi
callq 0x4110
leaq -0x98(%rbp), %rdi
callq 0x4748
addq $0x4a8, %rsp            # imm = 0x4A8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq -0x2c8(%rbp), %rbx
leaq -0x98(%rbp), %r14
leaq 0xb77f(%rip), %r15      # 0x16e88
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4090
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0xb6a9
cmpq $0x0, -0x90(%rbp)
je 0xb6a9
movq %r15, %rdi
movq %r14, %rsi
callq 0x8312
jmp 0xb709
movq 0xa8ac(%rip), %rdi      # 0x15ff0
leaq 0x335e(%rip), %rsi      # 0xeaa9
callq 0x4390
movq %rax, %rdi
callq 0x41f0
leaq 0xcc19(%rip), %rdi      # 0x18378
leaq 0x3380(%rip), %rsi      # 0xeae6
callq 0x46d0
jmp 0xb5c1
jmp 0xb7d9
jmp 0xb7d9
jmp 0xb7d9
jmp 0xb7d9
jmp 0xb7d9
jmp 0xb7b1
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x4748
jmp 0xb7e8
jmp 0xb7d4
movq %rax, %rbx
jmp 0xb7f4
jmp 0xb7a6
jmp 0xb7a6
movq %rax, %rbx
leaq -0x4d0(%rbp), %rdi
callq 0x4748
jmp 0xb809
movq %rax, %rbx
jmp 0xb809
jmp 0xb7d9
jmp 0xb7d9
jmp 0xb7d9
movq %rax, %rbx
leaq -0x50(%rbp), %rdi
callq 0x4748
jmp 0xb7dc
jmp 0xb7d4
jmp 0xb7d4
movq %rax, %rbx
leaq -0x2c8(%rbp), %rdi
callq 0x4110
jmp 0xb7e8
movq %rax, %rbx
jmp 0xb7e8
movq %rax, %rbx
leaq -0x2c8(%rbp), %rdi
callq 0x42c0
leaq -0xc0(%rbp), %rdi
callq 0x4748
leaq -0x70(%rbp), %rdi
callq 0x4748
leaq -0x4d0(%rbp), %rdi
callq 0x4110
leaq -0x98(%rbp), %rdi
callq 0x4748
movq %rbx, %rdi
callq 0x4650