MCPcopy Create free account
hub / github.com/diasurgical/devilution / HSExists

Function HSExists

SourceX/controls/plrctrls.cpp:642–650  ·  view source on GitHub ↗

check if hot spell at X Y exists

Source from the content-addressed store, hash-verified

640
641// check if hot spell at X Y exists
642bool HSExists(int x, int y)
643{
644 for (int r = 0; r < speedspellcount; r++) { // speedbook cells are 56x56
645 if (MouseX >= speedspellscoords[r].x - 28 && MouseX < speedspellscoords[r].x + (28) && MouseY >= speedspellscoords[r].y - (28) && MouseY < speedspellscoords[r].y + 28) {
646 return true;
647 }
648 }
649 return false;
650}
651
652void HotSpellMove(MoveDirection dir)
653{

Callers 1

HotSpellMoveFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected