diff options
author | Juan J. Martinez <jjm@usebox.net> | 2023-07-20 23:19:50 +0100 |
---|---|---|
committer | Juan J. Martinez <jjm@usebox.net> | 2023-07-20 23:24:56 +0100 |
commit | 273026bf7e21865ef305af22dc8826be462117f0 (patch) | |
tree | 129ec9d103d986dd1aea23395f1dfcf99b3f186d /src/entities.c | |
parent | f00ca8c1a2ae1c59854e60b13d3f529ab9e685c5 (diff) | |
download | gold-mine-run-273026bf7e21865ef305af22dc8826be462117f0.tar.gz gold-mine-run-273026bf7e21865ef305af22dc8826be462117f0.zip |
Erase collected gold
Although the erase code of the player is likely to clean the gold after
being picked up, there could be some left overs in some corner cases, so
we let the map erase the gold to ensure it is 100% clean.
Diffstat (limited to 'src/entities.c')
-rw-r--r-- | src/entities.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/entities.c b/src/entities.c index 321af98..6b6c7a1 100644 --- a/src/entities.c +++ b/src/entities.c @@ -101,6 +101,9 @@ void entities_draw() { Rect dst = { 0, 0, 16, 16 }; + /* in case we need to clean collected gold */ + map_erase(); + player_erase(); for (uint8_t i = 0; i < last; i++) |