From e857fcf03bba8e8a778bff3a8cf28d6096001b24 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Kat=20March=C3=A1n?= <kzm@zkat.tech>
Date: Thu, 8 Apr 2021 19:27:32 -0700
Subject: [PATCH] no need to re-instantiate a score

---
 README.md          | 2 +-
 examples/thirst.rs | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index ee84a1a..b143e25 100644
--- a/README.md
+++ b/README.md
@@ -31,7 +31,7 @@ pub fn score_thirst_system(
 ) {
     for (Parent(actor), mut score) in query.iter_mut() {
         if let Ok(thirst) = thirsts.get(*actor) {
-            *score = Score(thirst.thirst);
+            score.0 = thirst.thirst;
         }
     }
 }
diff --git a/examples/thirst.rs b/examples/thirst.rs
index cadfc2a..73c3099 100644
--- a/examples/thirst.rs
+++ b/examples/thirst.rs
@@ -107,7 +107,7 @@ pub fn thirsty_scorer_system(
             // calculation here, possibly to clamp the value to a range, add a
             // curve, etc. In our case, we'll just assume thirst goes from
             // 0.0..100.0, to keep things simple.
-            *score = Score(thirst.thirst);
+            score.0 = thirst.thirst;
         }
     }
 }
-- 
GitLab