Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Write a plugin porting guide #12

Open
FairlySadPanda opened this issue Sep 16, 2019 · 0 comments
Open

Write a plugin porting guide #12

FairlySadPanda opened this issue Sep 16, 2019 · 0 comments

Comments

@FairlySadPanda
Copy link
Owner

Plugins need modification to work. A good plugin that is being used in this engine needs:

  1. Any global variables assigned to the window object
  2. All modifications to classes defined in declaration merges, either in file or in an independent d.ts file
  3. All modifications to game objects that remain in state on saves and loads (that is, that uses JsonEx) using the replacement process for saving and loading objects on load (gameLoadInput options inside class files)
  4. CommonJS requires or import statements for any imported classes
  5. Manipulation of export modules when redefining constructors (please note: please stop redefining constructors. It's a pain in the ass.)

We need a good documentation guide to cover this. We want to encourage plugin writers to use ES6, rather than TS, as TS would be too much work to learn for most indie JS devs who are not being paid.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant