I copied your .h, .cpp, and .pde files into the 0022 version of the IDE.
You have more errors than you listed.
void gain(int setGain)
Needs a ; at the end;
void ERER::emitterN(int emitterNegative){
pinMode(emitterN, OUTPUT);
_irEmitterP = emitterNegative;
}
In the pinMode statement, emitterN is the name of the function, not the pin to be set.
void init(int emitter) {
What happened to the ERER::?
Your class is missing a constructor.
void ERER::distanceCheck() {
if(currentInit == 0){if(digitalRead(_irReceiverN) == LOW) ERER::ambientCheck();}
if(currentInit == 1){if(digitalRead(_irReceiverN) == LOW) ERER::emissionCheck();}
}
Get rid of the scope resolution operator. Again.
sensore1.receiverN(2);
sensore1.receiverP(5);
sensore1.emitterP(13);
sensore1.gain(4);
sensore1.maxRangeValue(666666);
sensore1.maxRange(2000);
Executable code needs to be inside a function.