SlideShare a Scribd company logo
1 of 30
Download to read offline
Partyrocking

By @pekewake and @dvdchavarri
From Chat to Realtime Game
Who we are.

David Chavarri and Rubén Chavarri

…where the idea comes from
Introduction

What we are going to talk about
Practical Example – ZombieRocking
Personal Experience
Future Possibilities
From Chat to Realtime Game
…a little bit about the background
HTML5 Tour: Programación de
Videojuegos HTML5
Fernando Oteros

Desarrollo de videojuegos en JavaScript
Sergio Ruiz (@serginator)
Carlos Benitez (@etnassoft)
Implementar Websockets con...
Jorge Del Casar (@jorgecasar)
From Chat to Realtime Game
Technology
From Chat to Realtime Game
1) Scene
2) Events
3) Chat
4) ZombieRocking

5) World of ZombieRocking
From Chat to Realtime Game

1) Scene
From Chat to Realtime Game
1) Scene

.html

scene.js

Our trick: CAAT no intrusive
“Game Framework” that help
us to encapsulate in our
examples the “Canvas”
interaction throw object
concepts like Director,
Scene, Actors & gameloop).

other Frameworks

ally.js
From Chat to Realtime Game

2) Events
Behaviours
Breath

Walk - Wait
Shot

Input Controls
From Chat to Realtime Game

2) Events
Behaviors

Inputs
From Chat to Realtime Game

3) Chat
io.sockets.emit(“msg”)

socketio.emit(“msg”)

socketio.emit(“msg”)
From Chat to Realtime Game

3) Chat
Server
(node)

Client
(html)

source code
From Chat to Realtime Game

4) ZombieRocking

Emit websocket
action Left
action Right
action Wait
action Shot

Emit clientToServer
From Chat to Realtime Game

4) ZombieRocking
Update Controls

Manage Events
From Chat to Realtime Game

5) World of ZombieRocking

emit
clientToServer

Emit websocket
From Chat to Realtime Game

5) World of ZombieRocking
server (node)

client
Now What?

Let deploy the App
in Smartphones

!
Now What? Deploy the App in Smartphones

Inconveniences
WebSocket Support
Performance

Native Interaction
Inconveniences
WebSocket Support

http://caniuse.com/websockets
Inconveniences

Performance - JS Acceleration
CocoonJS - Canvas Acceleration
http://sumonhtml5.ludei.com/

Famo.us - HTML Acceleration
http://famo.us/
Inconveniences

Native Interaction with HTML5 Capabilities
Supported
+ Hybrid Approach
GeolocationAPI
Offline support
WebStorage
2D animations

Camera
Notifications
Sensors
Device Info
Market Store
Deploying the App in Smartphones

Hybrid Mobile App Frameworks
Cordova / PhoneGap (Javascript)
(IBM Worklite, HP Anywhere, Intel XDK, SAP Platform –SUP)

Appcelerator Titanium (Javascript)
KonyOne (Lua & Javascript)
Xamarin (C#)
Rhodes (Ruby)
Deploying the App in Smartphones

Appcelerator Titanium
Proprietary Software
Compiles to native code
Proprietary JavaScript UI
that maps to native OS UI
Enterprise Support

Android, IOS
(Windows phone, BlackBerry
and Tizen, soon)

http://www.appcelerator.com/
Deploying the App in Smartphones

Cordova PhoneGap
Open Source
Wraps the webView

HTML5 & CSS3
Great OpenSource
Community

Most Mobile Platforms

http://phonegap.com/
Now What? Deploy the App in Smartphones

A few Pointers
Data on the wire!
Please don't send your app HTML from the server,
Javascript does a perfect job rendering it

Use local storage
Whenever possible, show cached content to the user

Write plugins & custom native UI
Sometimes is worth the development of Native features
What about WebSockets Scalability?
MVC Real-time
frameworks
Cross-platform
OpenSource,Scaffolding
Multilingual

Yes

Yes

Resource View
Presenter

Model-View-Controller

Model-View-Controller
Active-Record

MongoDB

Design pattern

Yes

MongoDB
Redis

MySQL, MongoDB,Flat
File, Redis,
PostgreSQL

Good

Basic

Good

Reactive programming
Component-oriented
Pub/Sub

Component-oriented
Event-driven Reactive
programming

Event-driven

27%

38%

35%

Database
Community Driven
Programming paradigm
Preference

http://vschart.com/compare/meteor-web-framework/vs/derbyjs/vs/sails-js
What about WebSockets Scalability?
WebSocket Server Providers:
Pusher
http://pusher.com/

Firebase
https://www.firebase.com/

Tambur.io
https://www.tambur.io/
Just one more demonstration

Demo Time !!!
World of ZombieRocking
Our experiments

http://www.partyrocking.tv
“Be Partyrocking
my friend…”
The twins

By @pekewake..
@dvdchavarri

More Related Content

Similar to PartyRocking: Jugando con Javascript y Websockets

Fragmentation in mobile design: fact or fiction
Fragmentation in mobile design: fact or fictionFragmentation in mobile design: fact or fiction
Fragmentation in mobile design: fact or fiction
Belen Barros Pena
 
iPhone/iPad Development with Titanium
iPhone/iPad Development with TitaniumiPhone/iPad Development with Titanium
iPhone/iPad Development with Titanium
Axway Appcelerator
 
Philly ete-2011
Philly ete-2011Philly ete-2011
Philly ete-2011
davyjones
 

Similar to PartyRocking: Jugando con Javascript y Websockets (20)

Hybrid HTML5 Apps
Hybrid HTML5 AppsHybrid HTML5 Apps
Hybrid HTML5 Apps
 
Prototyping in aframe
Prototyping in aframePrototyping in aframe
Prototyping in aframe
 
Making VR Webby
Making VR WebbyMaking VR Webby
Making VR Webby
 
Fragmentation in mobile design: fact or fiction
Fragmentation in mobile design: fact or fictionFragmentation in mobile design: fact or fiction
Fragmentation in mobile design: fact or fiction
 
Plattformübergreifende App-Entwicklung (ein Vergleich) - MobileTechCon 2010
Plattformübergreifende App-Entwicklung (ein Vergleich) - MobileTechCon 2010Plattformübergreifende App-Entwicklung (ein Vergleich) - MobileTechCon 2010
Plattformübergreifende App-Entwicklung (ein Vergleich) - MobileTechCon 2010
 
Augmented reality
Augmented realityAugmented reality
Augmented reality
 
Appcelerator iPhone/iPad Dev Con 2010 San Diego, CA
Appcelerator iPhone/iPad Dev Con 2010 San Diego, CAAppcelerator iPhone/iPad Dev Con 2010 San Diego, CA
Appcelerator iPhone/iPad Dev Con 2010 San Diego, CA
 
iPhone/iPad Development with Titanium
iPhone/iPad Development with TitaniumiPhone/iPad Development with Titanium
iPhone/iPad Development with Titanium
 
HoloLens.pdf
HoloLens.pdfHoloLens.pdf
HoloLens.pdf
 
Samsung
SamsungSamsung
Samsung
 
Philly ete-2011
Philly ete-2011Philly ete-2011
Philly ete-2011
 
O futuro do desenvolvimento .NET
O futuro do desenvolvimento .NETO futuro do desenvolvimento .NET
O futuro do desenvolvimento .NET
 
Fake it 'til you make it
Fake it 'til you make itFake it 'til you make it
Fake it 'til you make it
 
HTML5 Can't Do That
HTML5 Can't Do ThatHTML5 Can't Do That
HTML5 Can't Do That
 
Introduction to WebVR Autodesk Forge 2016
Introduction to WebVR Autodesk Forge 2016Introduction to WebVR Autodesk Forge 2016
Introduction to WebVR Autodesk Forge 2016
 
Começando com Android
Começando com AndroidComeçando com Android
Começando com Android
 
Bridging Realitites
Bridging RealititesBridging Realitites
Bridging Realitites
 
Building a game engine with jQuery
Building a game engine with jQueryBuilding a game engine with jQuery
Building a game engine with jQuery
 
Apps vs. Sites vs. Content - a vendor-agnostic view on building stuff for the...
Apps vs. Sites vs. Content - a vendor-agnostic view on building stuff for the...Apps vs. Sites vs. Content - a vendor-agnostic view on building stuff for the...
Apps vs. Sites vs. Content - a vendor-agnostic view on building stuff for the...
 
20141216 멜팅팟 부산 세션 ii - cross platform 개발
20141216 멜팅팟 부산   세션 ii - cross platform 개발20141216 멜팅팟 부산   세션 ii - cross platform 개발
20141216 멜팅팟 부산 세션 ii - cross platform 개발
 

More from Ruben Chavarri

More from Ruben Chavarri (7)

Construir una App con AI nunca fue tan fácil
Construir una App con AI nunca fue tan fácilConstruir una App con AI nunca fue tan fácil
Construir una App con AI nunca fue tan fácil
 
Block chain lets kill the hype
Block chain lets kill the hypeBlock chain lets kill the hype
Block chain lets kill the hype
 
T3chCoin: dando forma al mundo a base de tokens
T3chCoin: dando forma al mundo a base de tokensT3chCoin: dando forma al mundo a base de tokens
T3chCoin: dando forma al mundo a base de tokens
 
BitCoin, BlockChain, más criaturas fantásticas, y donde utilizarlas
BitCoin, BlockChain, más criaturas fantásticas, y donde utilizarlasBitCoin, BlockChain, más criaturas fantásticas, y donde utilizarlas
BitCoin, BlockChain, más criaturas fantásticas, y donde utilizarlas
 
Angular2 + New Firebase in Action
Angular2 + New Firebase in ActionAngular2 + New Firebase in Action
Angular2 + New Firebase in Action
 
The cognitive side of IoT (TechSummit 2016)
The cognitive side of IoT (TechSummit 2016)The cognitive side of IoT (TechSummit 2016)
The cognitive side of IoT (TechSummit 2016)
 
Introduccion WebComponents y Visual Studio
Introduccion WebComponents y Visual StudioIntroduccion WebComponents y Visual Studio
Introduccion WebComponents y Visual Studio
 

Recently uploaded

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 

Recently uploaded (20)

CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
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
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
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
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
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...
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
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
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 

PartyRocking: Jugando con Javascript y Websockets

  • 2. From Chat to Realtime Game Who we are. David Chavarri and Rubén Chavarri …where the idea comes from
  • 3. Introduction What we are going to talk about Practical Example – ZombieRocking Personal Experience Future Possibilities
  • 4. From Chat to Realtime Game …a little bit about the background HTML5 Tour: Programación de Videojuegos HTML5 Fernando Oteros Desarrollo de videojuegos en JavaScript Sergio Ruiz (@serginator) Carlos Benitez (@etnassoft) Implementar Websockets con... Jorge Del Casar (@jorgecasar)
  • 5. From Chat to Realtime Game Technology
  • 6. From Chat to Realtime Game 1) Scene 2) Events 3) Chat 4) ZombieRocking 5) World of ZombieRocking
  • 7. From Chat to Realtime Game 1) Scene
  • 8. From Chat to Realtime Game 1) Scene .html scene.js Our trick: CAAT no intrusive “Game Framework” that help us to encapsulate in our examples the “Canvas” interaction throw object concepts like Director, Scene, Actors & gameloop). other Frameworks ally.js
  • 9. From Chat to Realtime Game 2) Events Behaviours Breath Walk - Wait Shot Input Controls
  • 10. From Chat to Realtime Game 2) Events Behaviors Inputs
  • 11. From Chat to Realtime Game 3) Chat io.sockets.emit(“msg”) socketio.emit(“msg”) socketio.emit(“msg”)
  • 12. From Chat to Realtime Game 3) Chat Server (node) Client (html) source code
  • 13. From Chat to Realtime Game 4) ZombieRocking Emit websocket action Left action Right action Wait action Shot Emit clientToServer
  • 14. From Chat to Realtime Game 4) ZombieRocking Update Controls Manage Events
  • 15. From Chat to Realtime Game 5) World of ZombieRocking emit clientToServer Emit websocket
  • 16. From Chat to Realtime Game 5) World of ZombieRocking server (node) client
  • 17. Now What? Let deploy the App in Smartphones !
  • 18. Now What? Deploy the App in Smartphones Inconveniences WebSocket Support Performance Native Interaction
  • 20. Inconveniences Performance - JS Acceleration CocoonJS - Canvas Acceleration http://sumonhtml5.ludei.com/ Famo.us - HTML Acceleration http://famo.us/
  • 21. Inconveniences Native Interaction with HTML5 Capabilities Supported + Hybrid Approach GeolocationAPI Offline support WebStorage 2D animations Camera Notifications Sensors Device Info Market Store
  • 22. Deploying the App in Smartphones Hybrid Mobile App Frameworks Cordova / PhoneGap (Javascript) (IBM Worklite, HP Anywhere, Intel XDK, SAP Platform –SUP) Appcelerator Titanium (Javascript) KonyOne (Lua & Javascript) Xamarin (C#) Rhodes (Ruby)
  • 23. Deploying the App in Smartphones Appcelerator Titanium Proprietary Software Compiles to native code Proprietary JavaScript UI that maps to native OS UI Enterprise Support Android, IOS (Windows phone, BlackBerry and Tizen, soon) http://www.appcelerator.com/
  • 24. Deploying the App in Smartphones Cordova PhoneGap Open Source Wraps the webView HTML5 & CSS3 Great OpenSource Community Most Mobile Platforms http://phonegap.com/
  • 25. Now What? Deploy the App in Smartphones A few Pointers Data on the wire! Please don't send your app HTML from the server, Javascript does a perfect job rendering it Use local storage Whenever possible, show cached content to the user Write plugins & custom native UI Sometimes is worth the development of Native features
  • 26. What about WebSockets Scalability? MVC Real-time frameworks Cross-platform OpenSource,Scaffolding Multilingual Yes Yes Resource View Presenter Model-View-Controller Model-View-Controller Active-Record MongoDB Design pattern Yes MongoDB Redis MySQL, MongoDB,Flat File, Redis, PostgreSQL Good Basic Good Reactive programming Component-oriented Pub/Sub Component-oriented Event-driven Reactive programming Event-driven 27% 38% 35% Database Community Driven Programming paradigm Preference http://vschart.com/compare/meteor-web-framework/vs/derbyjs/vs/sails-js
  • 27. What about WebSockets Scalability? WebSocket Server Providers: Pusher http://pusher.com/ Firebase https://www.firebase.com/ Tambur.io https://www.tambur.io/
  • 28. Just one more demonstration Demo Time !!! World of ZombieRocking
  • 30. “Be Partyrocking my friend…” The twins By @pekewake.. @dvdchavarri