From 7b05778e3ef8ef01a4bb15a6ed6fde5b329a8c9b Mon Sep 17 00:00:00 2001 From: XaviDCR92 Date: Sun, 5 Nov 2017 19:08:38 +0100 Subject: *Removed decceleration for camera. Improved pathfinding when a unit collides with another unit. Added generic function to find distances. Other minor changes. --- System.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'System.c') diff --git a/System.c b/System.c index 68742d4..be3bbc7 100644 --- a/System.c +++ b/System.c @@ -326,3 +326,8 @@ bool Systemitoa(char* str, size_t sz, int16_t value) return false; } + +uint32_t SystemGetHyp(uint16_t x, uint16_t y) +{ + return (uint32_t)((uint32_t)(x * x) + (uint32_t)(y * y)); +} -- cgit v1.2.3