June 2015
Beginner
354 pages
8h 23m
English
Carry out the following steps to make our game work in a tablet with touch inputs:
index.html file, we add the following touch controls before the end of the #game-container:<div id="left-button" class="touch-control"></div> <div id="right-button" class="touch-control"></div> <div id="restart-button" class="touch-control">Restart</div>
<meta> tag inside the <head> tag to control the viewport to fit the game into the iPad's 1024 px width.<meta name="viewport" content="width=device-width, initial-scale=0.78, minimum-scale=0.78, maximum-scale=0.78">
cargame.css file:.touch-control { position: ...Read now
Unlock full access