Serializer.
This commit is contained in:
		
					parent
					
						
							
								3691042b6e
							
						
					
				
			
			
				commit
				
					
						4f1075dc28
					
				
			
		
					 1 changed files with 13 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -56,6 +56,19 @@ namespace character {
 | 
			
		|||
 | 
			
		||||
		[[nodiscard]] std::uint32_t get_money() const { return money; }
 | 
			
		||||
	};
 | 
			
		||||
 | 
			
		||||
	void to_json(json &j, const CharacterSheet &billy) {
 | 
			
		||||
		j["caractere"] = billy.get_caractere();
 | 
			
		||||
		j["adresse"] = billy.get_adresse();
 | 
			
		||||
		j["endurance"] = billy.get_endurance();
 | 
			
		||||
		j["chance"] = billy.get_chance();
 | 
			
		||||
		j["habilete"] = billy.get_habilete();
 | 
			
		||||
		j["health_point"] = billy.get_health_point();
 | 
			
		||||
		j["armor"] = billy.get_armor();
 | 
			
		||||
		j["damage"] = billy.get_damage();
 | 
			
		||||
		j["glory"] = billy.get_glory();
 | 
			
		||||
		j["money"] = billy.get_money();
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue