<small id='LmPWS'></small><noframes id='LmPWS'>

      <tfoot id='LmPWS'></tfoot>
      <i id='LmPWS'><tr id='LmPWS'><dt id='LmPWS'><q id='LmPWS'><span id='LmPWS'><b id='LmPWS'><form id='LmPWS'><ins id='LmPWS'></ins><ul id='LmPWS'></ul><sub id='LmPWS'></sub></form><legend id='LmPWS'></legend><bdo id='LmPWS'><pre id='LmPWS'><center id='LmPWS'></center></pre></bdo></b><th id='LmPWS'></th></span></q></dt></tr></i><div id='LmPWS'><tfoot id='LmPWS'></tfoot><dl id='LmPWS'><fieldset id='LmPWS'></fieldset></dl></div>
      <legend id='LmPWS'><style id='LmPWS'><dir id='LmPWS'><q id='LmPWS'></q></dir></style></legend>
      • <bdo id='LmPWS'></bdo><ul id='LmPWS'></ul>

      如何在 UIView 上添加 CCSprite

      时间:2024-08-12
    1. <legend id='Nirt9'><style id='Nirt9'><dir id='Nirt9'><q id='Nirt9'></q></dir></style></legend>

        <bdo id='Nirt9'></bdo><ul id='Nirt9'></ul>

      • <tfoot id='Nirt9'></tfoot>
          <tbody id='Nirt9'></tbody>
        <i id='Nirt9'><tr id='Nirt9'><dt id='Nirt9'><q id='Nirt9'><span id='Nirt9'><b id='Nirt9'><form id='Nirt9'><ins id='Nirt9'></ins><ul id='Nirt9'></ul><sub id='Nirt9'></sub></form><legend id='Nirt9'></legend><bdo id='Nirt9'><pre id='Nirt9'><center id='Nirt9'></center></pre></bdo></b><th id='Nirt9'></th></span></q></dt></tr></i><div id='Nirt9'><tfoot id='Nirt9'></tfoot><dl id='Nirt9'><fieldset id='Nirt9'></fieldset></dl></div>

              <small id='Nirt9'></small><noframes id='Nirt9'>

              • 本文介绍了如何在 UIView 上添加 CCSprite的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                In my cocos2d application, I have a UIView that I am displaying on my screen by adding a subview to [[CCDirector sharedDirector] openGLView], but I am wondering if there is someway to display a CCSprite above this view, since I have to do lots of interactions and animations with those CCObjects.

                Please help. Thanks in advance...

                解决方案

                Of course you can't add CCSprite on UIView. CCSprite is from Cocos2d library class and UIView is UIKit class. If you want add UIView over game view then you need to access rootviewcontroller view which is root of UIWindow. Its something like this,

                [appDelegate.yourRootViewController.view addSubview:yourview];
                

                Always keep remember Cocos2d library control are part of GLView.

                这篇关于如何在 UIView 上添加 CCSprite的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                上一篇:如何从 Objective-C 中的方法返回 C 数组? 下一篇:了解 applicationSignificantTimeChange:

                相关文章

                1. <tfoot id='n6uf6'></tfoot>
                2. <small id='n6uf6'></small><noframes id='n6uf6'>

                      <bdo id='n6uf6'></bdo><ul id='n6uf6'></ul>

                    <legend id='n6uf6'><style id='n6uf6'><dir id='n6uf6'><q id='n6uf6'></q></dir></style></legend>

                    <i id='n6uf6'><tr id='n6uf6'><dt id='n6uf6'><q id='n6uf6'><span id='n6uf6'><b id='n6uf6'><form id='n6uf6'><ins id='n6uf6'></ins><ul id='n6uf6'></ul><sub id='n6uf6'></sub></form><legend id='n6uf6'></legend><bdo id='n6uf6'><pre id='n6uf6'><center id='n6uf6'></center></pre></bdo></b><th id='n6uf6'></th></span></q></dt></tr></i><div id='n6uf6'><tfoot id='n6uf6'></tfoot><dl id='n6uf6'><fieldset id='n6uf6'></fieldset></dl></div>