Coh3n
2010-11-29 03:30:32
Again, RM has said a few times about the possibilities when using reflection to gather color walking information. We can get exact tile colors, angles, etc. which can also be updated automatically during runtime if we were to use a record of some sort.
What I want to discuss is the ridiculous amount of color walking routines we have. I brought this up a while ago and we decided to leave as many options as possible; however, with reflection in the works now, it only makes sense that we pick a method. This will not only clean up the include, but it will make everything less confusing for everyone.
In addition, if done properly, the color walking will be written for us. If everything is gathered during runtime, all our paths will be automatically made. sounds pretty awesome, doesn't it?
So, I think we need to come up with the best system for what needs to be done. What will be the most accurate? What is all the information we need to collect and why?
I think we should use Garrett's method, expanded of course. He has one function that will walk to any point based on a record. What needs to be added, what can be deleted?
I'd also like to point out that this isn't going to be rushed. This will probably be the last reflection component that's added simply because I think it will be the most complex.
What I want to discuss is the ridiculous amount of color walking routines we have. I brought this up a while ago and we decided to leave as many options as possible; however, with reflection in the works now, it only makes sense that we pick a method. This will not only clean up the include, but it will make everything less confusing for everyone.
In addition, if done properly, the color walking will be written for us. If everything is gathered during runtime, all our paths will be automatically made. sounds pretty awesome, doesn't it?
So, I think we need to come up with the best system for what needs to be done. What will be the most accurate? What is all the information we need to collect and why?
I think we should use Garrett's method, expanded of course. He has one function that will walk to any point based on a record. What needs to be added, what can be deleted?
type
TWalkInfo = record
Name : string;
Color : Integer;
Tolerance : Integer;
SplitMethod : Integer; // See the split method constants
SortMethod : Integer; // See the sort method constants
Filter : Boolean; // Use FilterPointsPie?
CTS2 : Boolean; // Use ColorToleranceSpeed 2?
HueMod : Extended;
SatMod : Extended;
StartRadial : Integer;
EndRadial : Integer;
MinRadius : Integer;
MaxRadius : Integer;
SortPoint : TPoint; // Point to sort from (for SortTPAFrom only)
SplitDist : Integer; // For TPAToATPA/SplitTPA only
W, H : Integer; // For TPAToATPAEx/SplitTPAEx only
end;
// Revised
type
TColorMMPoint = record // I'd like to think of a better name, TWalkInfo may be fine
end;
I'd like to read everyone's thoughts on this. :)I'd also like to point out that this isn't going to be rushed. This will probably be the last reflection component that's added simply because I think it will be the most complex.

