Hey guys, I’m not sure why but visual studio won’t let me implement the ISaveable interface. Moy entirely sure what the issue is.
thanks in advance.
Hey guys, I’m not sure why but visual studio won’t let me implement the ISaveable interface. Moy entirely sure what the issue is.
thanks in advance.
What does this mean?
Are you including
using RPG.Saving;
in your using clauses?
I am, the issue that I’m having is that vs code doesn’t give me the option to implement the interface when I add the ISavable interface the Monobehaviour line. then i get this error in the unity console. I’m at a loss at what to do.
ISaveable, you’re missing an e
It’s telling you that to fulfil the ISaveable interface, you need the following methods
public object CaptureState()
{
return healthPoints;
}
public void RestoreState(object state)
{
healthPoints = (float)state;
if(healthPoints<=0.0f)
{
Die();
}
}
in the video Challenge: Saveable Health he creates two methods using control . to make them, it’s not letting me do that. Will it still work the same if i manually type them out?
Yes, it will work the same. Visual Studio Code is currently broken when it comes to intellisense and autocompletion (including control-.)
could i trouble you with another error? Do I need to ask a separate question for different topics?
This is the error i get now that the ISaveable interface works.
It looks like you’ve defined the IAction in 2 different places… likely, you want to remove the one in Movement and leave the one in core.