vagaev's Recent Forum Activity

  • And one more thing it's important to scroll to the center of the layout. Sometimes you will need to make the background even bigger that the layout. It's all about proportions. I'm not sure if constructs when is scaling outer is adding the equal amount of pixels from both sides.

  • Well the layout size doesn't really matters here. What really matters is the window size,backround size (to cover gaps) and the anchor behaviors.(to keep everything relative to window)

    The game in my example was a pinball like game so it was very important to keep all the stuff in place (the game surface is bigger in age of zombies so relative position variation inside of the layout may be less important.

    The first question you will ask yourself is what kind of mobile platform do you aim?

    If you want your game to work from iphone 4 to ipad then you must support the 3:2,4:3,16:9.

    Which means (i give an example) that your window will be: 1152*768 (3:2) and layout will be 1366*768. This kind of configuration is good for pinbal games but it will maybe seem strange and not in proportion for other games when you will test it on 16:9 ratio. So you should maybe pick another layout or windows resolution from the link i have put above.

    It's all about proportions.

    I advise you to make a basic setup and give it a try.

  • if you use touch you don't need to use mouse condition.

    You can use sub events sticked with the 2 variables instead of "or"

  • I think this is possible if you mess with physics behaviors. Basically you will need to divide the loop into 2 pieces that will have different proprieties but form one object

  • Does the player has scroll to or bound to layout behaviors?

    I don't really know why it is occurring.

    Try on start of layout->scroll to object; player.

    Ps: try to resize your FF window size. Just curious

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • dude you cannot posts url :p

    Drop me a mail at agaev.vladimir(at)gmail.com

  • Or you can use web storage local values

  • If you want to add ads to make money you will have to be premium with cocoonjs. Sign up with mopub and use admob via mopub. They will give you a unique code you will have to insert when you will upload your app to cocoonjs site for final compiling. But before this you will have to program the apparition of ads in your give through cocoonjs plugin.

    For a link to a website try iframe (in custom plugins forum section)

  • Can you link your capx ?

    did you put scroll to behavior and platform behavior on the player?

  • <div class="post-censorship-notice">vagaev can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?</div>

    vagaev can only post plain text URLS until they have 500 rep. 1 URLS modified. Why?

    I have a good example ( i guess) on how to adapt your game to multiple ipad and iPhone resolutions.

    Here scirra.com/forum/viewtopic.php

  • Here are some ratio and resolutions comparisons

    http://en.wikipedia.org/wiki/Graphics_display_resolution

  • Here is an example that works on iphone5 and all ipads (haven't tested it on iphone 4 though, it has a 3:2 ratio)

    The WINDOW PROJECT is set to 1024, 768. It's a 4:3 ratio

    So it's designed for the smallest resolution.

    But the Layout size is designed for the bigger resolution. 768,1366 it's 16:9 ratio

    So when the window will zoom out to SCALE OUTER the 16:9 ratio we won't see the white lines because the layout will be big enough to cover it.

    However. If you don't use anchor behaviors on all your active and interactive game objects (don't use on moving objects though) all the positions will be changed because the screen windows is changing with the resolution (it's adapting from ipad to iphone5 screen). But if you put anchor behavior the relative position of all of your stuff would be conserved.

    Notice the Layout size: 768,1366 it's 16:9 ratio. that's because the layout must to be big enough to fit the iphone 5 resolution screen. Ipad resolutions are relatively smaller. For 768p the 4:3 ratio of the ipad has 1024 instead of 1366, about 100 pixel white stripe!!!. So if you design your game for ipad it will run perfectly on it but will have white stripes issues on larger resolutions such as ipod ones. So ALWAYS DESIGN YOUR WINDOW FOR SMALLER RATIO/RESOLUTION BUT YOUR LAYOUT SIZE FOR THE BIGGER RATIO/RESOLUTION.

    But if you look to the scroll to function you have (383, 683) -->actually it has to be 384, 683. Dunno why i wrote 383.

    We want to scroll to the center of the screen may it be a 4:3 or 16:9 ratio or even 3:2. It will be approximatively in the center of Layout

    To illustrate once more. I mentioned i haven't designed my game for iphone 4. (3:2 ratio)

    So how will i do it? Simple!

    I pick a window size compatible with 3:2 resolution (try to pick the nearest from 3:2, to 4:3 and 16:9 so distorsions will be minimal). Place your objects considering you have a 3:2 ratio game. Then anchor stuff. Make sure you layout is big enough to fit the bigger resolution and enjoy.

    You will have to check that your anchor behavior worked well though. Sometimes you have to mess with settings.

    Another alternative is pin to object. You create an invisible sprite with window's size and you pin stuff on it. But anchor is better.

vagaev's avatar

vagaev

Member since 7 Feb, 2014

None one is following vagaev yet!

Connect with vagaev

Trophy Case

  • 10-Year Club

Progress

10/44
How to earn trophies