Skip to main content

CCLayer

CCLayer

Cocos2D

Inheritance: System.Object → Cocos2D.CCNode

Implements: Cocos2D.ICCSelectorProtocol, Cocos2D.ICCFocusable, Cocos2D.ICCTargetedTouchDelegate, Cocos2D.ICCStandardTouchDelegate, Cocos2D.ICCTouchDelegate, Cocos2D.ICCKeypadDelegate, Cocos2D.ICCKeyboardDelegate, Cocos2D.ICCRGBAProtocol, System.Collections.Generic.IComparer{Cocos2D.CCNode}, Cocos2D.ICCAccelerometerDelegate

Constructors

CCLayer()

CCLayer()()

Default layer constructor that does not use clipping.

Example

CCLayer(CCClipMode)

CCLayer(CCClipMode)(Cocos2D.CCClipMode clipMode)
Parameters:
clipMode (Cocos2D.CCClipMode)

Fields

m_childClippingMode(Cocos2D.CCClipMode)

Set to true if the child drawing should be isolated in their own render target

Properties

AccelerometerEnabled(System.Boolean)
ChildClippingMode(Cocos2D.CCClipMode)
ContentSize(Cocos2D.CCSize)

Methods

AddedToScene()

AddedToScene()()
Example

DidAccelerate(CCAcceleration)

DidAccelerate(CCAcceleration)(Cocos2D.CCAcceleration pAccelerationValue)
Parameters:
pAccelerationValue (Cocos2D.CCAcceleration)
Example

Init()

System.Boolean Init()()
Returns:
System.Boolean
Example

OnEnter()

OnEnter()()
Example

OnEnterTransitionDidFinish()

OnEnterTransitionDidFinish()()
Example

OnExit()

OnExit()()
Example

Visit()

Visit()()

This is called with every call to the MainLoop on the CCDirector class. In XNA, this is the same as the Draw() call.

Example