Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Getting started with HTML5
Started by Rob Miracle Mar 20 2018 08:08 AM

- - - - -
170 replies to this topic
[TOPIC CONTROLS]
Page 1 of 7 1 2 3 »
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 26,697 posts
  • Enterprise

To test your HTML5 app, you will need to upload the entire folder to your web server and access that folder through your HTML5 compatible browser. Due to JavaScript security restrictions, HTML5 builds only work if they are served from a web server.

 

If you have Python installed you can test locally by starting a web browser on your computer and accessing your HTML5 build folder in your browser. The easiest way to get it served on macOS is to drag your build folder on to Terminal.app then paste

python -m SimpleHTTPServer

into the terminal window. Then open http://localhost:8000/index.html in you web browser. For Windows, with Python installed, run cmd.exe and then use the cd command to change directories to your build folder and run the same Python command and then open your browser to the above URL. If you need to see the console log, please open http://localhost:8000/index-debug.html instead.

 

Please post questions about HTML5 here.

 

Rob


  • horacebury, roaminggamer, Develephant and 1 other like this

[TOPIC: post.html]
#2

jhanca_s_o2011

[GLOBAL: userInfoPane.html]
jhanca_s_o2011
  • Observer

  • 3 posts
  • Corona SDK

Just what I expected, fantastic! :D ,I'm from Perú.



[TOPIC: post.html]
#3

evanspro

[GLOBAL: userInfoPane.html]
evanspro
  • Contributor

  • 187 posts
  • Corona SDK

First of all : this is amazing news ! :)

 

I've just tried converting my game into html5 but I've got two errors as soon as I start building my app :

17:51:50.793  ERROR: unable to download plugin.openssl (com.coronalabs). Error message: 
17:51:50.793  <?xml version="1.0" encoding="UTF-8"?>
17:51:50.793  <Error><Code>NoSuchKey</Code><Message>The specified key does not exist.</Message><Key>com.coronalabs/plugin.openssl/2016.2883/web/data.tgz</Key><RequestId>XXXXXXX</RequestId><HostId>XXXXX=</HostId></Error>
17:52:22.336  ERROR: Out of Memory error
17:52:22.336  not enough memory

I've been able to get rid of the UTF-8 error / Facebook api / etc / (by removing all the plugin in my build.setting file), so I'm fine with this one. But i'm not sure what to do with the "Out of Memory error"...

 

Oh and are there any Corona SDK / HTML5 documentation available somewhere ?



[TOPIC: post.html]
#4

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 26,697 posts
  • Enterprise

As noted in the announcement, https://coronalabs.com/blog/2018/03/20/html5-builds-are-now-in-open-beta/

 

Many plugins cannot be converted to HTML5.  The ones that can may not have been converted yet. 

 

There is no specific HTML5 documentation.  You just need to do File->Build->HTML5 and to control your screen size, it uses the same build.settings as desktop builds: https://docs.coronalabs.com/guide/distribution/win32Build/index.html#windowsettings

 

Rob



[TOPIC: post.html]
#5

conor1

[GLOBAL: userInfoPane.html]
conor1
  • Contributor

  • 166 posts
  • Corona SDK

This is stunning. Well done guys.

I ported my Tides app and it works. Uses xml as data, converts times and tide heights (sorry landlubbers) into screen coordinates and draws the beautiful sine curves. Horizontal scrolling works, text labels well placed on my tide curve.

 

Available to view at apptoonz.com/corona/irishtides/

I'll leave it there for a while. No intention of using this app in HTML5, but it's one hell of a test.

 

Obviously I stripped out plugins - appodeal, IAP etc. Won;t work anyway.

 

Brilliant, Brilliant, Brilliant.



[TOPIC: post.html]
#6

evanspro

[GLOBAL: userInfoPane.html]
evanspro
  • Contributor

  • 187 posts
  • Corona SDK

As noted in the announcement, https://coronalabs.com/blog/2018/03/20/html5-builds-are-now-in-open-beta/

 

Many plugins cannot be converted to HTML5.  The ones that can may not have been converted yet. 

 

There is no specific HTML5 documentation.  You just need to do File->Build->HTML5 and to control your screen size, it uses the same build.settings as desktop builds: https://docs.coronalabs.com/guide/distribution/win32Build/index.html#windowsettings

 

Rob

 

I must admit I didn't read to the end of the post as I was way too excited to try it first :D ... but I did understood that some plugin wouldn't work :)

 

My main issue is the "Out of memory error" that shows up, even after getting rid of all the plugins. I'll do more test to try to see where it's coming from.



[TOPIC: post.html]
#7

conor1

[GLOBAL: userInfoPane.html]
conor1
  • Contributor

  • 166 posts
  • Corona SDK

Update: irishtides works great on android/chrome and iphone5s/chrome.

Javascript fail on iphone5s/safari. 

 

No doubt lots to learn and bugs to squash. Looking forward to using this.

 

Thanks guys.



[TOPIC: post.html]
#8

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 26,697 posts
  • Enterprise

I've asked Engineering to look into this.

 

Rob



[TOPIC: post.html]
#9

roballison182

[GLOBAL: userInfoPane.html]
roballison182
  • Contributor

  • 181 posts
  • Corona SDK

Awesome work guys :)



[TOPIC: post.html]
#10

sbullock

[GLOBAL: userInfoPane.html]
sbullock
  • Contributor

  • 186 posts
  • Corona SDK

Stunning, awesome, brilliant. I just looked at conor1’s Irish Tides app on my iPad. I’m super impressed by the Corona team’s accomplishment. My thanks to all that worked so hard on this! Steve

[TOPIC: post.html]
#11

conor1

[GLOBAL: userInfoPane.html]
conor1
  • Contributor

  • 166 posts
  • Corona SDK

Rob,

 

Is it reasonable to assume this development should be usable for Facebook Messenger games? Maybe Facebook games in general (I'm not yet familiar with FB Games).

 

Conor



[TOPIC: post.html]
#12

gianmichele

[GLOBAL: userInfoPane.html]
gianmichele
  • Enthusiast

  • 43 posts
  • Corona SDK

Quick question: is this done through emscripten or is a custom html5 engine on export? How's performance on mobile?



[TOPIC: post.html]
#13

Develephant

[GLOBAL: userInfoPane.html]
Develephant
  • Corona Geek

  • 1,475 posts
  • Corona SDK

Hi,

 

Amazing stuff!  :D

 

-dev



[TOPIC: post.html]
#14

sbullock

[GLOBAL: userInfoPane.html]
sbullock
  • Contributor

  • 186 posts
  • Corona SDK

That’s a timely question Conor. I’m at the Game Developer Conference in S.F. and two of the very biggest pushes from the giants involve the word “instant”. Multiple presentations have been made over 2 days by both Google and Facebook pushing their new game tech. In a nutshell: Google’s “Instant Apps” are sub-10 Mb versions of full apps that can be played entirely in a device’s memory without an install. So players can tap a TRY IT button and be playing a game in seconds. Big game companies have been testing Instant Apps since last Fall. Now it is open to everyone. This isn’t pertinent to HTML 5; but it is worth everyone’s attention. Link: https://www.theverge.com/2018/3/19/17137088/instant-apps-game-developers-google-play-mobile-ads-agones-kubernetes Facebook’s “Instant Games” is their big focus and push. These are small footprint HTML 5 games played in Messenger. Facebook has had some large companies (i.e. Zynga, King, etc.) making the initial games for this space and the play numbers are enormous — even for Facebook. Here’s their main intro doc on this: https://developers.facebook.com/docs/games/instant-games . As an aside, both Cocos and Unity have made a big deal about their support for both Instant Apps (Google) and Instant Games (Facebook). This is certainly too early to try to connect this HTML 5 Beta to “Instant Games” — but it is cool to think that the potential might be here.

[TOPIC: post.html]
#15

roaminggamer

[GLOBAL: userInfoPane.html]
roaminggamer
  • Corona Geek

  • 7,673 posts
  • Corona SDK

For anyone who wants to see some Corona Content as HTML5 in action go here to see most of my game templates and some other stuff, running as HTML5
 

 

https://roaminggamer.github.io/RGDocs/pages/html5_tests/

 

 

**WARNING** If there is a pause after the download, give it a second.  I'm not sure why but some of these take a moment to start.  

 

It could be me, or it could just be a beta thing.  :)


Edited by roaminggamer, 20 March 2018 - 04:08 PM.

  • Develephant likes this

[TOPIC: post.html]
#16

Develephant

[GLOBAL: userInfoPane.html]
Develephant
  • Corona Geek

  • 1,475 posts
  • Corona SDK

Hi,

 

@roaminggamer works great for me. Awesome stuff!

 

-dev



[TOPIC: post.html]
#17

cyberparkstudios

[GLOBAL: userInfoPane.html]
cyberparkstudios
  • Contributor

  • 593 posts
  • Corona SDK

@roaminggamer very impressive!



[TOPIC: post.html]
#18

ymmtny

[GLOBAL: userInfoPane.html]
ymmtny
  • Enthusiast

  • 34 posts
  • Corona SDK

http://kwiksher.com/demo/kwik-the-cat/

I published my demo book made with Kwik. 12pages 25mb of .data file.  Perfect on chrome and Safari on Mac


  • roaminggamer and evanspro like this

[TOPIC: post.html]
#19

sbullock

[GLOBAL: userInfoPane.html]
sbullock
  • Contributor

  • 186 posts
  • Corona SDK

@roaminggamer - your stuff rocks!

Steve

[TOPIC: post.html]
#20

Sayhong's CTO

[GLOBAL: userInfoPane.html]
Sayhong's CTO
  • Observer

  • 29 posts
  • Corona SDK

Numeric Input Only textField has problem.



[TOPIC: post.html]
#21

roaminggamer

[GLOBAL: userInfoPane.html]
roaminggamer
  • Corona Geek

  • 7,673 posts
  • Corona SDK

Numeric Input Only textField has problem.

 

I think text fields in general are still WIP.  I tried some normal ones yesterday and they were oversized.



[TOPIC: post.html]
#22

vitaly1

[GLOBAL: userInfoPane.html]
vitaly1
  • Contributor

  • 212 posts
  • Corona SDK

Quick question: is this done through emscripten or is a custom html5 engine on export? How's performance on mobile?

Emscripten



[TOPIC: post.html]
#23

vitaly1

[GLOBAL: userInfoPane.html]
vitaly1
  • Contributor

  • 212 posts
  • Corona SDK

I must admit I didn't read to the end of the post as I was way too excited to try it first :D ... but I did understood that some plugin wouldn't work :)

 

My main issue is the "Out of memory error" that shows up, even after getting rid of all the plugins. I'll do more test to try to see where it's coming from.

I can try to fix the issue but I need a testcase or a link to this app



[TOPIC: post.html]
#24

Falcon777

[GLOBAL: userInfoPane.html]
Falcon777
  • Contributor

  • 440 posts
  • Corona SDK

I would appreciate if someone or Corona Team can give us example on the following. Thanks in advance.  :)

 

If your app makes calls to web servers, using API’s like network.request(), because of JavaScript cross-domain scripting rules, you can’t directly call REST type APIs. Instead you will need to write a local web script on the same domain that will make your REST API calls and then echo the returned data back to network.request().

 


  • plicatibu likes this

[TOPIC: post.html]
#25

gamebit.labs

[GLOBAL: userInfoPane.html]
gamebit.labs
  • Contributor

  • 224 posts
  • Corona SDK

+1




[topic_controls]
Page 1 of 7 1 2 3 »
 
[/topic_controls]