Error(s) cuasing 0x of item to be added into inventory

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
So basically i have been working on a script that messes with how the database is loaded, and it cuases specifically "gainitem" to give an unusable x0 of an item in the inventory.

Adding the items how they normally are through events works fine, however for what i need i need to be able to use the gain item function.

Any ideas on what could cuase this? I can provide snippits of code if it helps.
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
Changing how the database is loaded should not affect the gainItem function. My guess is that you just may not be calling it correctly.

Please show how you are doing the call. A screenshot is best, because if you just type it you could add a typo, or NOT add a typo that's actually there. It will also be helpful to see other things about the event that's attempting to add it (I'm assuming you're calling it through a script call within an event), so if that's the case please also provide a screenshot of the (full) event window.

When you run this, and execute the call and it adds 0 items, please hit F8 to open developer tools, then go to the Console tab. Let us know if there are any error messages there, and if there are, post a screenshot of it.
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
Changing how the database is loaded should not affect the gainItem function. My guess is that you just may not be calling it correctly.

Please show how you are doing the call. A screenshot is best, because if you just type it you could add a typo, or NOT add a typo that's actually there. It will also be helpful to see other things about the event that's attempting to add it (I'm assuming you're calling it through a script call within an event), so if that's the case please also provide a screenshot of the (full) event window.

When you run this, and execute the call and it adds 0 items, please hit F8 to open developer tools, then go to the Console tab. Let us know if there are any error messages there, and if there are, post a screenshot of it.
I know how to open the devloper menu and whatnot, it doesnt show any errors;

 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
I know how to open the devloper menu and whatnot
Because I don't know what you know and what you don't, I have to assume that you need to be told. Otherwise we waste a lot of time going back and forth just to get the info I need (I am saying this after JUST responding to a post where I asked for the same thing, and explained the steps to get there, and they provided the wrong screenshot). I can't guess at what each person knows who asks for help.


Please show anything in your script that affects items - probably not so much the loading of items from the database, but anything you've changed about the Game_Party class that affects items, anything about the item window or scene. Also any other plugins you've added that have anything to do with items or that screen.


And something else I'll get you to try, is to run the command as you've done it, and then run this command to see what it returns:
$gameParty.numItems($dataItems[3]);
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
Because I don't know what you know and what you don't, I have to assume that you need to be told. Otherwise we waste a lot of time going back and forth just to get the info I need (I am saying this after JUST responding to a post where I asked for the same thing, and explained the steps to get there, and they provided the wrong screenshot). I can't guess at what each person knows who asks for help.


Please show anything in your script that affects items - probably not so much the loading of items from the database, but anything you've changed about the Game_Party class that affects items, anything about the item window or scene. Also any other plugins you've added that have anything to do with items or that screen.


And something else I'll get you to try, is to run the command as you've done it, and then run this command to see what it returns:
$gameParty.numItems($dataItems[3]);



Doing some more messing around, Its not my script that is affecting how this works, i have tried it with both turning it on, and turning it off. same results, but what my plugin does is it basically just creates a database file from several smaller ones to allow for mods of sorts. now using the original items.json seems to not have any issues, but using my built items.json does;

Appearently you cant upload .json files so.
JavaScript:
[
null,
{"id":1,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers MP by 300 points.","effects":[{"code":12,"dataId":0,"value1":0,"value2":300}],"hitType":0,"iconIndex":218,"itypeId":1,"name":"Cheese","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:false>\n<GraphicPath:null>\n<GraphicName:null> \n<GraphicCalcVariable:176>","occasion":0,"price":300,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},
{"id":2,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers HP by 500 points.","effects":[{"code":11,"dataId":0,"value1":0,"value2":500}],"hitType":0,"iconIndex":226,"itypeId":1,"name":"Soda","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:true>\n<GraphicPath:/Images/Iconsets/>\n<GraphicName:Iconset> \n<GraphicCalcVariable:196>","occasion":0,"price":100,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},
{"id":3,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers MP by 300 points.","effects":[{"code":12,"dataId":0,"value1":0,"value2":300}],"hitType":0,"iconIndex":218,"itypeId":1,"name":"Good Bomb","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:false>\n<GraphicPath:null>\n<GraphicName:null> \n<GraphicCalcVariable:176>","occasion":0,"price":300,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0}
]

JavaScript:
[null,{"id":1,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers MP by 300 points.","effects":[{"code":12,"dataId":0,"value1":0,"value2":300}],"hitType":0,"iconIndex":218,"itypeId":1,"name":"Cheese","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:false>\n<GraphicPath:null>\n<GraphicName:null> \n<GraphicCalcVariable:176>","occasion":0,"price":300,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},{"id":2,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers HP by 500 points.","effects":[{"code":11,"dataId":0,"value1":0,"value2":500}],"hitType":0,"iconIndex":226,"itypeId":1,"name":"Soda","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:true>\n<GraphicPath:/Images/Iconsets/>\n<GraphicName:Iconset> \n<GraphicCalcVariable:196>","occasion":0,"price":100,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},{"id":3,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers MP by 300 points.","effects":[{"code":12,"dataId":0,"value1":0,"value2":300}],"hitType":0,"iconIndex":218,"itypeId":1,"name":"Good Bomb","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:false>\n<GraphicPath:null>\n<GraphicName:null> \n<GraphicCalcVariable:176>","occasion":0,"price":300,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},{"id":4,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers HP by 500 points.","effects":[{"code":11,"dataId":0,"value1":0,"value2":500}],"hitType":0,"iconIndex":176,"itypeId":1,"name":"Potion","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:false>\n<GraphicPath:null>\n<GraphicName:null> \n<GraphicCalcVariable:176>","occasion":0,"price":100,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},{"id":5,"animationId":41,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"Recovers MP by 300 points.","effects":[{"code":12,"dataId":0,"value1":0,"value2":300}],"hitType":0,"iconIndex":176,"itypeId":1,"name":"Magic Water","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:false>\n<GraphicPath:null>\n<GraphicName:null> \n<GraphicCalcVariable:176>","occasion":0,"price":300,"repeats":1,"scope":7,"speed":0,"successRate":100,"tpGain":0},{"id":6,"animationId":49,"consumable":true,"damage":{"critical":false,"elementId":0,"formula":"b.mhp / 2","type":3,"variance":20},"description":"Raises the user from the dead. (Recovers HP by half.)","effects":[{"code":22,"dataId":1,"value1":1,"value2":0}],"hitType":0,"iconIndex":176,"itypeId":1,"name":"Stimulant","note":"<ModID:1993184732974y8274382asda22>\n<UsesCustomGraphic:true>\n<GraphicPath:/Images/Iconsets/>\n<GraphicName:Iconset> \n<GraphicCalcVariable:176>","occasion":0,"price":500,"repeats":1,"scope":9,"speed":0,"successRate":100,"tpGain":0}]

neither of these files prompt errors in the console when using them as the file that the game reads items from, but when using Build_Items.json it cuases the errors shown.
 
Last edited:

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
So the console log where you did the gainItems then numItems and it showed correctly - was that with your script turned on, or off? Because it looks like it worked there.

Is this script, changing what files are loaded, the ONLY change you have made? Have you made changes to any of the Game_Party functions or any of the windows?

Please show your script, in full.
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
So the console log where you did the gainItems then numItems and it showed correctly - was that with your script turned on, or off? Because it looks like it worked there.

Is this script, changing what files are loaded, the ONLY change you have made? Have you made changes to any of the Game_Party functions or any of the windows?

Please show your script, in full.
My function has actually only edited two functions related to how graphics are loaded, when testing the "gainItem" function it had the same results both times when both on and off.

The only time it works again is when using an unmodified items.json file.
when i used the .json file that this plugin builds (as pasted above) it breaks.

JavaScript:
/*:
 * @plugindesc Hardcore breaks out how the engine loads files, Parts of this system are modded plugins to allow for external asset loading see credits for plugins used.
 * @version 1.0
 * @author Poppie360
 *
 * @help
 * How to use the mod system;
 * Load map;
 * Add Item;
 * Remove Item;
 *
 * @param Test
 * @desc This is just to make sure it works.
 * Default: 120
 * @default 120
 */
var ModSystem = ModSystem || {};  // namespace for your plugins, equal to itself if already defined or an empty object otherwise
ModSystem.ResourceHandling = {};

(function($) {

    //=========================================================================================================================================
    //Declared Variables
    //=========================================================================================================================================

    const fs = require('fs');
    const path = require('path');

    var TempVar;
    var AnotherTemp;
    var TempArray = [];

    var flipper = 1;

    //=========================================================================================================================================
    //Internal functions
    //=========================================================================================================================================

    CreateDatabase = function(){
        BuildItems("Actors");
        BuildItems("Armors");
        BuildItems("Classes");
        BuildItems("CommonEvents");
        BuildItems("Enemies");
        BuildItems("Items");
        BuildItems("Skills");
        BuildItems("States");
        BuildItems("Troops");
        BuildItems("Weapons");
    }

    BuildItems = async function(Name) {
        //get all Item Files
        var Thingie = [];
        var Thing = [];
        var Things = [];
        var Items = [];

        Thing = await ReadAndAdd1("/Mods/Game Load Files/");

        for(var i = 0; i < Thing.length; i++){
            Thing[i] = "./Mods/Game Load Files/" + Thing[i];
        }

        for(var i = 0; i < Thing.length; i++) {
            TempVar = await ReadAndAdd2(Thing[i]);
            Thingie.push(JSON.parse(TempVar));
        }

        AnotherTemp = "./data/" + Name + ".json";
        TempVar = await ReadAndAdd2(AnotherTemp);
        Things.push(JSON.parse(TempVar));

        for(var i = 0; i < Thingie.length; i++) {
            AnotherTemp = "./Mods/Mod Data/" + Thingie[i].Id + "/Data/" + Name + ".json";
            TempVar = await ReadAndAdd2(AnotherTemp);
            Things.push(JSON.parse(TempVar));
        }

        for(var i = 0; i < Things.length; i++) {
            Items = Items.concat(Things[i]);
        }

        Items = Items.filter(checkNull);
        var QuickThing = JSON.stringify(Items).substr(1);
        QuickThing = "[null," + QuickThing;
        Items = JSON.parse(QuickThing);

        for(var i = 1; i < Items.length; i++) {
            Items[i].id = i + 1;
        }

        fs.writeFileSync("./data/Build_" + Name + ".json", JSON.stringify(Items));
    };


    ReadAndAdd1 = function(Directory = "."){
        var TrashPile = [];

        Directory = path.join('.', Directory)

        return new Promise((resolve, reject) => {
            fs.readdir(Directory, (err, files) => {
                TrashPile = files.filter(file => file.includes(".json"))
                resolve(TrashPile);
            });
        })
    }

    ReadAndAdd2 = function(Directory = "."){
        var TrashPile;

        Directory = path.join('.', Directory)

        return new Promise((resolve, reject) => {
            fs.readFile(Directory, 'utf8', (err, jsonString) => {
                TrashPile = jsonString;
                resolve(TrashPile);
            });
        })
    }

    //=========================================================================================================================================
    //Changed/added core functions
    //=========================================================================================================================================

    //New graphic loader
    ImageManager.loadImageThing = function(Path, filename, hue) {
        return this.loadBitmap(Path, filename, hue, true);
    };

    //Overwrite old functions
    ImageManager.loadSystem = function(filename, hue) {
        if ($gameVariables.value(2) != 0) {
            return this.loadImageThing($gameVariables.value(3), $gameVariables.value(4), hue, false);
        } else {
            return this.loadBitmap('img/system/', filename, hue, false);
        }
    };

    Window_Base.prototype.drawItemName = function(item, x, y, width) {
        width = width || 312;
        if (item) {
            var iconBoxWidth = Window_Base._iconWidth + 4;
            this.resetTextColor();
            //Set icon information (how to do stuff "$gameVariables.setValue(ID, VALUE);" "$dataItems[i].meta.UsesCustomGraphic")
            if (item.meta.UsesCustomGraphic != "false"){
                $gameVariables.setValue(2, 1);
                $gameVariables.setValue(3, ("Mods/Mod Data/" + item.meta.ModID + item.meta.GraphicPath));
                $gameVariables.setValue(4, item.meta.GraphicName);
                this.drawIcon(Number(item.meta.GraphicCalcVariable), x + 2, y + 2);
                $gameVariables.setValue(2, 0);
            } else {
                this.drawIcon(item.iconIndex, x + 2, y + 2);
                $gameVariables.setValue(2, 0);
            }

            //Old method of icon drawing "this.drawIcon(item.iconIndex, x + 2, y + 2);"
            this.drawText(item.name, x + iconBoxWidth, y, width - iconBoxWidth);
        }
    };


    window.onload = function() {
        CreateDatabase();
        SceneManager.run(Scene_Boot);
    };

    //=========================================================================================================================================
    //Custom functions that let me do stuff that in this script
    //=========================================================================================================================================

    Checker = function(path) { var path = '.' + path; fs.access(path, function(error) { if (error) { return false; } else { return true; } } ) }

    checkNull = function(Value) { return Value != null; }

    //=========================================================================================================================================
    //public functions commands
    //=========================================================================================================================================

    $.ChangeItemByName = function(Name, Amount){
        //finish when not broken
    }

})(ModSystem.ResourceHandling);
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
Oh - I thought you meant it worked when the plugin was disabled. So maybe it IS something to do with your file then.

Your variable names are almost identical, which makes everything pretty confusing.

Can you just walk through the logic of how this works? What it does to items.json when it finds a mod? What's stopping it from adding the same things over and over again (and in this case the items would really get out of whack)?

Is it JUST items that has this problem, or is it all database files? What if you try the same thing with weapons or armors? Can you try party members?
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
Oh - I thought you meant it worked when the plugin was disabled. So maybe it IS something to do with your file then.

Your variable names are almost identical, which makes everything pretty confusing.

Can you just walk through the logic of how this works? What it does to items.json when it finds a mod? What's stopping it from adding the same things over and over again (and in this case the items would really get out of whack)?

Is it JUST items that has this problem, or is it all database files? What if you try the same thing with weapons or armors? Can you try party members?
So the logic of it is actually quite simple of how to compiles a database from smaller ones;
It first finds all GLF .json files (game load files, a custom structure, basically just lets my mod system know how to go about loading the mods.)

when dealing with databases, it simply just uses the GLF to generate a path to the mod data, grabs the database files from that mod. it then takes that information along with the infromation from all the other mod files and builds it into one large database. (as of right now the database is only 6 items long as i am still working out kinks given by this thread.)

it does this for the following databases;
Actors, Classes, Skill, Items, Weapons, Armors, Enemies, Troops, States, CommonEvents

Once it has the unformatted database made, it simply goes through, removing all null enties, making sure the IDs dont conflict by assigning each item an id based on its position in the json array, and the final step it adds a null to the begining of the database just like the unmodified ones have. (it doesnt really affect how the engine handles it either way, it just makes it so calling the elements is different, but i changed it to fit with how its supposed to be)

the game engine has no problems at all loading information from these databases or even starting up, no errors whatsoever and it can even add modded items and all that to the inventory and the engine reconizes it in the console.

But when you add it the menu has this issue...Just did some more testing and it seems that giving items through events is also broken.

why would the game engine have such a problem working with data from formatting and content wise normal database?

edit; also just tried adding a modded actor into the party, works perfectly fine.
weapons work fine, its only items
 
Last edited:

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
There is nothing you're doing to items that you're not also doing to every other file though, so if you have the issue with items, you should also have the issue with weapons and armors and actors.

The position in the json array is what determines the item numbers. What have you got in place to keep them in the correct positions? How do you know if a mod is added, what was item #3 does not become item #6 if one of the mod files has additional items in it?

Does your plugin do all its stuff before loadNormalDatabase is called? What do you see if you put $dataItems into the console? Is it the full item list, including the original items.json plus anything new in build_items.json?
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
There is nothing you're doing to items that you're not also doing to every other file though, so if you have the issue with items, you should also have the issue with weapons and armors and actors.

The position in the json array is what determines the item numbers. What have you got in place to keep them in the correct positions? How do you know if a mod is added, what was item #3 does not become item #6 if one of the mod files has additional items in it?

Does your plugin do all its stuff before loadNormalDatabase is called? What do you see if you put $dataItems into the console? Is it the full item list, including the original items.json plus anything new in build_items.json?
Well basically the mod system takes the orginonal database, and just shoves the entries from the modded ones at the end of that and writes it to a new file that the game looks at when loading stuff for the game.

(the downside is that when changing mods you have to boot the game once, let it compile the mods, and then restart it.)

And the engine works fine with weapons and actors when working with the modded database. basically the .json is a normal database, how i intend on making getting items work when this is settled is by specifying the mod you are looking at, and the item name you are looking for.

But i cant do that until the issues with items are fixed.

and yes i have tried it let me show you the results;

original Items.json has 3 items
Items.json from the mod has 3 items

when the mod system does its thing;

a merged database has the items from both.

(ignore similar items for each, when making the test mod i pretty much changed like a few things here and there than copied the database files.)

as you can see it has no problems retreiving the data.

But why if all the other databases work perfectly as expected, does items just kinda die?
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
crazy! I can't see any reason why it would be different.

We know it adds the item, because it returns the correct number when you check how many are held. I suppose just to be absolutely certain, you could do a $gamePlayer._items in the console just to see what's in the array, but I expect it will be correct.

At this point, I'd be setting debug points and just tracing the code through as it goes, to see what's going on.
 

gstv87

Veteran
Veteran
Joined
Oct 20, 2015
Messages
1,903
Reaction score
911
First Language
Spanish
Primarily Uses
RMVXA
that shot of the item window reading 0...... did you refresh that same window after adding the 1 potion?

....because if that's not the default window, and/or you didn't add the item via the default method, and/or you didn't return control of the update to the window itself after adding the item, you might be having an update error, as shown by the return of the correct result via the console command but not the window: clearly the value printed out by the window is not the same one being returned by the console.
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
crazy! I can't see any reason why it would be different.

We know it adds the item, because it returns the correct number when you check how many are held. I suppose just to be absolutely certain, you could do a $gamePlayer._items in the console just to see what's in the array, but I expect it will be correct.

At this point, I'd be setting debug points and just tracing the code through as it goes, to see what's going on.
I am not sure what to do about that, and i did that before and it was just the normal; [{itemID,amount},] stuff. the error doesnt persist when using my plugin but having it read from the normal items.json file.


that shot of the item window reading 0...... did you refresh that same window after adding the 1 potion?

....because if that's not the default window, and/or you didn't add the item via the default method, and/or you didn't return control of the update to the window itself after adding the item, you might be having an update error, as shown by the return of the correct result via the console command but not the window: clearly the value printed out by the window is not the same one being returned by the console.
The window is the default one, even when running the engine with no plugins but reading from the file the error persists.
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
Window_ItemList just uses $gameParty.numItems(id)

Where are you doing the call to $gameParty.gainItem(...)? Can you post a screenshot of that?

If you're ready to pull your hair out, you're welcome to zip up your project and send to me to take a look - just make it as small as possible (a demo project where the error can be reproduced, minus the audio folder as it's massive), and make it easy for me to reproduce the problem.
 

Poppie360

chocobo wrangler
Veteran
Joined
Feb 28, 2018
Messages
175
Reaction score
51
First Language
English
Primarily Uses
RMMV
Window_ItemList just uses $gameParty.numItems(id)

Where are you doing the call to $gameParty.gainItem(...)? Can you post a screenshot of that?

If you're ready to pull your hair out, you're welcome to zip up your project and send to me to take a look - just make it as small as possible (a demo project where the error can be reproduced, minus the audio folder as it's massive), and make it easy for me to reproduce the problem.

It works randomly now? i havent changed anything about the project and suddenly...the error is gone? I have no idea what happened to cuase this witchcraft to happen, but it seems to be gone, i am going to now reload the project over and over again to see if anything changes;

(first time luanching) First test; just trying it through an event that called the function


(first time luanching) second test, adding it through the console


(second time luanching) third test, after using the event adding a different item with my own function from my plugin:



I have no logical explination, i am left completely dumbfounded, all i had done was.
close the editor, reluanch the editor...and suddenly it was working again. can anyone else at least provide some speculation as to why it did so?
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
38,453
Reaction score
12,014
First Language
English
Primarily Uses
RMMV
I can't imagine it just started working when you did absolutely nothing. There must have been something you changed. Maybe just saving in the editor, or in the script, where you might not have before. Hard to tell because we can't see where you were calling it.
 
Last edited:

gstv87

Veteran
Veteran
Joined
Oct 20, 2015
Messages
1,903
Reaction score
911
First Language
Spanish
Primarily Uses
RMVXA
the only way to update the number (the actual digit) on the item window (by default) is by drawing the set of icon, name and number, which is the draw item method on the item window itself.
WHICH, is called by the refresh method.
WHICH, is itself called by the item scene through the change of focus to the item window itself, on a scene composed by an item window, a category window and a help window.

upon a change of category, or a modification of any item, on the scene, the item window is updated.
if no change of items was triggered from the scene, then the chain of updates is broken.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

My kitty still young (3-4 months), I think I could teach her some funny tricks... like: "Play dead-ly good music for my games"
Here's a quality DPS class idea: The Beekeeper, who uses the "Bees!!" skill to attack and poison enemies.
Please don't create long, boring cutscenes in which characters do nothing but stand around talking.
What if I took a lesson from Half Minute Hero? Let the player get dumb powerful each area, but reset them down to just slightly stronger than before for the next map?
Been averaging 2-3 hours sleep for almost a month now. Starting to space out all the time ^^;

Forum statistics

Threads
94,269
Messages
919,516
Members
123,988
Latest member
inazumaelevenspain
Top