Add MathEngineTest and Commects and clean ups

This commit is contained in:
2018-08-18 20:50:06 -04:00
parent bd3c111fa1
commit a815367c9d
52 changed files with 386 additions and 144 deletions
@@ -20,31 +20,52 @@ namespace MathEngine {
private:
cCollision();
~cCollision();
public:
/// Functions
/* returns true if a is touching b */
static const bool BoundingBox( const SDL_Rect& a, const SDL_Rect& b );
/* returns true if a is touching b */
static const bool BoundingBox( const Vector4& a, const Vector4& b );
static const bool BoundingBox( const SDL_Rect& a, const Vector4& b );
static const bool BoundingBox( const Vector4& a, const SDL_Rect& b );
/* returns true if a is touching b */
static const bool BoundingBox(const iVector4& a, const iVector4& b);
static const bool BoundingBox( const iVector4& a, const iVector4& b );
/* returns true if a is touching b */
static const bool BoundingBox( const SDL_Rect& a, const Vector4& b );
/* returns true if a is touching b */
static const bool BoundingBox( const Vector4& a, const SDL_Rect& b );
/* returns true if a is touching b */
static const bool BoundingBox( const SDL_Rect& a, const iVector4& b );
/* returns true if a is touching b */
static const bool BoundingBox( const iVector4& a, const SDL_Rect& b );
/* returns true if a is touching b */
static const bool BoundingBox( const iVector4& a, const Vector4& b );
/* returns true if a is touching b */
static const bool BoundingBox( const Vector4& a, const iVector4& b );
static const Vector2 Inside( const SDL_Rect& a, const SDL_Rect& b );
/* returns the Vector2 were a over laps b */
static const Vector2 Inside( const Vector4& a, const Vector4& b );
/* returns the Vector2 were a over laps b */
static const Vector2 Inside( const SDL_Rect& a, const Vector4& b );
/* returns the Vector2 were a over laps b */
static const Vector2 Inside( const Vector4& a, const SDL_Rect& b );
/* returns true if xy are inside SDL_Rect */
static const bool isInside( const signed long int x, const signed long int y, const SDL_Rect& inside );
/* returns true if xy are inside iVector4 */
static const bool isInside( const signed long int x, const signed long int y, const iVector4& inside );
/* returns the iVector2 were a over laps b */
static const iVector2 Inside(const SDL_Rect& a, const SDL_Rect& b);
/* returns the iVector2 were a over laps b */
static const iVector2 Inside( const iVector4& a, const iVector4& b );
/* returns the iVector2 were a over laps b */
static const iVector2 Inside( const SDL_Rect& a, const iVector4& b );
/* returns the iVector2 were a over laps b */
static const iVector2 Inside( const iVector4& a, const SDL_Rect& b );
static const Vector2 Inside( const iVector4& a, const Vector4& b );
static const Vector2 Inside( const Vector4& a, const iVector4& b );
};/// END CLASS DEFINITION cCollision
}/// END NAMESPACE DEFINITION MathEngine
#endif/// END IFNDEF _CCOLLISION_HPP_