I've been looking through classes and been trying to organize material as best I can, so I have started setting up values in functions contained in classes. Whenever the value of damage is returned I get -858993460. Any ideas?
Header file the class is stored in:
class swords
{
public:
void setDamage(int strengthEffect, int sharpnessEffect)
{
int damage = (strengthEffect + sharpnessEffect)*sharpnessEffect;
};
int getDamage()
{
return damage;
}
private:
int damage;