Constrain game size to device screen size

caiokawasakicaiokawasaki Member Posts: 68
edited February 2013 in Working with GS (Mac)
What do you think about that? On the menu scene i want to put some rules that will change the game display size to the device screen size, with that i want to make my game able to all the android devices... What do you think about that? Should it work?

Comments

  • PixelMetalPixelMetal Member Posts: 283
    edited February 2013
    It will partially work. GS doesn't accurately report available display size on devices with on-screen Android OS controls, it will only report the full display size. The lack of iOS on-screen controls hides the issue on the Apple product side.

    There's more to it than resizing the game display size, but that's a good place to start.

  • caiokawasakicaiokawasaki Member Posts: 68
    It will partially work. GS doesn't accurately report available display size on devices with on-screen Android OS controls, it will only report the full display size.

    There's more to it than resizing the game display size, but that's a good place to start.

    Do you think i can get any type of bug?
  • PixelMetalPixelMetal Member Posts: 283
    That's not a very specific question :).
  • caiokawasakicaiokawasaki Member Posts: 68
    That's not a very specific question :).
    there is another way to make the resize? My method is a good one?
  • PixelMetalPixelMetal Member Posts: 283
    edited February 2013
    Your way is pretty much the only way to do it. Without the ability to differentiate between Android devices with on-screen controls or not, the best we can do is get the display size and resize our scenes to that.

    NOTE: Scene resizing does NOT work properly if the actor is in the scene when the scene loads. You should spawn the actor controlling the scene size AFTER the scene loads.
  • POMPOM Member Posts: 2,599
    Change the game display size? you refer to the camera size?

    Roy.
  • caiokawasakicaiokawasaki Member Posts: 68
    Change the game display size? you refer to the camera size?

    Roy.
    not the camera size, but the game size.
    example: the iphone size is 480x320 i want to create any rules to resize the game to an 800x600 device...
    do you understand?
  • caiokawasakicaiokawasaki Member Posts: 68
    Your way is pretty much the only way to do it. Without the ability to differentiate between Android devices with on-screen controls or not, the best we can do is get the display size and resize our scenes to that.

    NOTE: Scene resizing does NOT work properly if the actor is in the scene when the scene loads. You should spawn the actor controlling the scene size AFTER the scene loads.
    i do that... In all my projects, i create a "spawner", it will spawn all actors in the scene, my actors positions are random it will change all time...
  • mrpacogpmrpacogp Member Posts: 400
    You can change camera size but not game size.
    Its the fighting with overscaning i think:
    http://cookbook.gamesalad.com/tutorials/1/parts/50
  • POMPOM Member Posts: 2,599
    Change the game display size? you refer to the camera size?

    Roy.
    not the camera size, but the game size.
    example: the iphone size is 480x320 i want to create any rules to resize the game to an 800x600 device...
    do you understand?
    Not sure i understand, do you WANT to do this? or did you already managed to do this?

    Cause im not sure its even possible.. you can play with the camera but not with game size

    Roy.
  • caiokawasakicaiokawasaki Member Posts: 68
    Change the game display size? you refer to the camera size?

    Roy.
    not the camera size, but the game size.
    example: the iphone size is 480x320 i want to create any rules to resize the game to an 800x600 device...
    do you understand?
    Not sure i understand, do you WANT to do this? or did you already managed to do this?

    Cause im not sure its even possible.. you can play with the camera but not with game size

    Roy.
    I want...
  • PixelMetalPixelMetal Member Posts: 283
    edited February 2013
    Change the game display size? you refer to the camera size?

    Roy.
    not the camera size, but the game size.
    example: the iphone size is 480x320 i want to create any rules to resize the game to an 800x600 device...
    do you understand?
    Not sure i understand, do you WANT to do this? or did you already managed to do this?

    Cause im not sure its even possible.. you can play with the camera but not with game size

    Roy.
    Changing the game scene size at runtime does work, if the object resizing the scene is spawned after the scene loads.

  • POMPOM Member Posts: 2,599
    Change the game display size? you refer to the camera size?

    Roy.
    not the camera size, but the game size.
    example: the iphone size is 480x320 i want to create any rules to resize the game to an 800x600 device...
    do you understand?
    Not sure i understand, do you WANT to do this? or did you already managed to do this?

    Cause im not sure its even possible.. you can play with the camera but not with game size

    Roy.
    Changing the game scene size at runtime does work, if the object resizing the scene is spawned after the scene loads.

    Hey @PixelMetal
    Can you share a simple template? im not sure I'm following what you refer to when you say resize a game size.. it sounds like you are saying you can stretch the game display size during runtime (not the camera but the actual display size), and I'm trying to do it, it doesn't work.

    Roy.
Sign In or Register to comment.