SlideShare una empresa de Scribd logo
1 de 16
Academy 102

Gideros Studio: Installation and your
              first code


           GIDEROS MOBILE ACADEMY SERIES
Agenda


• Downloading Gideros Studio

• Installing the prerequisites

• Installing Gideros Studio

• Running Gideros Studio

• Your first code!
Gideros Studio requirements


• You can use Gideros Studio standalone, without installing other 3rd
  party applications for building your application.
    – This way you can
        • Evaluate the software
        • Run your application under Gideros Player, and
        • See how it'll feel like.
    – However it may not be possible to test some of the features that
      come with device, e.g gyro, compass, etc.
• Therefore, in order to build for iOS and Android, you’ll need some
  libraries and IDE’s, such as
    – Java
    – Eclipse and Xcode
iPhone / iPad device build requirements


• To build for iPhone/iPad real device, you'll need the following:

    • 64 bit Mac OS X Snow Leopard or Mac OS X Lion (for compiling
      and signing)

    • Xcode

    • Apple Developer License




    These are not required to build for Android
Android device build requirements


• To build for Android real device, you'll need the following:

    • Java SDK

    • Eclipse IDE

    • Android SDK 2.1 or higher

    • Android Development Tools (ADT)

    • (Later) Google Developer License – for sending apps to Android
      markets.



    These are not required to build for iOS (iPhone or iPad)
Installing Java JDK


• Java is required if you want to modify, enhance and build your
  application using Eclipse IDE. To install Java JDK, follow these steps.

    • Go to
      http://www.oracle.com/technetwork/java/javase/downloads/index.html

    • Click on Java 6 JDK

    • Choose your platform

    • Install Java JDK on your system



    This step not required to build for iOS (iPhone or iPad)
Installing Eclipse


• Eclipse is required to build APK files for Android. If you are not going
  to build for this platform, then you may skip this step. To install
  Eclipse, do the following:
    • Go to http://eclipse.org/downloads/
    • Choose your operating system
    • Choose either 32 or 64 bit, depending on your operating
      system, and download "Eclipse IDE for Java Developers".
    • Extract the zip file to a folder
    • Eclipse is now ready to run.

    This step not required to build for iOS (iPhone or iPad)
Installing Android SDK 2.1


• Gideros Studio uses Android SDK 2.1 or higher, therefore Android
  applications built with Gideros Studio runs on devices running
  Android 2.1.
    • Go to http://developer.android.com/sdk/index.html

    • Download and install the package for the platform of your choice.

    • Run tools/android (Android SDK and AVD Manager)

    • Click on Available Packages

    • Install SDK Platform Android 2.1, API 7, revision 3


    This step not required to build for iOS (iPhone or iPad)
Installing Android Development Tools for Eclipse



• ADT extends Eclipse to let you quickly modify your
  application, which is exported from Gideros Studio.

• Using the Android SDK tools, you can export signed (or unsigned)
  .apk files in order to distribute your application.

• Since Gideros Studio can export Java source code, you can modify
  exported Java code before building the final APK (Android package)

• Install ADT plugin for Eclipse using the installation steps defined
  here: http://developer.android.com/sdk/eclipse-adt.html


    This step not required to build for iOS (iPhone or iPad)
Downloading Gideros Studio



• Downloading and installing Gideros Studio is free.

• You are also encouraged to try beta builds, but make sure that beta
  software may contain some bugs.

• System requirements:

    • 1 Ghz processor

    • 1 Gb RAM

    • 250 Mb disk space for MS Windows

    • 340 Mb disk space for Mac OS X
Installing Gideros Studio



• For MS Windows:

   • Double click on the executable you downloaded and follow
     these steps:

   • Choose destination folder

   • Click install

• For Mac OS X:

   • Double-click the .dmg file to mount it

   • Drag & drop Gideros folder into your Applications directory
Your first code, hello ball



• Open Gideros Studio and create a new project from "File → New
  Project" menu. Name your project “HelloBall”

• Right click the project name at Project tab and select "Add New
  File…" Name your file "main.lua" and click OK (this is your main file)

• Double-click main.lua and write print("Hello Ball") in IDE.

• Press start button (or select "Player → Start" from main menu) to
  run the project.

• You’ll see the output of your project at the "Output" panel.
A more complex example


   • Copy the code below and paste it into main.lua
local background =                                  if x < 0 then
Bitmap.new(Texture.new("field.png"))                     fruit.xdirection = 1
stage:addChild(background)                            end

                                                      if x > 320 - fruit:getWidth() then
local fruit = Bitmap.new(Texture.new("ball.png"))        fruit.xdirection = -1
                                                      end
fruit.xdirection = 1
fruit.ydirection = 1                                  if y < 0 then
                                                         fruit.ydirection = 1
fruit.xspeed = 2.5
                                                      end
fruit.yspeed = 4.3
                                                      if y > 480 - fruit:getHeight() then
stage:addChild(fruit)                                    fruit.ydirection = -1
                                                      end
function onEnterFrame(event)
                                                      fruit:setX(x)
  local x = fruit:getX()                              fruit:setY(y)
  local y = fruit:getY()                            end

  x = x + (fruit.xspeed * fruit.xdirection)         stage:addEventListener(Event.ENTER_FRAME, onEnterFra
                                                    me)
  y = y + (fruit.yspeed * fruit.ydirection)
Adding images to asset library



• Now let’s add some images to our asset library

• Download field.png and ball.png (URL below) and copy these
  images to your project directory.

• Right click the project name and select "Add Existing Files…" to add
  your image files to the project

                    Field.png: http://giderosmobile.com/documentation/assets/field.png




                    Ball.png: http://giderosmobile.com/documentation/assets/ball.png
Running in Gideros Player



• Now select "Player → Start Local Player” to start Gideros Player.
    • It shows the IP address of your PC and the player.

    • After player opens, start and stop icons become enabled on the toolbar.

    • This means Gideros Studio is now connected to Gideros Player and ready to
      upload your code and assets and then run the project.

• Press start button (or select "Player → Start" from main menu) to
  run the project.

• Balls will be bouncing back and forth in the Player
GIDEROS MOBILE ACADEMY SERIES




info@giderosmobile.com

Más contenido relacionado

Similar a Installation and your first code

Android Development Primer - GDG Los Angeles
Android Development Primer - GDG Los AngelesAndroid Development Primer - GDG Los Angeles
Android Development Primer - GDG Los AngelesGerard
 
Build Your First Android App Session #1
Build Your First Android App Session #1Build Your First Android App Session #1
Build Your First Android App Session #1Troy Miles
 
Building Android games using LibGDX
Building Android games using LibGDXBuilding Android games using LibGDX
Building Android games using LibGDXJussi Pohjolainen
 
Intro to Building Android Games using libGDX
Intro to Building Android Games using libGDXIntro to Building Android Games using libGDX
Intro to Building Android Games using libGDXJussi Pohjolainen
 
01 04 - android set up and creating an android project
01  04 - android set up and creating an android project01  04 - android set up and creating an android project
01 04 - android set up and creating an android projectSiva Kumar reddy Vasipally
 
Ayw android env_setup
Ayw android env_setupAyw android env_setup
Ayw android env_setuppbeerak
 
Android Application Development Environment Setup
Android Application Development Environment SetupAndroid Application Development Environment Setup
Android Application Development Environment SetupIan Pinto
 
Android build on windows
Android build on windowsAndroid build on windows
Android build on windowsAddweup
 
Mobile application and Game development
Mobile application and Game developmentMobile application and Game development
Mobile application and Game developmentWomen In Digital
 
Android Wear from zero to hero
Android Wear from zero to heroAndroid Wear from zero to hero
Android Wear from zero to heroRoberto Orgiu
 
Android OS & SDK - Getting Started
Android OS & SDK - Getting StartedAndroid OS & SDK - Getting Started
Android OS & SDK - Getting StartedHemant Chhapoliya
 
Android studio
Android studioAndroid studio
Android studioAndri Yabu
 

Similar a Installation and your first code (20)

Android Development Primer - GDG Los Angeles
Android Development Primer - GDG Los AngelesAndroid Development Primer - GDG Los Angeles
Android Development Primer - GDG Los Angeles
 
Build Your First Android App Session #1
Build Your First Android App Session #1Build Your First Android App Session #1
Build Your First Android App Session #1
 
ANDROID PPT 1.pdf
ANDROID PPT 1.pdfANDROID PPT 1.pdf
ANDROID PPT 1.pdf
 
AndEngine
AndEngineAndEngine
AndEngine
 
Building Android games using LibGDX
Building Android games using LibGDXBuilding Android games using LibGDX
Building Android games using LibGDX
 
Intro to Building Android Games using libGDX
Intro to Building Android Games using libGDXIntro to Building Android Games using libGDX
Intro to Building Android Games using libGDX
 
Android app upload
Android app uploadAndroid app upload
Android app upload
 
01 04 - android set up and creating an android project
01  04 - android set up and creating an android project01  04 - android set up and creating an android project
01 04 - android set up and creating an android project
 
Ayw android env_setup
Ayw android env_setupAyw android env_setup
Ayw android env_setup
 
Android Application Development Environment Setup
Android Application Development Environment SetupAndroid Application Development Environment Setup
Android Application Development Environment Setup
 
Android build on windows
Android build on windowsAndroid build on windows
Android build on windows
 
Mobile application and Game development
Mobile application and Game developmentMobile application and Game development
Mobile application and Game development
 
Android Wear from zero to hero
Android Wear from zero to heroAndroid Wear from zero to hero
Android Wear from zero to hero
 
Android
AndroidAndroid
Android
 
Android_PDF
Android_PDFAndroid_PDF
Android_PDF
 
Android OS & SDK - Getting Started
Android OS & SDK - Getting StartedAndroid OS & SDK - Getting Started
Android OS & SDK - Getting Started
 
Intro to appcelerator
Intro to appceleratorIntro to appcelerator
Intro to appcelerator
 
Android SDK: How to Install
Android SDK: How to InstallAndroid SDK: How to Install
Android SDK: How to Install
 
Android studio
Android studioAndroid studio
Android studio
 
React nativebeginner1
React nativebeginner1React nativebeginner1
React nativebeginner1
 

Último

Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 

Último (20)

Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 

Installation and your first code

  • 1. Academy 102 Gideros Studio: Installation and your first code GIDEROS MOBILE ACADEMY SERIES
  • 2. Agenda • Downloading Gideros Studio • Installing the prerequisites • Installing Gideros Studio • Running Gideros Studio • Your first code!
  • 3. Gideros Studio requirements • You can use Gideros Studio standalone, without installing other 3rd party applications for building your application. – This way you can • Evaluate the software • Run your application under Gideros Player, and • See how it'll feel like. – However it may not be possible to test some of the features that come with device, e.g gyro, compass, etc. • Therefore, in order to build for iOS and Android, you’ll need some libraries and IDE’s, such as – Java – Eclipse and Xcode
  • 4. iPhone / iPad device build requirements • To build for iPhone/iPad real device, you'll need the following: • 64 bit Mac OS X Snow Leopard or Mac OS X Lion (for compiling and signing) • Xcode • Apple Developer License These are not required to build for Android
  • 5. Android device build requirements • To build for Android real device, you'll need the following: • Java SDK • Eclipse IDE • Android SDK 2.1 or higher • Android Development Tools (ADT) • (Later) Google Developer License – for sending apps to Android markets. These are not required to build for iOS (iPhone or iPad)
  • 6. Installing Java JDK • Java is required if you want to modify, enhance and build your application using Eclipse IDE. To install Java JDK, follow these steps. • Go to http://www.oracle.com/technetwork/java/javase/downloads/index.html • Click on Java 6 JDK • Choose your platform • Install Java JDK on your system This step not required to build for iOS (iPhone or iPad)
  • 7. Installing Eclipse • Eclipse is required to build APK files for Android. If you are not going to build for this platform, then you may skip this step. To install Eclipse, do the following: • Go to http://eclipse.org/downloads/ • Choose your operating system • Choose either 32 or 64 bit, depending on your operating system, and download "Eclipse IDE for Java Developers". • Extract the zip file to a folder • Eclipse is now ready to run. This step not required to build for iOS (iPhone or iPad)
  • 8. Installing Android SDK 2.1 • Gideros Studio uses Android SDK 2.1 or higher, therefore Android applications built with Gideros Studio runs on devices running Android 2.1. • Go to http://developer.android.com/sdk/index.html • Download and install the package for the platform of your choice. • Run tools/android (Android SDK and AVD Manager) • Click on Available Packages • Install SDK Platform Android 2.1, API 7, revision 3 This step not required to build for iOS (iPhone or iPad)
  • 9. Installing Android Development Tools for Eclipse • ADT extends Eclipse to let you quickly modify your application, which is exported from Gideros Studio. • Using the Android SDK tools, you can export signed (or unsigned) .apk files in order to distribute your application. • Since Gideros Studio can export Java source code, you can modify exported Java code before building the final APK (Android package) • Install ADT plugin for Eclipse using the installation steps defined here: http://developer.android.com/sdk/eclipse-adt.html This step not required to build for iOS (iPhone or iPad)
  • 10. Downloading Gideros Studio • Downloading and installing Gideros Studio is free. • You are also encouraged to try beta builds, but make sure that beta software may contain some bugs. • System requirements: • 1 Ghz processor • 1 Gb RAM • 250 Mb disk space for MS Windows • 340 Mb disk space for Mac OS X
  • 11. Installing Gideros Studio • For MS Windows: • Double click on the executable you downloaded and follow these steps: • Choose destination folder • Click install • For Mac OS X: • Double-click the .dmg file to mount it • Drag & drop Gideros folder into your Applications directory
  • 12. Your first code, hello ball • Open Gideros Studio and create a new project from "File → New Project" menu. Name your project “HelloBall” • Right click the project name at Project tab and select "Add New File…" Name your file "main.lua" and click OK (this is your main file) • Double-click main.lua and write print("Hello Ball") in IDE. • Press start button (or select "Player → Start" from main menu) to run the project. • You’ll see the output of your project at the "Output" panel.
  • 13. A more complex example • Copy the code below and paste it into main.lua local background = if x < 0 then Bitmap.new(Texture.new("field.png")) fruit.xdirection = 1 stage:addChild(background) end if x > 320 - fruit:getWidth() then local fruit = Bitmap.new(Texture.new("ball.png")) fruit.xdirection = -1 end fruit.xdirection = 1 fruit.ydirection = 1 if y < 0 then fruit.ydirection = 1 fruit.xspeed = 2.5 end fruit.yspeed = 4.3 if y > 480 - fruit:getHeight() then stage:addChild(fruit) fruit.ydirection = -1 end function onEnterFrame(event) fruit:setX(x) local x = fruit:getX() fruit:setY(y) local y = fruit:getY() end x = x + (fruit.xspeed * fruit.xdirection) stage:addEventListener(Event.ENTER_FRAME, onEnterFra me) y = y + (fruit.yspeed * fruit.ydirection)
  • 14. Adding images to asset library • Now let’s add some images to our asset library • Download field.png and ball.png (URL below) and copy these images to your project directory. • Right click the project name and select "Add Existing Files…" to add your image files to the project Field.png: http://giderosmobile.com/documentation/assets/field.png Ball.png: http://giderosmobile.com/documentation/assets/ball.png
  • 15. Running in Gideros Player • Now select "Player → Start Local Player” to start Gideros Player. • It shows the IP address of your PC and the player. • After player opens, start and stop icons become enabled on the toolbar. • This means Gideros Studio is now connected to Gideros Player and ready to upload your code and assets and then run the project. • Press start button (or select "Player → Start" from main menu) to run the project. • Balls will be bouncing back and forth in the Player
  • 16. GIDEROS MOBILE ACADEMY SERIES info@giderosmobile.com

Notas del editor

  1. Hello and welcome to Gideros Mobile Academy. Gideros Studio is a multiplatform mobile development environment, which allows develop your mobile application easily and faster. It includes an integrated development environment and an Software Development Kit, together with several examples and tutorials. This video is the second part of Gideros Mobile Academy series, and we’ll talk about installing Gideros Studio, together with requirements and how to install these requirements.
  2. This slide gives an agenda of this tutorial. In this presentation, we’ll talk about downloading and installing Gideros Studio and required libraries such as Eclipse, Xcode and Java.