Add-a-ball issue

32 views
Skip to first unread message

Nixco

unread,
Feb 6, 2026, 4:48:25 AM (13 days ago) Feb 6
to MPF Users
Hi everyone,

i noticed an error count with add-a-ball.

Here is the bug report:

config.yaml
machine:
    balls_installed: 4

multiball.yaml
multiballs:
    multiball_3b:
        ball_count: 3
        ball_count_type: total
        start_events: start_multiball_3b
        shoot_again: 4s
        add_a_ball_events: add_a_ball

If i have 3 balls on the playfield and the add-a-ball event is launched, it gives me one more ball. This is maybe not an issue, but it goes beyond the 'Total'.

The issue is :

if i send again the add-a-ball event with 4 balls on the playfield, obviously nothing happens (i only have 4 balls in my machine) but,  if i drain 3 balls, the bonus_mode start while there is still one ball on the playfield.

Any idea on this one ?

Thanks :D

Dan - aka BorgDog

unread,
Feb 7, 2026, 12:09:11 AM (13 days ago) Feb 7
to MPF Users
I would say the first part of adding balls beyond the 'total' is expected behavior as docs say "total: Means the ball_count: setting will provide a target for the total number of balls that should be in play when this multiball starts."

the second part of the ball ending with 1 ball still in play is weird, possible bug, but I don't know.  Did you happen to notice if the multiball ends when you are down to 2 balls?  which would be 2 of the original 3 drained. 
if you want add_a_ball to NOT go beyond the 3 balls you could add a conditional something like  add_a_ball_events: add_a_ball{game.balls_in_play < 3 } or you could add that conditional to whatever posts the add_a_ball event

Nixco

unread,
Feb 9, 2026, 4:29:39 AM (10 days ago) Feb 9
to MPF Users
Thank you for your answer.

I did a few tests, and there is only one scenario where the count is wrong.

It's when the event add_a_ball try to add WHILE all the balls are on the playfield. 

- multiball 3 balls
- add_a_ball event
- 4 balls on the playfield
- add_a_ball event {nothing happens, only 4 balls in the game} --> 4 balls on the playfield
- if i drain 1 ball,  mpf gives me back 1 ball {i think mpf count the fifth ball i asked for} --> 4 balls on the playfield
- i drain 2 balls 
- multiball ends --> 2 balls on the playfield
- i drain 1 ball
- the ball end with 1 ball on the playfield

Nixco

unread,
Feb 9, 2026, 4:58:48 AM (10 days ago) Feb 9
to MPF Users
Using game.balls_in_play with a limit works well, thank you.
Reply all
Reply to author
Forward
0 new messages