[EDIT] I got it!
It was a typo ^^'''
Instead of this:
extinguisher: JSON.parse(Eli.Structure.Param.myStructure["BackgroundOnOff"])
It has to be:
extinguisher: JSON.parse(Eli.Structure.Parameters.myStructure["BackgroundOnOff"])
It was a typo ^^'''
Instead of this:
extinguisher: JSON.parse(Eli.Structure.Param.myStructure["BackgroundOnOff"])
It has to be:
extinguisher: JSON.parse(Eli.Structure.Parameters.myStructure["BackgroundOnOff"])
Hi people!
A while ago I have asked here how can I properly set a Struct parameter. People answer me nicely and provide me a lot of solutions, that in the time, I ended using.
But, now, I have liked the "old" way with more extensive work.
I manage to make the struct work.
But I'm having a problem, that I can't say if it is something that I made wrong or it is just how Visual Studio Code handles things.
I want to be capable of this to access my properties in visual studio code(In this example I manage to do it):
But in this example, it's not working, don't know why.
What I'm missing?
[EDIT]The whole "plugin" here:
A while ago I have asked here how can I properly set a Struct parameter. People answer me nicely and provide me a lot of solutions, that in the time, I ended using.
But, now, I have liked the "old" way with more extensive work.
I manage to make the struct work.
But I'm having a problem, that I can't say if it is something that I made wrong or it is just how Visual Studio Code handles things.
I want to be capable of this to access my properties in visual studio code(In this example I manage to do it):
But in this example, it's not working, don't know why.
What I'm missing?
[EDIT]The whole "plugin" here:
JavaScript:
/*:
@plugindesc v1.0 -
@author Eliaquim or Rakuen Zero
@help
Made and tested with Rpg Maker Mv 1.6.2.
Always have a backup from your project!
@param MyStructure
@desc This is a structure
@default {}
@type struct<Structure1>
*/
/*~struct~Structure1:
@param BackgroundOnOff
@type boolean
@desc
@default true
*/
"use strict"
var Imported = Imported || {};
Imported.Eli_Structure = true;
var Eli = Eli || {};
Eli.Structure = Eli.Structure || {};
Eli.Structure.Parameters = PluginManager.parameters('Eli_Structure');
Eli.Structure.Param = Eli.Structure.Param || {};
Eli.Structure.Param = {
myStructure: JSON.parse(Eli.Structure.Parameters["MyStructure"])
};
Eli.Structure.Param.myStructure = {
extinguisher: JSON.parse(Eli.Structure.Param.myStructure["BackgroundOnOff"])
};
Last edited:

