Android Question Adapting a game on multiple screens

Victor Gazquez

New Member
Hey, i'm actually creating a game on B4A. The game is simple, i have a car (blue one) that I can move on differents lines to escape the pink cars that are comming from the Top of the screen.

Everthing is working great exept that when I Debug the game on an other phone all the cars dimension are moving.

I've tried multiple time to look differents thread on multiple screen, I've change all my dimension to dip unit but nothing change i've also tried to create multiple layout with different scale but nothing changed as well.

I'm begging on B4A and i don't understand everything.
Can you help me out? :) ;)

Thank you :p

8RlKTdu.jpg

NWg8va8.jpg
 
Last edited:

sorex

Expert
Licensed User
Longtime User
you need to think in percentage of the screen.

you car moves between the 2 yellow lines so between 8%x & 92%x based on the first image.

you also need to scale your car proportionally to your screen width. it's about 17%x by 34%x in the first image.

the same goes for those lines (or is it a tarmac + lines image?). scale and position them based on the current resolution.
 
Last edited:
Upvote 0
Top