Universal Build – Using Stretch

This post was written by BBEnk

I see a lot of talk about Universal Build here lately, and thought I would share how I do it for those who need help. I don’t like overscan because you lose area so I use stretch and gain a few pixels much better,and my mic is broken so I will try and explain and show video of it working.

I can’t say it’s 100% perfect but works well enough for me. :)

sorry my grammar is bad but here goes,lol.

I have a actor unlocked called camSize on every scene in here I change 5 attributes for the game in video, I have a portrait game that only uses 3.

camSize – this stores new camera size by checking the device against iPad size “deviceWidth x768 / deviceHeight = new
camSize, this is used to change camera size on ever scene, and by using stretch you get a perfect fit on anything.

Soffset.X – this store offset for actors if iPad is used it’s 0 so nothing changes “new camera size – 1024 = offset”
this is used to offset actors for different devices. Now you only need to add this to actors that set at 512 and
higher because ever thing below this doesn’t need to move.because camera expands to the right not left.
also sometime you may use change self to position+offset for a full move aka “controls” but some things may
only move to position+offset/2, and if iPad is being used offset will be 0.
offset is used the most on anything that will need to change positions for different devices just adding a simple
change attribute to actors saying change self position to self.position+offSet or offSet/2 does the trick.

SceneMin – this store half of the new cam size.
this I use for actors that set in middle of scene “512” I just tell them to go here, no matter what device there on
they will find there spot, and so can backgrounds if need be.

SceneMax – this stores scene size – sceneMin.
I use this for level select screen and to make sure camera stops moving at end of scene at correct spot,and ETC

SceneSize – stores full length of scene.
I use scene size to get sceneMin or whatever.

Heres a video of my game Steam Jack, notice the splash screen sets up most things and a single scene like title screen only needs to change camera size and a game screen changes 4 and that one could be 1 but my level select needs a scene size change so I just include it in ever play scene.

Hopefully this will help new people out.