// File: /workspace/github_cpp_makefile_star2_O1/nickgammon[P]tinymudserver/load.cpp
// Function: LoadMessages()
void LoadMessages ()
{
  // format is: <code> <message>
  //  eg. motd Hi there!
  // Imbedded %r sequences will becomes new lines.
  ifstream fMessages (MESSAGES_FILE, ios::in);
  if (!fMessages)
    {
    cerr << "Could not open messages file: " << MESSAGES_FILE << endl;
    return;
    }

  while (!(fMessages.eof ()))
    {
    string sMessageCode, sMessageText;
    fMessages >> sMessageCode >> ws;
    getline (fMessages, sMessageText);
    if (!(sMessageCode.empty ()))
      messagemap [tolower (sMessageCode)] =
            FindAndReplace (sMessageText, "%r", "\n");
    } // end of read loop

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2c8, %rsp            # imm = 0x2C8
leaq 0x9702(%rip), %rsi      # 0x10357
leaq -0x2f0(%rbp), %rbx
movq %rbx, %rdi
movl $0x8, %edx
callq 0x3570
movq (%rbx), %rax
movq -0x18(%rax), %rax
testb $0x5, -0x2d0(%rbp,%rax)
je 0x6cdd
movq 0xf367(%rip), %rdi      # 0x15fe8
leaq 0x95f9(%rip), %rsi      # 0x10281
movl $0x1e, %edx
callq 0x3370
movq 0xf34f(%rip), %rbx      # 0x15fe8
leaq 0x96b7(%rip), %rsi      # 0x10357
movl $0x15, %edx
movq %rbx, %rdi
callq 0x3370
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x32d0
movsbl %al, %esi
movq 0xf31d(%rip), %rdi      # 0x15fe8
callq 0x3030
movq %rax, %rdi
callq 0x3220
jmp 0x6ecb
movq -0x2f0(%rbp), %rax
movq -0x18(%rax), %rax
testb $0x2, -0x2d0(%rbp,%rax)
jne 0x6ecb
xorl %r13d, %r13d
leaq -0x48(%rbp), %r14
leaq -0x68(%rbp), %r15
leaq -0x38(%rbp), %rax
movq %rax, -0x48(%rbp)
movq %r13, -0x40(%rbp)
movb %r13b, -0x38(%rbp)
leaq -0x58(%rbp), %rax
movq %rax, -0x68(%rbp)
movq %r13, -0x60(%rbp)
movb %r13b, -0x58(%rbp)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33b0
movq %rax, %rdi
callq 0x3280
movq -0x2f0(%rbp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x32d0
movsbl %al, %edx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3580
cmpq $0x0, -0x40(%rbp)
je 0x6e80
leaq -0x78(%rbp), %rax
movq %rax, -0x88(%rbp)
leaq -0x88(%rbp), %rdi
leaq 0x9522(%rip), %rsi      # 0x102a0
leaq 0x951d(%rip), %rdx      # 0x102a2
callq 0x4bc4
leaq -0x98(%rbp), %rax
movq %rax, -0xa8(%rbp)
leaq -0xa8(%rbp), %r12
movq %r12, %rdi
leaq 0x9323(%rip), %rsi      # 0x100cc
leaq 0x931d(%rip), %rdx      # 0x100cd
callq 0x4bc4
leaq -0xc8(%rbp), %rdi
movq %r15, %rsi
leaq -0x88(%rbp), %rdx
movq %r12, %rcx
callq 0x4c60
leaq -0xe8(%rbp), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x4e39
leaq 0xfad1(%rip), %rdi      # 0x168b8
movq %r12, %rsi
callq 0x79b2
movq %rax, %rdi
leaq -0xc8(%rbp), %rsi
callq 0x33a0
movq -0xe8(%rbp), %rdi
leaq -0xd8(%rbp), %rax
cmpq %rax, %rdi
je 0x6e20
movq -0xd8(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0xc8(%rbp), %rdi
leaq -0xb8(%rbp), %rax
cmpq %rax, %rdi
je 0x6e42
movq -0xb8(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
cmpq %rax, %rdi
je 0x6e64
movq -0x98(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0x88(%rbp), %rdi
leaq -0x78(%rbp), %rax
cmpq %rax, %rdi
je 0x6e80
movq -0x78(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
je 0x6e99
movq -0x58(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0x48(%rbp), %rdi
leaq -0x38(%rbp), %rax
cmpq %rax, %rdi
je 0x6eb2
movq -0x38(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0x2f0(%rbp), %rax
movq -0x18(%rax), %rax
testb $0x2, -0x2d0(%rbp,%rax)
je 0x6d01
leaq -0x2f0(%rbp), %rdi
callq 0x30c0
addq $0x2c8, %rsp            # imm = 0x2C8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
jmp 0x6fbe
movq %rax, %rbx
movq -0xe8(%rbp), %rdi
leaq -0xd8(%rbp), %rax
cmpq %rax, %rdi
je 0x6f27
movq -0xd8(%rbp), %rsi
incq %rsi
callq 0x32f0
jmp 0x6f27
jmp 0x6f89
movq %rax, %rbx
jmp 0x6f6b
movq %rax, %rbx
jmp 0x6f49
movq %rax, %rbx
movq -0xc8(%rbp), %rdi
leaq -0xb8(%rbp), %rax
cmpq %rax, %rdi
je 0x6f49
movq -0xb8(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0xa8(%rbp), %rdi
leaq -0x98(%rbp), %rax
cmpq %rax, %rdi
je 0x6f6b
movq -0x98(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0x88(%rbp), %rdi
leaq -0x78(%rbp), %rax
cmpq %rax, %rdi
je 0x6f8c
movq -0x78(%rbp), %rsi
incq %rsi
callq 0x32f0
jmp 0x6f8c
movq %rax, %rbx
movq -0x68(%rbp), %rdi
leaq -0x58(%rbp), %rax
cmpq %rax, %rdi
je 0x6fa5
movq -0x58(%rbp), %rsi
incq %rsi
callq 0x32f0
movq -0x48(%rbp), %rdi
leaq -0x38(%rbp), %rax
cmpq %rax, %rdi
je 0x6fbe
movq -0x38(%rbp), %rsi
incq %rsi
callq 0x32f0
leaq -0x2f0(%rbp), %rdi
callq 0x30c0
movq %rbx, %rdi
callq 0x3530