So can anyone tell me why someone would want plugin commands over an actual script command?
I mean I don't get why plugin commands are even a thing. They don't add anything special and they can't be used everywhere script calls can be. So what's the point with them anyways?
Ya I suppose that makes sense, it's just the exact opposite of the standard set by previous rpg makers.
And they'll add a lot of function call bloat the more plugins you get that add them, if you have 30 plugins all aliasing or hooking the same function. I don't know if that bloat will be bad or not I don't know how fast JavaScript is compared to other languages like ruby or lua.
Yeah, we have been discussing that on other threads. It makes a big relative difference (but not big enough to cause lag).
I'll start adding a param on my plugins for people to decide if they want to use plugin commands or not.
JavaScript is much faster than Ruby. Also, your version of Game_Interpreter.pluginCommand should return, if it matches with your command, so it won't have to call all aliases methods, but only as many as needed. I wouldn't use plugin commands for stuff, that's executed every few frames, anyway.
Oh ya I didn't think about the return, and good ruby was slow I knew lua was faster than ruby but wasn't sure how java compared.
So I'm not the only one who thought of the impact awesome I thought maybe I was understanding something wrong. But if it's not a laggy impact then I suppose it's not horrible.
I guess I'll just accept it as the new practice. It's just weird after playing with dog makers since xp lol.
By the way handy link in your signature.
Just a thought on proformance and the endlessly hooked function would it be worth it to try and get something wrote up for the MVCommons that handles this without hooking the same function?
Like say
MVCommons.addPlugin(name, func) {
_data[name ] = func;
}
And then it would just call
_data[name](args);
Or would it be pointless?
try this... call a script call of a plugin...
remove the plugin because somehow you decided to not using it. (let's say it cause lag / incompatible with other plugin)
crash... (you need to edit ALL your event and remove that script call).
vs
call a plugin command of a plugin
remove the plugin because of same reason as above.
work fine without crash.
so i would prefer using plugin command as user.
Us I suppose, but I'd rather the error so I can know which events have useless data in them.
But good thought anyways I wouldn't of even thought about that.
If 2 plugins share the same command, i'm inclined to say that they are incompatible. That's why i add a plugin parameter to all of my plugins, that can be used to modify the commands (i probably should disable them entirely, if the parameter is empty, though).
I can't really think of a convincing example where two compatible plugins would use the same command. You have a point there 🙂
I would still call the original method though. Just feels better.
I always call the original method too.