I have to use python for this p roject even though I know very little, I taught myself c# and fairly faimilar with it but with python I still have my swimming bands on. In using a state machine to control a virtual pet
I have a parent class called State
I have children classes one of which is Default state
I keep getting this error TypeError: function takes 1 positional arguments but 2 were given
when I call this function
def update(self,vpet) -> None:
super().update(vpet)
which obviously calls the super class
def update(self,vpet) -> None:
pass
I call it like so from the vpet class
def update(self) -> None:
self.currentState.update(self)
The logic in my brain seems like it should work but it doesnt, I know this is an issue with the coder
the error is thrown at line 7 in defaultState.py where it calls the parent update