Page 1 of 3

love.js standalone player

Posted: Wed Dec 08, 2021 10:27 am
by ivan
The standalone version of the love.js player allows you to run Love2D game on the web. This player is based on the previous work of Davidobot and Tanner Rogalsky using Emscripten.

Repository:
https://github.com/2dengine/love.js

Live demos:
https://2dengine.com/arena
https://2dengine.com/superchains
https://2dengine.com/collisions
https://2dengine.com/commando

What's new:
- Cleaned up the frontend
- Refactored the game.js file.
- Cookie consent dialog for GDPR compliance
- New and cool looking loading screen
- Fixed the cross-origin issue on Apache with a simple .htaccess file

Todo:
- Better memory allocation

Re: love.js standalone player

Posted: Wed Dec 08, 2021 6:35 pm
by gianmichele
This works incredibly well! I think it should be included as an official platform.

Re: love.js standalone player

Posted: Wed Dec 08, 2021 10:33 pm
by ivan
Thank you. Most of the credit goes to Davidobot and Tenner.
Please note that there are some known issues in terms of the memory management so it's still not worthy of an official release. Perhaps love.js may take off in the future if more people get involved.

Re: love.js standalone player

Posted: Thu Dec 09, 2021 5:22 am
by alejandroalzate
pleaseee we wanna an web port
take ur time but realase it

Re: love.js standalone player

Posted: Thu Dec 09, 2021 8:43 am
by ivan
alejandroalzate, the full source code is available in the repository mentioned above.
If you want to see more development and updates then please consider supporting Davidobot and Tanner.

...or help me out by supporting 2dengine and our games

Re: love.js standalone player

Posted: Fri Dec 10, 2021 1:34 pm
by ivan
Just pushed another update to the player.
It now shows a red "X" symbol when an error occurs.
I have also addressed the Emscripten "Expected 'application/wasm'" issue using an .htaccess file

Re: love.js standalone player

Posted: Fri Dec 17, 2021 9:02 pm
by gianmichele
This is also nice for quick testing without a web server

https://servefolder.dev/

Re: love.js standalone player

Posted: Fri Dec 17, 2021 11:15 pm
by ivan
Just pushed another update that forces compatibily mode on mobile devices.

Re: love.js standalone player

Posted: Sun Aug 07, 2022 3:48 pm
by Popolon
Thank you very much for you work.

I have the following error in firefox console (translated from my language version):

CanvasRenderingContext2D is obsolet Use tabs.captureTab API instead for extensions https://developer.mozilla.org/fr/docs/M ... captureTab

A round circle turn, but the application doesn't work.

Re: love.js standalone player

Posted: Sun Aug 07, 2022 4:30 pm
by Popolon
managed to make it work, under nginx, with the following rules in server{} section:

Code: Select all

  add_header Cross-Origin-Opener-Policy "same-origin";
  add_header Cross-Origin-Embedder-Policy "require-corp";
  add_header Set-Cookie "Path=/; HttpOnly; Secure";
Thanks a lot !!!!