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

Function RightMouseDown

Source/diablo.cpp:770–791  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

768}
769
770void RightMouseDown()
771{
772 if (!gmenu_is_active() && sgnTimeoutCurs == CURSOR_NONE && PauseMode != 2 && !plr[myplr]._pInvincible) {
773 if (doomflag) {
774 doom_close();
775 } else if (!stextflag) {
776 if (spselflag) {
777 SetSpell();
778 } else if (MouseY >= SPANEL_HEIGHT
779 || (!sbookflag || MouseX <= RIGHT_PANEL)
780 && !TryIconCurs()
781 && (pcursinvitem == -1 || !UseInvItem(myplr, pcursinvitem))) {
782 if (pcurs == 1) {
783 if (pcursinvitem == -1 || !UseInvItem(myplr, pcursinvitem))
784 CheckPlrSpell();
785 } else if (pcurs > CURSOR_HAND && pcurs < CURSOR_FIRSTITEM) {
786 SetCursor_(CURSOR_HAND);
787 }
788 }
789 }
790 }
791}
792
793BOOL PressSysKey(int wParam)
794{

Callers 1

GM_GameFunction · 0.85

Calls 7

gmenu_is_activeFunction · 0.85
doom_closeFunction · 0.85
SetSpellFunction · 0.85
TryIconCursFunction · 0.85
UseInvItemFunction · 0.85
CheckPlrSpellFunction · 0.85
SetCursor_Function · 0.85

Tested by

no test coverage detected