RTS2D
|
00001 #ifndef MYMATH_H 00002 #include <cmath> 00003 #include <string> 00004 #include <sstream> 00005 #define MYMATH_H 00006 00007 namespace mymath { 00008 float distance(float x1, float y1, float x2, float y2); 00009 bool collide(float x1, float y1, float r1, float x2, float y2, float r2); 00010 float powDistance(float x1, float y1, float x2, float y2); 00011 bool inrange(float x1, float y1, float r1, float x2, float y2, float r2); 00012 bool inside(float x, float y, float r, float rectx1, float recty1, float rectx2, float recty2); 00013 int div(float x, int d); 00014 } 00015 00016 00017 #endif // MYMATH_H