AlpacaLibary  1.63
A closed source C++ bot for OSRS
Box Class Reference

#include <Box.hpp>

Public Member Functions

 Box ()
 
 Box (std::int32_t X, std::int32_t Y, std::int32_t Width, std::int32_t Height)
 
 Box (const Box &B)
 
bool Contains (const Point &P) const
 
bool Contains (const Box &B) const
 
bool Contains (std::int32_t X, std::int32_t Y) const
 
Point GetMiddle () const
 
std::int32_t GetX2 () const
 
std::int32_t GetY2 () const
 
bool OnScreen () const
 
bool IsValid () const
 
Point GetUniformRandomPoint () const
 
Point GetBinomialRandomPoint (double ProbabilityX, double ProbabilityY) const
 
Point GetNormalRandomPoint (double PercentageDeviationX, double PercentageDeviationY) const
 
Point GetHybridRandomPoint (double ProbabilityX, double ProbabilityY, double StandardDeviationX, double StandardDeviationY, double PointGenAccuracy) const
 
Point GetProfileHybridRandomPoint () const
 
Point GetProfileHybridRandomPoint (double PointGenAccuracy) const
 
bool operator== (const Box &B) const
 
bool operator!= (const Box &B) const
 
 operator bool () const
 
 ~Box ()
 

Public Attributes

std::int32_t X
 The top-left x-axis coordinate. More...
 
std::int32_t Y
 The top-left y-axis coordinate. More...
 
std::int32_t Width
 
std::int32_t Height
 

Friends

std::ostream & operator<< (std::ostream &OS, const Box &B)
 

Detailed Description

Definition at line 10 of file Box.hpp.

Constructor & Destructor Documentation

◆ Box() [1/3]

Box::Box ( )

◆ Box() [2/3]

Box::Box ( std::int32_t  X,
std::int32_t  Y,
std::int32_t  Width,
std::int32_t  Height 
)
Parameters
XTop-left x-axis coordinate of the box to construct
YTop-left y-axis coordinate of the box to construct
WidthThe width of the box to construct
HeightThe Height of the box to construct

◆ Box() [3/3]

Box::Box ( const Box B)

◆ ~Box()

Box::~Box ( )

Member Function Documentation

◆ Contains() [1/3]

bool Box::Contains ( const Box B) const

◆ Contains() [2/3]

bool Box::Contains ( const Point P) const

◆ Contains() [3/3]

bool Box::Contains ( std::int32_t  X,
std::int32_t  Y 
) const

◆ GetBinomialRandomPoint()

Point Box::GetBinomialRandomPoint ( double  ProbabilityX,
double  ProbabilityY 
) const

◆ GetHybridRandomPoint()

Point Box::GetHybridRandomPoint ( double  ProbabilityX,
double  ProbabilityY,
double  StandardDeviationX,
double  StandardDeviationY,
double  PointGenAccuracy 
) const

◆ GetMiddle()

Point Box::GetMiddle ( ) const

◆ GetNormalRandomPoint()

Point Box::GetNormalRandomPoint ( double  PercentageDeviationX,
double  PercentageDeviationY 
) const

◆ GetProfileHybridRandomPoint() [1/2]

Point Box::GetProfileHybridRandomPoint ( ) const

◆ GetProfileHybridRandomPoint() [2/2]

Point Box::GetProfileHybridRandomPoint ( double  PointGenAccuracy) const

◆ GetUniformRandomPoint()

Point Box::GetUniformRandomPoint ( ) const

◆ GetX2()

std::int32_t Box::GetX2 ( ) const

◆ GetY2()

std::int32_t Box::GetY2 ( ) const

◆ IsValid()

bool Box::IsValid ( ) const
Returns
True if the x and y axis coordinates, width and height are greater than or equal to zero

◆ OnScreen()

bool Box::OnScreen ( ) const
Returns
True if the box is within the client canvas bounds

◆ operator bool()

Box::operator bool ( ) const
Returns
True if the x and y axis coordinates, width and height are greater than or equal to zero

◆ operator!=()

bool Box::operator!= ( const Box B) const

◆ operator==()

bool Box::operator== ( const Box B) const

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  OS,
const Box B 
)
friend

Member Data Documentation

◆ Height

std::int32_t Box::Height

Definition at line 26 of file Box.hpp.

◆ Width

std::int32_t Box::Width

Definition at line 25 of file Box.hpp.

◆ X

std::int32_t Box::X

The top-left x-axis coordinate.

Definition at line 23 of file Box.hpp.

◆ Y

std::int32_t Box::Y

The top-left y-axis coordinate.

Definition at line 24 of file Box.hpp.


The documentation for this class was generated from the following file: