This commit is contained in:
2025-02-20 14:25:32 +03:30
parent 39b9dc0388
commit 195276c221
8 changed files with 6853 additions and 4546 deletions
+213
View File
@@ -927,13 +927,226 @@ else if (isPriceRejected)
/////////////////////////////////////////////////////////////////////////////////////////////////////
//
// When FVg is Worked ...
else
{
//
XCFVG *fvgs[];
if (isBullish)
{
//
Copy(
analyseState.bullishFairValueGaps,
fvgs //
);
}
else
{
//
Copy(
analyseState.bearishFairValueGaps,
fvgs //
);
}
//
// int count = ArraySize(fvgs);
// bool has = IsValidSize(count);
// if (has)
// {
// //
// for (int i = 0; i < count; i++)
// {
// //
// XCBaseObject *iObj;
// bool isCreate = visionCycleHelper
// .mPOIDrawer
// .CreateFairValueGap(
// fvgs[i],
// iObj //
// );
// }
// }
//
// Extract UnActivated FVGs ...
int fvgsCount = FilterZones(
//
fvgs,
//
trend,
NULL, // For Period ...
workerBar.time,
//
// Start ...
XZONE_STATE_IGNORED,
true, // Force Body Out ...
//
// Activation ...
XZONE_STATE_FAILED,
false, // Force Body Out ...
//
// Breaktion ...
XZONE_STATE_IGNORED,
false, // Force Body Out ...
//
// Works ...
XZONE_STATE_IGNORED,
false, // Body Out ...
//
true, // Apply Sorting ...
true // Ignore Inside ...
);
//
bool has = IsValidSize(fvgsCount);
if (has)
{
//
int youngestIDX = GetYoungest(fvgs);
has = IsValidIndex(youngestIDX);
if (has)
{
//
workingZone
.orderFlow[youngestOBFVGIDX]
.fvg = fvgs[youngestIDX];
//
workingZone.UpdateTo(cTime);
//
XCBaseObject *iFVGObj;
bool isCreated = visionCycleHelper
.mPOIDrawer.CreateFairValueGap(
fvgs[youngestIDX],
iFVGObj //
);
if (isCreated)
{
Print("");
}
}
}
}
/////////////////////////////////////////////////////////////////////////////////////////////////////
//
// TODO: Neews to Review ...
else if (
isOBWorked &&
isFVGWorked &&
isOBActivated &&
isFVGActivated &&
fvgActivationBar.time >= obActivationBar.time &&
fvgActivationBar.time <= obActivationBar.NextAt() &&
obWorkerBar.time > fvgWorkerBar.time)
{
//
XOHCL iBar;
bool isBarPassed = iBar.Init(
symbol,
period,
zIndex //
);
//
if (isBarPassed)
{
//
bool isBarInsideFVG =
isBullish
? (
//
iBar.low < workingZone.orderFlow[youngestOBFVGIDX].fvg.Upper() &&
iBar.high > workingZone.orderFlow[youngestOBFVGIDX].fvg.Lower() &&
//
consolidationZBar.low < workingZone.orderFlow[youngestOBFVGIDX].fvg.Upper()
//
)
: (
//
iBar.high > workingZone.orderFlow[youngestOBFVGIDX].fvg.Lower() &&
iBar.low < workingZone.orderFlow[youngestOBFVGIDX].fvg.Upper() &&
//
consolidationZBar.high > workingZone.orderFlow[youngestOBFVGIDX].fvg.Lower()
//
);
if (isBarInsideFVG)
{
Print("");
}
}
//
iBar.Clean();
}
/////////////////////////////////////////////////////////////////////////////////////////////////////
//
// TODO:
// Remove Drawn Objects ...
// //
// if (hasNewOB)
// {
// //
// XCBaseObject *iObj;
// bool isCreated = visionCycleHelper
// .mPOIDrawer
// .CreateOrderBlock(
// newOB,
// iObj //
// );
// Print("New OB");
// }
// //
// if (hasNewFVG)
// {
// //
// XCBaseObject *iObj;
// bool isCreated = visionCycleHelper
// .mPOIDrawer
// .CreateFairValueGap(
// newFVG,
// iObj //
// );
// Print("New FVG");
// }
// //
// if (hasNewAnalyseOB)
// {
// //
// XCBaseObject *iObj;
// bool isCreated = analyseCycleHelper
// .mPOIDrawer
// .CreateOrderBlock(
// newAnalyseOB,
// iObj //
// );
// Print("New OB");
// }
// //
// if (hasNewAnalyseFVG)
// {
// //
// XCBaseObject *iObj;
// bool isCreated = analyseCycleHelper
// .mPOIDrawer
// .CreateFairValueGap(
// newAnalyseFVG,
// iObj //
// );
// Print("New FVG");
// }
/////////////////////////////////////////////////////////////////////////////////////////////////////