Skip to content

Commit d01088f

Browse files
committed
Don't allow non-sick people to get healed
1 parent 9090da9 commit d01088f

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

cogs/virus.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,9 @@ def heal(self, other):
213213
if other.is_cured():
214214
raise VirusError("You can't heal those who are already cured.")
215215

216+
if not other.infected:
217+
raise VirusError("No point in healing those who aren't sick")
218+
216219
if other.healer:
217220
raise VirusError("I'm sure they know how to treat themselves, we've got others to worry about for now.")
218221

@@ -969,7 +972,7 @@ async def backpack_use(self, ctx, *, emoji: str):
969972

970973
if state is State.already_dead:
971974
return await ctx.send("The dead can't use items...")
972-
else:
975+
elif state is not None:
973976
await self.process_state(state, user, member=ctx.author)
974977

975978
await ctx.send('The item was used... I wonder what happened?')

0 commit comments

Comments
 (0)