Giter VIP home page Giter VIP logo

negum.core's Introduction

Negum.Core

1. General Overview

Negum.Core is a library which provides key classes and interfaces for a 2D fighting game engine.
It allows you to read and parse characters, stages, fonts, etc.

1.1. Library structure

Negum.Core was build out of layers which communicate with each other.

Layer Name Description File
X Container Used to create objects and store them in shared space. Can be customized to use 3rd party container. NegumContainer
1 Configurations Contains various configuration definitions describing files in directories by their types (AIR, SFF, DEF, ANIM, etc.). IConfiguration
1 Readers Readers are generally used to read File or Stream into appropriate output configuration or other type. IReader
2 Managers Managers are used to represent various file types and search through them to find values. IManager
3 Loaders Loaders are used to load all entities (characters, stages, fonts, etc.) from specified directory or for specified Engine. ILoader
3/4 Engines Engine represent everything what was read from specified root directory using IEngineProvider IEngineProvider

1.2. Features

  • Read files with extensions: cfg, def, sff (v1, v2, v2.1), air, cns, cmd, snd, act, fnt (v0, v2)
  • Read fields from files
  • Load all characters, stages, fonts, etc.
  • Load characters and stages only from configuration files
  • Load data from config directory
  • Generate single object with all data from directory - IEngine

2. How To Use

2.1. Installation (NuGet)

Easiest way to install Negum.Core library is via NuGet like so:

dotnet add package Negum.Core

Or check it directly Here

2.2. Code / Sample Usage

using Negum.Core.Containers; // We want to initialize and use NegumContainer class
using Negum.Core.Engines; // Contains main IEngine and IEngineProvider interfaces

// ...

// This step is optional !!!
// You can override default binding for NegumContainer and assign it to 3rd party Container
NegumContainer.Registerer = (lifetime, interfaceType, implementationType) => { }; // Used for registering new type
NegumContainer.Resolver = (typeToResolve) => null; // Used for resolving type

// ...

// Take main provider which is used to build IEngine object
IEngineProvider engineProvider = NegumContainer.Resolve<IEngineProvider>();

// Read data from root directory
// Root directory is a directory which contains: chars, data, font, stages, sound, etc.
// This initialization may be used multiple times for various directories
// Every time this method is used, new IEngine object will be returned
IEngine engine = await engineProvider.InitializeAsync("path_to_root_directory");

// ...

// As an example we can take a display name of the first character read from chars directory
string characterName = engine.Characters.FirstOrDefault().CharacterManager.Info.DisplayName;

// ...

3. Default Usage

Default usage of Negum.Core can be found in Negum.Game
It should not have any external dependencies except .NET libraries.


4. License

Click Me

negum.core's People

Contributors

sejoslaw avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

bubdm nionsisre

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.