Assist: Fail move if no moves have been found
continuous-integration/drone/push Build is failing

This commit is contained in:
Deukhoofd committed 2021-11-12 13:03:18 +01:00
1 parent afe091eefa
commit 67762af0e7
3 files changed
+8 -2

No files matched your search

+5 -1
View File
@@ -655,7 +655,11 @@
"protect",
"reflectable",
"mirror"
]
],
"effect": {
"name": "ChangeTargetAtt",
"parameters": [-1]
}
},
{
"name": "baneful_bunker",
@@ -3,5 +3,7 @@ type MoveTurnChoice {
Pokemon@ User { get const; };
LearnedMove@ Move { get const; };
int8 Priority { get const; };
bool HasFailed { get const; };
void Fail();
BaseTurnChoice@ opImplCast();
}
+1 -1
View File
@@ -20,7 +20,7 @@ namespace Gen7 {
}
}
if (possibleMoves.length == 0){
// TODO: Log failure.
move.Fail();
return;
}
auto i = battle.Random.Get(possibleMoves.length);