Quick Links: Download Gideros Studio | Gideros Documentation | Gideros Development Center | Gideros community chat | DONATE
How to dynamically place objects? - Page 2 — Gideros Forum

How to dynamically place objects?

2»

Comments

  • I ended up understanding and using @zvardin's link.
    local dx = application:getLogicalTranslateX() / application:getLogicalScaleX()
    local dy = application:getLogicalTranslateY() / application:getLogicalScaleY()
    local ex = dx + application:getContentWidth()
    local ey = dy + application:getContentHeight()
    dx,dy for topleft and ex,ey for bottomright :)

    Likes: hgvyas123

    Gideros Tutorials and Mobile apps:
    http://BlueBilby.com/
    +1 -1 (+1 / -0 )Share on Facebook
  • actually -dx,-dy will be top left

    :)
  • Oh yes. Sorry.
    Gideros Tutorials and Mobile apps:
    http://BlueBilby.com/
  • petecpetec Member
    edited April 2013
    actually this method will work for only on know ratio it will not work when new device launched with new type of aspect ratio or might be any missed ratio also for the resolutions like 480x800 and 480x854 ratio would be almost same. so i think my method is better for all kind of resolution

    :)
    I'm sure it is likely to be!
  • Hmmmm. Now ex and ey are 320 and 480 no matter what resolution the Player is. I'm doing something wrong somewhere.
    Gideros Tutorials and Mobile apps:
    http://BlueBilby.com/
  • Ah. Didn't set scaling. nm
    Gideros Tutorials and Mobile apps:
    http://BlueBilby.com/
Sign In or Register to comment.