@MasterGy yours looks more clunky than mine, if mine is always correct you will be interested, it will save you from loops.
@OldMoses yours I can immediately apply with spider code and not even have to convert dx, dy's to an angle heading. Mine might be less calculation if I had the heading already calculated which for spiders I don't.
But I am thinking it might be handy to use speed with heading for dx, dy calc's. It is also interesting that a vector solution has crept into my trig problem. I might get an insight into vector stuff from this.
But what is SpinnerDot? It looks like you compare to Cos(30 degrees) not straight 30 degrees.
Next how to test all our solutions to
1. make sure they are always correct and then 2. which is speediest?
Hmm... also I was assuming the difference as absolute value, always positive. But if I want to apply to one or the other angles I guess I need both pos and neg solutions.
BTW I was thinking Function looks like:
AngleDifferenceD(degrees1, degrees2)
AngleDifferenceR(radians1, radians2)
@OldMoses yours I can immediately apply with spider code and not even have to convert dx, dy's to an angle heading. Mine might be less calculation if I had the heading already calculated which for spiders I don't.
But I am thinking it might be handy to use speed with heading for dx, dy calc's. It is also interesting that a vector solution has crept into my trig problem. I might get an insight into vector stuff from this.
But what is SpinnerDot? It looks like you compare to Cos(30 degrees) not straight 30 degrees.
Next how to test all our solutions to
1. make sure they are always correct and then 2. which is speediest?
Hmm... also I was assuming the difference as absolute value, always positive. But if I want to apply to one or the other angles I guess I need both pos and neg solutions.
BTW I was thinking Function looks like:
AngleDifferenceD(degrees1, degrees2)
AngleDifferenceR(radians1, radians2)
b = b + ...