• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# cocos2d.ccGridSize类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中cocos2d.ccGridSize的典型用法代码示例。如果您正苦于以下问题:C# ccGridSize类的具体用法?C# ccGridSize怎么用?C# ccGridSize使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



ccGridSize类属于cocos2d命名空间,在下文中一共展示了ccGridSize类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: turnOffTile

        public void turnOffTile(ccGridSize pos)
        {
            ccQuad3 coords = new ccQuad3();

            //memset(coords, 0, sizeof(ccQuad3));
            setTile(pos, coords);
        }
开发者ID:Ratel13,项目名称:cocos2d-x-for-xna,代码行数:7,代码来源:CCTurnOffTiles.cs


示例2: actionWithSize

 /// <summary>
 /// creates the action with the grid size and the duration 
 /// </summary>
 public static CCFadeOutUpTiles actionWithSize(ccGridSize gridSize, float time)
 {
     CCFadeOutUpTiles pAction = new CCFadeOutUpTiles();
     if (pAction.initWithSize(gridSize, time))
     {
         return pAction;
     }
     return null;
 }
开发者ID:hiceka,项目名称:cocos2d-x-for-xna,代码行数:12,代码来源:CCFadeOutUpTiles.cs


示例3: testFunc

        public override float testFunc(ccGridSize pos, float time)
        {
            CCPoint n = new CCPoint((float)(m_sGridSize.x * (1.0f - time)), (float)(m_sGridSize.y * (1.0f - time)));
            if ((pos.x + pos.y) == 0)
            {
                return 1.0f;
            }

            return (float)Math.Pow((n.x + n.y) / (pos.x + pos.y), 6);
        }
开发者ID:Ratel13,项目名称:cocos2d-x-for-xna,代码行数:10,代码来源:CCFadeOutBLTiles.cs


示例4: actionWithSize

        /// <summary>
        /// creates the action with size and duration
        /// </summary>
        public static CCGridAction actionWithSize(ccGridSize gridSize, float duration)
        {
            CCGridAction pAction = new CCGridAction();
            if (pAction.initWithSize(gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:cocos2d-for-xna-windows,代码行数:13,代码来源:CCGridAction.cs


示例5: testFunc

        public virtual float testFunc(ccGridSize pos, float time)
        {
            CCPoint n = new CCPoint((float)(m_sGridSize.x * time), (float)(m_sGridSize.y * time));
            if ((n.X + n.Y) == 0.0f)
            {
                return 1.0f;
            }

            return (float)Math.Pow((pos.x + pos.y) / (n.X + n.Y), 6);
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:10,代码来源:CCFadeOutTRTiles.cs


示例6: testFunc

        public virtual float testFunc(ccGridSize pos, float time)
        {
            CCPoint n = new CCPoint((float)(m_sGridSize.x * (1.0f - time)), (float)(m_sGridSize.y * (1.0f - time)));
            if (pos.y == 0)
            {
                return 1.0f;
            }

            return (float)Math.Pow(n.y / pos.y, 6);
        }
开发者ID:ChowZenki,项目名称:cocos2d-x-for-xna,代码行数:10,代码来源:CCFadeOutDownTiles.cs


示例7: testFunc

        public override float testFunc(ccGridSize pos, float time)
        {
            CCPoint n = new CCPoint((float)(m_sGridSize.x * time), (float)(m_sGridSize.y * time));
            if (n.y == 0.0f)
            {
                return 1.0f;
            }

            return (float)Math.Pow(pos.y / n.y, 6);
        }
开发者ID:hiceka,项目名称:cocos2d-x-for-xna,代码行数:10,代码来源:CCFadeOutUpTiles.cs


示例8: actionWithSize

        /// <summary>
        /// creates the action with the grid size and the duration
        /// </summary>
        public static new CCTurnOffTiles actionWithSize(ccGridSize size, float d)
        {
            CCTurnOffTiles pAction = new CCTurnOffTiles();
            if (pAction.initWithSize(size, d))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:13,代码来源:CCTurnOffTiles.cs


示例9: actionWithSeed

        /// <summary>
        /// creates the action with a random seed, the grid size and the duration 
        /// </summary>
        public static CCTurnOffTiles actionWithSeed(int s, ccGridSize gridSize, float duration)
        {
            CCTurnOffTiles pAction = new CCTurnOffTiles();
            if (pAction.initWithSeed(s, gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:13,代码来源:CCTurnOffTiles.cs


示例10: actionWithSize

        /// <summary>
        /// create the action
        /// </summary>
        public static CCPageTurn3D actionWithSize(ccGridSize gridSize, float time)
        {
            CCPageTurn3D pAction = new CCPageTurn3D();

            if (pAction.initWithSize(gridSize, time))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:14,代码来源:CCPageTurn3D.cs


示例11: actionWithRange

        /// <summary>
        /// creates the action with a range, shake Z vertices, a grid and duration
        /// </summary>
        public static CCShaky3D actionWithRange(int range, bool shakeZ, ccGridSize gridSize, float duration)
        {
            CCShaky3D pAction = new CCShaky3D();

            if (pAction.initWithRange(range, shakeZ, gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:14,代码来源:CCShaky3D.cs


示例12: gridWithSize

        public static CCGridBase gridWithSize(ccGridSize gridSize, Texture texture, bool flipped)
        {
            CCGridBase pGridBase = new CCGridBase();

            if (pGridBase.initWithSize(gridSize, texture, flipped))
            {
                return pGridBase;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:11,代码来源:CCGridBase.cs


示例13: gridWithSize

        public static new CCTiledGrid3D gridWithSize(ccGridSize gridSize, CCTexture2D pTexture, bool bFlipped)
        {
            CCTiledGrid3D pRet = new CCTiledGrid3D();

            if (pRet.initWithSize(gridSize, pTexture, bFlipped))
            {
                return pRet;
            }

            return null;
        }
开发者ID:hiceka,项目名称:cocos2d-x-for-xna,代码行数:11,代码来源:CCTiledGrid3D.cs


示例14: initWithSize

        /** initializes the action with size and duration */
        public virtual bool initWithSize(ccGridSize gridSize, float duration)
        {
            if (base.initWithDuration(duration))
            {
                m_sGridSize = gridSize;

                return true;
            }

            return false;
        }
开发者ID:ChowZenki,项目名称:cocos2d-x-for-xna,代码行数:12,代码来源:CCGridAction.cs


示例15: actionWithJumps

        public static CCJumpTiles3D actionWithJumps(int j, float amp, ccGridSize gridSize, float duration)
        {
            CCJumpTiles3D pAction = new CCJumpTiles3D();

            if (pAction.initWithJumps(j, amp, gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:11,代码来源:CCJumpTiles3D.cs


示例16: actionWithPosition

        /// <summary>
        /// creates the action with center position, radius, a grid size and duration
        /// </summary>
        public static CCLens3D actionWithPosition(CCPoint pos, float r, ccGridSize gridSize, float duration)
        {
            CCLens3D pAction = new CCLens3D();

            if (pAction.initWithPosition(pos, r, gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:14,代码来源:CCLens3D.cs


示例17: actionWithWaves

        /// <summary>
        /// creates the action with a number of waves, the waves amplitude, the grid size and the duration
        /// </summary>
        public static CCWavesTiles3D actionWithWaves(int wav, float amp, ccGridSize gridSize, float duration)
        {
            CCWavesTiles3D pAction = new CCWavesTiles3D();

            if (pAction.initWithWaves(wav, amp, gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:14,代码来源:CCWavesTiles3D.cs


示例18: actionWithRange

        /// <summary>
        /// creates the action with a range, whether of not to shatter Z vertices, a grid size and duration
        /// </summary>
        public static CCShatteredTiles3D actionWithRange(int nRange, bool bShatterZ, ccGridSize gridSize, float duration)
        {
            CCShatteredTiles3D pAction = new CCShatteredTiles3D();

            if (pAction.initWithRange(nRange, bShatterZ, gridSize, duration))
            {
                return pAction;
            }

            return null;
        }
开发者ID:liwq-net,项目名称:cocos2d-for-xna-windows,代码行数:14,代码来源:CCShatteredTiles3D.cs


示例19: transformTile

        public override void transformTile(ccGridSize pos, float distance)
        {
            ccQuad3 coords = originalTile(pos);
            CCPoint step = m_pTarget.Grid.Step;

            coords.bl.y += (step.y / 2) * (1.0f - distance);
            coords.br.y += (step.y / 2) * (1.0f - distance);
            coords.tl.y -= (step.y / 2) * (1.0f - distance);
            coords.tr.y -= (step.y / 2) * (1.0f - distance);

            setTile(pos, coords);
        }
开发者ID:hiceka,项目名称:cocos2d-x-for-xna,代码行数:12,代码来源:CCFadeOutUpTiles.cs


示例20: initWithSize

        public virtual bool initWithSize(ccGridSize gridSize, float duration)
        {
            if (gridSize.x != 1 || gridSize.y != 1)
            {
                // Grid size must be (1,1)
                Debug.Assert(false);

                return false;
            }

            return base.initWithSize(gridSize, duration);
        }
开发者ID:liwq-net,项目名称:liwq718,代码行数:12,代码来源:CCFlipX3D.cs



注:本文中的cocos2d.ccGridSize类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Exception.BusinessException类代码示例发布时间:2022-05-26
下一篇:
C# cocos2d.CCZone类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap