Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Positioning at absolute bottom
Started by nickolascarlos Nov 08 2019 06:05 AM

2 replies to this topic
[TOPIC CONTROLS]
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

nickolascarlos

[GLOBAL: userInfoPane.html]
nickolascarlos
  • Observer

  • 1 posts
  • Corona SDK

I'm trying to position a ground (platform) exactly at the bottom of the device screen, but its position changes when I change the screen aspect ratio, as you can see in these images below:

 

https://prnt.sc/pu8wc0

https://prnt.sc/pu8wc0

 

I've already tried changing .contentHeight to .actualContentHeight, but it didn't go as expected. I've also changed the content scale in config.lua file, but the game got completely deformed. How can I fix it?

 



[TOPIC: post.html]
#2

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 26,300 posts
  • Enterprise

This blog post should help you...  https://coronalabs.com/blog/2018/08/08/understanding-content-scaling-in-corona/

 

Rob



[TOPIC: post.html]
#3

roaminggamer

[GLOBAL: userInfoPane.html]
roaminggamer
  • Corona Geek

  • 7,593 posts
  • Corona SDK

Here too is and example that may help you understand how to figure things out:

 

https://github.com/roaminggamer/RG_FreeStuff/raw/master/AskEd/2015/10/lgg4.zip

 

lgg4.png

 

 

 

From my AskEd repository (400+ code answers to posts).  Get whole set and more by downloading RG FreeStuff:

https://github.com/roaminggamer/RG_FreeStuff/archive/master.zip


  • pixec likes this


[topic_controls]
[/topic_controls]