edbeeching / godot_rl_agents

An Open Source package that allows video game creators, AI researchers and hobbyists the opportunity to learn complex behaviors for their Non Player Characters or agents
MIT License
942 stars 69 forks source link

Real time speed up feature #109

Closed Miner34dev closed 10 months ago

Miner34dev commented 1 year ago

Hello, i'm here to report a bug/missing feature: the speed up doesn't work if changed while executing. There's the code that changes the speed up value:

func _physics_process(_delta):
    if spdupbut.button_pressed:
        syncronizer.speed_up = 2
    else:
        syncronizer.speed_up = 1

Where spdupbut is a switch button and syncronizer is sync.gd. Nothing changes when clicking the button, even the AI fps stays still.

edbeeching commented 1 year ago

I don't see the need for this feature. Typically you would build the environment and train in headless at higher speeds.

Miner34dev commented 1 year ago

In the near future i want to create a game with some AI's as enemies and more, and i want it with a timewarp feature. I'm not saying that's an important feature which should be added as soon as possible, but that it can be useful especially in full games, which is the thing i'm planning to do. Oh, and a slow down feature? I think it can be useful too. You are experimenting with exportation with no dependencies for the next update, right? This is a little change but flanked with the enhanced export feature this can become a thing to be used for real games, not only simple AI tests.

edbeeching commented 1 year ago

Hi @Miner34dev , yes models can now be exported in ONNX format. So you should be able to bundle them with a game. As for the time warp feature, I think this is too specific for this use case.

Ivan-267 commented 10 months ago

@Miner34dev would it be OK to close this issue?