| Because of the rapid development of mobile phones in recent years,almost every people hold a mobile phone.Mobile games also entered people's daily lives.So the market of mobile game is growing up,and the development of it is becoming more valuable too.The development of game software is generally based on a game engine,so the research and application of game engine is particularly important.So it's need to do some research and choice about mobile game engine.In this context,the study made a comparative study of the mobile game engine and took libGDX as selected engine,based on which developed a tower defence game.The path-finding function,AI solution and screen fragmentation is the key technological problem.During the development process,the thesis studied the problem and gave the resolution and then verified the feasibility.The work could be a technological reference for other developers.Based on the background,after researching of Andoird game engine and development of a tower defence game,the thesis focused on the following points:1)After the research about Unity Navmesh and A star path-finding function,the thesis used a function based on the path conner.2)After the research about two AI solution FSM and behavior tree,the thesis used an AI solution based on ACT(Action,Condition and Trigger)which was used to describe the AI for monster,tower and the level.3)After the research about the solution for screen fragment problem on Android platform(the problem about different performance on the Android devices who have different pixel resolution)in Android native application and Unity NGUI,the thesis used a new solution based on “Design resolution” and “Anchor” for the problem.The development Forest Guard is devided into two phases,the research of this topic is in the first,while the game completion and the production is in the second.However,in order to consider the integrity of the research for engine,some requirement would be listed in the requirement analysis and system design,but the requirements would be implemented in the second phases.The development of Forest Guard can be separated into two parts: core combat and level organization.In core combat part,some game units like game map,game monsters,defend towers and glory towers were designed.Based on those game units,the auto path of monster,the distribution and monster detection of defense towers,and fighting between defense towers and monsters were implemented.Meanwhile,the calculation of damage and check of game success or fail was added.Upon completion of core combat,level system with increasing difficulty was configured,so players can start from level 1,explore and advent more levels.The operation and core combat of every level is very same,but difference of monster amounts,the time interval between two monster armies and the type of the useable defend tower make it more interesting to explore more levels.Then some optimization of game content,game UI,and game values was made to make the game more interesting.Finally,built the game software on the libGDX1.5,and made some test on several android mobile phones,including feature test,performance test and compatibility test.On the other hand,the technical solution such as path-finding function,AI solution,screen fragment problem was tested.The test results showed that:1)As the carrier of engine research,the development of Forest Guard covered some progress about game development based on libGDX.It provided some referece about engine choosing and Android game developing based on libGDX.2)libGDX game engine is capable to develop the most casual games,but not suitable for heavy game development.3)Path-finding function that based on the path conner could cover the requirement in the tower defence games.4)The AI solustion based on ACT element could complete the AI feature about the monster,tower,and the level in tower defence game.5)The solution about the screen fragment resolved the problem in the Android game development based on libGDX,the UI of Forest Guard displayed correctly on 4 different devices. |