mirror of
				https://github.com/OpenMW/openmw.git
				synced 2025-11-04 14:56:41 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			15 lines
		
	
	
	
		
			368 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			15 lines
		
	
	
	
		
			368 B
		
	
	
	
		
			C++
		
	
	
	
	
	
#include "sstream"
 | 
						|
 | 
						|
namespace ESM
 | 
						|
{
 | 
						|
    std::string printName(const std::uint32_t typeId)
 | 
						|
    {
 | 
						|
        unsigned char typeName[4];
 | 
						|
        typeName[0] =  typeId        & 0xff;
 | 
						|
        typeName[1] = (typeId >>  8) & 0xff;
 | 
						|
        typeName[2] = (typeId >> 16) & 0xff;
 | 
						|
        typeName[3] = (typeId >> 24) & 0xff;
 | 
						|
 | 
						|
        return std::string((char*)typeName, 4);
 | 
						|
    }
 | 
						|
}
 |