MrScautHD / Sparkle

A fast, Cross-platform .NET 8 C# 12 game engine.

Home Page:https://sparkle-engine.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Logo

Welcome to Sparkle πŸŽ‰

A fast, Cross-platform .NET 8 C# 12 game engine.

grafik

πŸͺ™ Installation - Nuget

dotnet add package Sparkle --version 3.0.2

⭐ Getting Started

We trust you'll relish your time with Sparkle! To kick things off, head over to our Wiki for a seamless start.

πŸ“š Libraries - Nuget

πŸŒ‹ Graphic Engine

β€πŸ’» Platforms

πŸ§‘ Contributors

πŸ–₯️ Basic Example

public class GameTest : Game {

    public Texture2D Texture;
    
    public GameTest(GameSettings settings) : base(settings) {
        
        // Create your own config file!
        JsonConfig config = new JsonConfigBuilder("config", "test")
            .Add("Hello", "Hello World!")
            .Add("Bye", 1000)
            .Build();

        Logger.Info(config.GetValue<string>("Hello"));
    }

    protected override void Init() {
        base.Init();
        
        // Open a url.
        Window.OpenUrl("https://www.youtube.com/");
    }

    protected override void Load() {
        base.Load();
        
        // Load resources.
        this.Texture = this.Content.Load(new TextureContent("icon.png"));
    }

    protected override void Draw() {
        base.Draw();
        
        // Draw circle if "A" down.
        if (Input.IsKeyDown(KeyboardKey.A)) {
            ShapeHelper.DrawCircle(new Vector2(50, 50), 20, Color.Blue);
        }

        // Draw texture if "B" down.
        if (Input.IsKeyDown(KeyboardKey.B)) {
            TextureHelper.Draw(this.Texture, Vector3.Zero, Color.White);
        }
    }
}

πŸ’Έ Sponsors

Please consider SPONSOR me to further help development and to allow faster issue triaging and new features to be implemented.

About

A fast, Cross-platform .NET 8 C# 12 game engine.

https://sparkle-engine.com

License:MIT License


Languages

Language:C# 100.0%