Git Product home page Git Product logo

wenzcao / noahgameframe Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ketoo/noahgameframe

0.0 2.0 0.0 1.13 GB

A fast, scalable, distributed game server framework for C++, include actor library, network library,can be used as a real time mutliplayer game engine ( MMO RPG ) .

Home Page: http://www.yowoyo.com

License: Apache License 2.0

Batchfile 0.05% C++ 72.70% Objective-C 0.18% C 0.28% Makefile 4.24% Lua 0.22% Protocol Buffer 0.54% HTML 1.87% Shell 0.03% C# 19.83% Smalltalk 0.05%

noahgameframe's Introduction

NoahGameFrame

######Copyright © http://www.yowoyo.com

#####交流QQ群:341159815

##What is it?

NF is a lightweight, fast, scalable, distributed plugin framework.

The features:

  • 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

Manual

https://github.com/ketoo/NoahGameFrame/blob/develop/Introduce/NFrame_Introduction_CHS.pdf

Architecture:

###App Architecture:

App Architecture

###Server Architecture Server Architecture

###Event Driver:

Event Driver

Get the Sources:

git clone https://github.com/ketoo/NoahGameFrame.git

or

svn checkout https://github.com/ketoo/NoahGameFrame

Dependencies:

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++

Supported Compilers

  • GCC >= 4.8
  • VC >= 9.0 (sp1)

How to build:

Windows[VS2012]

  • 1:download all source;

  • 2:extract nessasery lib: Dependencies\boost_1_53_0.zip to Dependencies\

  • 3:extract nessasery lib: Dependencies\lib.zip to Dependencies\

  • 4:open the solution: trunk\NoahFrame.sln

  • 5:build the solution

  • 6: run the binary file by trunk_Out\Server\Debug\Run.bat

Linux[CodeBlock 13.1]

  • 1:download all source;

  • 2:extract nessasery lib: Dependencies\boost_1_53_0.zip to Dependencies\

  • 3:extract nessasery lib: Dependencies\lib.zip to Dependencies\

  • 4:open the solution by code::block: trunk\NF.workspace

  • 5:add c++11 optional for every project of this solution

  • 6:build library: NFNet, NFCore, NFEventTriggerPlugin, NFKernelPlugin, Theron, libprotocolbuf[libprotocolbuf-lite], NFLogPlugin, NFPluginLoader

  • 7:build all other plugin

  • 8: run the binary file by trunk_Out\Server\Debug\Run.sh

Tutorial:

// -------------------------------------------------------------------------
//    @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

noahgameframe's People

Contributors

ketoo avatar flyicegood avatar nickyang4github avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.