Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

> Window Selectable List
Tsukihime
post May 6 2012, 11:58 PM
Post #1


Level 25
Group Icon

Group: Revolutionary
Posts: 565
Type: None
RM Skill: Undisclosed
Rev Points: 25




Window Selectable List
Tsukihime

Introduction

This window extends the Selectable window by storing a list of selected
items. You can specify the number of items that are allowed to be stored,
the number of columns that should be displayed, and most importantly you
can add and remove items from the list, as well as accessing items in
the list by index, or retrieving the entire list.

You can choose whether duplicates are allowed to be added or not.

By default, the currently highlighted item will be returned if you don't
specify an index.

I provide additional handlers for dir4 (left) and dir6 (right), and other things if I think it's useful, which should provide you with more flexibility.

Additions will be added as I think of things that might be cool.
One thing I am looking forward to adding is allowing you to choose whether
the items "stay in place" or automatically shift themselves over to fill
in the gaps when items are removed.

Usage

Copy into scripts and then start using it for your own scenes.
It is the same as any other window scripting with selectable windows.

The methods that will be of interest to you are

  1. add_item(item) - adds item to the list of selected items
  2. remove_item(item) - removes item from the list of selected items
  3. items - returns the list of selected items
  4. item(index) - returns the item located at the given index. Default is the currently highlighted item (if available)


Script

Script: http://db.tt/4xmceWMd

Improvements

If you can think of anything that would be nice or anything that should be changed let me know.

This post has been edited by Tsukihime: May 6 2012, 11:59 PM


__________________________
My Scripts
Go to the top of the page
 
+Quote Post
   

Posts in this topic
- Tsukihime   Window Selectable List   May 6 2012, 11:58 PM


Closed TopicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 19th June 2013 - 04:01 PM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker