Copyright © http://www.noahframe.com
#####交流QQ群:341159815
NF is a lightweight, fast, scalable, distributed plugin framework.Greatly inspired by OGRE and Bigworld.
- it is easy to use interface oriented design minimise the effort
- extensible plugin framework makes getting your application running is quick and simple
- clean, uncluttered design, stable engine used in several commercial products
- using the actor model has very high performance(by theron);
- based on the event-driven and attribute-driver can make business more clearly and easy to maintenance
- based on the standard c + + development, cross-platform support
- with existing c++, c# game client for rapid development
- Cross-platform
git clone https://github.com/ketoo/NoahGameFrame.git
or
svn checkout https://github.com/ketoo/NoahGameFrame
Need build sub librares:
- Boost.System
- Boost.Chrono
- Boost.Thread
- libevent-2.0.21-stable
- protobuf-2.5.0
- redis-cplusplus-client
- Theron-6.00.01
- easylogging++
- GCC >= 4.8
- VC >= 9.0 (sp1)
- Download all source;
- Extract nessasery lib: Dependencies/boost_1_53_0.zip to Dependencies/
- Extract nessasery lib: Dependencies/lib.zip to Dependencies/
- Extract nessasery lib: Dependencies/gperftools-2.1.zip to Dependencies/
- Extract nessasery lib: Dependencies/curl-7.37.1.zip to Dependencies/
- Open the solution: NoahFrame.sln
- Build the solution
- Copy files:libmysql.dll mysqlpp_d.dll to _Out/Server/Debug/NFGameServer1/
- Copy files:libmysql.dll mysqlpp.dll to _Out/Server/Release/NFGameServer1/
- Copy files:libmysql.dll mysqlpp_d.dll to _Out/Server/Debug/NFLoginServer/
- Copy files:libmysql.dll mysqlpp.dll to _Out/Server/Release/NFLoginServer/
- Copy files:libmysql.dll mysqlpp_d.dll to _Out/Server/Debug/NFWorldServer/
- Copy files:libmysql.dll mysqlpp.dll to _Out/Server/Release/NFWorldServer/
- Run the binary file by _Out/Server/Debug/Run.bat
Who can do this?
- Download all source;
- Extract nessasery lib: Dependencies/boost_1_53_0.zip to Dependencies/
- Extract nessasery lib: Dependencies/lib.zip to Dependencies/
- Extract nessasery lib: Dependencies/gperftools-2.1.zip to Dependencies/
- Extract nessasery lib: Dependencies/curl-7.37.1.zip to Dependencies/
- Open the solution with CodeBlocks: NF.workspace
- Add c++11 optional for every project of this solution
- Build library: NFNet, NFCore, NFEventTriggerPlugin, NFKernelPlugin, Theron, libprotocolbuf[libprotocolbuf-lite], NFLogPlugin, NFPluginLoader
- Build all other plugin
- Run the binary file by _Out/Server/Debug/Run.sh
WebSite: https://github.com/NFGameTeam/NFrame-java
WebSite: https://github.com/ketoo/NFrame
The NFrame project is currently available under the Apache License.
// -------------------------------------------------------------------------
// @FileName : HelloWorld1.h
// @Author : ketoo
// @Date : 2014-05-01 08:51
// @Module : HelloWorld1
//
// -------------------------------------------------------------------------
#ifndef _NFC_HELLO_WORLD1_H_
#define _NFC_HELLO_WORLD1_H_
#include "NFComm/NFPluginModule/NFIPluginManager.h"
class HelloWorld1
: public NFILogicModule
{
public:
HelloWorld1(NFIPluginManager* p)
{
pPluginManager = p;
}
virtual bool Init();
virtual bool AfterInit();
virtual bool Execute(const float fLasFrametime, const float fStartedTime);
virtual bool BeforeShut();
virtual bool Shut();
protected:
};
#endif
#include "HelloWorld1.h"
bool HelloWorld1::Init()
{
// Use this for initialization
std::cout << "Hello, world1, Init" << std::endl;
return true;
}
bool HelloWorld1::AfterInit()
{
// AfterInit is called after Init
std::cout << "Hello, world1, AfterInit" << std::endl;
return true;
}
bool HelloWorld1::Execute( const float fLasFrametime, const float fStartedTime )
{
// Execute is called once per frame
//std::cout << "Hello, world1, Execute" << std::endl;
return true;
}
bool HelloWorld1::BeforeShut()
{
//before final
std::cout << "Hello, world1, BeforeShut" << std::endl;
return true;
}
bool HelloWorld1::Shut()
{
//final
std::cout << "Hello, world1, Shut" << std::endl;
return true;
}
- how to use the world's most advanced data engine
- how to use the synchronous events
- how to use the asynchronous events
- use multiple cpus to get high performance