Cocos Creator API

1.2.0

Cocos Creator is a highly customizable game development tool that utilizes the power of cocos2d-x.

visibleRect

模块: cc

cc.visibleRect is a singleton object which defines the actual visible rect of the current view, it should represent the same rect as cc.view.getViewportRect()

属性(properties)

topLeft Vec2

Top left coordinate of the screen related to the game scene.

topRight Vec2

Top right coordinate of the screen related to the game scene.

top Vec2

Top center coordinate of the screen related to the game scene.

bottomLeft Vec2

Bottom left coordinate of the screen related to the game scene.

bottomRight Vec2

Bottom right coordinate of the screen related to the game scene.

bottom Vec2

Bottom center coordinate of the screen related to the game scene.

center Vec2

Center coordinate of the screen related to the game scene.

left Vec2

Left center coordinate of the screen related to the game scene.

right Vec2

Right center coordinate of the screen related to the game scene.

width Number

Width of the screen.

height Number

Height of the screen.

There are no properties that match your current filter settings. You can change your filter settings in the index section on this page. index

方法

init
(
  • visibleRect
)

initialize

名称 类型 描述
visibleRect Rect

There are no methods that match your current filter settings. You can change your filter settings in the index section on this page. index