forked from animatedread/Warrior_EA
| Filename | Latest commit message | Latest commit date |
|---|---|---|
Two literal duplications the scan found, both of the kind where a divergence is silent: - Training.mqh stashed the era-loop resume context at FOUR yield points, seven identical assignments each (pass 1 differing only in i-1). A field missed at one of them resumes the next chunk against a different era than the one that yielded, and nothing reports it until the numbers drift. Now StashEraResume(). - AltDataFetch grew its five parallel arrays inline in three places. They are one record split across five buffers, so a resize missed on any one reads out of range on the NEXT append, not at the site of the mistake. Now AltSeriesAppend(), which returns the new index and zero-fills; callers set only the columns their source has. Braces balance across every in-scope file. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> |
||
| .. | ||
| AltData.mqh | ||
| AltDataFetch.mqh | ||
| AtomicFile.mqh | ||
| BinomialStats.mqh | ||
| CrossAsset.mqh | ||
| NewBar.mqh | ||
| NewsRelevance.mqh | ||
| PrintVerbose.mqh | ||
| Random.mqh | ||
| README.md | ||
| StatusLabel.mqh | ||
| TradeChecks.mqh | ||
System Subsystem (System/)
Overview
The System/ directory contains utility and infrastructure code for the Warrior EA. These modules provide essential services such as new bar detection, conditional logging, crash-safe file writes and trade validation, supporting robust and maintainable EA operation.
Key Components
NewBar.mqh
- Function:
NewBar() - Purpose: Detects the arrival of a new bar (candle) on the chart.
- Logic: Compares the current bar's time with the last seen bar time. Returns true if a new bar is detected.
- Integration: Used for event-driven logic, e.g., only executing logic once per bar.
PrintVerbose.mqh
- Function:
PrintVerbose(string message) - Purpose: Conditional logging based on a
VerboseModeflag. Prints messages only if verbose mode is enabled. - Integration: Useful for debugging and development without cluttering logs in production.
Documented April 2026. For further details, see the main project documentation.