Conflicting sound instructions?

i was trying to have a sound both backwards and last some time (i.e. flipping a drum to rate -1 and using it as a “crescendo” right before a drop), but i want that to exactly coincide with the drop so i wanna stretch it to 1 or 2, but then that conflicts with rate and it isn’t correctly timed – do you know how such conflicting operations reconcile with each other?

This is what I tried to do:
sample :drum_cymbal_closed, rate: -0.5, amp: 2, beat_stretch: 1

It seems to take about 2 timesteps – it sounds like first it’s stretched, then rate-edited? How does one know the precedence of such operations in general? Such info doesn’t seem to be in the docs under sample.

Both commands rate: and beat_stretch; are essentially changing rate. For what you want to do think of it this way. First consider beat_stretch: 0.5
puts sample_duration :drum_cymbal_closed, beat_stretch: 0.5 => 0.5

if you then play that at half the rate (+ or -) it will take twice as long giving a duration of 1
puts sample_duration :drum_cymbal_closed, beat_stretch: 0.5,rate: -0.5 =>1

This gives the same
puts sample_duration :drum_cymbal_closed,rate: -0.5, beat_stretch: 0.5- =>1

so I think what you need to get the effect you want is

sample  :drum_cymbal_closed,rate: -0.5, beat_stretch: 0.5 #duration 1 beat
sleep 1
sample :bd_haus,amp: 2

Edit I think the overall time will be beat_stretch divided by absolute(rate) so
rate: -1,beat_stretch:1 would give 1, and
rate: -0.5,beat_stretch: 0.25 would give 2 and
rate -0.25,beat_stretch:4 would give 16