Simulating Machine Learning Agents inside a game engine that I am developing

Simulating Machine Learning Agents inside a game engine that I am developing

I’ve been working on a Reinforcement Learning system inside my own game engine, and this is a small demo of two agents learning hide and seek.

Here: Red = chaser and Green = hider

These agents improve by exploring the environment and adjusting their actions to get the highest reward possible.

The chaser learns to track and catch the hider over time, while the hider learns to avoid and survive longer.

Some details:
– Multi-agent reinforcement learning setup
– Reward shaping for both chase and survival
– Real-time simulation + training inside the engine
– No pre-defined paths, navigation, or rules

This is still early, but I’m aiming to build a system for more intelligent NPC behavior rather than traditional scripted AI. Here is some back story:

It all started last year when i though about how much of a difference it would make if we can easily create NPCs that are not scripted. NPCs that would adapt and improve their behaviour based on the player. So i started making my own game engine.

After 9 months I finally have a 2D renderer, ECS, Physics, UI and other features needed to create small games. I integrated Libtorch in my engine to train these ML Agents.

Right now i am working on Procedurally Generated Animation system and when i am done i will share my progress with everyone again.

In the meantime, i would like to hear what you think of my engine.

submitted by /u/ZealousidealDesk3261
[link] [comments]

Liked Liked