Jump to content

Import third party library


Davaaron
 Share

Recommended Posts

Hi,

 

I'd like to use a scroll view list (https://github.com/mattcolman/phaser-list-view) but I don't know how to import it. I'm developing under Phaser Editor (version 1.5.1 I guess), and as far as I know, it uses Javascript 5.

The phaser-list-view.js is copied into my project and included via the script (src) tag. On the official website (github), the class ListView is imported with import { ListView } from 'phaser-list-view.js'. But this kind of statement does not seem to work in Phaser Editor.

 

Can someone help me quickly?

 

Link to comment
Share on other sites

  • 1 month later...

Hi @Davaaron

 

Phaser Editor supports JavaScript 6, but you should disable the content assist (it only works for JS 5), or install the Typescript IDE: https://phasereditor2d.com/blog/2017/04/welcome-typescript-ide

However, you can ask the phaser-list-view developers how to use their lib in JS5. It should be possible, I guess you can open an issue in their repo about it.

 

Link to comment
Share on other sites

Hi,

I decided to take kinematic scrolling which was developed by a user here. However, I found a way to tell the editor to take JavaScript 6, but Im not sure how to install it (taking the libs into the editor). As the project is, meanwhile, too big, I will stick to JS5.

 

Edit: Is there a way to contribute to the Phaser Editor? Wouldn't it be awesome to be able to configure the physics in the canvas or something like that (collision detection: category bits, mask bits, category group)?

Link to comment
Share on other sites

Yes, you can contribute to the editor, the source code is on GitHub:

https://github.com/PhaserEditor2D/PhaserEditor

However, right now we are working on the v2, that is the future of the editor. This version is not ready yet for collaboration, first I have to release a Beta and there are some decisions related to the Canvas editor that I have to make, like replace JavaFX scene by another toolkit.

Just keep in touch

Thanks!

 

Link to comment
Share on other sites

Hi

v1 is not going to die, it will be updated until clients request it. But for new users, it is the better to wait until v2 if they plan to work with Phaser 3.

JavaFX is not out of date, but it is not good for pixel art, there is no way to disable the interpolation and antialiasing of the graphics, at least not a straight way, there are some workarounds but it is not clean. Anyway, I like the idea of paint everything myself because I have more control over everything.

 

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...