OK, so there can be 4-6 players which i'd like to place around a circular table (the table is just a background i suppose). My problem is, since each player can have many cards (up to 10) i'd like that the user will always see himself at the bottom with his cards opened, and see the rest of the players with hidden cards. Now, a player can join the ta开发者_StackOverflow中文版ble if it has room, i need then to adjust the sits accordingly so if a player clicks on the top left join button, when he starts playing i need him to see himself at the bottom.
How can i approach this? I suppose placing static views is not the right way. I've attached a scratch image of my desire UI.
Perhaps have a background (being the table) on your layout and then place markers at various points e.g 5 "boxes" around the table with the default text being join. When a play joins "seat" him at one by removing the default text and drawing his avatar perhaps on the location.
The players own view could be just his cards in the foreground of the screen. He views the table from first person.
Another approach would be to have 2 views, 1 being an overview of the table and a second for viewing the cards etc. which the user can switch between. Personally I'd prefer the first.
To build the first I would make the layout horizontal, use images for the 5 other players / join icons and then just have images for the player cards in the foreground, where the image changes depending on his cards. You can always dynamically add more images along the foreground as the number of cards go up.
I imagine the view looking something like this, but with the players cards more so in the foreground. http://www.bankroll-shark.com/images/888Poker/888PokerTable.jpg
There are two ways of doing this. You can either try to emulate the look of playing at an actual card table, or you can abstract completely, and just have a UI which shows the pertinent data, such as a handful of cards.
For a mobile device, abstracting out to include only important info makes better use of the tiny screens; however, there is no denying that a more realistic look tends to feel more professional and 'complete'.
So, assuming you do want to render the table and players and whatnot, then the simple way would be to let the player pick their seat from an overhead view, then just rotate the view so that their seat is rotated to the bottom of the screen.
精彩评论