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

Pokemon pinball wrapper #314

Closed
wants to merge 37 commits into from

Conversation

NicoleFaye
Copy link
Contributor

Created a wrapper for the Gameboy color Pokemon Pinball game.

This wrapper includes definitions for game stages, Pokemon spawn rates, maps, special modes, ball types. It tracks game stats, manages game states, allows you to programmatically start catch mode, allows you to start the game on any stage, including bonus stages, and optional evolution hack that replaces the pause button with evolution start.

@Baekalfen Baekalfen force-pushed the v2.0.0 branch 2 times, most recently from 3d0a116 to e8519db Compare March 14, 2024 20:20
@Baekalfen Baekalfen force-pushed the v2.0.0 branch 6 times, most recently from 8d62b89 to 26d2197 Compare March 17, 2024 10:35
@Baekalfen Baekalfen changed the base branch from v2.0.0 to master March 17, 2024 14:03
Copy link
Owner

@Baekalfen Baekalfen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really well done over all. Nice work :)

pyboy/plugins/game_wrapper_pokemon_pinball.pxd Outdated Show resolved Hide resolved
pyboy/plugins/game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
pyboy/plugins/game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
pyboy/plugins/game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
pyboy/plugins/game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
pyboy/plugins/game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
tests/test_game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
tests/test_game_wrapper_pokemon_pinball.py Outdated Show resolved Hide resolved
pokemon_pinball = pyboy.game_wrapper
pokemon_pinball.start_game()
pyboy.button("a")
for i in range(6185):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a very specific number. How was it derived?

Copy link
Contributor Author

@NicoleFaye NicoleFaye May 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just did some further testing, the actual value that should go there is 6176. this will be the first tick that game over is true if you press a every 100 ticks, which essentially just launches the ball as soon as its up, and doesnt really do anything to prevent it from going into the loss slot repeatedly.

Originally it was just trial and error by hand, started with a big number i knew would be enough for a game over and started lowering until it was just after the game over occurred.

Comment on lines 109 to 105
if i % 100 == 0:
pyboy.button("a")
pyboy.tick(render=False)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A trick could be to do:

for _ in range(60):
    pyboy.button("a")
    pyboy.tick(100, render=False)

@Baekalfen
Copy link
Owner

Superseeded by #326

@Baekalfen Baekalfen closed this May 24, 2024
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

Successfully merging this pull request may close these issues.

None yet

2 participants