summaryrefslogtreecommitdiffhomepage
path: root/digital
diff options
context:
space:
mode:
Diffstat (limited to 'digital')
-rw-r--r--digital/io/src/playground.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/digital/io/src/playground.h b/digital/io/src/playground.h
index 95f7aad3..779b22c8 100644
--- a/digital/io/src/playground.h
+++ b/digital/io/src/playground.h
@@ -51,14 +51,14 @@
* value for on the X axis depending on the color.
*/
#define PG_X_VALUE_COMPUTING(x) \
- (bot_color ? x : PG_WIDTH - x)
+ (bot_color ? (x) : PG_WIDTH - (x))
/**
* Considering there is a symmetry axis on X, this macro will compute the
* value of the angle depending on the color.
*/
#define PG_A_VALUE_COMPUTING(a) \
- (bot_color ? a : (a + BOT_ANGLE_DEGREE * 180))
+ (bot_color ? (a) : ((a) + BOT_ANGLE_DEGREE * 180))
/**
* The position where to reset the bot when it starts, depending on the color.