Tsukihime 1,489 Posted May 14, 2012 (edited) This script is outdated and will not be supported. For individual equips and items, consider using Instance Items The rest of the features will likely be implemented as part of the instance items framework, or a separate set of scripts. FP Inventory System Author: Tsukihime Overview This script replaces the default inventory system to use a more sophisticated way of managing items. Features Currently I've implemented the following built-in individual equips and items built-in equip and item weights (no use on their own) customizable max stacks and max limits for all items (by item type) Unlimited stack sizes proper inventory tracking: if you use an item, it's the item you selected, from the specific stack Usage Just copy into project. By default, all items have stack sizes of 99 and all equips have stack sizes of 1. In this demo version, you can specify individual item weights and stack sizes by tagging items and equips with <stack: 23> <weight: 4> <limit: 100> Weights don't do anything for now, but logic will be added to check whether you can carry the item or not. Weights will be used at the individual item level, stack level, and inventory level as well. screenshots You can customize item stack sizes for each item All equips are treated independently. You can see two instances of the same type of equip having different attributes This is a preview of the equip system I am developing, which requires this inventory system. Works fine with Ace shop system (as it should, since I'm not changing the weapon/armor/items themselves) Silly item stack sizes! Download Script: http://db.tt/RKw6FHes Compatibility Updates Kread-EX's Runic Enchantment - compatibility scripts added to directly add runes to equips and remove runes from inventory rather than fetching from database. Edited January 16, 2014 by Tsukihime 9 Share this post Link to post Share on other sites
Chaos17 31 Posted May 14, 2012 Hi, I've got this bug : It happens even when I remove Yanfly Shop options script. Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 15, 2012 (edited) Fixed. The error occurs when you try to get the number of items that are currently in the inventory, but there are none (and thus no slot exists for that item ID). Try again Edited May 15, 2012 by Tsukihime Share this post Link to post Share on other sites
Chaos17 31 Posted May 15, 2012 Good, it works. May I suggest you for your futur feature that you show the lvl of the weapon like in Formar script please ? Look foward to see more of your script. Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 15, 2012 (edited) You mean like this? Anyways the script is written...I'm just not sure how much customization details I should provide. There's a lot of parameters that you could possibly modify, like exp to level, parameter increase, price modifications based on equip stats, etc. Edited May 15, 2012 by Tsukihime Share this post Link to post Share on other sites
Chaos17 31 Posted May 15, 2012 (edited) Yes, like this. For the customisation is part... That's difficult because sometime too much information will not be easy to follow. Maybe you can set something like this in script so the maker can change or add thing if he likes : - Default forumla for exp curve - Default formula for param curve - Default formula for price curve Then you may let the maker also use notetag so he will have full control by choosing which equipement he wants to level up or not. Yeah, making all equipements level up by default isn't a good idea imo. This way, you let the maker decide if he want to keep the default formula you made or he can change it by himself. Though, i don't don't if my ideas are good since I am not good with math... Edited May 15, 2012 by Chaos17 Share this post Link to post Share on other sites
Dark Horseman 93 Posted May 15, 2012 (edited) I tried to run this with Yanfly's Equip Engine and Kread's Limited Item Script and received a line 574 Error (this was expected though with the script conflicts). When I removed those two, your script was working properly distributing stacks and individual instances of each weapon/item. While I was equipping, however, I noticed some of the stats got muddled up for the same item. They would alter slightly for each individual instance of the same item. (Was the stat randomized for testing purposes?): From the image, I have 6 of the same weapon all giving +12 MAT. It properly displays "this will increase MAT by 4" but oddly will increase the ATK as well. Further, each individual ring has its own random ATK, one gives none, another gives +7 and yet another gives +13. The MAT will stay at 12 but the ATK stat becomes sporadic. Edited May 15, 2012 by Dark Horseman Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 15, 2012 (edited) Line 574 is for processing "nil" equipping, or basically when you're removing an item. Not sure what might have triggered it since all it does is assign nil. I couldn't find the limited item script (what does it do?) And ya, I threw in a stat randomizer for testing whether a deep copy of the object was made lol Previously there was a bug where everytime you took off your equip, it would get a power up, and before that when I didn't realize they all referred to the same equip, they all got the same power up Edited May 15, 2012 by Tsukihime Share this post Link to post Share on other sites
Dark Horseman 93 Posted May 15, 2012 (edited) It's basically a Suikoden item system where you have to equip items to use them. It adds more flavor to battles by not allowing item spam and prevents item hoarding from the player. http://grimoirecastl...ctor-inventory/ So far no other issues with the script then. I'll try randomizing stack quantities later. Edited May 15, 2012 by Dark Horseman Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 15, 2012 (edited) k it should be fixed. Game_Party#has_item? actually took two arguments (the item, as well as a include_equip boolean). I was just missing that boolean. Edited May 15, 2012 by Tsukihime Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 16, 2012 Should work with ace equip engine now. Share this post Link to post Share on other sites
Chaos17 31 Posted May 17, 2012 Should work with ace equip engine now. No, it isn't working with Ace equip engine, still the same error. The version of the script is : Version: 1.1 Date: May 14, 2012 Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 17, 2012 I don't know what the issue is unless I can reproduce it. Ace Equip Engine works fine for me when I try to equip some items, remove some items, etc. Share this post Link to post Share on other sites
Chaos17 31 Posted May 17, 2012 (edited) I've found the problem, the nil error happen when I put tag in the note actor for adding new slots. This for example : <equip slots> Weapon Headgear Bodygear Shoulders </equip slots> Again, I didn't have this problem with the old version of your script. Edited May 17, 2012 by Chaos17 Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 17, 2012 It really was slot_id being nil. Ok I added two words to check for it and now it should be fine. Try it again 1 Share this post Link to post Share on other sites
Broken Blade Muramasa 0 Posted May 20, 2012 I really like your system. And seems promising what you've in mind. And I was wondering, if you could give it decimals support, for item weights I mean (for other stuff it's like... weird hahah). Also for zero-weight items (quest/important items, as no one likes to drop stuff for that super-heavy key of doom). I did some tests with it and sadly I didn't made it. So I hurried back here >_<. I will be testing with it anyway, and the rest of your scripts, since I like them, cheers, Muramasa Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 20, 2012 (edited) Decimal weights added. Default weight for key items can now be customized (default 0) Default weight for regular items is still 1 (can also be customized) Weight display is also available. It can be customized, although you have to know some ruby syntax cause I use formatted strings. Items that cannot be stored are currently automatically discarded. I haven't thought about how I should handle discard items (well, I have the variables and methods set up, I just didn't implement it) Edited May 20, 2012 by Tsukihime Share this post Link to post Share on other sites
Shablo5 8 Posted May 23, 2012 (edited) Hi there. Firstly, thank you for making this Script. I am impressed by the fact you're so active and readily able to update and fix problems that arise, quickly and effectively. Thanks for that, it's not always common. Secondly, what is your FP Series? Can you just give me insight into why you are doing this (The FP Series of scripts)? Do you have a blog showcasing all of these scripts? Also, where did the weight inspiration come from? Will it be akin to skyrim style inventory management in the sense that you won't be able to pick up an item that weighs 5(Kg/lb/etc) when you have 196/200(kg/lb/etc), thus making you have 201 and not working? Will this be optional or will we have to set every item weight value to 0 if we don't want to use this part of the script? Curious, will we have to set every weight value or will there be default values added (Like equips = 5, and potions = 1 or something, by default but customizable). Also, will most of these features be optional? Like, I LOVE the idea of the "Pick & Choose" chest interface, however i'm not a fan of having 5 separate inventories in my party, or leaving an inventory behind and forgetting "That one sword" When my story permits me to leave a party member out. Now that I think about the aforementioned actor join/leave, will the inventory of the leaving actor be dumped into remaining actors inventories? What if they wouldn't fit? What if you chose not to take the items out, then removed him from the party? Sorry for all the text, hopefully as a content creator you truly love to answer these questions just as much as I love to ask them. I look forward to seeing where this goes, great job! P.S. Grats on the user awards. Edited May 23, 2012 by Shablo5 Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 23, 2012 (edited) I just realized I renamed the file on dropbox but didn't update the link at the top lol maybe that's why none of the updates were reflected. Also, where did the weight inspiration come from? Mainly cause someone requested it. There are several inventory-extension scripts like item weights, customized stacks, item limits, individual equips/items, etc but all of them are based on the default engine's implementation of inventories which is very inflexible in general. So I wrote an inventory system that can support all of this, and more. you won't be able to pick up an item that weighs 5(Kg/lb/etc) when you have 196/200(kg/lb/etc), thus making you have 201 and not working? That has been implemented. If you did have 196/200 and you picked up an item that's 5 arbitrary weight units, then you wouldn't be able to pick it up. Unfortunately, I don't have any code that will nicely inform you that you can't pick it up and put it back where you found it. Similarly, if your inventory can only hold 25 items, and you already have 25, you can't pick up any new items. Curious, will we have to set every weight value or will there be default values added Default values are provided at the top. There are defaults for items, key items, and equips. Also, will most of these features be optional Yes. will the inventory of the leaving actor be dumped into remaining actors inventories? I'm thinking the developer can choose whether that should happen or not. I'm sure there are games where actors leave and take those good equips with them LOL What if they wouldn't fit? What if you chose not to take the items out, then removed him from the party? Naturally you would have the issue of exceeded inventory cause someone decided to drop out. If the actor's inventory is merged with the rest, then you'd have to pick what to discard. If it's not merged, then...well you have a different issue to work with. Secondly, what is your FP Series? It seemed like a cool way to name scripts at the time. Feature Plus refers to the extension of Ace's "feature" system where all bonuses given by equips,items, states, actors, classes, enemies, etc. are all handled uniformly. I simply extend the engine by adding additional features. All scripts I've written are in my signature. It takes too much effort to maintain a blog. Edited May 23, 2012 by Tsukihime Share this post Link to post Share on other sites
Shablo5 8 Posted May 23, 2012 (edited) Thank you for your response. It seems like you're a bit unsure about the party members leaving, will there be indepth functionality added into this? You say it's up to the Dev, but will he be able to choose between many options? Ex: Party member leaves and will rejoin in the future (Dev knows this), he'll be able to choose for him to keep said items, knowing he'll rejoin. So will functionality be there to keep the items stored in memory to be called on in the future when party member rejoins? Because I don't think many Devs would be very keen on the whole "Okay, time to drop all that shit you picked up in a boring way that'll take about 10 minutes to complete". I had more examples, but I went off on a tangent and forgot. My basic question was, will we be able to handle that scenario in a myriad of different ways? Because I assume that'll be a decent amount of work, to make each option (Keep items, drop items (in a single click?), transfer items (Evenly? To 1 Actor?). Etc. Just giving my two cents from what's on my mind. Thanks again. OH I had a question. Will all of your scripts work together flawlessly? Perhaps create a 'pack' at a later date where it's like "The Extension of VX ACE Features, all in one download" type deal? Edited May 23, 2012 by Shablo5 Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 23, 2012 So will functionality be there to keep the items stored in memory to be called on in the future when party member rejoins? It's already available due to the nature of object-oriented programming. If the inventories are not merged, then the inventory will just stay with the Game_Actor object. Unless the game actor is disposed, all of his inventory would remain intact the next time you add him back to the party. Because I assume that'll be a decent amount of work, to make each option (Keep items, drop items (in a single click?), transfer items (Evenly? To 1 Actor?). Etc. Keeping items on the leaving actor is easy. Having him drop his items is also pretty easy, but if you want to be able to drop them *on the ground* and pick up...well that's another matter. I don't think I will be supporting that. Actually, if we had a script that allows you to actually drop an item on the ground pick it up, maybe I will consider. Transferring items I would likely just go through each actor and try to add as much as I can, before discarding the leftovers. I actually want to implement a "discard" scene where you can choose what to keep, what to discard, and switch between keeps and discards. But I haven't gotten around to it. Share this post Link to post Share on other sites
Clyve 0 Posted May 23, 2012 (edited) Using the Yanfly menu (amongst other Yanfly scripts and a couple battle ones), as soon as I try to open the menu I get: Any ideas? Edited May 23, 2012 by Clyve Share this post Link to post Share on other sites
Tsukihime 1,489 Posted May 23, 2012 def weight @inventory.weight end Something must be over-writing the Game_Party initialization Share this post Link to post Share on other sites
Clyve 0 Posted May 23, 2012 Ah, alright... probably this one: http://yanflychannel.wordpress.com/rmvxa/core-scripts/party-system/ I'm not well versed enough to be able to tell. Share this post Link to post Share on other sites