All Projects → tortuga-foundation → tortuga

tortuga-foundation / tortuga

Licence: MIT license
A modern game engine built using dot net core

Programming Languages

C#
18002 projects
GLSL
2045 projects

Projects that are alternatives of or similar to tortuga

Bgfx
Cross-platform, graphics API agnostic, "Bring Your Own Engine/Framework" style rendering library.
Stars: ✭ 10,252 (+73128.57%)
Mutual labels:  engine, sdl, vulkan
Samples-NET.Core-MVC-CSharp
ASP.NET Core 2.0 MVC C# samples for Stimulsoft Reports.Web reporting tool.
Stars: ✭ 28 (+100%)
Mutual labels:  core, net
Flingengine
A Vulkan game engine with a focus on data oriented design
Stars: ✭ 239 (+1607.14%)
Mutual labels:  engine, vulkan
Sapphiredb
SapphireDb Server, a self-hosted, easy to use realtime database for Asp.Net Core and EF Core
Stars: ✭ 326 (+2228.57%)
Mutual labels:  core, net
Aether3d
Aether3D Game Engine
Stars: ✭ 177 (+1164.29%)
Mutual labels:  engine, vulkan
Vulkan Renderer
A new 3D game engine using modern C++ and Vulkan API
Stars: ✭ 205 (+1364.29%)
Mutual labels:  engine, vulkan
ASP.NET-Core-2-MVC-CRUD-datatables-jQuery-Plugin
Asp.Net Example implementation of datatables.net using Asp.Net Core 2 Mvc CRUD datatables jQuery Plugin
Stars: ✭ 25 (+78.57%)
Mutual labels:  core, net
Entrypoint
Composable CLI Argument Parser for all modern .Net platforms.
Stars: ✭ 136 (+871.43%)
Mutual labels:  core, net
Raft.net
Implementation of RAFT distributed consensus algorithm among TCP Peers on .NET / .NETStandard / .NETCore / dotnet
Stars: ✭ 112 (+700%)
Mutual labels:  core, net
Rupengmessagehub
.Net Chat Server Hub
Stars: ✭ 84 (+500%)
Mutual labels:  core, dot-net
Innocenceengine
Cross-platform modern game engine.
Stars: ✭ 149 (+964.29%)
Mutual labels:  engine, vulkan
Dotnettyrpc
A RPC Framework Based On DotNetty
Stars: ✭ 153 (+992.86%)
Mutual labels:  core, net
Xray 16
Improved version of the X-Ray Engine, the game engine used in the world-famous S.T.A.L.K.E.R. game series by GSC Game World. Join OpenXRay! ;)
Stars: ✭ 1,806 (+12800%)
Mutual labels:  engine, sdl
Yave
Yet Another Vulkan Engine
Stars: ✭ 211 (+1407.14%)
Mutual labels:  engine, vulkan
Substrate
A cross-platform render-graph based rendering system written in Swift
Stars: ✭ 94 (+571.43%)
Mutual labels:  engine, vulkan
ormdb
ORM tool for .Net / .Net.Core
Stars: ✭ 14 (+0%)
Mutual labels:  core, net
Tristeon3d
A 3D Engine built by two Game Engineering students.
Stars: ✭ 68 (+385.71%)
Mutual labels:  engine, vulkan
Gears Vk
Powerful low-level C++20 rendering framework for Vulkan 1.2, including Real-Time Ray Tracing (RTX) support, built atop Auto-Vk.
Stars: ✭ 71 (+407.14%)
Mutual labels:  engine, vulkan
Cauldron
C# Toolkit
Stars: ✭ 27 (+92.86%)
Mutual labels:  core, net
Rpg Core
UNITY engine RPG framework
Stars: ✭ 146 (+942.86%)
Mutual labels:  core, engine

Tortuga

Tortua is an open source game engine built using C# dot net core 3.0

.NET Core

IMG

Prerequisites

  • Dot Net Core 3.0
  • Vulkan
  • GlsLang Tools
  • SDL2
  • Open AL
  • Bullet Physics Library
sudo apt install -y libopenal1 libsdl2-2.0-0 libvulkan1 glslang-tools libgdiplus

Using the package in your project

You can use nuget to install the package TortugaEngine

nuget install TortugaEngine

How to Run

  1. git clone https://github.com/tortuga-foundation/tortuga.git
  2. cd tortuga
  3. dotnet restore tortuga.sln
  4. dotnet build tortuga.sln
  5. ./Tortuga.Test/bin/Debug/netcoreapp3.0/Tortuga.Test.dll

Example

Sample Code:

//setup sdl input system
Engine.Instance.AddModule<Input.InputModule>();
//setup vulkan instance
Engine.Instance.AddModule<Graphics.GraphicsModule>();
//setup open al
Engine.Instance.AddModule<Audio.AudioModule>();

//create new scene
var scene = new Core.Scene();
Input.InputModule.OnApplicationClose += () => Engine.Instance.IsRunning = false;

//camera
Graphics.Camera mainCamera;
{
    var entity = new Core.Entity();
    mainCamera = await entity.AddComponent<Graphics.Camera>();
    mainCamera.RenderTarget = Graphics.Camera.TypeOfRenderTarget.DeferredRendering;
    scene.AddEntity(entity);
}

//mesh
{
    var entity = new Core.Entity();
    var transform = entity.GetComponent<Core.Transform>();
    transform.Position = new Vector3(0, 0, -5);
    var renderer = await entity.AddComponent<Graphics.Renderer>();
    renderer.MeshData = await Graphics.Mesh.Load("Assets/Models/Sphere.obj");
    renderer.MaterialData = await Graphics.Material.Load("Assets/Materials/Bricks.json");
    scene.AddEntity(entity);
}

//light
{
    var entity = new Core.Entity();
    var light = await entity.AddComponent<Graphics.Light>();
    scene.AddEntity(entity);
}

//user interface
{
    var win = new UI.UiWindow();
    win.Position = new Vector2(100, 100);
    win.Scale = new Vector2(500, 500);
    scene.AddUserInterface(win);
    var windowContent = new UI.UiRenderable();
    windowContent.RenderFromCamera = mainCamera;
    windowContent.PositionXConstraint = new UI.PercentConstraint(0.0f);
    windowContent.PositionYConstraint = new UI.PercentConstraint(0.0f);
    windowContent.ScaleXConstraint = new UI.PercentConstraint(1.0f);
    windowContent.ScaleYConstraint = new UI.PercentConstraint(1.0f);
    win.Content.Add(windowContent);
}

//add systems to the scene
scene.AddSystem<Audio.AudioSystem>();
scene.AddSystem<Graphics.RenderingSystem>();

//load scene
Engine.Instance.LoadScene(scene);
//run main loop
await Engine.Instance.Run();

Material JSON

{
  "Type": "Material",
  "Value": {
    "Pipeline": {
      "RenderPass": {
        "Count": 4,
        "IsDepthEnabled": true
      }
    },
    "Shaders": [
      {
        "Type": "ShaderFile",
        "Value": {
          "ShaderType": "Vertex",
          "Data": "Assets/Shaders/Default/MRT.vert"
        }
      },
      {
        "Type": "ShaderFile",
        "Value": {
          "ShaderType": "Fragment",
          "Data": "Assets/Shaders/Default/MRT.frag"
        }
      }
    ],
    "DescriptorSets": [
      {
        "Type": "DescriptorSet",
        "Value": {
          "Name": "TEXTURES",
          "Bindings": [
            {
              "Type": "DescriptorSetBinding",
              "Value": {
                "DescriptorType": "CombinedImageSampler",
                "Stage": "Fragment",
                "Data": {
                  "Type": "TexturePath",
                  "Value": "Assets/Images/Bricks/Color.jpg"
                }
              }
            },
            {
              "Type": "DescriptorSetBinding",
              "Value": {
                "DescriptorType": "CombinedImageSampler",
                "Stage": "Fragment",
                "Data": {
                  "Type": "TexturePath",
                  "Value": "Assets/Images/Bricks/Normal.jpg"
                }
              }
            },
            {
              "Type": "DescriptorSetBinding",
              "Value": {
                "DescriptorType": "CombinedImageSampler",
                "Stage": "Fragment",
                "Data": {
                  "Type": "TexturePathChannels",
                  "Value": {
                    "R": "Assets/Images/Bricks/Metal.jpg",
                    "G": "Assets/Images/Bricks/Roughness.jpg",
                    "B": "Assets/Images/Bricks/AmbientOclusion.jpg"
                  }
                }
              }
            }
          ]
        }
      },
      {
        "Type": "DescriptorSet",
        "Value": {
          "Name": "MATERIAL",
          "Bindings": [
            {
              "Type": "DescriptorSetBinding",
              "Value": {
                "DescriptorType": "UniformBuffer",
                "Stage": "Vertex",
                "Data": {
                  "Type": "Int32",
                  "Value": [
                    1
                  ]
                }
              }
            }
          ]
        }
      }
    ]
  }
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].