Inexor is an open-source project which ???.
The main objective of this repository is the development of a entity component system based on Rust, a graph database,
Inexor is licensed under the MIT license.
The Reactive Semantic Entity Component System
is meant to be the core of the game engine
which represents the
game state
as the one and only truth using entities
and semantic relations
in a graph that controls and runs
the game logic
using reactive technologies
.
The minimal valuable product (MVP) contains the following goals:
- The entity system is a network of entities which are connected with semantic and directional relations in a graph
- The entity system is a network of properties which are connected with connectors in order to control the data flow from one entity to another
- The underlying data store technology is a graph database which is embedded in the application
- The entities/relations are reactive. This means the properties of the entity/relation are processed internally using reactive technologies (for example an entity of type AND outputs the result of a boolean and operation of the two boolean inputs)
- As a developer I can define components using the API
- As a developer I can create entities (with properties) using the API
- As a developer I can create relations (with properties) using the API
- As a developer I can connect and disconnect two properties which data flows from one to the other using the API
- As a developer I can create an entity of type AND-operation which outputs the AND-operation of two inputs using the API
- As a flow designer I can define components which can be used as building block for entities using a JSON file
- As a flow designer I can create entities with properties using a JSON file
- As a flow designer I can connect and disconnect two properties which data flows from one to the other using a JSON file
- As a flow designer I can define components which can be used as building block for entities using JavaScript
- As a flow designer I can create entities with properties using JavaScript
- As a flow designer I can connect and disconnect two properties which data flows from one to the other using JavaScript
- As a flow designer I can create flows using JavaScript
- As a flow designer I can define components which can be used as building block for entities using a GraphQL interface
- As a flow designer I can create entities with properties using a GraphQL interface
- As a flow designer I can connect and disconnect two properties which data flows from one to the other using a GraphQL interface
- As a flow designer I can create flows using a GraphQL interface
The goal is to integrate a set of strategically important libraries and glue them together in order to archive the goals:
- Dependency Injection (waiter_di)
- Embedded Graph Database (indradb)
- Reactive Streams (bidule)
- Logging
- Websockets Server
- HTTP Server
- GraphQL Server
- JavaScript Runtime (deno)
Further libraries might be of interest (asset management, remote procedure calls, ...) but these four libraries are the essential ones.
- Readme
- License
- Code of Conduct
- Changelog
- Code Documentation (
cargo doc
) - Unit tests (
cargo test --package rust-ecs-poc --bin rust-ecs-poc -- --nocapture --exact -Z unstable-options --show-output
) - Source Code Format (
cargo fmt
) - Reference Documentation (rst, wiki)
- Logging Framework
- GitHub Actions
- Compile
- Run tests
- Generate Code Documentation
- Create GitHub Release by Tag
- Packaging
- Create snap package
-
Component
-
EntityType
-
EntityInstance
- From Vertex Properties
-
RelationInstance
- From Edge Properties
-
Flow
- List of entity instances
- List of relation instances
-
ReactivePropertyInstance
- Not serializable
- Getter
- Typed Getters
- Setter
- Send (Send but not set)
- Tick (Resend)
-
ReactiveEntityInstance
- Not serializable
- Construct ReactiveEntityInstance from Vertex
- Construct Properties
- Typed Getters
- Setter
-
ReactiveRelationInstance
- Not serializable
- Construct ReactiveRelationInstance from Edge
- Construct Properties
- Typed Getters
- Setter
-
ReactiveFlow
- List of
ReactiveEntityInstance
- List of
ReactiveRelationInstance
- List of
The idea is to wrap functionality around ReactiveEntityInstance
s and ReactiveRelationInstance
s.
A ReactiveEntityInstance
has properties with streams but doesn't do anything yet.
The reactive behaviour implements the behaviour of a type. For example the AND
-
ConstValue
- Unit-Test: Fill
ConstValue
with external data - Drop
- Unit-Test: Fill
-
LogicalGate
- AND
- Unit-Test: One AND-Gate R = (B1 && B2)
- Unit-Test: Three AND-Gates R = ((B1 && B2) && (B3 && B4)) -> Using Connectors
- OR
- Unit-Test: One OR-Gate R = (B1 || B2)
- Unit-Test: Three OR-Gates R = ((B1 || B2) || (B3 || B4)) -> Using Connectors
- AND
-
ArithmeticGate
- ADD
- Unit-Test: One ADD-Gate R = (N1 + N2)
- Unit-Test: Three AND-Gates R = ((N1 + N2) + (N3 + N4)) -> Using Connectors
- SUB
- Unit-Test: One SUB-Gate R = (N1 - N2)
- Unit-Test: Three SUB-Gates R = ((N1 - N2) - (N3 - N4)) -> Using Connectors
- ADD
-
TrigonometricOperation
- SIN
- COS
-
SimpleClosure
- LOG
-
Connector
-
Connector::from_relation(ReactiveRelationInstance)
-
Connector::new(OutboundEntity, OutboundPropName, InboundEntity, InboundPropName)
-
Connector::connect
-
Connector::disconnect
- Optionally: Initially send value down the stream
- Optionally: Pause + Resume
-
-
Component Manager
-
EntityTypeManager
-
EntityVertexManager
-
EntityInstanceManager
-
ReactiveEntityInstanceManager
-
RelationTypeManager
-
RelationEdgeManager
-
RelationInstanceManager
-
ReactiveRelationInstanceManager
- Resolves which behaviour(s) should be applied on an entity
- Delegation to Registry
-
ReactiveEntityManager
delegates toEntityBehaviourManager
-
ReactiveRelationManager
delegates toRelationBehaviourManager
-
EntityBehaviourManager
delegates toEntityBehaviourRegistries
-
RelationBehaviourManager
delegates toRelationBehaviourRegistries
-
EntityBehaviourRegistry
-
RelationBehaviourRegistry
-
EntityBehaviourFactory
-
RelationBehaviourFactory
-
EntityBehaviour
-
RelationBehaviour
-
FlowManager
-
ReactiveFlowManager
-
ComponentManagerImpl
- Store references of
Component
- Has Component by Name
- Register Component
- Get All Components
- Get Component By Name
- Delete Component By Name
- Export Component To JSON File
- Import Component From JSON File
- Unit Tests
- Store references of
-
EntityTypeManagerImpl
- Store references of
EntityType
- Has Entity Type by Name
- Register Entity Type
- Expand Effective Properties From All Components (merge properties with the properties provided by the components)
- Create Entity Type
- Get Entity Type by Name
- Delete Entity Type By Name
- Export Entity Type To JSON File
- Import Entity Type From JSON File
- Unit Tests
- Store references of
-
RelationTypeManagerImpl
- Store references of
RelationType
- Has Relation Type by Name
- Register Relation Type
- Expand Effective Properties From All Components (merge properties with the properties provided by the components)
- Create Relation Type
- Get Relation Type by Name
- Delete Relation Type By Name
- Export Relation Type To JSON File
- Import Relation Type From JSON File
- Unit Tests
- Store references of
-
EntityVertexManagerImpl
- Has Vertex by UUID
- Get Vertex by UUID
- Get Vertex Properties by UUID
- Create Vertex
- Create Vertex with UUID
- Check if id exists in Datastore (must not exist)
- Create Vertex Properties
- Delete Vertex
- Unit Tests
-
RelationEdgeManagerImpl
- Has Edge by Outbound-UUID, type-name and Inbound-UUID
- Get Edge by Outbound-UUID, type-name and Inbound-UUID
- Get Edge Properties by Outbound-UUID, type-name and Inbound-UUID
- Create Edge
- Delete Edge By Outbound-UUID, type-name and Inbound-UUID
- Unit Tests
-
EntityInstanceManagerImpl
- Has Entity Instance by UUID
- Get Entity Instance by UUID
- Create Entity Instance
- Create Entity Instance with UUID
- Delete Entity Instance By UUID
- Import EntityInstance from JSON
- Export EntityInstance to JSON
- Create EntityInstance from Vertex
- Unit Tests
-
RelationInstanceManagerImpl
- Has Relation Instance by Outbound-UUID, type-name and Inbound-UUID
- Get Relation Instance by Outbound-UUID, type-name and Inbound-UUID
- Create Relation Instance
- Delete Relation Instance By Outbound-UUID, type-name and Inbound-UUID
- Import Relation Instance from JSON
- Export Relation Instance to JSON
- Unit Tests
-
ReactiveEntityInstanceManagerImpl
- Central registry of all
ReactiveEntityInstance
s - Create
ReactiveEntityInstance
by UUID - On Instantiation: Instantiate
EntityBehaviour
- Check if id exists in HashMap (must not exist)
- Check if id exists in Datastore -> Manager
- Unit Tests
- Central registry of all
-
ReactiveRelationInstanceManagerImpl
- Central registry of all
ReactiveRelationInstance
s- These are the actually "running" / "living" instances
- Create
ReactiveRelationInstance
by UUID- Get Relation Instance by EdgeKey from
RelationInstanceManager
- On Instantiation: Instantiate
ReactiveRelationInstanceBehaviour
by TYPE- Connector
- Get Relation Instance by EdgeKey from
- Unit Tests
- Central registry of all
-
EntityInstanceBehaviourManager
- Instantiate Behaviour
- Remove Behaviour
-
RelationInstanceBehaviourManager
- Instantiate Behaviour
- Remove Behaviour
-
FlowManagerImpl
- Create Flow: Creates entity and relation instances contained in the flow
- Delete Flow: Deletes entity and relation instances contained in the flow
- Import, Export
- Unit Tests
-
ReactiveFlowManagerImpl
- Map<FlowId, List>
- Has
- Get
- Create
- Commit
- Delete
- Export
- Import
- Unit Tests
- Implement Numeric Comparison
- Implement String Operations
- Implement String Gates
- Implement String Comparison
- Implement Timers / Cron Jobs
- Implement Entity with Numeric Constant by name
- Math Constants https://doc.rust-lang.org/std/f64/consts/index.html
- Implement Noise Generation (Procedural Textures + Terrain Generation + Particles)
- CR: entity types / relation types
- CRUD: entity instances / relation instances / flows
- Notification entity / relation / flow / property
- https://github.com/housleyjk/ws-rs
- https://github.com/housleyjk/ws-rs/blob/master/examples/threaded.rs
- https://github.com/graphql-rust/juniper
- Queries for entity instances / relation instances / flows
- Mutations for entity instances / relation instances / flows
- Websocket endpoint for command input
- Command parsing
- Rename behaviour simple_closure (log, print, ...) to command
- Make sure a simple_closure can have access to managers in order to get/create/update entities/relations
- Implement a terminal in the flow editor
- Implement Flow for the Environment Variables
- Implement Flow for the Command Line Arguments
- Implement Flow for the System / OS Constants
- rust bindgen C++
- Bindings for Vulkan Renderer
- models
- rust + glTF: https://github.com/gltf-rs/gltf
- procedural textures
- Generate
- particles
- sound
- Game API (JavaScript Access)
- Map = Flow
- Game Mode = Flow
- Game State = Flow
- Player = Flow
- System = Flow