SlideShare uma empresa Scribd logo
1 de 45
Baixar para ler offline
cocos2d
    Kobold2D
@Seasons
cocos2d AUTHOR



Blog Seasons.NET
•cocos2d
•

@cocos2dfan_jp
•cocos2d
iOS




      2011 9,10
      IMPACT      !!
Kobold2D



    •   cocos2d
    •   MIT
    •   2D
    •
    •
    •
    •
    •   http://www.kobold2d.com
Kobold2D


             •   cocos3d(3D)
             •   wax(Lua,         )
             •   iAd(      )
             •   iSimulator(                  )
             •   SneakyInput(                         )
             •   cocos2d extensions(              )

Built in!!   •   Chipmunk(                )
             •   Box2D (              )
             •   ObjectAL(                        )
             •   CocosDension(                            )
Kobold2D

                cocos2d
                                !!

           1.
           2.
           3.


                              om e! !
                      Aw es
Kobold2D



           @gaminghorror

     cocos2d




               cocos2d     !!
cocos2d → Kobold2D
Users Guide
Kobold2D



    •   Xcode 4.0
    •   iOS 4.3
    •   Mac OS X Snow Leopard(10.6)
    •   500MB



    • Xcode 4.1 or
    • Mac OS X Lion(10.7)
    • Objective-C
Kobold2D



• Kobold2D
• Kobold2D.pkg
•                !!
•      =    :)
Kobold2D




               ~/Kobold2D/

           ※
Kobold2D



• Kobold2D Project Starter.app
•
• [   ]
 ➡ Add to Workspace
 ➡
• New Project Name
  ※Xcode



      Create Project
           Xcode                 !!
Kobold2D




※__Kobold2D__   Kobold2D



 Kobold2D
                           __Kobold2D__
Kobold2D



※Kobold2D            (Workspace)
• Kobold2D-X.Y
•
 ➡



※Kobold2D          (Project)
• Kobold2D
• Kobold2D       Xcode 4.0,
• Xcode Scheme
Kobold2D




※




           !!
Kobold2D

※Kobold2D
•
•                                          Xcode
    ➡                   Xcode         !!


※Kobold2D
•                      Kobold2D API
    ➡
    ➡ API                  Kobold2D


    Xcode4
Xcode                                              Kobold2D
             (         )
    2            ...
cocos2d




          How to migrate???
cocos2d




※cocos2d
1.         cocos2d
     ➡               Kobold2D


2.
     ➡
     ➡                     Kobold2D


3.
     ➡ Kobold2D
cocos2d




       Hello-Kobold2d template
    _Particle_Effects_template_
cocos2d

1. Kobold2D project

•
    HelloWorld.h/m , Pow.caf , ship.png
    ➡

         config.lua                        !!
cocos2d

2.

•
    ➡ Xcode   Add Files to                          Destination
                     iOS , Mac

                             !!

     •GameConfig.h
     •(ProjectName)AppDelegate.*
     •RootViewController.*
     •main.m
     •(ProjectName)_Prefix.h
     •                     (cocos2d,box2d,etc...)
cocos2d

3.

•
                                    !!


     •Info.plist
     •Default.png , Icon.png( @2x        )




                       Finder
          Info.plist       /
cocos2d

3.                (Info.plist)



       Kobold2D                  2   Info.plist
                            iOS , Mac
cocos2d

4. config.lua

• config.lua


    •FirstSceneClassName
      ➡
    •EnableUserInteraction,EnableMultiTouch
      ➡
    •DefaultTexturePixelFormat
      ➡
    •GLViewColorFormat
      ➡OpenGL
    •GLViewDepthFormat
      ➡OpenGL
cocos2d


•GLViewPreserveBackBuffer
 ➡OpenGL
•GLViewMultiSampling
 ➡OpenGL
•GLViewNumberOfSamples
 ➡
 [     ]YES



•Enable2DProjection
 ➡3D          (   )

•EnableRetinaDisplaySupport
 ➡RetinaDisplay        (      )

•DeviceOrientaion
 ➡
cocos2d



•AutorotationType
 ➡
•ShouldAutorotateToLandscapeOrientation
 ➡UIViewController
•ShouldAutorotateToPortraitOrientation
 ➡UIViewController
•AllowAutorotateOnFirstAndSecondGenerationDevices
 ➡ 1,2                             NO     AutorotationType


 [    ] 1,2
cocos2d

iAd

•EnableAdBanner
  ➡iAd            (   iAd   )

•LoadOnlyPortraitBanners
  ➡
•LoadOnlyLandscapeBanners
  ➡
•PlaceBannerOnBottom
  ➡
cocos2d

Mac OS X

•AutoScale
 ➡
•AcceptsMouseMovedEvents
 ➡
•WindowFrame
 ➡
cocos2d


※config.lua
1. FirstSceneClassName
  ➡

2. config.lua
  ➡ Kobold2D
                               cocos2d AppDelegate.m
      GameConfig.h



       config.lua         Kobold2D


                                           ...
 config.lua                !!
cocos2d


※config.lua
• config.lua




  KKStartupSettings Property name:
  gLViewColorFormat
  enableMultiTouch
  deviceOrientation

  config.lua Parameter name:
  GLViewColorFormat                  3
  EnableMultiTouch
  DeviceOrientation
cocos2d

5.

     Kobold2D      config.lua FirstSceneClass
                                 cocos2d       +(id)
     scene
                   +(id) scene




        Kobold2D       3
cocos2d

     1 scene -> node
+ (id) scene -> + (id) node
( interface , implementation   )
cocos2d

     2 + (id) scene    init

+ (id) scene           init

scene
                init


self addChild                 [self.parent
addChild:myLayer]
cocos2d

       3 - (void) initializationComplete

cocos2d
                     initializationComplete
runWithScene

1,2
      cocos2d                                 AppDelegate
initializationComplete          CCDirector runWithScene



- (void) initializationComplete {
  [[CCDirector sharedDirector] runWithScene:[MyFirstScene scene]];
}
cocos2d

6. AppDelegate,RootViewController


                 AppDelegate RootViewController
      Kobold2D

                                                  super


 Kobold2D                  AppDelegate RootViewController
    config.lua
cocos2d

7.

                                             ”            ”
                                  Kobold2D
                      (                           ^^; )


 • Info.plist
     ➡     /


 • Default.png , Icon.png
     ➡ Finder      Kobold2D           Resources
                          Xcode
cocos2d

8.




 • cocos2d
     ➡ Kobold2D

 •
     ➡
         Kobold2D
Kobold2D         Error Warning

Warning                    !!

Kobold2D


              100%

      Xcode            ”
               ”                Kobold2D
Kobold2D   iOS , Mac




1.
2.
3.
cocos2d → Kobold2D


Kobold2D             (
One more thing...
Kobold2D.com
(Japanese side)   !!
Kobold2D.com
.....
http://www.kobold2d.com/display/KKDOC/Kobold2D+User%27s+Guide
Enjoy Kobold2D!!

Mais conteúdo relacionado

Mais de Keisuke Hata

CCSendMessages introduction
CCSendMessages introductionCCSendMessages introduction
CCSendMessages introductionKeisuke Hata
 
Cocos2d Performance Tips
Cocos2d Performance TipsCocos2d Performance Tips
Cocos2d Performance TipsKeisuke Hata
 
CCResourceAsyncLoader
CCResourceAsyncLoaderCCResourceAsyncLoader
CCResourceAsyncLoaderKeisuke Hata
 
Impact beginngers guide_1.19
Impact beginngers guide_1.19Impact beginngers guide_1.19
Impact beginngers guide_1.19Keisuke Hata
 
Introduction titanium
Introduction titaniumIntroduction titanium
Introduction titaniumKeisuke Hata
 
How To Build Last Fm For I Phone
How To Build Last Fm For I PhoneHow To Build Last Fm For I Phone
How To Build Last Fm For I PhoneKeisuke Hata
 
Mercurial&OnenoteServer
Mercurial&OnenoteServerMercurial&OnenoteServer
Mercurial&OnenoteServerKeisuke Hata
 
Are You Enjoy Ruby 1 Day
Are You Enjoy Ruby 1 DayAre You Enjoy Ruby 1 Day
Are You Enjoy Ruby 1 DayKeisuke Hata
 

Mais de Keisuke Hata (16)

CCSendMessages introduction
CCSendMessages introductionCCSendMessages introduction
CCSendMessages introduction
 
Cocos2d Performance Tips
Cocos2d Performance TipsCocos2d Performance Tips
Cocos2d Performance Tips
 
CCResourceAsyncLoader
CCResourceAsyncLoaderCCResourceAsyncLoader
CCResourceAsyncLoader
 
Impact beginngers guide_1.19
Impact beginngers guide_1.19Impact beginngers guide_1.19
Impact beginngers guide_1.19
 
Advanced cocos2d
Advanced cocos2dAdvanced cocos2d
Advanced cocos2d
 
Introduction titanium
Introduction titaniumIntroduction titanium
Introduction titanium
 
Hello cocos2d ios
Hello cocos2d iosHello cocos2d ios
Hello cocos2d ios
 
Hello cocos2d ios
Hello cocos2d iosHello cocos2d ios
Hello cocos2d ios
 
Google wave2010
Google wave2010Google wave2010
Google wave2010
 
How To Build Last Fm For I Phone
How To Build Last Fm For I PhoneHow To Build Last Fm For I Phone
How To Build Last Fm For I Phone
 
Mercurial&OnenoteServer
Mercurial&OnenoteServerMercurial&OnenoteServer
Mercurial&OnenoteServer
 
Math1 Vector
Math1 VectorMath1 Vector
Math1 Vector
 
Wiipen
WiipenWiipen
Wiipen
 
Gl Rotate
Gl RotateGl Rotate
Gl Rotate
 
Gl Matrix
Gl MatrixGl Matrix
Gl Matrix
 
Are You Enjoy Ruby 1 Day
Are You Enjoy Ruby 1 DayAre You Enjoy Ruby 1 Day
Are You Enjoy Ruby 1 Day
 

Último

Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfOverkill Security
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 

Último (20)

Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 

Kobold2d users_guide_japanese