// File: /workspace/github_cpp_makefile_star2_O2/rcolomina[P]the_charmed_house/src/factory.cpp
// Function: FactoryGame::buildScenarioById(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
pScene FactoryGame::buildScenarioById(string scenId){

     string mainNode("scenes");
     string attrib("title");
     string childrenNode("descriptions");
     string childrenNode2("image");

     // getting element item
     pElem elem_Scenes = this->getGameElement(mainNode.c_str());	  	  
     pElem elem_Scene  = this->searchForElementId(elem_Scenes,scenId.c_str());

     if(elem_Scenes==NULL){
	  cout<<"Handle returned a Null at elem_Scenes"<<endl;
	  exit(0);
     }
	  
     if(elem_Scene==NULL){
	  cout<<"Handle returned a Null at elem_Scen"<<endl;
	  exit(0);
     }

     const string& scen_title = elem_Scene->Attribute(attrib.c_str());

     //cout<<"title scenary:"<<scen_title<<endl;
	  
     // handler
     TiXmlHandle itemHandle(elem_Scene);	  	  
     pElem scen_descrips=itemHandle.FirstChild(childrenNode.c_str()).ToElement();
	  
     if(scen_descrips==NULL){
	  // TODO: Add an asscertion
	  cout<<"Handle returned a Null value"<<endl;
	  exit(0);
     }
	  
     vector<string> descripts = getTextListFromNode(scen_descrips);

     pElem scen_image = itemHandle.FirstChild(childrenNode2.c_str()).ToElement();	  
     string pathText  = scen_image->GetText();

     const Entidad& ent = Entidad(scenId,scen_title,descripts[0]);
	  
     pScene scene = new Escenario(ent,descripts[1],pathText);
			 
     return scene;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x1f0, %rsp            # imm = 0x1F0
movq %rsi, %rbx
movq %rdi, %r14
leaq 0xc214(%rip), %rsi      # 0x219f7
leaq 0x1d0(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x12230
leaq 0xc202(%rip), %rsi      # 0x219fe
leaq 0x1b0(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x12230
leaq 0xc183(%rip), %rsi      # 0x21998
leaq 0x190(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x12230
leaq 0xc1b0(%rip), %rsi      # 0x219de
leaq 0x170(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x12230
movq 0x1d0(%rsp), %rsi
leaq 0x150(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x12230
leaq 0x150(%rsp), %rsi
movq %r14, %rdi
callq 0x162bc
movq %rax, %r15
leaq 0x150(%rsp), %rdi
callq 0x5638
movq (%rbx), %rsi
leaq 0x130(%rsp), %rdi
leaq 0x28(%rsp), %rdx
callq 0x12230
leaq 0x130(%rsp), %rdx
movq %r15, %rsi
callq 0x16338
movq %rax, %r14
leaq 0x130(%rsp), %rdi
callq 0x5638
testq %r15, %r15
je 0x15a7b
testq %r14, %r14
je 0x15a98
movq 0x1b0(%rsp), %rsi
movq %r14, %rdi
callq 0x1d7fa
leaq 0x110(%rsp), %rdi
leaq 0x28(%rsp), %rdx
movq %rax, %rsi
callq 0x12230
leaq 0x8(%rsp), %rsi
movq %r14, (%rsi)
movq 0x190(%rsp), %rdx
leaq 0x28(%rsp), %rdi
callq 0x1edb8
leaq 0x28(%rsp), %rdi
callq 0x1220a
testq %rax, %rax
je 0x15ab5
leaq 0x10(%rsp), %rdi
movq %rax, %rdx
callq 0x16210
movq 0x170(%rsp), %rdx
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1edb8
leaq 0x28(%rsp), %rdi
callq 0x1220a
movq %rax, %rdi
callq 0x1de4a
leaq 0xf0(%rsp), %rdi
leaq 0x28(%rsp), %rdx
movq %rax, %rsi
callq 0x12230
leaq 0xd0(%rsp), %rdi
movq %rbx, %rsi
callq 0x5430
leaq 0xb0(%rsp), %rdi
leaq 0x110(%rsp), %rsi
callq 0x5430
movq 0x10(%rsp), %rsi
leaq 0x90(%rsp), %rdi
callq 0x5430
leaq 0x28(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
leaq 0xb0(%rsp), %rdx
leaq 0x90(%rsp), %rcx
callq 0x164c6
leaq 0x90(%rsp), %rdi
callq 0x5638
leaq 0xb0(%rsp), %rdi
callq 0x5638
leaq 0xd0(%rsp), %rdi
callq 0x5638
movl $0x168, %edi            # imm = 0x168
callq 0x5330
movq %rax, %r14
movq 0x10(%rsp), %rdx
addq $0x20, %rdx
leaq 0x28(%rsp), %rsi
leaq 0xf0(%rsp), %rcx
movq %rax, %rdi
callq 0x12de4
leaq 0x28(%rsp), %rdi
callq 0x13630
leaq 0xf0(%rsp), %rdi
callq 0x5638
leaq 0x10(%rsp), %rdi
callq 0x121e8
leaq 0x110(%rsp), %rdi
callq 0x5638
leaq 0x170(%rsp), %rdi
callq 0x5638
leaq 0x190(%rsp), %rdi
callq 0x5638
leaq 0x1b0(%rsp), %rdi
callq 0x5638
leaq 0x1d0(%rsp), %rdi
callq 0x5638
movq %r14, %rax
addq $0x1f0, %rsp            # imm = 0x1F0
popq %rbx
popq %r14
popq %r15
retq
movq 0x19536(%rip), %rdi     # 0x2efb8
leaq 0xbf7b(%rip), %rsi      # 0x21a04
callq 0x5310
movq %rax, %rdi
callq 0x51a0
jmp 0x15ad0
movq 0x19519(%rip), %rdi     # 0x2efb8
leaq 0xbf84(%rip), %rsi      # 0x21a2a
callq 0x5310
movq %rax, %rdi
callq 0x51a0
jmp 0x15ad0
movq 0x194fc(%rip), %rdi     # 0x2efb8
leaq 0xbf8b(%rip), %rsi      # 0x21a4e
callq 0x5310
movq %rax, %rdi
callq 0x51a0
xorl %edi, %edi
callq 0x53d0
jmp 0x15b90
movq %rax, %rbx
movl $0x168, %esi            # imm = 0x168
movq %r14, %rdi
callq 0x5340
jmp 0x15af1
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x13630
jmp 0x15b36
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0x5638
jmp 0x15b12
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
callq 0x5638
jmp 0x15b24
movq %rax, %rbx
leaq 0xd0(%rsp), %rdi
callq 0x5638
jmp 0x15b36
movq %rax, %rbx
leaq 0xf0(%rsp), %rdi
callq 0x5638
jmp 0x15b84
jmp 0x15b81
jmp 0x15b81
jmp 0x15b90
jmp 0x15b7c
jmp 0x15b7c
movq %rax, %rbx
leaq 0x130(%rsp), %rdi
jmp 0x15b9b
jmp 0x15b7c
movq %rax, %rbx
leaq 0x150(%rsp), %rdi
jmp 0x15b9b
jmp 0x15b7c
movq %rax, %rbx
jmp 0x15bad
movq %rax, %rbx
jmp 0x15bba
movq %rax, %rbx
jmp 0x15bc7
movq %rax, %rbx
jmp 0x15ba0
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x121e8
jmp 0x15b93
movq %rax, %rbx
leaq 0x110(%rsp), %rdi
callq 0x5638
leaq 0x170(%rsp), %rdi
callq 0x5638
leaq 0x190(%rsp), %rdi
callq 0x5638
leaq 0x1b0(%rsp), %rdi
callq 0x5638
leaq 0x1d0(%rsp), %rdi
callq 0x5638
movq %rbx, %rdi
callq 0x55a0