The loop play method of background map in mobile phone gamesTechnical field
The invention belongs to infotech, particularly relate to the loop play method of background map in mobile phone games.
Background technology
In the mobile phone games of current 2d, the movement of personage in background, is normally realized by the movement of background picture.In order to avoid the continuity of background picture, way common is at present arranged to by the width of background picture very long, and this not only causes the increase of program volume, also causes the waste of system resource.How to solve the problem, be the technical problem to be solved in the present invention.
Summary of the invention
In order to overcome the problems referred to above, the invention provides the loop play method of background map in the mobile phone games that a kind of efficiency is high, volume is little.
Technical scheme of the present invention is to provide the loop play method of background map in a kind of mobile phone games, it is characterized in that: it comprises the following steps,
1) make a background map, described background map is arranged in mobile phone screen;
2) copy of background map described in is made;
3) after described background map, described copy being close to described background map is disposed side by side on outside mobile phone screen;
4) described background map and copy is synchronously moved forward;
5) when described background map shifts out described mobile phone screen completely, described background map is moved to below being close to described copy and being disposed side by side on outside mobile phone screen of described copy, and synchronously move forward described background map and copy, and when described copy shifts out described mobile phone screen completely repeating said steps 3-5).
Preferably, the pattern energy seamless link of described background map left side edge and right side edge.
Preferably, the width of described background map is 1 to 1.5 times of described mobile phone screen width.
Preferably, the width of described background map is 1.1 times of described mobile phone screen width.
In mobile phone games of the present invention, the loop play method of background map simplifies art designing's making, and before and after utilizing, the mode of the background picture loop play of seamless link realizes the movement of background picture, and system resource is taken few, program volume is little.
Embodiment
Below the specific embodiment of the present invention is described in further detail.
The invention provides the loop play method of background map in a kind of mobile phone games, it comprises the following steps,
1) make a background map, background map is arranged in mobile phone screen;
2) copy of a background map is made;
3) after background map, copy being close to background map is disposed side by side on outside mobile phone screen;
4) background map and copy is synchronously moved forward;
5) when background map shifts out mobile phone screen completely, background map is moved to below being close to copy and being disposed side by side on outside mobile phone screen of copy, and synchronously moves forward background map and copy, and when copy shifts out mobile phone screen completely repetition step 3-5).
Level and smooth in order to ensure transition between copy and background map, when design background map, need guarantee the pattern energy seamless link of background map left side edge and right side edge.
In addition, the width of background map is 1.1 times of mobile phone screen width is the best, can avoid the background shake caused in handoff procedure.
Above embodiment is only the present invention's a kind of embodiment wherein, and it describes comparatively concrete and detailed, but therefore can not be interpreted as the restriction to the scope of the claims of the present invention.It should be pointed out that for the person of ordinary skill of the art, without departing from the inventive concept of the premise, can also make some distortion and improvement, these all belong to protection scope of the present invention.Therefore, the protection domain of patent of the present invention should be as the criterion with claims.