mirror of
https://github.com/GayPizzaSpecifications/padlab.git
synced 2025-08-04 05:31:33 +00:00
Separate stick functionality from main file
This commit is contained in:
9
maths.h
9
maths.h
@ -12,7 +12,9 @@
|
||||
#define SATURATE(X) (CLAMP(X, 0, 1))
|
||||
|
||||
typedef double vec_t;
|
||||
typedef struct {vec_t x, y;} vector;
|
||||
typedef struct { vec_t x, y; } vector;
|
||||
|
||||
typedef struct { int x, y, w, h; } rect;
|
||||
|
||||
static inline vector VecAdd(vector l, vector r)
|
||||
{
|
||||
@ -29,9 +31,4 @@ static inline double pfmod(double x, double d)
|
||||
return fmod(fmod(x, d) + d, (d));
|
||||
}
|
||||
|
||||
static inline double AccelCurve(double x, double y)
|
||||
{
|
||||
return (x * (x + y)) / (1.0 + y);
|
||||
}
|
||||
|
||||
#endif//MATHS_H
|
||||
|
Reference in New Issue
Block a user