The RPG Maker Resource Kit

RMRK RPG Maker Creation => VX => VX Scripts Database => Topic started by: IXFURU on September 25, 2014, 05:37:01 AM

Title: LootContainers v1.0a
Post by: IXFURU on September 25, 2014, 05:37:01 AM
LOOT CONTAINERS v1.0a
By: Ixfuru

Spoiler for INTRODUCTION:
This script is creates a containers system, where the player can access gold, items, weapons and armor as well as store those items.

Spoiler for FEATURES:
-storage of items, weapons, armor and gold
-lockable/unlockable, locked containers don't show loot
-take all button can be used to take everything in the container at once
-unlimited amount of containers
-manifested treasure; random containers with random loot
-adds a new scene for the container
-a good number of script calls to use for checking the status of containers

Spoiler for HOW TO USE THE SCRIPT:
Place the script above main and below materials in your project's script editor.
Follow the instructions to set up the containers.
Call the container scene with a script call from an event:

Code: [Select]
$scene = Scene_Container.new(container_id)

replacing 'container_id' with the ID you gave the specific container when you set it up.

Spoiler for SCREENSHOTS:
(http://i.imgur.com/OhcUcU0.jpg)

(http://i.imgur.com/AntsQI8.jpg)

Spoiler for SCRIPT:
ON PASTEBIN
http://pastebin.com/7Z3L6s98 (http://pastebin.com/7Z3L6s98)

Spoiler for CREDITS:
Just credit me, Ixfuru, if you use the script in your commercial/non-commercial projects.  Don't claim you created it yourself.  And don't post it in other places without my permission.

Spoiler for COMPATIBILITY:
This script does save a global variable $containers in your project.  This shouldn't be a problem.  But if at first you have issues, try moving the script in the script editor above/below other scripts who alias/overwrite the  save/load methods.  If you need help with this, let me know.  Because it aliases these methods, it may not work correctly in a previously started game.  You may have to add into a fresh playtest.  If you have a problem like this, or anything else, I'll try to assist you if you just post here with the issue.
Title: Re: LootContainers v1.0a
Post by: &&&&&&&&&&&&& on September 25, 2014, 05:43:45 AM
This is really cool. :o
Title: Re: LootContainers v1.0a
Post by: parafusion on September 26, 2014, 11:11:38 AM
Really awesome script! Interface of the scene looks really clean as well. Too bad I can't use it because my project is on VXAce, but still, this is a really neat script you made  :)
Title: Re: LootContainers v1.0a
Post by: IXFURU on September 26, 2014, 11:52:51 AM
Thanks.

I know.  I can't script Ace yet, so not a lot of folks use my scripts.  But hey maybe there's someone out there :)

And these screenshots are old.  You see how the one is locked, but you can see the word "empty" in the slots.  That was a mess up on my part.  And the new version,  the one you can download will not have that error in it.  That's the only thing I changed from 1.0 to 1.0a I think.

Anyway thanks to both of you for the feedback.