• Dear Cerberus X User!

    As we prepare to transition the forum ownership from Mike to Phil (TripleHead GmbH), we need your explicit consent to transfer your user data in accordance with our amended Terms and Rules in order to be compliant with data protection laws.

    Important: If you accept the amended Terms and Rules, you agree to the transfer of your user data to the future forum owner!

    Please read the new Terms and Rules below, check the box to agree, and click "Accept" to continue enjoying your Cerberus X Forum experience. The deadline for consent is April 5, 2024.

    Do not accept the amended Terms and Rules if you do not wish your personal data to be transferred to the future forum owner!

    Accepting ensures:

    - Continued access to your account with a short break for the actual transfer.

    - Retention of your data under the same terms.

    Without consent:

    - You don't have further access to your forum user account.

    - Your account and personal data will be deleted after April 5, 2024.

    - Public posts remain, but usernames indicating real identity will be anonymized. If you disagree with a fictitious name you have the option to contact us so we can find a name that is acceptable to you.

    We hope to keep you in our community and see you on the forum soon!

    All the best

    Your Cerberus X Team

Resolution in iPhone

miguetrek

New member
Joined
Aug 23, 2017
Messages
5
Hello,
I'm new in monkey/cerberus and I've been testing for a few days, but my app not get the correct resolution in IOS. I have created a basic program (code shown), built with "IOS Game" target, opened the project in xcode and run for iphone5 emulator. The resolution shown is low and incorrect, and the text does not appear in the upper corner (screenshot).
Is it a bug or am I doing something wrong?

code:
Code:
Import mojo

Class MyApp Extends App

Method OnRender()
DrawText DeviceWidth+"x"+DeviceHeight,0,0
End

End

Function Main()
New MyApp
End

screenshot:
iPhone5.png
 
You have to add a correctly sized launch images within xcode. I know this sounds strange but that way you get the correct size.
 
Thanks Martin! I have added a blank launch image of size 640x1136 and now goes right.
I have been a couple of years without developing for mobile and i had forgotten the strangeness of xcode/ios :)
 
Hello Mike,'
Do you guys have the Launch Screen for iPhone 11 Xs Max (2688 × 1242 pixels) and iPhone Xr ( 1792 × 828 pixels)?

The Defaulf image that is generated by Cerberus is 640x1136 pixels, this is the maximum resolution I get from my iPhone Xs Max.
 
I added two additional default images 1792 × 828 pixels for iPhone Xr and 2688 × 1242 pixels for iPhone Xs Max , but when I run on the simulator for iPhone Xs Max, the DeviceWidth() and DeviceHeight are retuning 1704 x 960 on the iPhone Xs Max on the Simulator and on my iPhone Xs Max this id not the correct resolutions.
What can I do to get the correct resolution from the Device? I am Using Cerberus v2020-05-09
 
I don't have a clue about xcode and ios, because I don't have any devices. But did you look into this last answer on StackOverflow?
If you have to create a storyboard, this video might help.
 
Phil7 Thanks for your response, I know that and I have all screen resolutions on my assets catalog, this game I am updating was also released before when it was Monkey X.’The questions is why the screen resolution Is incorrect ? Also the issue happens in the Simulator.
 
I will look into this during my vacation wish starts in 10 days.
 
Hello Mark, were you able to confirm if Cerberus is returning the correct resolution from the Device? You can confirm my issue using the Apple Emulator.
 
My name is Michael.

And sorry, so far i had no time to look into this but i hope soon.
 
I was able to display it in the native resolution of 750x1334 in the iphone SE simulator by adding a "Launch Screen.storyboard" file like described on this site.
Otherwise I also couldn't get a higher resolution than 640x1136 by changing the launch image. So I deleted it and added the mentioned file in xcode. The only thing I had to do was to disable "Safe Area Layout Guide" with the file inspector in the storyboard file.
 
@APC I have uploaded the changes suggested by Phil7 to Github. Works fine here. If you need further help, please let us know.
 
@APC I have uploaded the changes suggested by Phil7 to Github. Works fine here. If you need further help, please let us know.
Hello @MikeHart and @Phil7, thank you so much for fixing it, switching to storyboard launch screen is the way to got with iOS. I tested and the resolution issue is resolved! I downloaded the Cerberus_v2020-09-12 but it did no have the Cerberus application so just copied the iOS target files over to my version Cerberus_v2020-05-09. ad a suggestion on the Storyboard screen you could add the Cerberus Logo .
Now I will keep testing with other device sizes.
 
Last edited:
Back
Top Bottom