Answer the question
In order to leave comments, you need to log in
How to write turn switching logic for players in Java?
There is a small game
. The choice of participants from 2 to 5.
The player's move consists only in scoring points and displaying information about who exactly walks. moves should switch in turn depending on the selected number of players. Initially
there are two buttons. "Yes and no". For "Yes" 1 point is awarded to the walking player, for "No" - not awarded
There is a TextView in which the name of the player who is walking should be displayed
The number of players from the start activity is transferred to the game activity by the PutExtra method as 'int'
You can simply link to manuals and relevant articles on developer.android.com
, I just don’t know what exactly and how to look for
. I read one book on java for dummies, I didn’t find any advice from it
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question