SlideShare a Scribd company logo
Going Mobile with
AIR + Starling
Lessons from Real World projects

Presented by Amos Laber
About Me

Amos Laber
Game Developer, Coder, Architect

Background in C++, Console games, 3D
Engines.
Later: Flex, AS3, Casual and 2D Games.

Blog:
www.flexwiz.net
Content and Scope

The state of AIR as a mobile ecosystem (2013)

Practical use of Starling, Feathers and ANE

Tips, Common Problems and Practices
Demo
AIR vs. Native
Trivial: Need iOS and Anrdoid at the same time
AIR = Shorter timelines (Rapid development)

Leverage existing knowledge and code - Faster to
implement

Personal preference: AS3 over Java or Obj-C
Captive Runtime: App is same as native
The AIR Ecosystem
AIR 3.5 (FP 11.5) made a big shift from enterprise
into mobile (without Flex).
A new generation of AS3 frameworks has reached
maturity
Adobe Gaming SDK: Starling, Feathers,
Away3D
Also Flare3D, Citrus, Nape, DragonBones
New Tools: ASC2, Scout, FlashBuilder 4.7
Production Goals
Get stuff done fast.
But no cutting corners!
Spend time on the game (creative),
not on boilerplate code.

UI Elements tend to be the #1 time consuming
- try to minimize and simplify them.
Choosing Tools
Code and Art Toolchain

Glyph Designer
Choosing Libraries
Frameworks

Libraries
Gestouch
Extensions (ANEs)
Services:

Game Center

In App Payments:
Game Framework
Do we need one?
Game Framework (or Engine) will provide
features and classes that are commonly used in
games / apps.
It takes time to learn how to efficiently use one
and it creates another dependency

I decided to roll my own.
The Parallel Universe

Starling forms a parallel universe where
flash display list is completely hardware
accelerated.
Migrating to Starling
Starling vs. 'classic' Flash
Rendering: CPU
flash.display.*
Vector fonts

|Flash|
|||

Rendering: GPU (H. Accel OpenGL)
starling.display.*

|Starling (Stage3D)| fonts
Bitmap

Vector Shapes

N/A (* Quad only)

Bitmap / BitmapData

Image / Texture

Sprite and DisplayObject

Same

flash.events

starling.events (faster)
Starling Basics
Compose the display list the same way as in flash.

Layering Sprites, images and
buttons

Compose your views/ screens

Alpha blending and hierarchy
works the same way as in Flash.
Starling App Setup
Load all assets (mostly bitmaps) on initialize.

Nearly all display objects are images
Best is to pack them up into sprite sheets

Determine screen size with stage_resize event. Use
it across the app for layouts.
Sprite Sheets
UI Setup - Feathers
Decide when to use custom UI, case by case
Prepare a bitmap font and skin elements
(Bitmap font text field is provided)

Works best with a theme
Integrating ANEs
Drop into project and update the manifest /permissions
Watch out for default mode - should not throw errors.
Well documented and supported ANE are a better choice.
Don't waste time on building them - too many dependencies (iOS
and Android ver, SDK compatibility)
Testing is only done on the device. They're native.

Recommended: MilkMan and FreshPlanet
Example:
List and Item Renderer

import feathers.controls.List;

var list:List = new List();
list.itemRendererType= PetItemRenderer;
list.dataProvider = petList;

list.layout = new TiledColumnsLayout();
list.scrollerProperties.scrollBarDisplayMode = SCROLL_BAR_DISPLAY_MODE_FIXED;
Example:
The Item Renderer
class ItemVO {
name:String; image:Texture; locked:Boolean;
}

protected override function draw():void
{
var dataInvalid:Boolean = this.isInvalid(INVALIDATION_FLAG_DATA);
if (dataInvalid) {
|updateImage(data.image);|

|label.text = data.name;|

|label.visible = !data.locked;|

|image.blendMode = data.locked? BlendMode.ERASE :|
Composing Tips
Alpha and PNG w/Alpha works best - don't bake it

Use Tile Patterns with TiledImage.
Stretch elements with Slice9Image /Slice3Image.

Use scrollRect for simple masking and smooth
scrolling
Example:

Scroll and Mask

Castle gate was masked with scrollRect,
animated by tweening scrollRect.y

+

+
Common issues to
watch for
Touch
AIR SDK own touch handling is not very useful
3rd party libraries can fill in the gap
Gestouch is my recommended library:
Multitouch gestures for Starling or classic flash
http://github.com/fljot/Gestouch
Textures

Things to know

GPU memory on devices is limited.
iPhone 3GS has 24 MB

Standalone textures are rounded up to power of 2 size (e.g.
1024x1024 pixels).

Once created, the texture is uploaded to GPU.
When maxed out, the OS will close the app without
warning, exception or stack trace.
Textures

Best Preactices

Create the textures on demand - not when the Assets are
loaded.
Make sure to release with texture.dispose() when
removed from stage.
Pack everything to sprite sheets! We use TexturePacker

Have a central asset manager to hold textures
Textures

Sample Code

private var _textures:Dictionary;
..
public function getTexture(name:String):Texture
{
|if (_textures[name] == undefined)

{|

|

var data:Object = _loadedAssets[name];|

|

if (data is Bitmap)|

|_textures[name] = |
Texture.fromBitmap(data as Bitmap, false, false);
|}|
return _textures[name];
}

public function disposeTexture(name:String):void
{
if (_textures[name]) {
Texture(_textures[name]).dispose();
|textures[name] = |
null
|;|
Screen Size and Layout
Avoid hardcoded pixel sizes. Use relative align or
percentage
iPad Retina support No need to duplicate the assets (x1, x2, x4...)
Selective scale
Test layout in different screen sizes on simulator
and Something
extra
Deployment
Main Markets
Discoverability, Promotion

Apple App Store
Promote you App
For Zero Cost

Create a Facebook fan page.
Create a Twitter account and tweet frequently.
Make a YouTube video with actual gameplay footage.
Prepare a press kit with screenshots and marketting blurb
and send it for review to selected web sites.
Tracking Data
Weekly Downloads
iOS
Android

Chart was not exported from SlideRocket
Takedown
Is Starling Right for you?

AIR proved a viable solution for mobile

Starling is now a Solid and Mature framework

Developers can get stuff done faster
Resources
Starling Wiki:
wiki.starling-framework.org/

Starling Forum:
forum.starling-framework.org/

gotoAndLearn:

My Blog:
www.flexwiz.net

gotoandlearn.com

Flash Daily:
QA
&

[ Ask me anything ]
Thank You
@amosLaber
note@amosl.com

More Related Content

What's hot

Unleash 3D games with Babylon.js - JSConf 2014 talk
Unleash 3D games with Babylon.js - JSConf 2014 talkUnleash 3D games with Babylon.js - JSConf 2014 talk
Unleash 3D games with Babylon.js - JSConf 2014 talk
David Catuhe
 
XNA And Silverlight
XNA And SilverlightXNA And Silverlight
XNA And Silverlight
Aaron King
 
HTML5DevConf - Unleash the power of 3D with babylon.js
HTML5DevConf - Unleash the power of 3D with babylon.jsHTML5DevConf - Unleash the power of 3D with babylon.js
HTML5DevConf - Unleash the power of 3D with babylon.js
David Catuhe
 
Unleash 3D rendering with WebGL and Microsoft Edge
Unleash 3D rendering with WebGL and Microsoft EdgeUnleash 3D rendering with WebGL and Microsoft Edge
Unleash 3D rendering with WebGL and Microsoft Edge
David Catuhe
 
Introduction to html5 game programming with impact js
Introduction to html5 game programming with impact jsIntroduction to html5 game programming with impact js
Introduction to html5 game programming with impact js
Luca Galli
 
Creating a browser ready fps mmo in unity ppt-mew_final
Creating a browser ready fps mmo in unity ppt-mew_finalCreating a browser ready fps mmo in unity ppt-mew_final
Creating a browser ready fps mmo in unity ppt-mew_final
Amilton Diesel
 
Making VR with Unreal Engine Luis Cataldi
Making VR with Unreal Engine  Luis CataldiMaking VR with Unreal Engine  Luis Cataldi
Making VR with Unreal Engine Luis Cataldi
Unreal Engine
 
The tech. behind RoboBlastPlanet
The tech. behind RoboBlastPlanetThe tech. behind RoboBlastPlanet
The tech. behind RoboBlastPlanet
Javier Abud
 
Making mobile flex apps blazing fast
Making mobile flex apps blazing fastMaking mobile flex apps blazing fast
Making mobile flex apps blazing fast
Michał Wróblewski
 
Adobe AIR - Mobile Performance – Tips & Tricks
Adobe AIR - Mobile Performance – Tips & TricksAdobe AIR - Mobile Performance – Tips & Tricks
Adobe AIR - Mobile Performance – Tips & TricksMihai Corlan
 
SUSE Studio - LinuxTag Berlin 2010
SUSE Studio - LinuxTag Berlin 2010SUSE Studio - LinuxTag Berlin 2010
SUSE Studio - LinuxTag Berlin 2010
James Tan Y.J.
 
Virtual Presentation using Amazon Sumerian
Virtual Presentation using Amazon SumerianVirtual Presentation using Amazon Sumerian
Virtual Presentation using Amazon Sumerian
TakanoriTsutsui
 
Video game development for everybody
Video game development for everybodyVideo game development for everybody
Video game development for everybody
Sarah Sexton
 
The new Apple TV and the tvOS
The new Apple TV and the tvOSThe new Apple TV and the tvOS
The new Apple TV and the tvOS
Mugunth Kumar
 
Develop scalable high quality apps using Google Firebase - Lior Bruder, 11sheep
Develop scalable high quality apps using Google Firebase - Lior Bruder, 11sheepDevelop scalable high quality apps using Google Firebase - Lior Bruder, 11sheep
Develop scalable high quality apps using Google Firebase - Lior Bruder, 11sheep
DroidConTLV
 
Luidia eBeam Interact V2.2 Software Features VF
Luidia eBeam Interact V2.2 Software Features VFLuidia eBeam Interact V2.2 Software Features VF
Luidia eBeam Interact V2.2 Software Features VF
Timothy Misko
 
Creating A Game Using Microsoft’s Next Generation Technologies
Creating A Game Using Microsoft’s Next Generation TechnologiesCreating A Game Using Microsoft’s Next Generation Technologies
Creating A Game Using Microsoft’s Next Generation TechnologiesTamir Khason
 
Recipe of AWS Karuta
Recipe of AWS KarutaRecipe of AWS Karuta
Recipe of AWS Karuta
Takuya Tachibana
 
Open Source Solutions For Live Visuals
Open Source Solutions For Live VisualsOpen Source Solutions For Live Visuals
Open Source Solutions For Live Visuals
nocarrier
 

What's hot (20)

Unleash 3D games with Babylon.js - JSConf 2014 talk
Unleash 3D games with Babylon.js - JSConf 2014 talkUnleash 3D games with Babylon.js - JSConf 2014 talk
Unleash 3D games with Babylon.js - JSConf 2014 talk
 
XNA And Silverlight
XNA And SilverlightXNA And Silverlight
XNA And Silverlight
 
HTML5DevConf - Unleash the power of 3D with babylon.js
HTML5DevConf - Unleash the power of 3D with babylon.jsHTML5DevConf - Unleash the power of 3D with babylon.js
HTML5DevConf - Unleash the power of 3D with babylon.js
 
Unleash 3D rendering with WebGL and Microsoft Edge
Unleash 3D rendering with WebGL and Microsoft EdgeUnleash 3D rendering with WebGL and Microsoft Edge
Unleash 3D rendering with WebGL and Microsoft Edge
 
Introduction to html5 game programming with impact js
Introduction to html5 game programming with impact jsIntroduction to html5 game programming with impact js
Introduction to html5 game programming with impact js
 
Creating a browser ready fps mmo in unity ppt-mew_final
Creating a browser ready fps mmo in unity ppt-mew_finalCreating a browser ready fps mmo in unity ppt-mew_final
Creating a browser ready fps mmo in unity ppt-mew_final
 
Making VR with Unreal Engine Luis Cataldi
Making VR with Unreal Engine  Luis CataldiMaking VR with Unreal Engine  Luis Cataldi
Making VR with Unreal Engine Luis Cataldi
 
The tech. behind RoboBlastPlanet
The tech. behind RoboBlastPlanetThe tech. behind RoboBlastPlanet
The tech. behind RoboBlastPlanet
 
Making mobile flex apps blazing fast
Making mobile flex apps blazing fastMaking mobile flex apps blazing fast
Making mobile flex apps blazing fast
 
Adobe AIR - Mobile Performance – Tips & Tricks
Adobe AIR - Mobile Performance – Tips & TricksAdobe AIR - Mobile Performance – Tips & Tricks
Adobe AIR - Mobile Performance – Tips & Tricks
 
SUSE Studio - LinuxTag Berlin 2010
SUSE Studio - LinuxTag Berlin 2010SUSE Studio - LinuxTag Berlin 2010
SUSE Studio - LinuxTag Berlin 2010
 
Virtual Presentation using Amazon Sumerian
Virtual Presentation using Amazon SumerianVirtual Presentation using Amazon Sumerian
Virtual Presentation using Amazon Sumerian
 
Video game development for everybody
Video game development for everybodyVideo game development for everybody
Video game development for everybody
 
HTML5 Gaming
HTML5 GamingHTML5 Gaming
HTML5 Gaming
 
The new Apple TV and the tvOS
The new Apple TV and the tvOSThe new Apple TV and the tvOS
The new Apple TV and the tvOS
 
Develop scalable high quality apps using Google Firebase - Lior Bruder, 11sheep
Develop scalable high quality apps using Google Firebase - Lior Bruder, 11sheepDevelop scalable high quality apps using Google Firebase - Lior Bruder, 11sheep
Develop scalable high quality apps using Google Firebase - Lior Bruder, 11sheep
 
Luidia eBeam Interact V2.2 Software Features VF
Luidia eBeam Interact V2.2 Software Features VFLuidia eBeam Interact V2.2 Software Features VF
Luidia eBeam Interact V2.2 Software Features VF
 
Creating A Game Using Microsoft’s Next Generation Technologies
Creating A Game Using Microsoft’s Next Generation TechnologiesCreating A Game Using Microsoft’s Next Generation Technologies
Creating A Game Using Microsoft’s Next Generation Technologies
 
Recipe of AWS Karuta
Recipe of AWS KarutaRecipe of AWS Karuta
Recipe of AWS Karuta
 
Open Source Solutions For Live Visuals
Open Source Solutions For Live VisualsOpen Source Solutions For Live Visuals
Open Source Solutions For Live Visuals
 

Similar to Going Mobile with AIR+Starling

Minko - Targeting Flash/Stage3D with C++ and GLSL
Minko - Targeting Flash/Stage3D with C++ and GLSLMinko - Targeting Flash/Stage3D with C++ and GLSL
Minko - Targeting Flash/Stage3D with C++ and GLSLMinko3D
 
Cross-platform mobile dev with Mono
Cross-platform mobile dev with MonoCross-platform mobile dev with Mono
Cross-platform mobile dev with Mono
Craig Dunn
 
Windows 8 store apps development
Windows 8 store apps developmentWindows 8 store apps development
Windows 8 store apps development
Ahmed Emad
 
Top Tips for Android UIs - Getting the Magic on Tablets
Top Tips for Android UIs - Getting the Magic on TabletsTop Tips for Android UIs - Getting the Magic on Tablets
Top Tips for Android UIs - Getting the Magic on Tablets
Motorola Mobility - MOTODEV
 
Applico Android Info Session at Columbia University
Applico Android Info Session at Columbia UniversityApplico Android Info Session at Columbia University
Applico Android Info Session at Columbia UniversityApplico
 
Android Introduction on Java Forum Stuttgart 11
Android Introduction on Java Forum Stuttgart 11 Android Introduction on Java Forum Stuttgart 11
Android Introduction on Java Forum Stuttgart 11
Lars Vogel
 
Android Overview (Karlsruhe VKSI)
Android Overview (Karlsruhe VKSI)Android Overview (Karlsruhe VKSI)
Android Overview (Karlsruhe VKSI)
Lars Vogel
 
Presentación Unity
Presentación UnityPresentación Unity
Presentación Unity
Laura Milena Parra Navarro
 
React native
React nativeReact native
Android Development with Flash Builder Burrito
Android Development with Flash Builder BurritoAndroid Development with Flash Builder Burrito
Android Development with Flash Builder Burrito
Jeff Bollinger
 
Alan Tennent Resume 2016
Alan Tennent Resume 2016Alan Tennent Resume 2016
Alan Tennent Resume 2016Alan Tennent
 
Implementation
ImplementationImplementation
Implementation
hcicourse
 
Creating Flash Content for Multiple Screens
Creating Flash Content for Multiple ScreensCreating Flash Content for Multiple Screens
Creating Flash Content for Multiple Screens
paultrani
 
OzAltNet Fast-ANDroid-furious
OzAltNet Fast-ANDroid-furiousOzAltNet Fast-ANDroid-furious
OzAltNet Fast-ANDroid-furiousCraig Dunn
 
Intro to Android Programming
Intro to Android ProgrammingIntro to Android Programming
Intro to Android Programming
Peter van der Linden
 
Flash for Mobile Devices
Flash for Mobile DevicesFlash for Mobile Devices
Flash for Mobile Devices
paultrani
 
Introduction to Xamarin Mobile Platform
Introduction to Xamarin Mobile PlatformIntroduction to Xamarin Mobile Platform
Introduction to Xamarin Mobile Platform
Dominik Minta
 
Machine learning, WTF!?
Machine learning, WTF!? Machine learning, WTF!?
Machine learning, WTF!?
Alê Borba
 
Unite 2013 optimizing unity games for mobile platforms
Unite 2013 optimizing unity games for mobile platformsUnite 2013 optimizing unity games for mobile platforms
Unite 2013 optimizing unity games for mobile platforms
ナム-Nam Nguyễn
 

Similar to Going Mobile with AIR+Starling (20)

Minko - Targeting Flash/Stage3D with C++ and GLSL
Minko - Targeting Flash/Stage3D with C++ and GLSLMinko - Targeting Flash/Stage3D with C++ and GLSL
Minko - Targeting Flash/Stage3D with C++ and GLSL
 
Cross-platform mobile dev with Mono
Cross-platform mobile dev with MonoCross-platform mobile dev with Mono
Cross-platform mobile dev with Mono
 
Windows 8 store apps development
Windows 8 store apps developmentWindows 8 store apps development
Windows 8 store apps development
 
Adobe MAX Recap
Adobe MAX RecapAdobe MAX Recap
Adobe MAX Recap
 
Top Tips for Android UIs - Getting the Magic on Tablets
Top Tips for Android UIs - Getting the Magic on TabletsTop Tips for Android UIs - Getting the Magic on Tablets
Top Tips for Android UIs - Getting the Magic on Tablets
 
Applico Android Info Session at Columbia University
Applico Android Info Session at Columbia UniversityApplico Android Info Session at Columbia University
Applico Android Info Session at Columbia University
 
Android Introduction on Java Forum Stuttgart 11
Android Introduction on Java Forum Stuttgart 11 Android Introduction on Java Forum Stuttgart 11
Android Introduction on Java Forum Stuttgart 11
 
Android Overview (Karlsruhe VKSI)
Android Overview (Karlsruhe VKSI)Android Overview (Karlsruhe VKSI)
Android Overview (Karlsruhe VKSI)
 
Presentación Unity
Presentación UnityPresentación Unity
Presentación Unity
 
React native
React nativeReact native
React native
 
Android Development with Flash Builder Burrito
Android Development with Flash Builder BurritoAndroid Development with Flash Builder Burrito
Android Development with Flash Builder Burrito
 
Alan Tennent Resume 2016
Alan Tennent Resume 2016Alan Tennent Resume 2016
Alan Tennent Resume 2016
 
Implementation
ImplementationImplementation
Implementation
 
Creating Flash Content for Multiple Screens
Creating Flash Content for Multiple ScreensCreating Flash Content for Multiple Screens
Creating Flash Content for Multiple Screens
 
OzAltNet Fast-ANDroid-furious
OzAltNet Fast-ANDroid-furiousOzAltNet Fast-ANDroid-furious
OzAltNet Fast-ANDroid-furious
 
Intro to Android Programming
Intro to Android ProgrammingIntro to Android Programming
Intro to Android Programming
 
Flash for Mobile Devices
Flash for Mobile DevicesFlash for Mobile Devices
Flash for Mobile Devices
 
Introduction to Xamarin Mobile Platform
Introduction to Xamarin Mobile PlatformIntroduction to Xamarin Mobile Platform
Introduction to Xamarin Mobile Platform
 
Machine learning, WTF!?
Machine learning, WTF!? Machine learning, WTF!?
Machine learning, WTF!?
 
Unite 2013 optimizing unity games for mobile platforms
Unite 2013 optimizing unity games for mobile platformsUnite 2013 optimizing unity games for mobile platforms
Unite 2013 optimizing unity games for mobile platforms
 

Recently uploaded

Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
Frank van Harmelen
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
Product School
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Elena Simperl
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Tobias Schneck
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
Product School
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
RTTS
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
Laura Byrne
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Product School
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
91mobiles
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Ramesh Iyer
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
 

Recently uploaded (20)

Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
 
FIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdfFIDO Alliance Osaka Seminar: Overview.pdf
FIDO Alliance Osaka Seminar: Overview.pdf
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
 
Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
 

Going Mobile with AIR+Starling

  • 1. Going Mobile with AIR + Starling Lessons from Real World projects Presented by Amos Laber
  • 2. About Me Amos Laber Game Developer, Coder, Architect Background in C++, Console games, 3D Engines. Later: Flex, AS3, Casual and 2D Games. Blog: www.flexwiz.net
  • 3. Content and Scope The state of AIR as a mobile ecosystem (2013) Practical use of Starling, Feathers and ANE Tips, Common Problems and Practices
  • 5. AIR vs. Native Trivial: Need iOS and Anrdoid at the same time AIR = Shorter timelines (Rapid development) Leverage existing knowledge and code - Faster to implement Personal preference: AS3 over Java or Obj-C Captive Runtime: App is same as native
  • 6. The AIR Ecosystem AIR 3.5 (FP 11.5) made a big shift from enterprise into mobile (without Flex). A new generation of AS3 frameworks has reached maturity Adobe Gaming SDK: Starling, Feathers, Away3D Also Flare3D, Citrus, Nape, DragonBones New Tools: ASC2, Scout, FlashBuilder 4.7
  • 7. Production Goals Get stuff done fast. But no cutting corners! Spend time on the game (creative), not on boilerplate code. UI Elements tend to be the #1 time consuming - try to minimize and simplify them.
  • 8. Choosing Tools Code and Art Toolchain Glyph Designer
  • 11. Game Framework Do we need one? Game Framework (or Engine) will provide features and classes that are commonly used in games / apps. It takes time to learn how to efficiently use one and it creates another dependency I decided to roll my own.
  • 12. The Parallel Universe Starling forms a parallel universe where flash display list is completely hardware accelerated.
  • 13. Migrating to Starling Starling vs. 'classic' Flash Rendering: CPU flash.display.* Vector fonts |Flash| ||| Rendering: GPU (H. Accel OpenGL) starling.display.* |Starling (Stage3D)| fonts Bitmap Vector Shapes N/A (* Quad only) Bitmap / BitmapData Image / Texture Sprite and DisplayObject Same flash.events starling.events (faster)
  • 14. Starling Basics Compose the display list the same way as in flash. Layering Sprites, images and buttons Compose your views/ screens Alpha blending and hierarchy works the same way as in Flash.
  • 15. Starling App Setup Load all assets (mostly bitmaps) on initialize. Nearly all display objects are images Best is to pack them up into sprite sheets Determine screen size with stage_resize event. Use it across the app for layouts.
  • 17. UI Setup - Feathers Decide when to use custom UI, case by case Prepare a bitmap font and skin elements (Bitmap font text field is provided) Works best with a theme
  • 18. Integrating ANEs Drop into project and update the manifest /permissions Watch out for default mode - should not throw errors. Well documented and supported ANE are a better choice. Don't waste time on building them - too many dependencies (iOS and Android ver, SDK compatibility) Testing is only done on the device. They're native. Recommended: MilkMan and FreshPlanet
  • 19.
  • 20. Example: List and Item Renderer import feathers.controls.List; var list:List = new List(); list.itemRendererType= PetItemRenderer; list.dataProvider = petList; list.layout = new TiledColumnsLayout(); list.scrollerProperties.scrollBarDisplayMode = SCROLL_BAR_DISPLAY_MODE_FIXED;
  • 21. Example: The Item Renderer class ItemVO { name:String; image:Texture; locked:Boolean; } protected override function draw():void { var dataInvalid:Boolean = this.isInvalid(INVALIDATION_FLAG_DATA); if (dataInvalid) { |updateImage(data.image);| |label.text = data.name;| |label.visible = !data.locked;| |image.blendMode = data.locked? BlendMode.ERASE :|
  • 22. Composing Tips Alpha and PNG w/Alpha works best - don't bake it Use Tile Patterns with TiledImage. Stretch elements with Slice9Image /Slice3Image. Use scrollRect for simple masking and smooth scrolling
  • 23. Example: Scroll and Mask Castle gate was masked with scrollRect, animated by tweening scrollRect.y + +
  • 25. Touch AIR SDK own touch handling is not very useful 3rd party libraries can fill in the gap Gestouch is my recommended library: Multitouch gestures for Starling or classic flash http://github.com/fljot/Gestouch
  • 26. Textures Things to know GPU memory on devices is limited. iPhone 3GS has 24 MB Standalone textures are rounded up to power of 2 size (e.g. 1024x1024 pixels). Once created, the texture is uploaded to GPU. When maxed out, the OS will close the app without warning, exception or stack trace.
  • 27. Textures Best Preactices Create the textures on demand - not when the Assets are loaded. Make sure to release with texture.dispose() when removed from stage. Pack everything to sprite sheets! We use TexturePacker Have a central asset manager to hold textures
  • 28. Textures Sample Code private var _textures:Dictionary; .. public function getTexture(name:String):Texture { |if (_textures[name] == undefined) {| | var data:Object = _loadedAssets[name];| | if (data is Bitmap)| |_textures[name] = | Texture.fromBitmap(data as Bitmap, false, false); |}| return _textures[name]; } public function disposeTexture(name:String):void { if (_textures[name]) { Texture(_textures[name]).dispose(); |textures[name] = | null |;|
  • 29. Screen Size and Layout Avoid hardcoded pixel sizes. Use relative align or percentage iPad Retina support No need to duplicate the assets (x1, x2, x4...) Selective scale Test layout in different screen sizes on simulator
  • 32. Promote you App For Zero Cost Create a Facebook fan page. Create a Twitter account and tweet frequently. Make a YouTube video with actual gameplay footage. Prepare a press kit with screenshots and marketting blurb and send it for review to selected web sites.
  • 33. Tracking Data Weekly Downloads iOS Android Chart was not exported from SlideRocket
  • 34. Takedown Is Starling Right for you? AIR proved a viable solution for mobile Starling is now a Solid and Mature framework Developers can get stuff done faster
  • 36. QA & [ Ask me anything ]