mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-12-25 01:20:37 +00:00
Protection from accidentally activating Flash/Lightning (not implemented)
This commit is contained in:
parent
c54ed7222f
commit
42da061f2f
4
game.cpp
4
game.cpp
@ -6401,6 +6401,7 @@ bool movepcto(int d, int subdir, bool checkonly) {
|
|||||||
|
|
||||||
if(!passable(c2, cwt.c, P_ISPLAYER | P_MIRROR | P_USEBOAT | P_FRIENDSWAP) && items[itOrbFlash]) {
|
if(!passable(c2, cwt.c, P_ISPLAYER | P_MIRROR | P_USEBOAT | P_FRIENDSWAP) && items[itOrbFlash]) {
|
||||||
if(checkonly) return true;
|
if(checkonly) return true;
|
||||||
|
if(orbProtection(itOrbFlash)) return true;
|
||||||
activateFlash();
|
activateFlash();
|
||||||
bfs();
|
bfs();
|
||||||
if(multi::players > 1) { multi::whereto[multi::cpid].d = MD_UNDECIDED; return false; }
|
if(multi::players > 1) { multi::whereto[multi::cpid].d = MD_UNDECIDED; return false; }
|
||||||
@ -6410,6 +6411,7 @@ bool movepcto(int d, int subdir, bool checkonly) {
|
|||||||
|
|
||||||
if(!passable(c2, cwt.c, P_ISPLAYER | P_MIRROR | P_USEBOAT | P_FRIENDSWAP) && items[itOrbLightning]) {
|
if(!passable(c2, cwt.c, P_ISPLAYER | P_MIRROR | P_USEBOAT | P_FRIENDSWAP) && items[itOrbLightning]) {
|
||||||
if(checkonly) return true;
|
if(checkonly) return true;
|
||||||
|
if(orbProtection(itOrbLightning)) return true;
|
||||||
activateLightning();
|
activateLightning();
|
||||||
keepLightning = true;
|
keepLightning = true;
|
||||||
bfs();
|
bfs();
|
||||||
@ -6724,6 +6726,7 @@ bool movepcto(int d, int subdir, bool checkonly) {
|
|||||||
|
|
||||||
if(items[itOrbFlash]) {
|
if(items[itOrbFlash]) {
|
||||||
if(checkonly) return true;
|
if(checkonly) return true;
|
||||||
|
if(orbProtection(itOrbFlash)) return true;
|
||||||
activateFlash();
|
activateFlash();
|
||||||
checkmove();
|
checkmove();
|
||||||
return true;
|
return true;
|
||||||
@ -6731,6 +6734,7 @@ bool movepcto(int d, int subdir, bool checkonly) {
|
|||||||
|
|
||||||
if(items[itOrbLightning]) {
|
if(items[itOrbLightning]) {
|
||||||
if(checkonly) return true;
|
if(checkonly) return true;
|
||||||
|
if(orbProtection(itOrbLightning)) return true;
|
||||||
activateLightning();
|
activateLightning();
|
||||||
checkmove();
|
checkmove();
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user