C # development Wpf/silverlight animation and games series Tutorials (Game Tutorial): (37)

Source: Internet
Author: User
Tags silverlight

C # development Wpf/silverlight animation and game series Tutorials (Game Tutorial): (37) Map Adaptive Zone loading

Now that the map editor has been able to slice the map, the next thing we need to do is to assemble the cut picture to replace the whole map. What needs to be specifically stated is that if you load all slices into the game at once and display them, the effect is almost indistinguishable from using an entire map, and may even be worse in performance. The purpose of this section is to adaptively populate the game window area with these slices, That is, the use of the least map to achieve a seamless window fill, thereby improving the overall performance of the game.

Tutorial Example Game window mode when the form size is 800*600, then we first based on this size to 400*300 to use the map editor to cut several map slices:

At this point, we turn back to compare the size of the map and the volume of the map slices that are now sliced, it will be found that the total capacity after slicing is nearly half as long as it remains unchanged. If you are doing a network version, slicing to achieve on-demand downloads will shorten the time users load the program and reduce the burden on the server:

Next is the key, the game window 800*600, map slices for each 400*300, then each need to show how many slices can be in the protagonist no matter where the position can fill the game window? You may wish to look at the following picture:

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.