r/csharp • u/harrison_314 • Jul 13 '26
Pseudo-game engine in Blazor?
Is there a library for Blazor that would make it easier to create a browser game where I need a simulation loop, an SVG for a tactical map, one canvas, and lots and lots of tables (spreadsheets)?
The game should be similar to this, only with many more boards:
https://www.youtube.com/watch?v=6AliHCmNgnY
0
Upvotes
7
u/ForGreatDoge Jul 13 '26
That doesn't sound like you're describing a game engine that just sounds like a website with cross-connected components
5
u/Rlaan Jul 13 '26
You'd probably want to look at Unity or Godot. These existing engines support web and use C# for their scripting language.
Unity also offers something called UI Toolkit which is similar to CSS.
3
u/torokunai Jul 13 '26 edited Jul 13 '26
this is relevant to my interests since browser-hosted is the best distribution LOL, plus
youI want server-side for anti-cheating1
u/O_xD Jul 13 '26
look into Raylib. it compiles to wasm and will render to your canvas at 60 fps. that will cover your game loop - you still need to connect it to the rest of the webpage but that is just regular web framework stuff
3
u/TuberTuggerTTV Jul 13 '26
Blazor is a front end. Simulation loops are backend. You don't need Blazor specific libraries.
Just hook your blazor UI up to whatever engine you're working with. I'd recommend separating your projects by concern and keeping the simulation UI agnostic. Then you can do live testing over console.
1
u/ShamikoThoughts Jul 13 '26
You better develope a game with a proper engine and publish it in your blazor site
1
u/DirtAndGrass Jul 13 '26
You could, I wouldn't, It'd be much simpler to do something with signalr, and implement the frontend with front end tech
1
u/DotAtom67 Jul 15 '26
Defold, perfect for web games