Пример #1
0
DiscIO::IVolume::ECountry CNANDContentLoader::GetCountry() const
{
	if (!IsValid())
		return DiscIO::IVolume::COUNTRY_UNKNOWN;

	return CountrySwitch(m_Country);
}
Пример #2
0
IVolume::ECountry CVolumeDirectory::GetCountry() const
{
	_dbg_assert_(DVDINTERFACE, m_diskHeader);
	
	u8 CountryCode = m_diskHeader[3];

	return CountrySwitch(CountryCode);
}
Пример #3
0
IVolume::ECountry CVolumeGC::GetCountry() const
{
	if (!m_pReader)
		return COUNTRY_UNKNOWN;

	u8 country_code;
	m_pReader->Read(3, 1, &country_code);

	return CountrySwitch(country_code);
}
Пример #4
0
IVolume::ECountry CVolumeWiiCrypted::GetCountry() const
{
	if (!m_pReader)
		return COUNTRY_UNKNOWN;

	u8 CountryCode;
	m_pReader->Read(3, 1, &CountryCode);

	return CountrySwitch(CountryCode);
}
Пример #5
0
Country VolumeWAD::GetCountry(const Partition& partition) const
{
  if (!m_tmd.IsValid())
    return Country::COUNTRY_UNKNOWN;

  u8 country_code = static_cast<u8>(m_tmd.GetTitleId() & 0xff);
  if (country_code == 2)  // SYSMENU
    return TypicalCountryForRegion(GetSysMenuRegion(m_tmd.GetTitleVersion()));

  return CountrySwitch(country_code);
}
Пример #6
0
Country CVolumeWiiCrypted::GetCountry() const
{
  if (!m_pReader)
    return Country::COUNTRY_UNKNOWN;

  u8 country_byte;
  if (!m_pReader->Read(3, 1, &country_byte))
    return Country::COUNTRY_UNKNOWN;

  Country country_value = CountrySwitch(country_byte);

  u32 region_code;
  if (!ReadSwapped(0x4E000, &region_code, false))
    return country_value;

  switch (region_code)
  {
  case 0:
    switch (country_value)
    {
    case Country::COUNTRY_TAIWAN:
      return Country::COUNTRY_TAIWAN;
    default:
      return Country::COUNTRY_JAPAN;
    }
  case 1:
    return Country::COUNTRY_USA;
  case 2:
    switch (country_value)
    {
    case Country::COUNTRY_FRANCE:
    case Country::COUNTRY_GERMANY:
    case Country::COUNTRY_ITALY:
    case Country::COUNTRY_NETHERLANDS:
    case Country::COUNTRY_RUSSIA:
    case Country::COUNTRY_SPAIN:
    case Country::COUNTRY_AUSTRALIA:
      return country_value;
    default:
      return Country::COUNTRY_EUROPE;
    }
  case 4:
    return Country::COUNTRY_KOREA;
  default:
    return country_value;
  }
}
Пример #7
0
IVolume::ECountry CVolumeWAD::GetCountry() const
{
  if (!m_pReader)
    return COUNTRY_UNKNOWN;

  // read the last digit of the titleID in the ticket
  u8 country_code;
  Read(m_tmd_offset + 0x0193, 1, &country_code);

  if (country_code == 2)  // SYSMENU
  {
    u16 title_version = 0;
    Read(m_tmd_offset + 0x01dc, 2, (u8*)&title_version);
    country_code = GetSysMenuRegion(Common::swap16(title_version));
  }

  return CountrySwitch(country_code);
}
Пример #8
0
IVolume::ECountry CVolumeDirectory::GetCountry() const
{
	u8 CountryCode = m_diskHeader[3];

	return CountrySwitch(CountryCode);
}
Пример #9
0
Country CVolumeDirectory::GetCountry() const
{
  return CountrySwitch(m_diskHeader[3]);
}