From 78af7215e22d1552494aa8cd3b9a1fd8fa63add6 Mon Sep 17 00:00:00 2001 From: Arnaud Jamin Date: Tue, 17 Oct 2023 00:19:11 -0400 Subject: [PATCH] Update README.md --- README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 628ccad..a45c4b5 100644 --- a/README.md +++ b/README.md @@ -112,6 +112,11 @@ Can be used to activate and deactivate log categories ### Metric Gather various values sent by the selected actor and compte their rate per second. This is typically useful to compute the damage dealt or received per second. +- The following code shows how to add a metric: +```cpp +// Adding a metric +FCogDebugMetric::AddMetric(this, "Damage Dealt", Params.MitigatedDamage, Params.UnmitigatedDamage, false); +``` ![Metric](https://github.com/arnaud-jamin/Cog/assets/13844285/64d3cb7c-8731-4897-9ef9-b0868148ebe2) @@ -136,7 +141,7 @@ Displays attributes of the selected actor as pools. Plots values and events overtime. When applicable, only the values and events of the selected actor are displayed. ![Plots](https://github.com/arnaud-jamin/Cog/assets/13844285/def95b7b-ae59-4a8b-bc21-b07922e1fc6f) -- The following code snippets show how to plot values and events: +- The following code shows how to plot values and events: ```cpp // Plotting a value FCogDebugPlot::PlotValue(this, "Speed", Velocity.Length());