zoukankan      html  css  js  c++  java
  • CCOrbitCamera:create

    local layer = getBaseLayer()
     

    sprite = CCSprite:create("Images/white-512x512.png")

        layer:addChild(sprite, 0, 40)
        sprite:setPosition(CCPointMake(s.width / 5 * 1, s.height / 5 * 4))
        sprite:setColor(ccc3(0, 0, 255))
        sprite:setTextureRect(CCRectMake(0, 0, 120, 50))
     
     
    --旋转的时间、起始半径、半径差、起始z角、旋转z角差、起始x角、旋转x角差
        orbit = CCOrbitCamera:create(10, 1, 0, 0, 360, 0, 0)
     
        sprite:runAction(CCRepeatForever:create(orbit))
     
     
    调用lua
    package.path = package.path .. ";..?.lua"
    require(pardirfile)

     

  • 相关阅读:
    Investment
    The Fewest Coins
    Bone Collector II
    Cow Exhibition
    饭卡
    A + B Problem II
    F
    敌兵布阵
    单例模式
    面向对象
  • 原文地址:https://www.cnblogs.com/AbelChen1991/p/3831186.html
Copyright © 2011-2022 走看看