// File: /workspace/github_cpp_makefile_star2_O3/BohangZhang[P]Sorcery-C-Project/ascii_graphics.cc
// Function: display_ritual(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
card_template_t display_ritual(std::string name,int cost,int ritual_cost,std::string ritual_desc,
                               int ritual_charges) {
  std::ostringstream oss;
  card_template_t out(CARD_TEMPLATE_RITUAL);
  prepare_for_replace(out);
  replace_text_left(out,'N',name);
  oss << cost;
  replace_text_right(out,'C',oss.str());
  replace_text_right(out,'T',"Ritual");
  oss.str("");
  oss << ritual_cost;
  replace_text_left(out,'K',oss.str());
  replace_text_left(out,'E',ritual_desc);
  oss.str("");
  oss << ritual_charges;
  replace_text_right(out,'D',oss.str());
  return out;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x268, %rsp            # imm = 0x268
movl %r9d, 0xc(%rsp)
movq %r8, %r15
movl %ecx, %r12d
movl %edx, %r14d
movq %rsi, %r13
movq %rdi, %rbx
leaq 0xf0(%rsp), %rdi
callq 0x5270
leaq 0x260b9(%rip), %rsi     # 0x33208
movq %rbx, %rdi
callq 0xe1d8
movq %rbx, %rdi
callq 0xd464
leaq 0xe0(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq (%r13), %rsi
movq 0x8(%r13), %rdx
addq %rsi, %rdx
leaq 0xd0(%rsp), %rdi
callq 0xb4e8
leaq 0xd0(%rsp), %r13
movq %rbx, %rdi
movl $0x4e, %esi
movq %r13, %rdx
callq 0xd4a5
movq (%r13), %rdi
cmpq %rbp, %rdi
je 0xd1b4
movq 0xe0(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0xf0(%rsp), %rdi
movl %r14d, %esi
callq 0x5310
leaq 0xf8(%rsp), %r14
leaq 0xb0(%rsp), %rdi
movq %r14, %rsi
callq 0x52c0
leaq 0xb0(%rsp), %r13
movq %rbx, %rdi
movl $0x43, %esi
movq %r13, %rdx
callq 0xd545
movq (%r13), %rdi
leaq 0xc0(%rsp), %rax
cmpq %rax, %rdi
je 0xd215
movq 0xc0(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0xa0(%rsp), %rbp
movq %rbp, -0x10(%rbp)
leaq 0x196b9(%rip), %rsi     # 0x268e1
leaq 0x196b8(%rip), %rdx     # 0x268e7
leaq 0x90(%rsp), %rdi
callq 0xb57e
leaq 0x90(%rsp), %r13
movq %rbx, %rdi
movl $0x54, %esi
movq %r13, %rdx
callq 0xd545
movq (%r13), %rdi
cmpq %rbp, %rdi
je 0xd26d
movq 0xa0(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0x20(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x19b1c(%rip), %rdx     # 0x26d99
leaq 0x10(%rsp), %rdi
movq %rdx, %rsi
callq 0xb57e
leaq 0x10(%rsp), %rsi
movq %r14, %rdi
callq 0x52a0
movq 0x10(%rsp), %rdi
cmpq %r13, %rdi
je 0xd2ae
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0xf0(%rsp), %rdi
movl %r12d, %esi
callq 0x5310
leaq 0x70(%rsp), %rdi
movq %r14, %rsi
callq 0x52c0
leaq 0x70(%rsp), %r12
movq %rbx, %rdi
movl $0x4b, %esi
movq %r12, %rdx
callq 0xd4a5
movq (%r12), %rdi
leaq 0x80(%rsp), %rax
cmpq %rax, %rdi
je 0xd301
movq 0x80(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0x60(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
leaq 0x50(%rsp), %rdi
callq 0xb4e8
leaq 0x50(%rsp), %r15
movq %rbx, %rdi
movl $0x45, %esi
movq %r15, %rdx
callq 0xd4a5
movq (%r15), %rdi
cmpq %r12, %rdi
je 0xd349
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0x10(%rsp), %rdi
movq %r13, (%rdi)
leaq 0x19a41(%rip), %rdx     # 0x26d99
movq %rdx, %rsi
callq 0xb57e
leaq 0x10(%rsp), %rsi
movq %r14, %rdi
callq 0x52a0
movq 0x10(%rsp), %rdi
cmpq %r13, %rdi
je 0xd384
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x51f0
leaq 0xf0(%rsp), %rdi
movl 0xc(%rsp), %esi
callq 0x5310
leaq 0x30(%rsp), %rdi
movq %r14, %rsi
callq 0x52c0
leaq 0x30(%rsp), %r14
movq %rbx, %rdi
movl $0x44, %esi
movq %r14, %rdx
callq 0xd545
movq (%r14), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0xd3d1
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x51f0
movq 0x25be0(%rip), %rsi     # 0x32fb8
leaq 0xf0(%rsp), %rdi
callq 0x5120
leaq 0x160(%rsp), %rdi
callq 0x50b0
movq %rbx, %rax
addq $0x268, %rsp            # imm = 0x268
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xd40b
jmp 0xd430
movq %rax, %r14
movq 0x10(%rsp), %rdi
cmpq %r13, %rdi
je 0xd433
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x51f0
jmp 0xd433
jmp 0xd430
jmp 0xd430
movq %rax, %r14
jmp 0xd43b
movq %rax, %r14
movq %rbx, %rdi
callq 0xc796
movq 0x25b76(%rip), %rsi     # 0x32fb8
leaq 0xf0(%rsp), %rdi
callq 0x5120
leaq 0x160(%rsp), %rdi
callq 0x50b0
movq %r14, %rdi
callq 0x5320