Game Development Reference
In-Depth Information
Figure 3-1. The snap view image I am using for my game Super Paper Monster Smasher.
The basic concept is that, while the canvas is automatically being stretched out to take up the
full screen, the snap-view image isn't visible. To make sure, we'll alter its CSS properties to
hide it. When I detect snap view, I simply hide the canvas and show the snap-view image.
First, let's take a look at the CSS-only approach.
@media screen and (-ms-view-state: fullscreen-landscape) {
#canvas{
display: block;
}
Search WWH ::




Custom Search