I've moved this thread to Learning JavaScript. Please be sure to post your threads in the correct forum next time. Thank you.
MV doesn't use scripts, they use plug-ins. I assume you meant plug-in call instead? As it is, I put your thread under the learning javascript thread so someone in the know about the command can tell you the JavaScript command that you need.
It won't be a plugin call - it'll be a script call.
Whenever you have something that you can do via event commands, and you want to do it with a script call instead, head to the rpg_objects.js file and search for the event command exactly as it appears on the button in the event editor.
The reason what you've tried won't work is that you're using RGSS code with Ace classes and functions, and MV uses Javascript and its classes and functions are named differently, so your code isn't going to work.
Basically I wanted to pull in two game variables, one for the event ID and another for which character index I needed for the event (they all use the same character sheet). I got that part sorted, but you're saying there's no call available to set event graphics? Is there another way I'm just overlooking or is this something a plugin would need to be written to do?
And thanks for your help.
Who are you talking to? I told you to search through rpg_objects.js for the text that's on the event graphic change command, and to see how that does it. I couldn't tell you what the event text was (so what to search for), or how to do it, because I wasn't at my computer. But I thought my instructions were pretty simple.
Ok, so in the rpg_objects.js file this is the relevant portion.
Game_Character.prototype.processMoveCommand = function(command) {
var gc = Game_Character;
var params = command.parameters;
switch (command.code) {
case gc.ROUTE_CHANGE_IMAGE:
this.setImage(params[0], params[1]);
break;
Still not sure what the the call I need is. I tried something like this,
$gameMap.events[ID].setImage ("characterName", characterIndex)
but still no dice.
Does your characterName and characterIndex exist?