mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-22 23:26:40 -08:00
Fix 0 shot for new defense
This commit is contained in:
@@ -15,12 +15,13 @@ public class Shot
|
||||
{
|
||||
// Although the game instructions reference two different jump shots,
|
||||
// the original game code treats them both the same and just prints "Jump shot"
|
||||
0 => null,
|
||||
<= 2 => new JumpShot(),
|
||||
3 => new Shot("Lay up"),
|
||||
4 => new Shot("Set shot"),
|
||||
_ => null
|
||||
};
|
||||
return shot is not null;
|
||||
return shotNumber == 0 || shot is not null;
|
||||
}
|
||||
|
||||
public static Shot Get(float shotNumber) =>
|
||||
|
||||
Reference in New Issue
Block a user