Godot RL Agents library problems

Godot Version

Godot 4

Question

Hi guys!
As anyone ever used the Godot RL Agents Library?
Cause I’m having some trouble using it!
I setted all up and I made a little program that has a red cube and a green cube, when the red cube reaches the green cube the AI is rewarded.
All worked fine until I decided to make the green cube position randomize everytime the AI gets to it… it got it one time and then started staying still(not really, it’s twitching as I put Sync speed to 10)

How could I evitate the AI getting stuck?
And no, a timer won’t work, it gets stuck anyways.

I based myself on this video:

(kinda outdated as I had to use an older python version, and I had to change lines of code in the python scripts)

I would make sure its not a bug in the game physics. Usually a capsule body will be less prone to getting stuck. You can still make it look like a square with its mesh. But it could require hours of training to get good. That is why its important to do training in parallel.

1 Like

thank ya
I’ll try
I just assumed it was a problem in how I was setting the AI but I guess it may be not