///Check the current device is tablet or not
private void checkTheCurrentDevice()
{
#if UNITY_IPHONE
string deviceModel = SystemInfo.deviceModel.ToLower().Trim();
if(deviceModel.StartsWith("ipad"))
{
bIsTablet = true;
}
else
{
bIsTablet = false;
}
#elif UNITY_ANDROID
float physicScreenSize = Mathf.Sqrt(Screen.width * Screen.width + Screen.height * Screen.height) / Screen.dpi;
if(physicScreenSize >= 7f) //If the screen size is >= 7 inches, it's a tablet
{
bIsTablet = true;
}
else
{
bIsTablet = false;
}
#else
bIsTablet = false;
#endif
// bIsTablet = false;
}