https://avangs.info/index.php?mid=rgss_vx_ace&page=6&document_srl=1029991
이 링크에 있는 사이트가 사라져버려 참고할 것이 없는 상태입니다.
위 사이트에 있는 스크립트가 어디에 남아있는지 알 수 있을까요?
아니면 따로 아이템 설명창을 길게 늘이는 방법이 어디 없을까요?
■ 질문전 필독!
- 질문할 내용이 이 게시판이나 강좌에 이미 있는지 확인합니다.
- 하나의 게시물에는 하나의 질문만 합니다.
- 제목은 질문의 핵심 내용으로 작성합니다.
- 질문 내용은 답변자가 쉽게 이해할 수 있도록 최대한 상세하게 작성합니다.
- 스크립트의 전문이 필요할 경우 txt 파일 등으로 첨부해 주시기 바랍니다.
- 답변받은 게시물은 삭제하지 않습니다.
- 답변이 완료된 경우 해당 답변해주신 분들께 감사의 댓글을 달아줍니다.
- 처음 오신 분들은 공지 게시물을 반드시 읽어주세요!
※ 미준수시 사전경고 없이 게시물을 삭제합니다.
한번 테스트 해보세요~
#===============================================================================
# * SEE - Item Menu ACE# * SEE - Item Menu ACE
# * By Crazyninjaguy# * By Crazyninjaguy
# * Requested by BizarreMonkey# * Requested by BizarreMonkey
# * http://www.stormxstudios.co.uk# * http://www.stormxstudios.co.uk
# * 02/01/2012# * 02/01/2012
# * If you like my scripts, please show your appreciation by checking out# * If you like my scripts, please show your appreciation by checking out
# my friendly, helpful Game Development Community, StormCross Studios.# my friendly, helpful Game Development Community, StormCross Studios.
# ---------------------------------------------------------------------------# ---------------------------------------------------------------------------
# * Aliased Methods# * Aliased Methods
# - start (Scene_Item)# - start (Scene_Item)
# - update_item_selection (Scene_Item)# - update_item_selection (Scene_Item)
# - terminate (Scene_Item)# - terminate (Scene_Item)
# ---------------------------------------------------------------------------# ---------------------------------------------------------------------------
# * This script adds a new item description window with support for four text# * This script adds a new item description window with support for four text
# text lines and a 96 x 96 picture in Graphics/Pictures.# text lines and a 96 x 96 picture in Graphics/Pictures.
# * To add a picture for your item, add this into the notebox of that item in# * To add a picture for your item, add this into the notebox of that item in
# the database# the database
# * <picture potionpicture># * <picture potionpicture>
# * Replacing potionpicture for your image filename.# * Replacing potionpicture for your image filename.
#===============================================================================#===============================================================================
$imported = {} if $imported == nil= {} if $imported == nil
$imported["SEE - Item Menu Ace"] = true["SEE - Item Menu Ace"] = true
#===============================================================================#===============================================================================
# * Main StormCross Engine Evolution Configuration Module# * Main StormCross Engine Evolution Configuration Module
#===============================================================================#===============================================================================
module SEEmodule SEE
#=============================================================================#=============================================================================
# * Item Menu Configuration Module# * Item Menu Configuration Module
#=============================================================================#=============================================================================
module Itemmodule Item
ITEMS = []= []
#===========================================================================#===========================================================================
# * The number at the beginning of the ITEMS[1] is the item id in the# * The number at the beginning of the ITEMS[1] is the item id in the
# database.# database.
# * Each line of text in quotes is a seperate line in the window.# * Each line of text in quotes is a seperate line in the window.
# Seperate each with a comma# Seperate each with a comma
#===========================================================================#===========================================================================
ITEMS[1] = ["This is a potion.", "It's very nice and restores 500hp.", "Costs 50 Gil in a shop.", "Has a purplish glow."][1] = ["This is a potion.", "It's very nice and restores 500hp.", "Costs 50 Gil in a shop.", "Has a purplish glow."]
ITEMS[2] = ["This is a high potion.", "It's very nice and restores 2500hp.", "Costs 150 Gil in a shop.", "Has a purplish glow."][2] = ["This is a high potion.", "It's very nice and restores 2500hp.", "Costs 150 Gil in a shop.", "Has a purplish glow."]
WEAPONS = []= []
WEAPONS[1] = ["Derp", "", "", ""][1] = ["Derp", "", "", ""]
ARMORS = []= []
ARMORS[1] = ["", "", "", ""][1] = ["", "", "", ""]
ITEM_COLOURS = []= []
#===========================================================================#===========================================================================
# * As with the previous, the number at the beginning of COLOURS[1] is the# * As with the previous, the number at the beginning of COLOURS[1] is the
# item id in the database.# item id in the database.
# * The numbers in the array correspond to the text_color() argument of# * The numbers in the array correspond to the text_color() argument of
# window base. 0 is white. You can find these by looking at the# window base. 0 is white. You can find these by looking at the
# Window.png graphic. Seperate each value with a comma.# Window.png graphic. Seperate each value with a comma.
#===========================================================================#===========================================================================
ITEM_COLOURS[1] = [0, 1, 2, 3][1] = [0, 1, 2, 3]
WEAPON_COLOURS = []= []
WEAPON_COLOURS[1] = [0, 1, 2, 3][1] = [0, 1, 2, 3]
ARMOR_COLOURS = []= []
ARMOR_COLOURS[1] = [0, 1, 2, 3][1] = [0, 1, 2, 3]
end # Itemend # Item
end # SEEend # SEE
module ReadNotemodule ReadNote
def read_note(note, tag, position = 1)def read_note(note, tag, position = 1)
note2 = note.dup= note.dup
lines = note2.scan(/<.+>/)= note2.scan(/<.+>/)
for line in linesfor line in lines
words = line.split(/[ <>]/)= line.split(/[ <>]/)
words.delete("").delete("")
for word in wordsfor word in words
if word == tagif word == tag
result = words[words.index(word) + position]= words[words.index(word) + position]
return true if result == nilreturn true if result == nil
return resultreturn result
endend
endend
endend
return falsereturn false
endend
endend
class Scene_Item < Scene_ItemBaseclass Scene_Item < Scene_ItemBase
def startdef start
supersuper
create_description_window
create_category_window
create_item_window
@description_index = 0@description_index = 0
endend
def create_description_windowdef create_description_window
@description = Window_ItemDescription.new@description = Window_ItemDescription.new
@description.viewport = @viewport@description.viewport = @viewport
endend
def create_category_windowdef create_category_window
@category_window = Window_ItemCategory.new@category_window = Window_ItemCategory.new
@category_window.viewport = @viewport@category_window.viewport = @viewport
@category_window.y = @description.height@category_window.y = @description.height
@category_window.set_handler(:ok, method(:on_category_ok))@category_window.set_handler(:ok, method(:on_category_ok))
@category_window.set_handler(:cancel, method(:return_scene))@category_window.set_handler(:cancel, method(:return_scene))
endend
def create_item_windowdef create_item_window
wy = @category_window.y + @category_window.height= @category_window.y + @category_window.height
wh = Graphics.height - wy= Graphics.height - wy
@item_window = Window_ItemList.new(0, wy, Graphics.width, wh)@item_window = Window_ItemList.new(0, wy, Graphics.width, wh)
@item_window.set_handler(:ok, method(:on_item_ok))@item_window.set_handler(:ok, method(:on_item_ok))
@item_window.set_handler(:cancel, method(:on_item_cancel))@item_window.set_handler(:cancel, method(:on_item_cancel))
@category_window.item_window = @item_window@category_window.item_window = @item_window
@item_window.viewport = @viewport@item_window.viewport = @viewport
endend
def on_item_canceldef on_item_cancel
@item_window.unselect@item_window.unselect
@category_window.activate@category_window.activate
@description.refresh(nil)@description.refresh(nil)
endend
def updatedef update
supersuper
if @description_index != @item_window.indexif @description_index != @item_window.index
@description.refresh(@item_window.item)@description.refresh(@item_window.item)
@description_index = @item_window.index@description_index = @item_window.index
endend
endend
endend
class Window_ItemDescription < Window_Baseclass Window_ItemDescription < Window_Base
include ReadNoteReadNote
include SEE::Item::Item
def initialize(item = nil)def initialize(item = nil)
super(0, 0, Graphics.width, (Graphics.height - 288))super(0, 0, Graphics.width, (Graphics.height - 288))
refresh(item)(item)
end # initializeend # initialize
def refresh(item)def refresh(item)
self.contents.clearself.contents.clear
if item != nilif item != nil
if item.is_a?(RPG::Item)if item.is_a?(RPG::Item)
picture = read_note($data_items[item.id].note, "picture")= read_note($data_items[item.id].note, "picture")
elsif item.is_a?(RPG::Weapon)elsif item.is_a?(RPG::Weapon)
picture = read_note($data_weapons[item.id].note, "picture")= read_note($data_weapons[item.id].note, "picture")
elsif item.is_a?(RPG::Armor)elsif item.is_a?(RPG::Armor)
picture = read_note($data_armors[item.id].note, "picture")= read_note($data_armors[item.id].note, "picture")
endend
if picture != falseif picture != false
bitmap = Cache.picture(picture)= Cache.picture(picture)
rect = Rect.new(0, 0, 96, 96)= Rect.new(0, 0, 96, 96)
self.contents.blt(0, 0, bitmap, rect)self.contents.blt(0, 0, bitmap, rect)
endend
if item.is_a?(RPG::Item)if item.is_a?(RPG::Item)
if ITEMS[item.id] != nilif ITEMS[item.id] != nil
if ITEM_COLOURS[item.id] != nilif ITEM_COLOURS[item.id] != nil
self.contents.font.color = text_color(ITEM_COLOURS[item.id][0])self.contents.font.color = text_color(ITEM_COLOURS[item.id][0])
self.contents.draw_text(96, 0, width - 128, 24, ITEMS[item.id][0])self.contents.draw_text(96, 0, width - 128, 24, ITEMS[item.id][0])
self.contents.font.color = text_color(ITEM_COLOURS[item.id][1])self.contents.font.color = text_color(ITEM_COLOURS[item.id][1])
self.contents.draw_text(96, 24, width - 128, 24, ITEMS[item.id][1])self.contents.draw_text(96, 24, width - 128, 24, ITEMS[item.id][1])
self.contents.font.color = text_color(ITEM_COLOURS[item.id][2])self.contents.font.color = text_color(ITEM_COLOURS[item.id][2])
self.contents.draw_text(96, 48, width - 128, 24, ITEMS[item.id][2])self.contents.draw_text(96, 48, width - 128, 24, ITEMS[item.id][2])
self.contents.font.color = text_color(ITEM_COLOURS[item.id][3])self.contents.font.color = text_color(ITEM_COLOURS[item.id][3])
self.contents.draw_text(96, 72, width - 128, 24, ITEMS[item.id][3])self.contents.draw_text(96, 72, width - 128, 24, ITEMS[item.id][3])
self.contents.font.color = text_color(0)self.contents.font.color = text_color(0)
elseelse
self.contents.draw_text(96, 0, width - 128, 24, ITEMS[item.id][0])self.contents.draw_text(96, 0, width - 128, 24, ITEMS[item.id][0])
self.contents.draw_text(96, 24, width - 128, 24, ITEMS[item.id][1])self.contents.draw_text(96, 24, width - 128, 24, ITEMS[item.id][1])
self.contents.draw_text(96, 48, width - 128, 24, ITEMS[item.id][2])self.contents.draw_text(96, 48, width - 128, 24, ITEMS[item.id][2])
self.contents.draw_text(96, 72, width - 128, 24, ITEMS[item.id][3])self.contents.draw_text(96, 72, width - 128, 24, ITEMS[item.id][3])
endend
endend
elsif item.is_a?(RPG::Weapon)elsif item.is_a?(RPG::Weapon)
if WEAPONS[item.id] != nilif WEAPONS[item.id] != nil
if WEAPON_COLOURS[item.id] != nilif WEAPON_COLOURS[item.id] != nil
self.contents.font.color = text_color(WEAPON_COLOURS[item.id][0])self.contents.font.color = text_color(WEAPON_COLOURS[item.id][0])
self.contents.draw_text(96, 0, width - 128, 24, WEAPONS[item.id][0])self.contents.draw_text(96, 0, width - 128, 24, WEAPONS[item.id][0])
self.contents.font.color = text_color(WEAPON_COLOURS[item.id][1])self.contents.font.color = text_color(WEAPON_COLOURS[item.id][1])
self.contents.draw_text(96, 24, width - 128, 24, WEAPONS[item.id][1])self.contents.draw_text(96, 24, width - 128, 24, WEAPONS[item.id][1])
self.contents.font.color = text_color(WEAPON_COLOURS[item.id][2])self.contents.font.color = text_color(WEAPON_COLOURS[item.id][2])
self.contents.draw_text(96, 48, width - 128, 24, WEAPONS[item.id][2])self.contents.draw_text(96, 48, width - 128, 24, WEAPONS[item.id][2])
self.contents.font.color = text_color(WEAPON_COLOURS[item.id][3])self.contents.font.color = text_color(WEAPON_COLOURS[item.id][3])
self.contents.draw_text(96, 72, width - 128, 24, WEAPONS[item.id][3])self.contents.draw_text(96, 72, width - 128, 24, WEAPONS[item.id][3])
self.contents.font.color = text_color(0)self.contents.font.color = text_color(0)
elseelse
self.contents.draw_text(96, 0, width - 128, 24, WEAPONS[item.id][0])self.contents.draw_text(96, 0, width - 128, 24, WEAPONS[item.id][0])
self.contents.draw_text(96, 24, width - 128, 24, WEAPONS[item.id][1])self.contents.draw_text(96, 24, width - 128, 24, WEAPONS[item.id][1])
self.contents.draw_text(96, 48, width - 128, 24, WEAPONS[item.id][2])self.contents.draw_text(96, 48, width - 128, 24, WEAPONS[item.id][2])
self.contents.draw_text(96, 72, width - 128, 24, WEAPONS[item.id][3])self.contents.draw_text(96, 72, width - 128, 24, WEAPONS[item.id][3])
endend
endend
elsif item.is_a?(RPG::Armor)elsif item.is_a?(RPG::Armor)
if ARMORS[item.id] != nilif ARMORS[item.id] != nil
if ARMOR_COLOURS[item.id] != nilif ARMOR_COLOURS[item.id] != nil
self.contents.font.color = text_color(ARMOR_COLOURS[item.id][0])self.contents.font.color = text_color(ARMOR_COLOURS[item.id][0])
self.contents.draw_text(96, 0, width - 128, 24, ARMORS[item.id][0])self.contents.draw_text(96, 0, width - 128, 24, ARMORS[item.id][0])
self.contents.font.color = text_color(ARMOR_COLOURS[item.id][1])self.contents.font.color = text_color(ARMOR_COLOURS[item.id][1])
self.contents.draw_text(96, 24, width - 128, 24, ARMORS[item.id][1])self.contents.draw_text(96, 24, width - 128, 24, ARMORS[item.id][1])
self.contents.font.color = text_color(ARMOR_COLOURS[item.id][2])self.contents.font.color = text_color(ARMOR_COLOURS[item.id][2])
self.contents.draw_text(96, 48, width - 128, 24, ARMORS[item.id][2])self.contents.draw_text(96, 48, width - 128, 24, ARMORS[item.id][2])
self.contents.font.color = text_color(ARMOR_COLOURS[item.id][3])self.contents.font.color = text_color(ARMOR_COLOURS[item.id][3])
self.contents.draw_text(96, 72, width - 128, 24, ARMORS[item.id][3])self.contents.draw_text(96, 72, width - 128, 24, ARMORS[item.id][3])
self.contents.font.color = text_color(0)self.contents.font.color = text_color(0)
elseelse
self.contents.draw_text(96, 0, width - 128, 24, ARMORS[item.id][0])self.contents.draw_text(96, 0, width - 128, 24, ARMORS[item.id][0])
self.contents.draw_text(96, 24, width - 128, 24, ARMORS[item.id][1])self.contents.draw_text(96, 24, width - 128, 24, ARMORS[item.id][1])
self.contents.draw_text(96, 48, width - 128, 24, ARMORS[item.id][2])self.contents.draw_text(96, 48, width - 128, 24, ARMORS[item.id][2])
self.contents.draw_text(96, 72, width - 128, 24, ARMORS[item.id][3])self.contents.draw_text(96, 72, width - 128, 24, ARMORS[item.id][3])
endend
endend
endend
endend
end # refreshend # refresh
end # Window_ItemDescriptionend # Window_ItemDescription