last works on XCAEA Pivots ...
This commit is contained in:
@@ -167,12 +167,12 @@ class XCXCAEASignaller : XCBase
|
||||
|
||||
//
|
||||
// Setup Conditions ...
|
||||
XBoxZone boxes[];
|
||||
XBoxZone pivots[];
|
||||
XBoxZone pivotBox;
|
||||
XBoxZone signalBox;
|
||||
int pivotsCount = 0;
|
||||
bool hasPivots = false;
|
||||
double additionalSL = 0;
|
||||
XBoxZone bullishBoxes[];
|
||||
XBoxZone bearishBoxes[];
|
||||
bool hasSignalBox = false;
|
||||
XCAEAConditions conditions;
|
||||
ENUM_X_DIRECTION signalBoxDir = X_DIRECTION_NONE;
|
||||
@@ -182,11 +182,6 @@ class XCXCAEASignaller : XCBase
|
||||
detector.Update(
|
||||
zIndex //
|
||||
);
|
||||
|
||||
//
|
||||
if (detector.newValeSupSWLPivotDetected) {
|
||||
Print("Salam");
|
||||
}
|
||||
|
||||
//
|
||||
// Validate Pivots ...
|
||||
@@ -201,36 +196,12 @@ class XCXCAEASignaller : XCBase
|
||||
|
||||
//
|
||||
// Retrieve Valid Boxes ...
|
||||
|
||||
// //
|
||||
// // Bullish ...
|
||||
// int bullishBoxesCount =
|
||||
// detector
|
||||
// .FillBullishBoxes(bullishBoxes);
|
||||
|
||||
// //
|
||||
// // Bearish ...
|
||||
// int bearishBoxesCount =
|
||||
// detector
|
||||
// .FillBearishBoxes(bearishBoxes);
|
||||
|
||||
// //
|
||||
// Copy(
|
||||
// bullishBoxes,
|
||||
// boxes,
|
||||
// false //
|
||||
// );
|
||||
// Copy(
|
||||
// bearishBoxes,
|
||||
// boxes,
|
||||
// false //
|
||||
// );
|
||||
int boxesCount = ArraySize(boxes);
|
||||
bool hasBoxes = IsValidSize(boxesCount);
|
||||
pivotsCount = detector.FillPivots(pivots);
|
||||
hasPivots = IsValidSize(pivotsCount);
|
||||
|
||||
//
|
||||
// Filter UnAvailable Boxes ...
|
||||
if (hasBoxes)
|
||||
if (hasPivots)
|
||||
{
|
||||
//
|
||||
// Remove UnAvailable Boxes ...
|
||||
@@ -248,13 +219,13 @@ class XCXCAEASignaller : XCBase
|
||||
has = FindBoxIndex(
|
||||
idx,
|
||||
iBox,
|
||||
boxes //
|
||||
pivots //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
//
|
||||
ArrayRemove(
|
||||
boxes,
|
||||
pivots,
|
||||
idx,
|
||||
1 //
|
||||
);
|
||||
@@ -263,23 +234,18 @@ class XCXCAEASignaller : XCBase
|
||||
}
|
||||
|
||||
//
|
||||
hasBoxes = HasChild(boxes);
|
||||
boxesCount = ArraySize(boxes);
|
||||
hasPivots = HasChild(pivots);
|
||||
pivotsCount = ArraySize(pivots);
|
||||
}
|
||||
|
||||
//
|
||||
//
|
||||
//
|
||||
|
||||
//
|
||||
// if (hasBoxes)
|
||||
// {
|
||||
// }
|
||||
|
||||
//
|
||||
// Detect Sinal Box ...
|
||||
hasSignalBox = DetectXCAEAConditions(
|
||||
boxes,
|
||||
pivots,
|
||||
conditions,
|
||||
pivotBox,
|
||||
signalBox,
|
||||
@@ -301,6 +267,17 @@ class XCXCAEASignaller : XCBase
|
||||
);
|
||||
}
|
||||
|
||||
//
|
||||
// Make Signal Box UnAvailable ...
|
||||
if (signalBox.IsValid())
|
||||
{
|
||||
//
|
||||
AddRef(
|
||||
signalBox,
|
||||
unAvailableBoxes //
|
||||
);
|
||||
}
|
||||
|
||||
//
|
||||
isBullish = hasSignalBox &&
|
||||
IsBullish(signalBoxDir);
|
||||
@@ -458,9 +435,7 @@ class XCXCAEASignaller : XCBase
|
||||
// Cleanup Resource ...
|
||||
|
||||
//
|
||||
Clean(boxes);
|
||||
Clean(bullishBoxes);
|
||||
Clean(bearishBoxes);
|
||||
Clean(pivots);
|
||||
|
||||
//
|
||||
zBar.Clean();
|
||||
@@ -762,24 +737,69 @@ class XCXCAEASignaller : XCBase
|
||||
detector.detectFVGBearishPivots = true;
|
||||
detector.detectValeSupSWLPivots = true;
|
||||
detector.detectPeakResSWHPivots = true;
|
||||
detector.detectPVFVGBullishPivots = true;
|
||||
detector.detectPVFVGBearishPivots = true;
|
||||
|
||||
//
|
||||
// Initialize and Configure Drawer ...
|
||||
drawer = new XCXCAEAPOIDrawer(detector);
|
||||
|
||||
//
|
||||
drawer.ignoreUpdateOSCTos = true;
|
||||
|
||||
//
|
||||
// Configure Drawer ...
|
||||
drawer.drawRSIPeakPivots = true;
|
||||
drawer.drawRSIValePivots = true;
|
||||
drawer.drawCCIPeakPivots = true;
|
||||
drawer.drawCCIValePivots = true;
|
||||
drawer.drawFVGBullishPivots = true;
|
||||
drawer.drawFVGBearishPivots = true;
|
||||
drawer.drawFVGBullishPivots = false;
|
||||
drawer.drawFVGBearishPivots = false;
|
||||
drawer.drawValeSupSWLPivots = true;
|
||||
drawer.drawPeakResSWHPivots = true;
|
||||
drawer.drawPVFVGBullishPivots = true;
|
||||
drawer.drawPVFVGBearishPivots = true;
|
||||
|
||||
//
|
||||
// Configure Widths ...
|
||||
drawer.rsiPeakPivotsWidth = 4;
|
||||
drawer.rsiValePivotsWidth = 4;
|
||||
drawer.cciPeakPivotsWidth = 4;
|
||||
drawer.cciValePivotsWidth = 4;
|
||||
drawer.fvgBullishPivotsWidth = 2;
|
||||
drawer.fvgBearishPivotsWidth = 2;
|
||||
drawer.valeSupSWLPivotsWidth = 1;
|
||||
drawer.peakResSWHPivotsWidth = 1;
|
||||
drawer.pvFVGBullishPivotsWidth = 1;
|
||||
drawer.pvFVGBearishPivotsWidth = 1;
|
||||
|
||||
//
|
||||
// Configure Colors ...
|
||||
drawer.rsiPeakPivotsColor = clrMagenta;
|
||||
drawer.rsiValePivotsColor = clrAqua;
|
||||
drawer.cciPeakPivotsColor = clrMagenta;
|
||||
drawer.cciValePivotsColor = clrAqua;
|
||||
drawer.fvgBullishPivotsColor = clrLime;
|
||||
drawer.fvgBearishPivotsColor = clrRed;
|
||||
drawer.valeSupSWLPivotsColor = clrAqua;
|
||||
drawer.peakResSWHPivotsColor = clrMagenta;
|
||||
drawer.pvFVGBullishPivotsColor = clrLime;
|
||||
drawer.pvFVGBearishPivotsColor = clrRed;
|
||||
|
||||
//
|
||||
// Configures Styles ...
|
||||
drawer.rsiPeakPivotsStyle = STYLE_DASH;
|
||||
drawer.rsiValePivotsStyle = STYLE_DASH;
|
||||
drawer.cciPeakPivotsStyle = STYLE_DASH;
|
||||
drawer.cciValePivotsStyle = STYLE_DASH;
|
||||
drawer.fvgBullishPivotsStyle = STYLE_DASHDOTDOT;
|
||||
drawer.fvgBearishPivotsStyle = STYLE_DASHDOTDOT;
|
||||
drawer.valeSupSWLPivotsStyle = STYLE_SOLID;
|
||||
drawer.peakResSWHPivotsStyle = STYLE_SOLID;
|
||||
drawer.pvFVGBullishPivotsStyle = STYLE_DASHDOTDOT;
|
||||
drawer.pvFVGBearishPivotsStyle = STYLE_DASHDOTDOT;
|
||||
|
||||
//
|
||||
// UnActive Pivots ...
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user