Lab

Cocos2d-x v3:準備された色を使う

 Tag :  Published : 2014-6-3

Pocket

あらかじめ準備された色を使います。
> Ver2.x : 『準備された色を使う』はこちら

あらかじめ準備されている色を使ってみる

白、黒、赤などプリミティブな色をカンタンに設定する事ができます。

    //Color3B
    Color3B color3bWHITE = Color3B::WHITE;
    Color3B color3bYELLOW = Color3B::YELLOW;
    Color3B color3bBLUE = Color3B::BLUE;
    Color3B color3bGREEN = Color3B::GREEN;
    Color3B color3bRED = Color3B::RED;
    Color3B color3bMAGENTA = Color3B::MAGENTA;
    Color3B color3bBLACK = Color3B::BLACK;
    Color3B color3bORANGE = Color3B::ORANGE;
    Color3B color3bGRAY = Color3B::GRAY;
    
    //Color4B
    Color4B color4bWHITE = Color4B::WHITE;
    Color4B color4bYELLOW = Color4B::YELLOW;
    Color4B color4bBLUE = Color4B::BLUE;
    Color4B color4bGREEN = Color4B::GREEN;
    Color4B color4bRED = Color4B::RED;
    Color4B color4bMAGENTA = Color4B::MAGENTA;
    Color4B color4bBLACK = Color4B::BLACK;
    Color4B color4bORANGE = Color4B::ORANGE;
    Color4B color4bGRAY = Color4B::GRAY;
    
    //Color4F
    Color4F color4fWHITE = Color4F::WHITE;
    Color4F color4fYELLOW = Color4F::YELLOW;
    Color4F color4fBLUE = Color4F::BLUE;
    Color4F color4fGREEN = Color4F::GREEN;
    Color4F color4fRED = Color4F::RED;
    Color4F color4fMAGENTA = Color4F::MAGENTA;
    Color4F color4fBLACK = Color4F::BLACK;
    Color4F color4fORANGE = Color4F::ORANGE;
    Color4F color4fGRAY = Color4F::GRAY;
    

pageTop