I am creating a game where a snake will be moving dynamically based on the user key directions, then how should I implement this snake image in my activity?
Use image view and put a snake image in that view, and move the view based on user key movements.
Use frame animation with multiple snake images on the same image view.
Use custom view, where you can draw your own shapes dynamically on canvas.
we can use any of the above 3 options for this requirement.
developing a snake game needs to redraw snake image very randomly and dynamically. also snake size may keeps increasing, so its better to take complete control over canvas and draw on it using a custom view.
Back To Top