From: Rudolf Polzer Date: Wed, 28 Sep 2011 04:21:55 +0000 (+0200) Subject: percussion fixes X-Git-Tag: xonotic-v0.6.0~72 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=3affa1daab78ba6f0b2bf6e10ac84e61f01dc10e;p=xonotic%2Fxonotic.git percussion fixes --- diff --git a/misc/tools/midi2cfg-ng.pl b/misc/tools/midi2cfg-ng.pl index a2e7083f..4fe6a0ce 100755 --- a/misc/tools/midi2cfg-ng.pl +++ b/misc/tools/midi2cfg-ng.pl @@ -539,16 +539,19 @@ sub botsort($$$$@) map { my $q = 0; - if(($_->{lastuse} // -666) >= $time - $time_forgetfulness) + if($channel != 10) # percussion just should do round robin { - if($channel == $_->{lastchannel}) + if(($_->{lastuse} // -666) >= $time - $time_forgetfulness) { - $q += $_->{lastchannelsequence}; - } - else - { - # better leave this one alone - $q -= $_->{lastchannelsequence}; + if($channel == $_->{lastchannel}) + { + $q += $_->{lastchannelsequence}; + } + else + { + # better leave this one alone + $q -= $_->{lastchannelsequence}; + } } } [$_, $q, rand]