Jump to content

Go to solution Solved by Diversityy,

8 posts in this topic

Recommended Posts

Posted (edited)

elseif ( string.sub( system.getInfo("model"), 1, 2 ) == "iP" and display.pixelHeight > 960 ) then

  application =

{  

content =

{  

  width = 320,

  height = 568,

  scale = "letterBox",

  xAlign = "center",

  yAlign = "center",

  imageSuffix =

{  

        ["@2x"] = 1.5,

        ["@ 4x"] = 3.0,  

      },

   },  

}

 

Note: Had to put a space between @ and 4x due to it configuring it to a member with 4x in their name. This is configuration for an Iphone 5, what device are you using?

Updated by XxGam3Ma2t3rxX
Posted

elseif ( string.sub( system.getInfo("model"), 1, 2 ) == "iP" and display.pixelHeight > 960 ) then

  application =

{  

content =

{  

  width = 320,

  height = 568,

  scale = "letterBox",

  xAlign = "center",

  yAlign = "center",

  imageSuffix =

{  

        ["@2x"] = 1.5,

        ["@ 4x"] = 3.0,  

      },

   },  

}

 

Note: Had to put a space between @ and 4x due to it configuring it to a member with 4x in their name. This is configuration for an Iphone 5, what device are you using?

<eof> expected near 'elseif'

I get that error when trying to run, are you sure it's that complicated?

elseif ( string.sub( system.getInfo("model"), 1, 2 ) == "iP" and display.pixelHeight > 960 ) then

  application =

{  

content =

{  

  width = 320,

  height = 568,

  scale = "letterBox",

  xAlign = "center",

  yAlign = "center",

  imageSuffix =

{  

        ["@2x"] = 1.5,

        ["@ 4x"] = 3.0,  

      },

   },  

}

 

Note: Had to put a space between @ and 4x due to it configuring it to a member with 4x in their name. This is configuration for an Iphone 5, what device are you using?

Testing it on iPad Mini 2 and iPhone 5
Posted
<eof> expected near 'elseif'
I get that error when trying to run, are you sure it's that complicated?

Testing it on iPad Mini 2 and iPhone 5

 

Use corona

As for the Ipad

With 360 as the width, we need to calculate the height that will fit the iPad’s screen shape.  The iPad screen is 768×1024, or 1536×2048 for the Retina iPad (double, so the same ratio). First, divide 1024 by 768 to get 1.33.  Then, to get the height, multiply 1.33 by 360 for a result of 480.

1024 / 768 = 1.33  --screen ratio (height:width)
1.33 x 360 = 480

Not sure for Ipad mini however.

Corona should work with the code provided above. But yes it is that complicated last time I checked.

Posted

Use coronaAs for the Ipad

With 360 as the width, we need to calculate the height that will fit the iPad’s screen shape.  The iPad screen is 768×1024, or 1536×2048 for the Retina iPad (double, so the same ratio). First, divide 1024 by 768 to get 1.33.  Then, to get the height, multiply 1.33 by 360 for a result of 480.

1024 / 768 = 1.33  --screen ratio (height:width)

1.33 x 360 = 480

Not sure for Ipad mini however.

Corona should work with the code provided above. But yes it is that complicated last time I checked.

Using AutoTouch to run the scripts >_<
Posted (edited)

Using AutoTouch to run the scripts >_<

Hmm maybe this script would be better..At least for auto-touch

local region = {800, 540, 600, 40}

local result = findColor(16431023, 0, region)

if next(result) == nil then

        --Color not found, run command

touchDown(6, 392, 238);

 

else

            --Color is found, run other commands

touchDown(8, 389, 1180);

 

end

 

[Auto-touch is for auto pressing so I would assume this would be the best script.]

Anyways I am going away for a bit! Look up auto-touch lua script screen adaptations on google!

Updated by XxGam3Ma2t3rxX
  • Solution
Posted
Solved
The question(s) in this support topic have been answered and the topic author has resolved their issue. This topic is now closed. If you have other questions, please open a new support topic.
Guest
This topic is now closed to further replies.
×
  • Create New...

Important Information

We would like to place cookies on your device to help make this website better. The website cannot give you the best user experience without cookies. You can accept or decline our cookies. You may also adjust your cookie settings. Privacy Policy - Guidelines