| The rapid popularity of mobile Internet and mobile devices,and to promote mobile games(especially card games)in rapid growth.However,behind the rapid growth of card games is the phenomenon of homogeneity of playing methods,poor functional expansibility and low efficiency of research and development.Therefore,the realization of a card game with innovative playing methods and stable performance is the focus of game industry companies and even individuals.This thesis is to develop a network card type of hand,the core of play is still the player through the network card,form their own team,to fight with the enemy,but of its distinct characteristics,not only the team's role is independent of the agent,to be able to walk,run,fight,more players draw the image on the screen with your fingers to control the role switching novel style of combat,the style is different from any card game on the market,has solved the problem of homogeneity.In the design and implementation of the game,the four core modules of registration/login,copy(a core gameplay that can complete tasks and upgrade levels in the game),arena and cross-suit warfare are designed and implemented.The main work is as follows:(1)The client adopts the cocos2d-x engine technology to realize the functions of interface switching,graphics rendering and event distribution in the game,and manages and optimizes the memory by means of reference counting and asynchronous resource loading technology,so as to improve the game performance and user experience.(2)The client uses the mixed programming of C++ and Lua,which integrates the advantages of each language to improve the development efficiency of the game.As an embedded scripting language,Lua can update the game resources independently,providing convenience for the maintenance after the game is launched.The design mode of SMVC is designed and adopted throughout the development process,which not only makes the function modular and readable,but also improves the efficiency of secondary development and facilitates code migration and function extension.(3)The network communication between client and server adopts Socket and Http mode to synchronize data in real time.The data adopts Protocol Buffer format.It reduces the data flow and improves data security.(4)Based on the gesture recognition technology in the field of artificial intelligence,a simple gesture recognition algorithm was designed and implemented,which realized the realization of the core gameplay function by identifying specific graphics based on coordinate points.(5)In the process of fighting,the character's image action USES the Spine bone animation technology,which replaces the previous frame animation.Because of its light weight and little resource,it can realize the function and reduce the burden of memory.(6)For the comparison and study of breadth-first search(BFS),Dijkstra,greedy best first search and A* algorithm,A* algorithm of binary-heap is adopted to realize the intelligent body's path search. |