Have Harmonic Pattern indicator codes. Can anyone help make it a functioning indicator?

 
//+------------------------------------------------------------------+
//|                   Harmonic Pattern Detector (MT5)                 |
//+------------------------------------------------------------------+
#property strict

// Input parameters
input ENUM_TIMEFRAMES period = PERIOD_H1; // Chart period
input int lookbackBars = 100; // Number of bars to analyze

// Price swing calculation
double CalculateSwingHigh(int start, int end)
{
    double high = High[start];
    for (int i = start; i <= end; i++)
    {
        if (High[i] > high)
            high = High[i];
    }
    return high;
}

double CalculateSwingLow(int start, int end)
{
    double low = Low[start];
    for (int i = start; i <= end; i++)
    {
        if (Low[i] < low)
            low = Low[i];
    }
    return low;
}

// Pattern detection functions
bool IsGartleyPattern()
{
    // Gartley pattern detection logic
    // Implement your own logic to check for Gartley pattern
    return false;
}

bool IsButterflyPattern()
{
    // Butterfly pattern detection logic
    // Implement your own logic to check for Butterfly pattern
    return false;
}

bool IsBatPattern()
{
    // Bat pattern detection logic
    // Implement your own logic to check for Bat pattern
    return false;
}

bool IsCrabPattern()
{
    // Crab pattern detection logic
    // Implement your own logic to check for Crab pattern
    return false;
}

// Initialization function
int OnInit()
{
    // Set the indicator buffers (if needed)
    return(INIT_SUCCEEDED);
}

// Deinitialization function
void OnDeinit(const int reason)
{
    // Perform any necessary cleanup here
}

// Main processing function
void OnTick()
{
    // Check if any harmonic pattern is detected
    if (IsGartleyPattern())
    {
        // Perform actions when Gartley pattern is detected
        Print("Gartley pattern detected!");
    }
    else if (IsButterflyPattern())
    {
        // Perform actions when Butterfly pattern is detected
        Print("Butterfly pattern detected!");
    }
    else if (IsBatPattern())
    {
        // Perform actions when Bat pattern is detected
        Print("Bat pattern detected!");
    }
    else if (IsCrabPattern())
    {
        // Perform actions when Crab pattern is detected
        Print("Crab pattern detected!");
    }
}
                 Thanks
 
Na Na:
                 Thanks

You can borrow ideas from this code base entry 

https://www.mql5.com/en/code/22218

Or from others (search result) : https://www.mql5.com/en/search#!keyword=harmonic&module=mql5_module_codebase&page=1

Harmonic Pattern Finder V3
Harmonic Pattern Finder V3
  • www.mql5.com
Indicator to display existent and emerging harmonic chart patterns.