get problem when follow the tutorial of changing background color : CCLayerColor

HI I follow the Chapter 2 - How to Add a sprite
and i got problem when i want to change the background color.

when i change the CCLayer to CCLayerColor…the CREATE_FUNC(Helloworld), got error
The type ‘HelloWorld’ must implement the inherited pure virtual method ‘cocos2d::CCRGBAProtocol::setOpacity’

i dun know why will cause this, i search in internet,and find out some other guys have this problem, but cant find soultion

The constructors are not the same between CCLayer and CCLayerColor

If you are extending a class, it needs to inherit from CCLayerColor

I extend and I do something like this:

bool PlainBackgroundLayer::initWithColorAndSize(cocos2d::ccColor4B inColor, cocos2d::CCSize inSize)
{
backgroundColor = inColor;
layerSize = inSize;
if (!CCLayerColor::initWithColor(backgroundColor)) return false;
setContentSize(CCSizeMake(inSize.width, inSize.height));
setPosition(0,0);
return true;
}