When online gaming companies grow to a certain stage, there will be some experience and technical accumulation, which will be used for game development in the future, but if they carry a heavy burden of history, they should be discarded, developing a new architecture is adapting to the current needs of game development technology.
Recently, I was thinking about a reusable Server framework. This is not a day or two, but it has not been officially implemented yet.
Framework design purpose
1: accelerate the game development process and shorten the development cycle-Design and code reuse
2: improve product quality-developed and maintained by so-called "elite" programmers
To improve efficiency, we must be able to reuse it effectively. We sorted out some ideas and divided reuse into several layers.
1: The lowest layer: source code reuse, providing infrastructure encapsulation such as common queues, buffer, serialization, memory, threads, etc.
2: Component layer: This layer provides binary multiplexing modules, such as network modules and IPC communications.
3: framework layer: This layer uses the code and components at the bottom to build a framework. For example, it directly maps underlying network messages to the upper-layer script system, thread control, and message driver, overall Scheduling
4: script layer: This layer mainly describes the game logic, which consists of script supporting components and script code.
5: the highest level: Editor, compile a variety of Editors-task Editor, item Editor, skill editor, and so on, and interact with the underlying layer through generated scripts or data.
Based on this idea, if the underlying layer provides a good design, it is ideal to use the editor to build more games.
Combined with server architecture:
The above levels are only for the most complex logic servers. Here we will not talk about the server architecture design, and each server will always use the above levels.
Personnel considerations (looks like recruitment information: d)
Source code layer: requires many years of C ++ development experience and is familiar with common libraries, especially generic programming.
Component layer: has certain interface design capabilities
Framework layer: has certain interface design capabilities
Script layer: requires a lot of game development experience and has a good understanding of game logic and planning communication.
Editor: it usually does not require too high technical requirements. It can be implemented according to the design.
Implementation process:
The ideal is beautiful, and the reality is cruel. We have to consider some risks. First, we should consider whether the company's current situation requires such a group of people to do such a thing. Second, whether the company has such R & D capabilities and whether it has the above-mentioned technical talents, third, if it fails, what are the gains and losses.