Universal Build Question

UltraLionBluUltraLionBlu Member, PRO Posts: 129

Some time ago I tried some universal builds found in the forum. I seemed to understand that the proportions were maintained but that depending on the device the portion of the screen visible horizontally is different.

So in a platformer it happens that I meet the enemies before or after depending on the device, do I understand correctly? If so, is there a way to have the same portion of the screen displayed everywhere?


  • bob loblawbob loblaw Member, PRO Posts: 602

    i’m guessing your using stretch for your build?

    shortish answer:

    you could set a ‘safe zone’ in the middle of your scenes, which would be the size/aspect ratio of your default build (for me that’s ipad/4:3), with the game play always taking place in just that area.

    then make a mask/filler layer below your HUD but overlaying the other layers that covers all the side bits where the display would extend to on longer devices.

    it would probably also help if you used logic where your enemy AI didn’t kick in unless it was within a certain range of the player.

    long answer:

    ^ that, plus this....

    in effect (using an 1024x768px ipad default build as the base and a scene size of 1800x768 px to cover for vary flat displays), your camera would be set at origin x=388 (midpoint 900- half ipad width or 512) and the safe area stretching from that point for 1024px. then either side of that you would put a mask actor of size 388x768. when adjusting for the stretch universal build, your camera x origin would change to 900 - half the display size of the device being used, and the camera width would change to the device screen width. so the wider the device, the more of the masking actors would show.

    otherwise you could do overscan, which chops the top and bottom of your scene to fill the width. anything that gets cropped that you need on the display would need rules to adjust. also, if you have a camera fixed on something it won’t follow right up or down so may affect game play.

    thats a little long winded but i hope it makes sense.

  • UltraLionBluUltraLionBlu Member, PRO Posts: 129

    First of all thank you for the long answer.

    Unfortunately I had problems with the card to pay and it is now blocked, so I won't be able to access gamesalad for a while.

    I had done some tests months ago, I seem to remember that the method I preferred was stretch with the universal build of the user Armelline (now I don't remember what discussion I had found it in).

    I was working on an ipad project and on my galaxy S8 everything was well proportioned but showed a larger portion of the screen horizontally.

    I don't know if I understood all the steps of your answer well, I think I understand that I should create an artificial letterbox, put 2 lateral bands following the movements of my character, right? And add intelligence to enemies to keep them from acting until they exit the artificial bands?

    I was afraid it was something like this, I was hoping for something easier, I would like to use letterbox but I read that it is not accepted, for now I don't have to publish anything but I wanted to start understanding.

  • bob loblawbob loblaw Member, PRO Posts: 602

    yep, you understood right - but i’ll just also say that if you use AI to trigger your enemy, you probably don’t need to use the side bands. depends what you want your user to see in gameplay.

    you could just use constrained behaviours in your enemy to check if magnitude and/or enemy x and y are with however many pixels of the player before the enemy is triggered.

  • UltraLionBluUltraLionBlu Member, PRO Posts: 129

    I don't like the idea that on one device it looks different than another. Perhaps the creation of actors on the sides will be the only way to prevent this from happening. In any case I will be able to better understand when the time to try will come, thanks!

  • ArmellineArmelline Member, PRO Posts: 4,994

    I am close to finishing a pretty thorough set of videos and templates explaining universal builds, what the options are, how to implement them. Well, I'm close to finishing the templates. How long the videos take will depend on how much editing they end up needing. Editing is not my speciality :D

  • UltraLionBluUltraLionBlu Member, PRO Posts: 129

    wow this is great news, I have to say that programming with Gamesalad I find it very pleasant, being able to make a character move make him perform actions is fun, but the universal build question and the purchases in the app do not interest me at all, to be able to see some good tutorial will be very useful !!

    Good luck with editing :D

Sign In or Register to comment.