The source code of the martial arts world, the predecessor of tianlong, was circulated on the Internet. The younger brother also made a copy from his friends and studied it.
90% of the source code has been read, and the role of each class is basically understood.
Some netizens often ask me questions about the tianlong source code framework. There are too many people to ask, so I just want to summarize it.
Tianlong ClientCode. There are two main parts: an editor and a client.
The editor and client share a rendering module, that is, wxcore;
Let me talk about the client first, as shown in figure
First, we will briefly introduce the basic functions of the module.
Ceguibase is the core module of cegui
Ceguifalagard is the appearance window class of cegui,
Ceguifalagardex is a self-expanded exterior window class, such as a small map.
Ceguiogrerenderer is the interface class for cegui rendering in ogre,
Ceguisystem is the re-encapsulation of cegui. Why re-encapsulation and expansion? The following will analyze
Expat is parsed in XML for tinyxml.
Opcode is the credential stuffing Library
Wxclient is the client EXE,
Wxcore is a rendering module that encapsulates ogre again,
Wxengine is an interface library, which has no function. It is designed to allow the two DLL libraries of the UI module and the render module to call the client EXE code and implement interfaces, if the UI and render are used as static Lib, The wxengine can be discarded completely.
Wxnetpackets, Network Package
Wxrender is a coupled layer that encapsulates wxcore again. In this way, you can use other engines without damaging the client framework,
The most important of the above modules is
Ceguifalagardex-extension, very practical
Ceguisystem-UI module, very important
Wxcore-underlying rendering Module
Wxrender -- Rendering Module
Wxclient-the overall framework of the client, including input, network, events, scripts, data, and objects.
This article from the csdn blog, reproduced please indicate the source: http://blog.csdn.net/qq18052887/archive/2010/06/01/5641004.aspx