Sfoglia il codice sorgente

Fix #1928
* disallow geneie to cast teleport

AlexVinS 11 anni fa
parent
commit
e583f4e44d
2 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 1 0
      lib/CBattleCallback.cpp
  2. 1 0
      lib/NetPacksLib.cpp

+ 1 - 0
lib/CBattleCallback.cpp

@@ -2295,6 +2295,7 @@ SpellID CBattleInfoCallback::getRandomBeneficialSpell(const CStack * subject) co
 						continue;
 				}
 				break;
+			case SpellID::TELEPORT: //issue 1928
 			case SpellID::CLONE: //not allowed
 				continue;
 				break;

+ 1 - 0
lib/NetPacksLib.cpp

@@ -1197,6 +1197,7 @@ void BattleResult::applyGs( CGameState *gs )
 void BattleStackMoved::applyGs( CGameState *gs )
 {
 	CStack *s = gs->curB->getStack(stack);
+	assert(s);
 	BattleHex dest = tilesToMove.back();
 
 	//if unit ended movement on quicksands that were created by enemy, that quicksand patch becomes visible for owner