summaryrefslogtreecommitdiff
path: root/System.c
diff options
context:
space:
mode:
authorXaviDCR92 <xavi.dcr@gmail.com>2017-11-05 19:08:38 +0100
committerXaviDCR92 <xavi.dcr@gmail.com>2017-11-05 19:08:38 +0100
commit7b05778e3ef8ef01a4bb15a6ed6fde5b329a8c9b (patch)
tree2629c7ad872b398dc045a863a75879533ce99aa0 /System.c
parent2d04eba931ac84e2f09d3c8391125f8a991ca7d3 (diff)
downloadpocketempires-7b05778e3ef8ef01a4bb15a6ed6fde5b329a8c9b.tar.gz
*Removed decceleration for camera.
Improved pathfinding when a unit collides with another unit. Added generic function to find distances. Other minor changes.
Diffstat (limited to 'System.c')
-rw-r--r--System.c5
1 files changed, 5 insertions, 0 deletions
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));
+}