i need to tilt a layout in android about 45 degree anticlockwise. i want to implement a game in android as stackopolis .is there any method to align tiles as in the game.I have the tile image,and now i use canvas to align this.but there i cannot get the click event and it is difficult to align tiles.is grid view is compatable.any new idea. i have these images with me.
i want to align this tile in grid.and need click event as in the stackopolis
For creating a game like this you really don't want to use layouts. You would create a tile engine using bitmap blitting or OpenGL.
You can use the following methods, for rotation of view,
setRotation
setRotationX
setRotationY
Note: All the above are Since: API Level 11
If you dont know much about making a game the read this book
http://www.amazon.com/dp/1430230428/?tag=stackoverfl08-20
It will teach you EVERYTHING you should need to know to do what you want. It also sets up OpenGL ES for you so your app will be nice and smooth
I really would suggest OpenGL, using the Canvas class will not only be slower but it is going to be limited as well
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With