RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
Limited Inventory

0 Members and 1 Guest are viewing this topic.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Limited Inventory
Version: 1.1c
Author: modern algebra
Date: September 27, 2009

Version History


  • <Version 1.1c> 09.27.2009 - Fixed a bug that freezes user input when using an item with scope set to None.
  • <Version 1.1b> 09.20.2009 - Fixed a hash updating bug that did not recognize items gained and discarded through loot as having been gained or discarded.
  • <Version 1.1> 08.19.2009 - Fixed some bugs, including some discardability problems and an improper scaling effect with empty slots
  • <Version 1.0b> 04.27.2009 - Fixed a bug with equipping something into an empty slot.
  • <Version 1.0> 04.27.2009 - Original Release

Description


Essentially, this allows you to limit the number of items a party can carry. Rather than being able to hold 99 of all items, this script divides inventory space into a limited number of slots, each of which can hold a single item type, and for which you can set a maximum stack size. So, for instance, if you have 6 potions, and the maximum stack size for potions is 5, then potions will take up two slots in the inventory, one with 5 in it and the other with only 1. This script allows you to change the number of slots in the inventory in-game with ease, as well. It allows you to discard items easily (and set items as non-discardable), and if there is ever a time in which you get more items than you have space for, it will call a loot screen so you can choose which items to discard.

Features

  • Limited Slot-based Inventory system
  • Can change the number of slots at any time during the game.
  • Can set a maximum stack size for each type of item individually
  • Can set an item to be undiscardable
  • Lots of customizability, even to what words represent what things in the inventory
  • Will automatically call a loot scene any time the party has too many items, so that the player can choose what to discard

Screenshots





Instructions

Quote from: Header
Place this script above Main and below other custom scripts.

To set a number of the default conditions for this script, please see the Editable Regions at 53, 84, and 109. Be sure to read the comments next to each consant to see what it does.

To set an item as non-discardable, put this command into its note box:

Code: [Select]
    \NONDISCARD

To set an item to have a stack size different from the default, use this command in its note box:

Code: [Select]
    \STACKMAX[x]

where x is and integer and the new maximum stack size for that item.

To resize the party inventory in-game, say after an event where the get a new backpack or whatever, then all you need to do is put this code into a call script:

    
Code: [Select]
resize_inventory (x)
 
where x is an integer and the new number of slots in the party inventory.

Script


It is a large script. Please see the text document or retrieve the script from the demo. They are both attached at the bottom of this post.

Credit


  • modern algebra

Thanks

  • grafikal009, for the request
  • Fizzly, for major bug reports
  • Celianna, for a bug report

Support


With such a large script, there are bound to be bugs. Please post in this topic at rmrk.net for swiftest support, and be as detailed as possible.

Known Compatibility Issues

No known compatibility issues, yet. But anything that heavily modifies Scene_Item or Window_Item would likely be incompatible.

Demo


Limited Inventory 1.1b Demo


Creative Commons License
This script by modern algebra is licensed under a Creative Commons Attribution-Non-Commercial-Share Alike 2.5 Canada License.
« Last Edit: February 11, 2010, 09:37:29 PM by Modern Algebra »

********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009

**
Rep: +0/-0Level 83
That one guy in that one place.
lol, modern... I got so used to seeing the other avatar and sig that when I saw on the other post you had finished, I was like... Who the hell?

Anyway, thanks for making this, I had thought about a limited inventory before, but as I think I somewhat said in the other post I had found the request already.

This'll be a nice addition to my game.

and, for this, I love you in a purely professional way.

Edit: Found a bug :D, if you go into your equip screen and attempt to equip an empty slot anything (I think) it pops up with
Quote
"line465: NoMethodError occurred. undefined method 'ma_discardable?' for nil:NilClass"
It unequips fine, Its just equipping something into an empty slot, as equipping into an already filled slot works as well. So basically, if you try to equip something into an empty slot it'll result in that error.
« Last Edit: April 28, 2009, 01:16:58 AM by mortigneous »
Hmm.... rm2k isn't compatible with vista? Looks like I'll go to rmvx... Scripting?
Oh sweet, I get to add new stuff! OH DEAR GOD! *head explodes*
CLICKY!
MyMiniCity

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Thanks for catching that.

To fix it, replace that line with:

Code: [Select]
      if item != nil && !item.ma_discardable?

EDIT::

Actually, that's not entirely true. That will fix the syntax error, but could potentially cause other problems in the script. Just get the script from the new demo or the new text file that I just uploaded, as that has the complete fix in it.
« Last Edit: April 28, 2009, 01:57:22 AM by modern algebra »

**
Rep: +0/-0Level 83
That one guy in that one place.
Also, would it be possible for you to make this script so that it has an option for something like the non-discardable items, but have them called key items, in a different page, but have up, say, above the help box have something like, Items, or inventory or something, then, beside that something like key items, then selecting key items brings you to a different menu that would basically just be an inventory for key items that wouldn't take up the players inventory space? I know that's long and probably has a lot of errors with grammar, but I'm kinda tired and changed where I was going with it a couple of times... (just ignore that random mess, unless you feel like you absolutely must read it... the lower description is better by far.)

Anyway, picture!

-Sorry about it being an off-site picture, I was having some odd issues with attaching.... (This site doesn't show any recognition of it being attached? Too used to RRR lol) but I hope that explains what I mean (basically just if you label an item as a 'key item' some way [possibly an item note?] it goes under Key items, and does not take up space in the inventory whatsoever. This way your not filling up your players' inventories with a bunch of useless crap that are basically just trophies that serve no purpose other than giving players that reminiscent feeling of that one very special quest.
« Last Edit: April 28, 2009, 02:53:31 AM by mortigneous »
Hmm.... rm2k isn't compatible with vista? Looks like I'll go to rmvx... Scripting?
Oh sweet, I get to add new stuff! OH DEAR GOD! *head explodes*
CLICKY!
MyMiniCity

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I might add that later. How do you want ot be able to switch over to Key Items?

**
Rep: +0/-0Level 83
That one guy in that one place.
not entirely sure on this, but I guess something where you have it to where you select item in the game menu, and it goes into the inventory, you hit the cancel button (esc?) and it moves the selection up to inventory and key items, and there you can select either one. Or if you have another way that's easier to script that's fine as well :D

I'm going to sleep pretty much right after I post this, but I'll check it tomorrow when I get home and see if you have questions/specifications.
Hmm.... rm2k isn't compatible with vista? Looks like I'll go to rmvx... Scripting?
Oh sweet, I get to add new stuff! OH DEAR GOD! *head explodes*
CLICKY!
MyMiniCity

**
Rep: +0/-0Level 83
That one guy in that one place.
I just now noticed something, when you are able to scroll down, it doesn't show the cursor at the bottom that basically says 'Hey! there's more!' it just shows the one up at the top. (see attached)

Also, how's the key items thing going? :P
Hmm.... rm2k isn't compatible with vista? Looks like I'll go to rmvx... Scripting?
Oh sweet, I get to add new stuff! OH DEAR GOD! *head explodes*
CLICKY!
MyMiniCity

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Yeah, it would show the cursor if you actually had items down there and not just empty slots. I've noted the concern though and will add it when I look at this script again. I haven't started working on the Key Items thing, and to be honest, it's pretty low in my queue.

**
Rep:
Level 84
Edit: Never mind.... LOL :-\


Nice script Algebra!
Its very usefull. You think you can do the same but making every actor in ones party have their own inventory or something?
« Last Edit: May 23, 2009, 03:19:25 AM by Zero2008 »

***
Rep:
Level 89
Thanks, it's really nice! But I found a bug: even if an item is non-discardable, the "discard" option is faded to gray, but it's still active and you can select this -> item goes to the Loot... Can you fix this? ^ ^;
Regards,
Mike

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Hmm, you're right. Around line 1011, change this:

Code: [Select]
         slot = @item_window.ma_grfkl_lim_nvtry_item_8rn
          type, id, n = slot.item_type, slot.item_id, slot.amount

Replace it with:

Code: [Select]
         slot = @item_window.ma_grfkl_lim_nvtry_item_8rn
          unless slot.item.ma_discardable?
            Sound.play_buzzer
            return
          end
          type, id, n = slot.item_type, slot.item_id, slot.amount

That ought to fix it.
« Last Edit: August 14, 2009, 11:20:20 PM by modern algebra »

***
Rep:
Level 89
Yup, it's working fine right now. ^^ Thank you!
Regards,
Mike

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Good to hear. Tell me if you encounter any other problems.

***
Rep:
Level 89
Hmm, I think there is one more. But not sure if I can call this a bug or glith. Anyway, if you change default amount of items in script for more than (default) one, they just can't group together. I mean, I've got for example 3x apples, and they are in inventory as: apple, apple and apple. When I'll get another two one, I have: apple, apple, apple, apple x2. Shouldn't they be as: apple x5?  ;) If you can fix this, would be great. =)

EDIT: And another one! ^^; This should be fixed for sure:
There is non-discardable item in inventory. I want to throw away some stuff (discardable) to make space for new one. When I'll use "Change" option, from Loot window, I can change discardable stuff (from Loot) with non-discardable one (from the inventory). So in fact, I can use a trick to throw something really important... ^^; <LOST MY KEYYY!! T_T>
« Last Edit: August 15, 2009, 01:23:45 AM by Fizzly »
Regards,
Mike

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I'll look into those bugs. They definitely shouldn't be happening.

***
Rep:
Level 89
Bump? =p

Anyway, modern algebra, can I have a little request about that script? I thin kthat would be pretty useful for others too. I mean:
Weapons can be "clickable" too, but instead of inactive "Use" option, they'll be "Equip" option. Same could be with armors and shields. :) That would be really great.
Regards,
Mike

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Then I'd have to introduce a targetting window, as well as an equip window to show what is being replaced and a stats window to show the difference in stats. Further, it's make the Equip scene useless, meaning that anyone wanting to use it would probably want to get rid of it, which is even more :( Also, any scenes which are so extensive would mean that anybody who has a nice custom Equip scene probably wouldn't want this script.

It's a nice idea, but it's a lot more trouble than it's worth. I'd rather not.

I will look into those errors though. Sorry for the time, but I've been busy.

***
Rep:
Level 89
No problem, and thanks. Still waiting for fixes, by the way.  ;)
Regards,
Mike

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Updated to 1.1. Those bugs should be fixed now.

It does tell me that grafikal hasn't been using the script he requested though :P I should be upset with him >: (

********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009
Haha, I was using it for a while, but never got around to extensively testing it since I didn't progress enough in the game to use the inventory a whole lot .______.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
 ;D

Also, @mortigenous - the new version does show the white arrow when there are more spaces down

***
Rep:
Level 89
Now it works just perfect!! Thanks, modern algebra.  ;)
Regards,
Mike

********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009
Bump? =p

Anyway, modern algebra, can I have a little request about that script? I thin kthat would be pretty useful for others too. I mean:
Weapons can be "clickable" too, but instead of inactive "Use" option, they'll be "Equip" option. Same could be with armors and shields. :) That would be really great.

Curious if that was implemented? That sounds really convenient O_O

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
No, I decided against it. It's not a bad idea but it's a lot of work:

Then I'd have to introduce  an equip window to show what is being replaced and a stats window to show the difference in stats. Further, it'd make the Equip scene useless, meaning that anyone wanting to use it would probably want to get rid of it, which is even more :( Also, any scenes which are so extensive would mean that anybody who has a nice custom Equip scene probably wouldn't want this script.

Maybe one day. Lots of other scripts to fix before that though.

********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009
Lol, I was just thinking like, click it once (Message box pops up "Equip this?" [yes, no], then if yes, it'll just unequip what ever you have on at the moment and put that on instead.) I wasn't thinking new windows and crazy stuff lol.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
What if it's Two Swords Style?

Not to mention that it would automatically make the script incompatible with any scripts that alter equipment, such as Usable Equipment, Extra Equipment, new Equipment scenes, etc...

**
Rep:
Level 83
プログラマです
Hey me again MA.

I found another glitch :P

If I have too many items... I can go to discard and they go into the Loot window yeh? BUT, I can leave the menu then aquire more items and repeat this process to have as many items as I want. See what I mean? It's like the Loot window is another Item menu with unlimited slots :P

Just thought I'd let you know, because this script is pretty banging haha (good)

Thanks.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I';m not receiving that error when I test. Is the warning window not coming up?

**
Rep:
Level 83
プログラマです
Is a warning message meant to come up so that you can't leave the item menu when the loot menu is up?

No error comes up or anything =/ I'm just allowed to leave items in the loot window to free up inventory slots.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I attached a picture.

If you have a script which overwrites return_scene of Scene_Item, then it would skip it. Do you have Yanfly's Scene Menu Redux or any Custom Commands script, by chance?

For now, try putting the Limited Inventory script below the menu script. If that causes problems, I will look into it, but hopefully it will resolve your error.

**
Rep:
Level 83
プログラマです
Yeh that's it fixed man, just moved the Scene Redux below Limited Items like you said and it works like a charm.

Thank you very much :D

**
Rep: +0/-0Level 83
Hi there. I love this script but I need to tell about a bug.
Here is the setting:
-Your inventory is full
-Lets say find a leather shield and wanna take it in exchange of anything in your inventory.
-Once the trade is done and you get the leather shield,
you want to equip it for you hero.
-BUG IS even tho you do HAVE the item listed in inventory, it just does not appear in the equip screen, nor is it equipable for anyone normally able to.
-I double checked the classes compatibility, nothing to do with it.

There you go.

I admire all your scripts nonetheless. Genius you are dude!

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
There must be a hash updating problem when gaining item through the loot. Thanks for the report; I will look into it.

**
Rep: +0/-0Level 83
There must be a hash updating problem when gaining item through the loot. Thanks for the report; I will look into it.

Very nice of you Modern because I'd really like to use your script for my game :)

Also, about limited inventories (just asking by the way)... I was wondering if you planned to create a script to
limit inventories à la Dragon Quest. You know, each character with limited carryable items(equiped items included), useable by them in battle according to they very own inventory (can't explain better, gotta play DQ to know otherwise. Indeed, if you ask me, THAT would be the perfect ''limited items'' script ever my friend. Just telling :-X

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I have no plans currently to make an individual limited inventories script as of now, but my Grid Inventory script has those capabilities. Obviously, it's quite different graphically and may not be what you are looking for, though.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Updated to Version 1.1b

Fixed the bug where the hash was not updating when gaining or destroying items through loot.

**
Rep: +0/-0Level 82
Would it be possible to add a "hero chest" feature to this script?  Let me explain what I mean:

I make a chest through quick event creation.  Then I go into the event and remove the "Show Text" and "Change Items" commands.  Finally I add a script call that would take the form of "$scene = Hero_Chest.new" or something like that.

Other than that, it's perfect!

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
It's a good idea and definitely possible. I did much the same thing with my Grid Inventory.

In any case, I will put it on my To Do list (which is unfortunately very long, so it might be a while)

**
Rep: +0/-0Level 82
I don't suppose there's a way to limit the amount of stacks? i.e.: in a inventory with 99 slots, you can only have, say, 3 stacks of potions.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
No, there isn't. Sorry.

**
Rep: +0/-0Level 82
Might not be a bad idea to add that then...

**
Rep: +0/-0Level 82
Just curious as to how far along you are with my requests...

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Nowhere. I haven't worked on it at all. And I have a lot more to do before I will even look at it. Plus, I'm playing Dragon Age now so I probably won't do any scripting for a while.

**
Rep: +0/-0Level 82
Actually, I've just come across (and implemented) a different "hero chest" system.  So no worries!  However, I am having a minor issue with this and KGC_CategorizeItem.  For the most part they work together, but when I select a category, it automatically uses the first item in that category rather than simply going into it.
« Last Edit: November 16, 2009, 08:10:32 PM by munkis »

*
Rep: +0/-0Level 82
Hi.
I'm a brazilian maker and I don't write english very good. I'm using the Babel Fish Tradutor  ;D
I would like to know if I could take this script until my Brazilian community Reino RPG

Thanks  :lol:

********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009
Oh, I've seen that website before. It's a very nice website. I would imagine that ModernAlgebra would allow you to post it on that website as long as you credit him as the creator and placed a link to this webpage incase someone would need help with the script.

*
Rep: +0/-0Level 82
Yes! All credits for he and me (I translated the script to portuguese) and I will place a link to this site  ;)

All rights reserved  ;D

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Yeah, that's fine with me :) Like grafikal said, I would appreciate the link to this site, but by all means you can post it on reinorpg.

**
Rep: +0/-0Level 82
Lol, edited the post and forgot to say what is this xD

this is a fix for those who are using Kgc's categorize item script
they will work fine now, just put kgc BEFORE this one (dunno if this matter but just do it)




Discard the other one, just found a better way to do it
Quote
====
on this line  (805 +/-)

Code: [Select]
class Scene_Item
  #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  # * Start processing
  #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  def start
    super
    create_menu_background
    @activated_frame = false

do this

Code: [Select]
class Scene_Item
  #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  # * Start processing
  #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  def start
    super
    @@btpresses = 0
    create_menu_background
    @activated_frame = false


then search for " Input.trigger?(Input::C) "

you'll get this line

Code: [Select]
elsif Input.trigger?(Input::C)
      # If exchanging
      if @loot_window.index > -1 && @item_window.active
        slot = @active_window.ma_grfkl_lim_nvtry_item_8rn

change to...

Code: [Select]
elsif Input.trigger?(Input::C)
      # If exchanging
      if @@btpresses == 0 then @@btpresses += 1 and return end
      if @loot_window.index > -1 && @item_window.active
        slot = @active_window.ma_grfkl_lim_nvtry_item_8rn

now do the same search again for the second line

Code: [Select]
elsif Input.trigger?(Input::C)
      if @active_window == @item_window
        case @command_window.index

change to

Code: [Select]
elsif Input.trigger?(Input::C)
      if @@btpresses == 0 then @@btpresses += 1 and return end
      if @active_window == @item_window
        case @command_window.index


and that's it

not the best fix but it does work.
« Last Edit: December 16, 2009, 02:39:03 AM by h3llh0und »

**
Rep: +0/-0Level 81
Let the battle begin.
Ok so I'm not very good with scripts first off. I have quite a bit of them in this game I'm putting together. It's non-commercial just kind of something to do to pass the time. I decided to put your script in there too cause I loved the idea. Problem is every time I try to open my item menu an error pops up saying...

Script 'Limited Inventory 1.1b' line 567:NoMethodError occured.

undefined method 'slots' for nil:NilClass

I'm sorry if it's something simple that I'm missing but your help would be much appreciated.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
It's an incomptibility with one of your other scripts. First try to move the Limited Inventory below every other custom script you have but still above Main. Beyond that, I'd need to know which script is causing the error before I could help you.

**
Rep: +0/-0Level 81
Let the battle begin.
Ok. Well would you mind if I PM you with all the scripts I'm using? I already have the limited inventory at the bottom right above main.

**
Rep: +0/-0Level 81
Let the battle begin.
Ok so never mind. It seems to work now. I think the problem was I was using the script on a saved game that I had made before I had added your script. I started a new game and it works just fine now. Thank you.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Alright; yeah, that would definitely cause the problem. I am happy that you have resolved it :)

***
Rep:
Level 89
Okay, I found another bug. I send you PM, but you didn't answer yet, so I'll post it anyway, to make sure you'll remember ^^'

The problem is, the game crushes every time, when I want to set item amout to variable. I've got this:
http://ifotos.pl/img/error_wxrqeq.PNG

Regards,
Mike

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
That's not a bug from Limited Inventory; if you notice, it will occur whether Limited Inventory is there or not. This is because it's a bug that enterbrain didn't fix when they released RMVX. Just get the Game_Interpreter fix - http://rmrk.net/index.php/topic,25243.0.html

Go through the entire topic

This post will fix the error you are reporting: http://rmrk.net/index.php/topic,25243.msg316194.html#msg316194

This post will fix another error with multiplying variables - http://rmrk.net/index.php/topic,25243.msg322221.html#msg322221

***
Rep:
Level 89
Oh!  :o You're right. Didn't notice this error earlier, sorry for bothering you. And thank you, anyway! It works fine now. Thanks for the multi-variable fix too!
« Last Edit: August 10, 2010, 01:19:04 PM by Fizzly »
Regards,
Mike

***
Rep:
Level 81
sorry for epic necroposting,
but is there a way to change the stacksize through a script command or an event?
i would be thrilled if you could help me.
sincerly
rofl1337

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
If I recall correctly, then no there is not. Sorry.

***
Rep:
Level 81
ok, i will try to work out a way on my own.
i will post results, if i succeed.
sincerly

update:
I defined a new function in the game_interpreter, called change_stacksize (new), which should change
the MA_STACK_AMOUNT to (new).
Code: [Select]
def change_stacksize (new)
    @ma_stack_amount = (new)
end
although the game doesnt give out any errors, the stacksize keeps the same.
anyone able to help me?

« Last Edit: September 20, 2010, 08:13:31 PM by rofl1337 »

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
That... is nothing like how you would go about doing it. That creates an instance variable in Game_Interpreter that is unrelated to how the script retrieves the maximum stack size. You are on the right track in a distant sort of way though. You want to change MA_DEFAULT_STACK_AMOUNT. Well, it's a constant and it's newly defined every time, so even if you had succeeded in changing the value of the constant (which you didn't and shouldn't do), then that change wouldn't be saved in the save file and would revert back to the default the next time the player starts the game.

So, not really the way to do it. A much simpler way is to insert the following code somewhere below the Limited Inventory:

Code: [Select]
#==============================================================================
# ** RPG::BaseItem
#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Summary of Changes:
#    redefined method - ma_stack_amount
#==============================================================================

class RPG::BaseItem
  #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  # * Stack Amount
  #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  def ma_stack_amount
    return $1.to_i if self.note[/\\STACKMAX\[(\d+)\]/i] != nil
    if $game_variables && $game_variables[RPG::MA_DEFAULT_STACK_AMOUNT] > 0
      return $game_variables[RPG::MA_DEFAULT_STACK_AMOUNT]
    else
      return 1
    end
  end
end

I haven't tested it, but what that does is repurposes the MA_DEFAULT_MAX_STACK constant. Instead of holding the default stack maximum, it now holds the ID of a variable, and the value of that variable will determine the max stack size (though it can never be less than 1).

So now, if you set MA_DEFAULT_MAX_STACK to 20, for instance, then default stack size for items is going to be whatever the value of variable 20 is. So, that will allow you to change it by changing the value of variable 20 through a simple Control Variable command. Note that if the stack max is set individually through an item's notebox, then that will still take priority.

Anyway, tell me if you have any problems with that.

***
Rep:
Level 81
thank you so much, it worked perfectly.
i dont know anything about scripting in rgss2, so this is really helpful for me.
there is one tiny problem with it though.
if you already have a stack of lets say 20 items in your inventory, they keep their size even after the maximum-stacksize is changed/lowered.
same problem the other way around. if i have stacks of 5 and the stacksize is increased, the stacks keep small and take up inventory space, that they wouldnt need with the new stacksize.
i suppose there isnt some update command for the inventory?

again thank you so much for the script
sincerly

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I really don't know. I wrote this script a very long time ago and don't really have the time to take a look now. If not, then it would be a rather simple procedure. Essentially all you would need to do is go through every item, lose them and then gain them. It would be something like:

Code: [Select]
class Game_Party
  def refresh_inventory
    items.each { |item|
      n = item_number (item)
      lose_item (item, n)
      gain_item (item, n)
    }
  end
end
You'd put that in a separate slot.

And every time you change the max stack size you could just put the following code in a script call right after:

Code: [Select]
$game_party.refresh_inventory

There may be an error since it isn't tested and, as I've said, I haven't looked at the script for a long time. I'm not sure whether it would properly work with loot either, but I think it should if I recall loot correctly.

***
Rep:
Level 81
one word: AWESOME!
i cant say how much i apprechiate your help.
everything works perfectly and just the way i imagined it. ;D
thanks, that you took time to code this.
respectfully
rofl1337

**
Rep: +0/-0Level 75
RMRK Junior
hey, perfect script works really well but is ther any way i can remove a part of it  :o
i didnt wont the loot idea, i wanted it to just have my inventory and the 50 slots i have placed, and items that stack to 10, with the option to discard i wanted them to just disapear, rather than go into a loots box.
it would be "REALLY" helpful if you could help me here, thanks :)
- Kureigu


oh , i found another way round it. i got confused but i just changed the name loot to "items to be discarded"
so it makes abit more sense. Thank you for the script, its great ;)


third edit haha!
yea its all working great until i changed the stack limit on items.
instead of it saying cake X5 or potions X3
it says cake 10 5 or potion 10 3
have no clue why :|?
« Last Edit: October 17, 2010, 09:12:15 PM by Kureigu »

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Well, the "x" is a label set up by in the configuration region. Maybe you changed it from "x" to "10 "

**
Rep: +0/-0Level 75
RMRK Junior
yeah i was thinking that was the problem  :-[ . haha im so stupid at times :P
thanks for the script again, i LOVE it!!

*
Rep: +0/-0Level 73
RMRK Junior
Sorry for the late post, but would it be possible for the script to work with Yanfly Engine Melody Item Scripts? Thanks.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
I don't know. What are they and can you link me to them?

**
Rep:
Level 84
I am guessing he wants you to see if you can make it compatible to http://wiki.pockethouse.com/index.php?title=Item_Overhaul ...
It's part of Yanfly's Melody scripts.

*
Rep: +0/-0Level 73
RMRK Junior
Nice script, just what I needed! :D

****
Rep:
Level 76
Praise the Sun (Arcana)
GIAW 14: 1st Place (Hard Mode)
Could I have the loot screen come up at all times?

***
Rep:
Level 81
Monster Hunter
it works perfectly , but it still asks if i want to discard the items when leaving the item menu how could i take it away?

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Well, I gave you two solutions since I wasn't sure which you wanted from your request - one was if you wanted them to go to loot but not to open, while the other was if you wanted to immediately destroy the items and not go to loot at all. It sounds like you chose the first one instead of the second. Go back to the PM and test the second one.

***
Rep:
Level 81
Monster Hunter
Well, I gave you two solutions since I wasn't sure which you wanted from your request - one was if you wanted them to go to loot but not to open, while the other was if you wanted to immediately destroy the items and not go to loot at all. It sounds like you chose the first one instead of the second. Go back to the PM and test the second one.
okay i will thanks ^^

***
Rep:
Level 81
Monster Hunter
Quote
Anyway, I'm a little confused as to what you're asking. Do you want it to go to Loot but just not immediately open the loot window? Or do you want the item to be immediately destroyed?

If the former, a possible solution is as follows: no guarantees as I haven't looked at the script for a very long time and I forget how it was supposed to work, but try replacing line 1036:


           
Code: [Select]
show_loot

with:

           
Code: [Select]
@item_window.refresh ($game_party.limit_inventory)
If the latter, try replacing this whole section from lines 1026 - 1039:

         
Code: [Select]
$game_temp.slots_to_discard.add_item (type, id, n)
          # Deactivate Command Window
          @command_window.active = false
          @command_window.index = -1
          @command_window.visible = false
          # Reactivate previous Window
          if @loot_window.visible
            @item_window.refresh ($game_party.limit_inventory, 1)
            @loot_window.refresh ($game_temp.slots_to_discard, 1)
          else
            show_loot
          end
          @item_window.active = true
          RPG::SE.new (Sound::MA_DISCARD_SE).play
with:


         
Code: [Select]
RPG::SE.new (Sound::MA_DESTROY_SE).play
          @command_window.active = false
          @command_window.visible = false

Again, I don't remember the script well enough to know if those changes would break anything. I don't think they should, but you should try it out in a test project first
.

as you told me in your PM only the first solution works for me, the second freezes once you click on discard (destroy) the item.
the only problem now is that once closing the item window it asks me if i'm okay with discarding the items , i would like it not to show this question. thanks for the help so far it works like a charm :p

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Well, instead of just:

Code: [Select]
          RPG::SE.new (Sound::MA_DESTROY_SE).play
          @command_window.active = false
          @command_window.visible = false

try making it:

Code: [Select]
          RPG::SE.new (Sound::MA_DESTROY_SE).play
          @command_window.active = false
          @command_window.visible = false
          @item_window.refresh ($game_party.limit_inventory, 1)
          @item_window.active = true

Like I said, I don't really remember this script very well and certainly don't feel like relearning it. Hopefully that will work fine.

***
Rep:
Level 81
Monster Hunter
Well, instead of just replacing:


Code: [Select]
$game_temp.slots_to_discard.add_item (type, id, n)
          # Deactivate Command Window
          @command_window.active = false
          @command_window.index = -1
          @command_window.visible = false
          # Reactivate previous Window
          if @loot_window.visible
            @item_window.refresh ($game_party.limit_inventory, 1)
            @loot_window.refresh ($game_temp.slots_to_discard, 1)
          else
            show_loot
          end
          @item_window.active = true
          RPG::SE.new (Sound::MA_DISCARD_SE).play

with

Code: [Select]
          RPG::SE.new (Sound::MA_DESTROY_SE).play
          @command_window.active = false
          @command_window.visible = false

try making it:

Code: [Select]
          RPG::SE.new (Sound::MA_DESTROY_SE).play
          @command_window.active = false
          @command_window.visible = false
          @item_window.refresh ($game_party.limit_inventory, 1)
          @item_window.active = true

Like I said, I don't really remember this script very well and certainly don't feel like relearning it. Hopefully that will work fine.

yes that worked thanks Modern algebra, just one little thing

make it

Code: [Select]
RPG::SE.new (Sound::MA_DESTROY_SE).play
          @command_window.active = false
          @command_window.visible = false
          @item_window.refresh ($game_party.limit_inventory)
          @item_window.active = true

instead, you'll see why (it gives a little bug if you don"t )

thanks again :p

**
Rep: +0/-0Level 82
I received this error when I obtained a Non-Discard item from a
chest while my inventory was already full. This happened in the
Limited Inventory 1.1 Demo. I'm not using any other scripts.

Script 'Limited Inventory 1.1c' line 480: NoMethodError occurred.
undefined method 'item_type' for nil:NilClass

***
Rep:
Level 89
I received this error when I obtained a Non-Discard item from a
chest while my inventory was already full. This happened in the
Limited Inventory 1.1 Demo. I'm not using any other scripts.

Script 'Limited Inventory 1.1c' line 480: NoMethodError occurred.
undefined method 'item_type' for nil:NilClass
Yup, checked this and you're right. <waiting for fixing this>  ::)

Hmmm, I wonder is it possible to had the free slots number in variable? Could you help, modern_algebra? :)
« Last Edit: February 05, 2011, 07:57:28 PM by Fizzly »
Regards,
Mike

**
Rep: +0/-0Level 72
Black Onslaught
Its a good script to make the player build a strategy to fight a tough boss or a quest boss.
Congrats!

***
Rep:
Level 74
I'm baaack!
This is an awesome script but I was wondering if I could use the normal Items window with the limited Items features.

EXAMPLE:
-No dark blue rectangles
-Can not scroll down to empty slots

BTW i forget what I was gonna post here (after the BTW)


EDIT: Another thing I wonder if it is possible:
Can the loot be disabled without disabling the ability to discard items?

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
Well, you could remove the loot scene, but it would be reckless. What if the player's inventory was full and you wanted someone to give them a key item? Without a loot scene it would destroy the item.

As for getting rid of the blocks, I haven't worked with this script for a very long time so no guarantees, but you could try finding this in the refresh method of the Window_Item class (still inside the Limited Inventory script - I do not mean the default Window_Item class):

Code: [Select]
    @item_max = inventory.max_size == -1 ? @data.size : inventory.max_size
    create_contents
    # Calculate number of empty slots to draw
    empty_slots = (inventory.max_size == -1 || !$scene.is_a? (Scene_Item)) ? 0 : inventory.max_size - inventory.slots.size

and changing it to:

Code: [Select]
    @item_max = @data.size
    create_contents
    # Calculate number of empty slots to draw
    empty_slots = 0

***
Rep:
Level 81
Is there a way to specify items, that do not use up item slots?
I would love that feature.

*
Rep:
Level 97
2014 Most Unsung Member2014 Best RPG Maker User - Engine2013 Best RPG Maker User (Scripting)2012 Best Member2012 Best RPG Maker User (Scripting)2012 Favorite Staff Member2012 Most Mature MemberSecret Santa 2012 ParticipantProject of the Month winner for July 20092011 Best Veteran2011 Favourite Staff Member2011 Most Mature Member2011 Best RPG Maker User (Scripting)2011 Best Use of Avatar and Signature Space2010 Most Mature Member2010 Favourite Staff Member
There isn't, though that would be a good idea for the future.

***
Rep:
Level 81

***
Rep:
Level 81
Double-Post-Bump, because I love this script.
I have another suggestion.
Could you add the option to "hide" items? You should still be able to check if there are present in the inventory, via events, but they don't show up in the
inventory screen.
I think there are a few possible uses for that.

Edit:
In the discard-window, the description box always displays the description of the last item in the inventory and not the one that is selected in the discard pile.
Is this a bug, or caused by this script conflicting with KGC_CategorizeItem?

« Last Edit: June 17, 2011, 11:57:12 AM by rofl1337 »

***
Rep:
Level 75
What the...?
Question about this script:

Is it possible, or would it be possible to use only one part of the script?

I need only the part which does the item stacking limitations. 

DRIACS system gives the ability to discard items, and it seems to be incompatible when the two scripts are running together.  So, if there was a way to limit via switch or some sort of boolean flag the parts of this script which do the same thing as DRIACS, just so I could use the stack-size limits that would be very beneficial.  Thanks.

**
Rep: +0/-0Level 75
RMRK Junior
I tried some stuff to fix this bug that I found but I can't fix it :(
When I open the Item Manu I get this error:

Script 'Limited Inventory 1.1b' line 851: ArgumentError occurred.
Wrong number of arguments(2 for 0)

I am useing YEMs scripts I removed YEMs Item Overhaul.
Anyway of fixing this? :/
MrD

**
Rep: +0/-0Level 67
RPGVX Advanced (I Do Not Script Tough)
AWESOME MA  ;)

****
Rep:
Level 76
Praise the Sun (Arcana)
GIAW 14: 1st Place (Hard Mode)
Is there any way to add inventory slots rather than change the amount of slots there are. For instance instead of acquiring a specific backpack ingame, you can find multiple pouches throughout the game that just add more slots to your total inventory space.

*****
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Most Missed Member2014 Zero to Hero2014 Best IRC Quote2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Code: [Select]
s = $game_party.limit_inventory.slots.size
s += 6 # The amount you're adjusting the size by. This can be any operation (+, -, *, /)
# Then either:
$game_party.limit_inventory.resize(s)
# Or:
resize_inventory(s)
it's like a metaphor or something i don't know

****
Rep:
Level 76
Praise the Sun (Arcana)
GIAW 14: 1st Place (Hard Mode)
There's no way I missed that...

Is that in the script? Or should I be adding that to it in some way?

*****
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Most Missed Member2014 Zero to Hero2014 Best IRC Quote2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
No, it's a command I whipped up just then. Use it in an event script call when you want to adjust the inventory. It should work, though I didn't test it.
it's like a metaphor or something i don't know

****
Rep:
Level 76
Praise the Sun (Arcana)
GIAW 14: 1st Place (Hard Mode)
Sounds good. Thanks a lot.

But... How exactly do I get this to work? Should I make this its own script? Or is that entire thing one script call.
« Last Edit: January 03, 2012, 04:11:36 AM by hiromu656 »

*****
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Most Missed Member2014 Zero to Hero2014 Best IRC Quote2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
It's a script call you use when you want to adjust the inventory relative to what it already is.
Essentially, it's only three lines:
Code: [Select]
s = $game_party.limit_inventory.slots.size
s += 6 # Or whatever
resize_inventory(s)
it's like a metaphor or something i don't know

****
Rep:
Level 76
Praise the Sun (Arcana)
GIAW 14: 1st Place (Hard Mode)
I used this:
Code: [Select]
s = $game_party.limit_inventory.slots.size
s += 6 # Or whatever
resize_inventory(5)
All it did was change the inventory size to 5.

Then I used:
Code: [Select]
s = $game_party.limit_inventory.slots.size
s += 6 # Or whatever
resize_inventory(s + 5)
And what that did was for some reason subtract 5 from the total size. So I tried using a minus sign instead, and that did the same as what my initial test had done.

 ;9

*****
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Most Missed Member2014 Zero to Hero2014 Best IRC Quote2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Check the last line of my code. It's an s, not a 5.
it's like a metaphor or something i don't know

****
Rep:
Level 76
Praise the Sun (Arcana)
GIAW 14: 1st Place (Hard Mode)
Sorry, this is an extremely late reply, but I only used 5 because I thought that s was just a placeholder for a number. But at first, I used the s as it is but still nothing beneficial happened.

What I did was create an event in which you get a new pouch, then I called the script, (copying what you typed). When I tested the event, it resized my inventory to 6. So it didn't add more spaces.

*****
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Most Missed Member2014 Zero to Hero2014 Best IRC Quote2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
s stores the number $game_party.limit_inventory.slots.size
You can alter this number once you store it, i.e. s += 6, s *= 2, s -= 3, whatever.
Once you alter the number, you can resize the inventory with this altered number.
Code: [Select]
resize_inventory(s)
it's like a metaphor or something i don't know

***
Rep:
Level 81
Monster Hunter
Modern Algebra could you add an option to have items that don't take up place at all please?