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

Console error on plugin integration #3

Open
rowild opened this issue Feb 23, 2016 · 2 comments
Open

Console error on plugin integration #3

rowild opened this issue Feb 23, 2016 · 2 comments
Labels

Comments

@rowild
Copy link

rowild commented Feb 23, 2016

Even though the plugin works fine, the implementation throws this error in the console:

Kiwi.PluginManager: Plugin 'Text' appears to be invalid. No property with that name exists on the Kiwi.Plugins object or the Plugin is not registered. Check that the js file containing the plugin has been included. This plugin will be ignored #plugin

The file is included like this:

var gameOptions =  {
  plugins: [ "Text" ]
}

var game = new Kiwi.Game('game', 'Game with multiline textboxes', null, gameOptions)
@rowild
Copy link
Author

rowild commented Feb 23, 2016

Rewriting like this:

// On top of the file
Kiwi.Plugins.Text =  {};
[...]
// adding minimumKiwiVerison
Kiwi.Plugins.Text.minimumKiwiVersion = "1.3.0";
Kiwi.PluginManager.register(Kiwi.Plugins.TextExtended);

Kiwi.Plugins.Text = (function()...

makes it work, but the console spits out a different, strange warning again:

Kiwi.PluginManager: 'TextExtended' is missing the minimumKiwiVersion property. It is unknown whether 'TextExtended' will work with this version of Kiwi #plugin

...even though it was explicitly added...

But I guess that's ugly (object vs. function)...

@BenjaminDRichards
Copy link
Contributor

I'm sure I've got a correct template sitting around somewhere. If we release another version of Text before we fold it into the core library, we'll be sure to modify that.

Tagging this as a bug, because it shouldn't do that.

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

No branches or pull requests

2 participants