Orbit - Count Only the First Switch, Not Both

14 views
Skip to first unread message

atum

unread,
Apr 2, 2020, 9:38:59 PM4/2/20
to MPF Users

I have a full orbit both ways, as well as an inner loop that feeds to one of the orbits.  I am trying to get it where it will trigger the first one, but not both as hit events.  So a right orbit (right then left switches) should count as a right hit, not both hits.  I have mirrored my code and it seems to do weird things.

I have the sequence_shots: code in my config, so I can use it anywhere:
sequence_shots:
    left_orbit_sequence
:
        switch_sequence
: s_left_orbit
        sequence_timeout
: 3s
        delay_switch_list
:
            s_right_orbit
: 4s
    right_orbit_sequence
:
        switch_sequence
: s_right_orbit
        sequence_timeout
: 3s
        delay_switch_list
:
            s_left_orbit
: 4s
    upper_loop_sequence
:
        switch_sequence
: s_upper_loop
        sequence_timeout
: 3s
        delay_switch_list
:
            s_right_orbit
: 4s
 
When I make a right orbit, it counts as a right hit only, not left even though it hits that switch.  But the other two count as hits to both.  I know this isn't really the goal of the sequence_shots, but I don't want to require the full loop.  Hitting the switch on a weak shot should still register.  Is there another mechanism to state that, or something else that I should add to account for that?

Just cannot get why one works and the other two don't.

Thanks in advance!

Avery

jabdoa

unread,
Apr 3, 2020, 1:20:05 PM4/3/20
to MPF Users
I guess your problem might be that you only list one of the switches, in switch_sequence. Should be something like this:

switch_sequence: s_left_orbit, s_right_orbit

Something like this: http://docs.missionpinball.org/en/dev/mechs/loops/index.html#loops-orbits-ramps

That way it requires both switches to be hit in that order. I would then add a timeout instead of the delay switch. This way MPF can track multiple orbit shots simultaneously.

Jan

atum

unread,
Apr 3, 2020, 1:49:01 PM4/3/20
to MPF Users
Jan,

I figured out what I was looking for.  I stumbled upon something else and ended up on the dev thread instead of latest, and in shots there is a feature called "delay_switch:".  This is what I actually wanted, in that I can make hitting my left orbit disable the right orbit switch listener for a couple of seconds.
    rorbit:
       
switch: s_right_orbit
        delay_switch
:
            s_left_orbit
: 3s
            s_upper_loop
: 3s
For any readers out here, hitting either of the delay switches, will disable the switch defined (s_right_orbit) from registering for the stated amount of time (3s in this case).


I am on v0.53.2, which I would assume is the "latest" thread on docs, and it doesn't include this functionality in the docs, but it works through my testing in all modes.  Is this something that just needs added to the latest docs http://docs.missionpinball.org/en/latest/config/shots.html from the dev docs http://docs.missionpinball.org/en/dev/config/shots.html?

Thanks for the help!

Avery

jabdoa

unread,
Apr 3, 2020, 5:44:24 PM4/3/20
to MPF Users
I usually update docs on dev. When we release MPF that version becomes the latest version. However, sometimes I add features and document them later on. Currently almost everything in the dev documentation should work in 0.53.


Jan

Reply all
Reply to author
Forward
0 new messages