void MaybeDrawCollection(MemoryMonitor.MemoryFrame memoryFrame, MemoryMonitor.CollectionType collectionType, Vector2 position, Vector2 barSize, Vector2 offset1, Vector2 offset2, Color color) { if ((memoryFrame.CollectionType & collectionType) == 0) { return; } //Draw a horizontal line and a little square marker indicating a collection has taken place. _memoryMonitor.TempBoxDrawer.ShowGradientBoxOnce(position, position - barSize, color, color); _memoryMonitor.TempBoxDrawer.ShowGradientBoxOnce(position - offset1, position - offset2, color, color); }
void DrawCollections(MemoryMonitor.MemoryFrame memoryFrame, Vector2 position, Vector2 barSize) { MaybeDrawCollection(memoryFrame, MemoryMonitor.CollectionType.Gen0, position, barSize, Vector2.Zero, new Vector2(10, 5), FlatTheme.Emerald); MaybeDrawCollection(memoryFrame, MemoryMonitor.CollectionType.Gen1, position, barSize, new Vector2(0, 5), new Vector2(10, 10), FlatTheme.Carrot); MaybeDrawCollection(memoryFrame, MemoryMonitor.CollectionType.Gen2, position, barSize, new Vector2(0, 10), new Vector2(10, 15), FlatTheme.Pomegrantate); if (_memoryMonitor.MonitorXbox360Garbage) { MaybeDrawCollection(memoryFrame, MemoryMonitor.CollectionType.Xbox360, position, barSize, new Vector2(0, 15), new Vector2(10, 20), FlatTheme.Silver); } }