MCPcopy Create free account
hub / github.com/EasyRPG/Player / IsOutOfBounds

Method IsOutOfBounds

src/rect.cpp:58–63  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

56}
57
58bool Rect::IsOutOfBounds(int max_width, int max_height) const {
59 if (width <= 0 || height <= 0) return true;
60 if (x >= max_width || y >= max_height) return true;
61 if (x + width <= 0 || y + height <= 0) return true;
62 return false;
63}
64
65bool Rect::IsOutOfBounds(const Rect &src_rect) const {
66 if (width <= 0 || height <= 0) return true;

Callers 2

GetEncountersAtMethod · 0.80
RefreshMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected