SlideShare une entreprise Scribd logo
1  sur  45
Télécharger pour lire hors ligne
Developing mobile games
and applications using
Castle Game Engine
Michalis Kamburelis
About Me
● Castle Game Engine - https://castle-engine.io/
● PasDoc - https://pasdoc.github.io/
● Modern Object Pascal Introduction -
https://castle-engine.io/modern_pascal
● Web3d member, Khronos<->Web3d liaison (3D standards - glTF, X3D)
● Co-owner of Cat-astrophe Games - https://cat-astrophe-games.com/
Castle Game Engine intro:
Editor, Components and Building
Applications
Castle Game Engine
Castle Game Engine
● 3D and 2D
● Editor
● Pascal API (all that you can do in editor + much more)
○ For your games and for engine
○ FPC (all platforms) and Delphi (Windows, Linux)
● Open-source
○ Want to fork to add a project-specific feature? OK.
● Multi-platform
○ Windows, Linux (Raspberry Pi too), FreeBSD, macOS
○ Android, iOS
○ Nintendo Switch
3D FPS game template
● Views
● Play view
○ Viewport, navigate in 3D
○ Left side: hierarchy with components
■ UI
■ viewport is also UI
■ 3D: transform scenes, cameras, lights
■ drag-and-drop 3D models, images
■ transform, delete, duplicate
■ behaviors attach to transforms, like billboard
○ Right side: properties
○ Bottom: files
■ preview
■ special data directory
■ double click to run view3dscene on scenes
2D game template
Run!
From CGE editor, or Lazarus, or Delphi, or VS Code.
Run on mobile
Just switch "Run -> Platform (...)" to "Android".
Assuming you have Android SDK and FPC cross-compilers, see https://castle-engine.io/android .
Physics and Coding
Setup and test Physics in editor -
colliders and rigid bodies
Edit in Lazarus IDE
Edit in VS Code
See our VS Code extension - https://castle-engine.io/vscode
Bigger Projects
Mobile: touch and multi-touch
Basic: mouse and touch unified
● Mouse is just like touch, but you only have 1 finger.
● Touch is just mouse, but you only have 1 (left) button.
So just recompile and it works
But some differences cannot be "hidden" by
engine
● When touching, user cannot move position without pressing
● Touching has less precision
○ (smaller physical devices (phones), your finger, you don't see the
cursor)
● Multi-touch possible in exchange: touch screens can track each finger
press independently.
Multi-touch API
● Press, Motion and other events have "FingerIndex"
● Observe current touches from any place (like Update):
○ Container.Touches[FingerIndex: Integer]: TTouch
○ Container.TouchesCount: Integer
drawing_toy example
examples/mobile/drawing_toy
Alternative version for my daughter :)
Ready TCastleTouchNavigation to navigate in
3D on mobile
UI Scaling
(for mobile, but also modern
screen with different sizes)
UI scaling - scale UI to some imaginary size
● The coordinates you specify are in floats, and follow "scaled coordinates".
● The "scaled coordinates" by default pretend that you have a screen 1600 x 900,
○ but adjusted (larger in one dimension) to keep aspect ratio.
○ Of course this is configurable, https://castle-engine.io/manual_castle_settings.php
UI Scaling - how coordinates work
UI Scaling - result
● Sizes and positions are scaled, so designing them on 1 screen will work on
another.
● You can just use hardcoded numbers for sizes and positions.
○ They will work (be scaled).
● Use anchors to keep things aligned to proper border/center.
● Your application works on all screen sizes --
○ various Androids, iOS, desktops…
Example: component_gallery
component_gallery on Android
Android Services
How are Android / iOS projects build
● FPC compiles your application to a library (so or a).
● We glue it with larger code that defines an Android or Xcode iOS project.
● So we can really use 100% of native platform capabilities.
● "Services" are pieces of code basically added to the native project,
○ that expose some native platform API (like vibrations).
○ They usually enable to control it from Pascal code
○ (you can use your own, e.g. JNI, or use our ready CastleMessaging -- good for
cases when communication is naturally asynchronous, like for all services that
do something over the network).
● See https://castle-engine.io/android_services
Example: vibrations
Example: Analytics - basic metrics
Example: Analytics - custom events, screen
views, progression
More services
https://castle-engine.io/android_services
● Various Ad frameworks
● Analytics
● In-app purchases https://castle-engine.io/in_app_purchases
● Networking (downloading URLs, TCP/IP client/server)
● Google Play Games (Achievements, Leaderboards)
● Vibrate
● Photo storage
● TestFairy (distribution, remote logging)
● More planned (GPS, maps, AR…)
iOS is as easy as Android, you just
need mac machine
iOS
If you have a mac machine, follow https://castle-engine.io/ios to get some dependencies:
● Xcode with cli tools
● FPC cross-compilers
and you can build iOS (iPhone, iPad) applications with equal ease as Android.
CGE can prepare
● Xcode project (that you can later deploy in any way from Xcode)
● or create ready archive like IPA (that you can distribute e.g. using TestFairy)
iOS services are available as well https://castle-engine.io/ios_services
Conclusion
Plans
● 7.0-alpha3 release next week
○ Ton of stuff:
https://castle-engine.io/new_features_in_castle_game_engine_7.0
● 7.0 release this year:
○ Material components (shaders, mirrors, easier)
○ Steam (for your games, but also for editor!)
● 7.2 (hopefully this Christmas):
○ Web platform (target, but also source!)
● More: https://castle-engine.io/roadmap
How to make this sustainable?
● We're a community of Pascal developers who are enthusiastic about open-source, games,
and Pascal.
● Engine is all free and open-source.
○ But we can sponsor open-source work (Andrzej Kilijański, Eugene Loza).
○ We also did commercial games (CAG, https://unholy-society.com/ ).
● Support us:
https://www.patreon.com/castleengine
● Want to work together, b2b contract?
michalis@castle-engine.io
Thank you!
https:/
/castle-engine.io
michalis@castle-engine.io

Contenu connexe

Similaire à Developing mobile games and applications using Castle Game Engine

Mak product overview_no_video
Mak product overview_no_videoMak product overview_no_video
Mak product overview_no_videoPeter Swan
 
mloc.js 2014 - JavaScript and the browser as a platform for game development
mloc.js 2014 - JavaScript and the browser as a platform for game developmentmloc.js 2014 - JavaScript and the browser as a platform for game development
mloc.js 2014 - JavaScript and the browser as a platform for game developmentDavid Galeano
 
HTML5 New Features and Resources
HTML5 New Features and ResourcesHTML5 New Features and Resources
HTML5 New Features and ResourcesRon Reiter
 
Programming for non tech entrepreneurs
Programming for non tech entrepreneursProgramming for non tech entrepreneurs
Programming for non tech entrepreneursRodrigo Gil
 
Video Terminal Evolution and The Future of Browsers
Video Terminal Evolution and The Future of BrowsersVideo Terminal Evolution and The Future of Browsers
Video Terminal Evolution and The Future of BrowsersThomas Walker Lynch
 
Interfaces of the future now available augmented reality - google glass - 3...
Interfaces of the future now available   augmented reality - google glass - 3...Interfaces of the future now available   augmented reality - google glass - 3...
Interfaces of the future now available augmented reality - google glass - 3...CuriousInventor
 
Cross Platform Mobile App Development
Cross Platform Mobile App DevelopmentCross Platform Mobile App Development
Cross Platform Mobile App DevelopmentAnnmarie Lanesey
 
Drupal 3D - Intro to Using Web 3D with Drupal
Drupal 3D - Intro to Using Web 3D with DrupalDrupal 3D - Intro to Using Web 3D with Drupal
Drupal 3D - Intro to Using Web 3D with DrupalBrian Hay
 
Your next data viz gear should be a Wii-U
Your next data viz gear should be a Wii-UYour next data viz gear should be a Wii-U
Your next data viz gear should be a Wii-UChristophe Guéret
 
A 3D printing programming API
A 3D printing programming APIA 3D printing programming API
A 3D printing programming APIMax Kleiner
 
Cloud Conf 2015 - Develop and Deploy IOT Applications
Cloud Conf 2015 - Develop and Deploy IOT ApplicationsCloud Conf 2015 - Develop and Deploy IOT Applications
Cloud Conf 2015 - Develop and Deploy IOT ApplicationsCorley S.r.l.
 
Flutter - Pixel by Pixel
Flutter - Pixel by PixelFlutter - Pixel by Pixel
Flutter - Pixel by PixelThomas Gazzoni
 
COMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LIST
COMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LISTCOMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LIST
COMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LISTtarun kumar sharma
 
Introduction to html5 game programming with ImpactJs
Introduction to html5 game programming with ImpactJsIntroduction to html5 game programming with ImpactJs
Introduction to html5 game programming with ImpactJsLuca Galli
 
Necessitas - Qt on Android - from FSCONS 2011
Necessitas - Qt on Android - from FSCONS 2011Necessitas - Qt on Android - from FSCONS 2011
Necessitas - Qt on Android - from FSCONS 2011Johan Thelin
 
I/O Frog: Not another Sigfox platform?
I/O Frog: Not another Sigfox platform?I/O Frog: Not another Sigfox platform?
I/O Frog: Not another Sigfox platform?Simple Hardware
 

Similaire à Developing mobile games and applications using Castle Game Engine (20)

Mak product overview_no_video
Mak product overview_no_videoMak product overview_no_video
Mak product overview_no_video
 
mloc.js 2014 - JavaScript and the browser as a platform for game development
mloc.js 2014 - JavaScript and the browser as a platform for game developmentmloc.js 2014 - JavaScript and the browser as a platform for game development
mloc.js 2014 - JavaScript and the browser as a platform for game development
 
Html5 (games)
Html5 (games)Html5 (games)
Html5 (games)
 
HTML5 New Features and Resources
HTML5 New Features and ResourcesHTML5 New Features and Resources
HTML5 New Features and Resources
 
Programming for non tech entrepreneurs
Programming for non tech entrepreneursProgramming for non tech entrepreneurs
Programming for non tech entrepreneurs
 
Video Terminal Evolution and The Future of Browsers
Video Terminal Evolution and The Future of BrowsersVideo Terminal Evolution and The Future of Browsers
Video Terminal Evolution and The Future of Browsers
 
Interfaces of the future now available augmented reality - google glass - 3...
Interfaces of the future now available   augmented reality - google glass - 3...Interfaces of the future now available   augmented reality - google glass - 3...
Interfaces of the future now available augmented reality - google glass - 3...
 
Cross Platform Mobile App Development
Cross Platform Mobile App DevelopmentCross Platform Mobile App Development
Cross Platform Mobile App Development
 
Drupal 3D - Intro to Using Web 3D with Drupal
Drupal 3D - Intro to Using Web 3D with DrupalDrupal 3D - Intro to Using Web 3D with Drupal
Drupal 3D - Intro to Using Web 3D with Drupal
 
Mobile cloud
Mobile cloudMobile cloud
Mobile cloud
 
Your next data viz gear should be a Wii-U
Your next data viz gear should be a Wii-UYour next data viz gear should be a Wii-U
Your next data viz gear should be a Wii-U
 
HTML5 Game Development frameworks overview
HTML5 Game Development frameworks overviewHTML5 Game Development frameworks overview
HTML5 Game Development frameworks overview
 
A 3D printing programming API
A 3D printing programming APIA 3D printing programming API
A 3D printing programming API
 
Cloud Conf 2015 - Develop and Deploy IOT Applications
Cloud Conf 2015 - Develop and Deploy IOT ApplicationsCloud Conf 2015 - Develop and Deploy IOT Applications
Cloud Conf 2015 - Develop and Deploy IOT Applications
 
Flutter - Pixel by Pixel
Flutter - Pixel by PixelFlutter - Pixel by Pixel
Flutter - Pixel by Pixel
 
COMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LIST
COMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LISTCOMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LIST
COMPUTER GRAPHICS AND MULTI MEDIA SOFTWARE LIST
 
(2) gui drawing
(2) gui drawing(2) gui drawing
(2) gui drawing
 
Introduction to html5 game programming with ImpactJs
Introduction to html5 game programming with ImpactJsIntroduction to html5 game programming with ImpactJs
Introduction to html5 game programming with ImpactJs
 
Necessitas - Qt on Android - from FSCONS 2011
Necessitas - Qt on Android - from FSCONS 2011Necessitas - Qt on Android - from FSCONS 2011
Necessitas - Qt on Android - from FSCONS 2011
 
I/O Frog: Not another Sigfox platform?
I/O Frog: Not another Sigfox platform?I/O Frog: Not another Sigfox platform?
I/O Frog: Not another Sigfox platform?
 

Dernier

Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
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
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
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
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
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
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
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
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
🐬 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
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
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
 
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
 
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
 
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
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 

Dernier (20)

Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
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...
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
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
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
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
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
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 ...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
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
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
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
 
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...
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 

Developing mobile games and applications using Castle Game Engine

  • 1. Developing mobile games and applications using Castle Game Engine Michalis Kamburelis
  • 2. About Me ● Castle Game Engine - https://castle-engine.io/ ● PasDoc - https://pasdoc.github.io/ ● Modern Object Pascal Introduction - https://castle-engine.io/modern_pascal ● Web3d member, Khronos<->Web3d liaison (3D standards - glTF, X3D) ● Co-owner of Cat-astrophe Games - https://cat-astrophe-games.com/
  • 3. Castle Game Engine intro: Editor, Components and Building Applications
  • 5. Castle Game Engine ● 3D and 2D ● Editor ● Pascal API (all that you can do in editor + much more) ○ For your games and for engine ○ FPC (all platforms) and Delphi (Windows, Linux) ● Open-source ○ Want to fork to add a project-specific feature? OK. ● Multi-platform ○ Windows, Linux (Raspberry Pi too), FreeBSD, macOS ○ Android, iOS ○ Nintendo Switch
  • 6. 3D FPS game template ● Views ● Play view ○ Viewport, navigate in 3D ○ Left side: hierarchy with components ■ UI ■ viewport is also UI ■ 3D: transform scenes, cameras, lights ■ drag-and-drop 3D models, images ■ transform, delete, duplicate ■ behaviors attach to transforms, like billboard ○ Right side: properties ○ Bottom: files ■ preview ■ special data directory ■ double click to run view3dscene on scenes
  • 7.
  • 9. Run! From CGE editor, or Lazarus, or Delphi, or VS Code.
  • 10. Run on mobile Just switch "Run -> Platform (...)" to "Android". Assuming you have Android SDK and FPC cross-compilers, see https://castle-engine.io/android .
  • 12. Setup and test Physics in editor - colliders and rigid bodies
  • 14. Edit in VS Code See our VS Code extension - https://castle-engine.io/vscode
  • 16.
  • 17.
  • 18. Mobile: touch and multi-touch
  • 19. Basic: mouse and touch unified ● Mouse is just like touch, but you only have 1 finger. ● Touch is just mouse, but you only have 1 (left) button.
  • 20. So just recompile and it works
  • 21. But some differences cannot be "hidden" by engine ● When touching, user cannot move position without pressing ● Touching has less precision ○ (smaller physical devices (phones), your finger, you don't see the cursor) ● Multi-touch possible in exchange: touch screens can track each finger press independently.
  • 22. Multi-touch API ● Press, Motion and other events have "FingerIndex" ● Observe current touches from any place (like Update): ○ Container.Touches[FingerIndex: Integer]: TTouch ○ Container.TouchesCount: Integer
  • 25. Alternative version for my daughter :)
  • 26. Ready TCastleTouchNavigation to navigate in 3D on mobile
  • 27. UI Scaling (for mobile, but also modern screen with different sizes)
  • 28. UI scaling - scale UI to some imaginary size ● The coordinates you specify are in floats, and follow "scaled coordinates". ● The "scaled coordinates" by default pretend that you have a screen 1600 x 900, ○ but adjusted (larger in one dimension) to keep aspect ratio. ○ Of course this is configurable, https://castle-engine.io/manual_castle_settings.php
  • 29. UI Scaling - how coordinates work
  • 30. UI Scaling - result ● Sizes and positions are scaled, so designing them on 1 screen will work on another. ● You can just use hardcoded numbers for sizes and positions. ○ They will work (be scaled). ● Use anchors to keep things aligned to proper border/center. ● Your application works on all screen sizes -- ○ various Androids, iOS, desktops…
  • 34. How are Android / iOS projects build ● FPC compiles your application to a library (so or a). ● We glue it with larger code that defines an Android or Xcode iOS project. ● So we can really use 100% of native platform capabilities. ● "Services" are pieces of code basically added to the native project, ○ that expose some native platform API (like vibrations). ○ They usually enable to control it from Pascal code ○ (you can use your own, e.g. JNI, or use our ready CastleMessaging -- good for cases when communication is naturally asynchronous, like for all services that do something over the network). ● See https://castle-engine.io/android_services
  • 36. Example: Analytics - basic metrics
  • 37. Example: Analytics - custom events, screen views, progression
  • 38. More services https://castle-engine.io/android_services ● Various Ad frameworks ● Analytics ● In-app purchases https://castle-engine.io/in_app_purchases ● Networking (downloading URLs, TCP/IP client/server) ● Google Play Games (Achievements, Leaderboards) ● Vibrate ● Photo storage ● TestFairy (distribution, remote logging) ● More planned (GPS, maps, AR…)
  • 39. iOS is as easy as Android, you just need mac machine
  • 40. iOS If you have a mac machine, follow https://castle-engine.io/ios to get some dependencies: ● Xcode with cli tools ● FPC cross-compilers and you can build iOS (iPhone, iPad) applications with equal ease as Android. CGE can prepare ● Xcode project (that you can later deploy in any way from Xcode) ● or create ready archive like IPA (that you can distribute e.g. using TestFairy) iOS services are available as well https://castle-engine.io/ios_services
  • 41.
  • 43. Plans ● 7.0-alpha3 release next week ○ Ton of stuff: https://castle-engine.io/new_features_in_castle_game_engine_7.0 ● 7.0 release this year: ○ Material components (shaders, mirrors, easier) ○ Steam (for your games, but also for editor!) ● 7.2 (hopefully this Christmas): ○ Web platform (target, but also source!) ● More: https://castle-engine.io/roadmap
  • 44. How to make this sustainable? ● We're a community of Pascal developers who are enthusiastic about open-source, games, and Pascal. ● Engine is all free and open-source. ○ But we can sponsor open-source work (Andrzej Kilijański, Eugene Loza). ○ We also did commercial games (CAG, https://unholy-society.com/ ). ● Support us: https://www.patreon.com/castleengine ● Want to work together, b2b contract? michalis@castle-engine.io