I need someone clever to come up with an efficient way to scan my tracker's Songs for used Pattern numbers.
I've got 8 Songs with 5 Tracks in each song. In each track there are 128 steps, a step is simply a Pattern number. There are 128 Patterns.
Any Pattern number can be used in any step and can be used multiple times.
One of the functions of Pulsar's editor needs to find an unused Pattern.
I've tried several different ways to do this but all of them so far take far too much processing (just to check ever Step of each Track of each Song is over 5000 iterations alone).
The ideal solution (because this type of information is useful in other areas of the editor) would be to maintain at all times which Patterns are used and which aren't.
Over to you
I've got 8 Songs with 5 Tracks in each song. In each track there are 128 steps, a step is simply a Pattern number. There are 128 Patterns.
Any Pattern number can be used in any step and can be used multiple times.
One of the functions of Pulsar's editor needs to find an unused Pattern.
I've tried several different ways to do this but all of them so far take far too much processing (just to check ever Step of each Track of each Song is over 5000 iterations alone).
The ideal solution (because this type of information is useful in other areas of the editor) would be to maintain at all times which Patterns are used and which aren't.
Over to you