This commit is contained in:
33 files changed
+511
-26
No files matched your search
@@ -11,6 +11,9 @@ public class WonderGuard : Script, IScriptBlockIncomingHit
|
||||
/// <inheritdoc />
|
||||
public void BlockIncomingHit(IExecutingMove executingMove, IPokemon target, byte hitIndex, ref bool block)
|
||||
{
|
||||
var type = executingMove.GetHitData(target, hitIndex).Type;
|
||||
if (type is null || type.Value.Value == 0)
|
||||
return;
|
||||
var effectiveness = executingMove.GetHitData(target, hitIndex).Effectiveness;
|
||||
if (!(effectiveness <= 1.0))
|
||||
return;
|
||||
|
||||
Reference in new issue
Block a user