Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WARNING: Exception thrown: 'Stage' object has no attribute 'stage' when running example.py #152

Open
anandijain opened this issue Nov 11, 2023 · 1 comment

Comments

@anandijain
Copy link

anandijain commented Nov 11, 2023

python .\smashbot.py -e "C:\Users\anand\AppData\Roaming\Slippi Launcher\playback" -i 4

was what was used to run smashbot, not sure why this WARNING: Exception thrown: 'Stage' object has no attribute 'stage' when running example.py`` is happening but it does seem to be affecting its play since fox just seems to stall

thanks a ton for all of the work put into these packages btw, super cool

any hints on where to look to debug?

@TheShinobiX
Copy link

The easiest solution is to downgrade our version of Libmelee to 0.37.0

We can perform this downgrade with the following command
pip install --upgrade melee==0.37.0

OR the following commands

pip uninstall melee
pip install melee=="0.37.0"

The reason for this bug is because the methods in Libmelee's "stages.py" was updated to use the gamestate object itself instead of just the gamestate.stage. Previous versions of Libmelee used just the "stage" object.
The code for SmashBot has not been updated for newer versions of Libmelee so it passes only the "stage" object to those methods.

Do note that this workaround solution causes Foutain of Dreams (FOD) to not be properly playable by the bot, but I don't even know if FOD is playable if everything was properly implemented.

I am very new to Melee, but I was fascinated by @altf4 and his SmashBot, so I spent a lot of time understanding this code. It took me quite a while to debug this problem myself.
I am a bit shy to play against real people yet (as I suck), so I thought practicing against a bot would be nicer.

Let me know if this solution works for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants