14-09-2011, 12:33 PM
DESCRIZIONE:
Questo script aggiunge una banca dove depositare o prelevare soldi... Voi direte: "Ma a che serve?". E io vi rispondo: "Continuate a leggere!" xD.
In aggiunta al solito "deposita e preleva", potrete investire il vostro denaro in due differenti modi:
-Più cammini, più guadagni;
-Più tempo giochi, più guadagni!
AUTORE/I:
gino
ISTRUZIONI:
Inserire lo script sotto Materials.
Per avviare la banca inserire in un call sript
SCRIPT:[SPOILER][/SPOILER]
BUG E CONFLITTI NOTI:
Nessuno
Questo script aggiunge una banca dove depositare o prelevare soldi... Voi direte: "Ma a che serve?". E io vi rispondo: "Continuate a leggere!" xD.
In aggiunta al solito "deposita e preleva", potrete investire il vostro denaro in due differenti modi:
-Più cammini, più guadagni;
-Più tempo giochi, più guadagni!
AUTORE/I:
gino
ISTRUZIONI:
Inserire lo script sotto Materials.
Per avviare la banca inserire in un call sript
Codice:
$scene = Scene_Bank.new
SCRIPT:[SPOILER]
Codice:
#===============================================================================
# GINO_BankSystem
#===============================================================================
#
# Put the command:
# $scene = Scene_Bank.new
# in CallScript inside an event.
#
#===============================================================================
#===============================================================================
# EDIT HERE
#===============================================================================
module BANK
#Commands' Text
CMDTEXT = ["Deposita", #0
"Ritira", #1
"Investi", #2
"Disinvesti", #3
"Esci", #4
"Sì", #5
"No", #6
"Step's Bros.", #7
"Clock&Watch", #8
]
#Messages' Text
MSGTEXT = ["Come posso aiutarla?", #0
"Quanto vuole depositare?", #1
"Sei sicuro di depositare % &?", #2
"Spiacente, ma lei non ha % & da depositare!", #3
"Grazie. Il suo denaro è stato depositato con successo.", #4
"Quanto vuoi ritirare?", #5
"Sei sicuro di voler ritirare % &?", #6
"Grazie. Il suo denaro è stato ritirato con successo.", #7
"Scegli quali azioni intendi comprare.", #8
"Acquista azioni Step's Bros. Costo unitario = 100 &", #9
"Acquista azioni Clock&Watch. Costo unitario = 100 %", #10
"Spiacente, ma lei non ha % & da investire!", #11
"Grazie. Il suo denaro è stato investito con successo.", #12
"Scegli quali azioni intendi disinvestire.", #13
"Quante azioni Step's Bros vuoi disinvestire?", #14
"Quante azioni Clock&Watch vuoi disinvestire?", #15
"Confermi l'acquisto di % azioni Step's Bros.?", #16
"Confermi l'acquisto di % azioni Clock&Watch?", #17
"Grazie. Il suo denaro è stato disinvestito con successo.", #18
"Spiacente, ma lei non ha % & da ritirare!", #19
"Confermi la vendita di % azioni Step's Bros.?", #20
"Confermi la vendita di % azioni Clock&Watch?", #21
"Non possiedi % azioni della Step's Bros.!", #22
"Non possiedi % azioni della Clock&Watch!", #23
]
#Helps' Text
HELPTEXT = ["Posseduti", #0
"Depositati", #1
"Step's Bros.", #2
"Clock&Watch", #3
"Investiti", #4
]
#Storage Variables
MEMORIZE = 19 #Temporarily stores gold involved in transation
DEPOSIT = 20 #Stores gold deposited in bank
SSTOCKS = 25 #Stores number of Step Stocks
TSTOCKS = 26 #Stores number of Time Stocks
SSTEPS = 23 #Stores initial Stepcount
TGT = 24 #Stores initial Gametime
end
#===============================================================================
# CAN'T TOUCH BELOW THIS LINE
#===============================================================================
#===============================================================================
# Window_BankMessage
#===============================================================================
class Window_BankMessage < Window_Base
def initialize(message)
super(0, 0, 544, WLH + 40)
@message = message
refresh
end
def refresh
self.contents.draw_text(0, 0, 512, WLH, @message, 1)
end
end
#===============================================================================
# Window_InHand
#===============================================================================
class Window_InHand < Window_Base
def initialize
super(0, 0, 160, WLH + 62)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(0, 0, 136, WLH, BANK::HELPTEXT[0], 0)
self.contents.font.color = normal_color
draw_currency_value($game_party.gold, 4, 32, 120)
end
end
#===============================================================================
# Window_InBank
#===============================================================================
class Window_InBank < Window_Base
def initialize
super(0, 0, 160, WLH + 62)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(0, 0, 136, WLH, BANK::HELPTEXT[1], 0)
self.contents.font.color = normal_color
draw_currency_value($game_variables[BANK::DEPOSIT], 4, 32, 120)
end
end
#===============================================================================
# Window_SInvested
#===============================================================================
class Window_SInvested < Window_Base
def initialize
super(0, 0, 160, WLH + 62)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(0, 0, 136, WLH, BANK::HELPTEXT[2], 0)
self.contents.font.color = normal_color
tot = $game_variables[BANK::SSTOCKS] * 100
draw_currency_value(tot, 4, 32, 120)
end
end
#===============================================================================
# Window_TInvested
#===============================================================================
class Window_TInvested < Window_Base
def initialize
super(0, 0, 160, WLH + 62)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(0, 0, 136, WLH, BANK::HELPTEXT[3], 0)
self.contents.font.color = normal_color
tot = $game_variables[BANK::TSTOCKS] * 100
draw_currency_value(tot, 4, 32, 120)
end
end
#===============================================================================
# Window_AllInvested
#===============================================================================
class Window_AllInvested < Window_Base
def initialize
super(0, 0, 160, WLH + 62)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(0, 0, 136, WLH, BANK::HELPTEXT[4], 0)
self.contents.font.color = normal_color
tot = ($game_variables[BANK::SSTOCKS] + $game_variables[BANK::TSTOCKS]) * 100
draw_currency_value(tot, 4, 32, 120)
end
end
#===============================================================================
# Window_BankInput
#===============================================================================
class Window_BankInput < Window_Base
def initialize
super(0, 0, 190, 64)
@number = 0
@digits_max = 6
@index = 0
self.opacity = 0
self.active = false
self.z += 9999
refresh
update_cursor
end
def number
return @number
end
def number=(number)
@number = [[number, 0].max, 10 ** @digits_max - 1].min
@index = 0
refresh
end
def digits_max
return @digits_max
end
def digits_max=(digits_max)
@digits_max = digits_max
refresh
end
def cursor_right(wrap)
if @index < @digits_max - 1 or wrap
@index = (@index + 1) % @digits_max
end
end
def cursor_left(wrap)
if @index > 0 or wrap
@index = (@index + @digits_max - 1) % @digits_max
end
end
def update
super
if self.active
if Input.repeat?(Input::UP) or Input.repeat?(Input::DOWN)
Sound.play_cursor
place = 10 ** (@digits_max - 1 - @index)
n = @number / place % 10
@number -= n * place
n = (n + 1) % 10 if Input.repeat?(Input::UP)
n = (n + 9) % 10 if Input.repeat?(Input::DOWN)
@number += n * place
refresh
end
last_index = @index
if Input.repeat?(Input::RIGHT)
cursor_right(Input.trigger?(Input::RIGHT))
end
if Input.repeat?(Input::LEFT)
cursor_left(Input.trigger?(Input::LEFT))
end
if @index != last_index
Sound.play_cursor
end
update_cursor
end
end
def refresh
self.contents.clear
self.contents.font.color = normal_color
s = sprintf("%0*d", @digits_max, @number)
for i in 0...@digits_max
self.contents.draw_text(24 + i * 16, 0, 16, WLH, s[i,1], 1)
end
end
def update_cursor
self.cursor_rect.set(24 + @index * 16, 0, 16, WLH)
end
end
#===============================================================================
# Scene_Bank
#===============================================================================
class Scene_Bank < Scene_Base
def start
super
create_menu_background
create_main_windows
create_command_window
end
def terminate
super
dispose_menu_background
@command_window.dispose
@main.dispose
@inhand.dispose
@inbank.dispose
@allinvested.dispose
end
def update
super
@command_window.update
if @command_window.active
update_command
end
end
def create_main_windows
@main = Window_BankMessage.new(BANK::MSGTEXT[0])
@inhand = Window_InHand.new
@inhand.y = (416 - @inhand.height)
@inbank = Window_InBank.new
@inbank.x = @inhand.width
@inbank.y = (416 - @inbank.height)
@allinvested = Window_AllInvested.new
@allinvested.x = @inhand.width + @inbank.width
@allinvested.y = (416 - @allinvested.height)
end
def create_command_window
@command_window = Window_Command.new(160, [BANK::CMDTEXT[0], BANK::CMDTEXT[1], BANK::CMDTEXT[2], BANK::CMDTEXT[3], BANK::CMDTEXT[4]])
@command_window.index = 0
@command_window.y = @main.y + @main.height
end
def update_command
if Input.trigger?(Input::B)
$scene = Scene_Map.new
elsif Input.trigger?(Input::C)
Sound.play_decision
case @command_window.index
when 0
$scene = Scene_Deposit.new
when 1
$scene = Scene_Withdraw.new
when 2
$scene = Scene_PreInvest.new
when 3
$scene = Scene_PreDivest.new
when 4
$scene = Scene_Map.new
end
end
end
end
#===============================================================================
# Scene_Deposit
#===============================================================================
class Scene_Deposit < Scene_Base
def start
super
create_menu_background
create_main_windows
end
def terminate
super
dispose_menu_background
@number_window.dispose
@main.dispose
end
def update
super
@number_window.update
if Input.trigger?(Input::B)
$scene = Scene_Bank.new
elsif Input.trigger?(Input::C)
Sound.play_decision
$game_variables[BANK::MEMORIZE] = @number_window.number
$scene = Scene_Confirm.new(1)
end
end
def create_main_windows
@main = Window_BankMessage.new(BANK::MSGTEXT[1])
@number_window = Window_BankInput.new
@number_window.digits_max = 7
@number_window.active = true
@number_window.number = $game_variables[BANK::DEPOSIT]
@number_window.opacity = 255
@number_window.y = @main.height
end
end
#===============================================================================
# Scene_Withdraw
#===============================================================================
class Scene_Withdraw < Scene_Base
def start
super
create_menu_background
create_main_windows
end
def terminate
super
dispose_menu_background
@number_window.dispose
@main.dispose
end
def update
super
@number_window.update
if Input.trigger?(Input::B)
$scene = Scene_Bank.new
elsif Input.trigger?(Input::C)
$game_variables[BANK::MEMORIZE] = @number_window.number
$scene = Scene_Confirm.new(2)
end
end
def create_main_windows
@main = Window_BankMessage.new(BANK::MSGTEXT[5])
@number_window = Window_BankInput.new
@number_window.digits_max = 7
@number_window.active = true
@number_window.number = $game_variables[BANK::DEPOSIT]
@number_window.opacity = 255
@number_window.y = @main.height
end
end
#===============================================================================
# Scene_PreInvest
#===============================================================================
class Scene_PreInvest < Scene_Base
def start
super
create_menu_background
create_main_windows
create_command_window
end
def terminate
super
dispose_menu_background
@command_window.dispose
@main.dispose
@sinvested.dispose
@tinvested.dispose
end
def update
super
@command_window.update
if @command_window.active
update_command
end
end
def create_main_windows
@main = Window_BankMessage.new(BANK::MSGTEXT[8])
@sinvested = Window_SInvested.new
@sinvested.y = (416 - @sinvested.height)
@tinvested = Window_TInvested.new
@tinvested.x = @sinvested.width
@tinvested.y = (416 - @tinvested.height)
end
def create_command_window
@command_window = Window_Command.new(180, [BANK::CMDTEXT[7], BANK::CMDTEXT[8], BANK::CMDTEXT[4]])
@command_window.index = 0
@command_window.y = @main.y + @main.height
end
def update_command
if Input.trigger?(Input::B)
$scene = Scene_Bank.new
elsif Input.trigger?(Input::C)
Sound.play_decision
case @command_window.index
when 0
$scene = Scene_Invest.new(1)
when 1
$scene = Scene_Invest.new(2)
when 2
$scene = Scene_Bank.new
end
end
end
end
#===============================================================================
# Scene_PreDivest
#===============================================================================
class Scene_PreDivest < Scene_Base
def start
super
create_menu_background
create_main_windows
create_command_window
end
def terminate
super
dispose_menu_background
@command_window.dispose
@main.dispose
@sinvested.dispose
@tinvested.dispose
end
def update
super
@command_window.update
if @command_window.active
update_command
end
end
def create_main_windows
@main = Window_BankMessage.new(BANK::MSGTEXT[13])
@sinvested = Window_SInvested.new
@sinvested.y = (416 - @sinvested.height)
@tinvested = Window_TInvested.new
@tinvested.x = @sinvested.width
@tinvested.y = (416 - @tinvested.height)
end
def create_command_window
@command_window = Window_Command.new(160, [BANK::CMDTEXT[7], BANK::CMDTEXT[8], BANK::CMDTEXT[4]])
@command_window.index = 0
@command_window.y = @main.y + @main.height
#semi-transparent button if there's no stock
@command_window.draw_item(0, false) if $game_variables[BANK::SSTOCKS] == 0
@command_window.draw_item(1, false) if $game_variables[BANK::TSTOCKS] == 0
#@@
end
def update_command
if Input.trigger?(Input::B)
$scene = Scene_Map.new
elsif Input.trigger?(Input::C)
Sound.play_decision
case @command_window.index
when 0
if $game_variables[BANK::SSTOCKS] != 0
$scene = Scene_Divest.new(1)
else
Sound.play_buzzer
end
when 1
if $game_variables[BANK::TSTOCKS] != 0
$scene = Scene_Divest.new(2)
else
Sound.play_buzzer
end
when 2
$scene = Scene_Bank.new
end
end
end
end
#===============================================================================
# Scene_Invest
#===============================================================================
class Scene_Invest < Scene_Base
def initialize(scene)
@scene = scene
end
def start
super
create_menu_background
create_main_windows
end
def terminate
super
dispose_menu_background
@main.dispose
@sinvested.dispose
@tinvested.dispose
@number_window.dispose
end
def update
super
@number_window.update
if Input.trigger?(Input::B)
$scene = Scene_PreInvest.new
elsif Input.trigger?(Input::C)
Sound.play_decision
$game_variables[BANK::MEMORIZE] = @number_window.number
$scene = Scene_Confirm.new(2 + @scene)
end
end
def create_main_windows
if @scene == 1 #Step Invest
@main = Window_BankMessage.new(BANK::MSGTEXT[9].gsub(/&/) {$data_system.terms.gold})
@number_window = Window_BankInput.new
@number_window.digits_max = 5
@number_window.active = true
@number_window.number = 0
@number_window.opacity = 255
@number_window.y = @main.height
elsif @scene == 2 #Time Invest
@main = Window_BankMessage.new(BANK::MSGTEXT[10].gsub(/%/) {$data_system.terms.gold})
@number_window = Window_BankInput.new
@number_window.digits_max = 5
@number_window.active = true
@number_window.number = 0
@number_window.opacity = 255
@number_window.y = @main.height
end
@sinvested = Window_SInvested.new
@sinvested.y = (416 - @sinvested.height)
@tinvested = Window_TInvested.new
@tinvested.x = @sinvested.width
@tinvested.y = (416 - @tinvested.height)
end
end #class
#===============================================================================
# Scene_Divest
#===============================================================================
class Scene_Divest < Scene_Base
def initialize(scene)
@scene = scene
end
def start
super
create_menu_background
create_main_windows
end
def terminate
super
dispose_menu_background
@main.dispose
@sinvested.dispose
@tinvested.dispose
@number_window.dispose
end
def update
super
@number_window.update
if Input.trigger?(Input::B)
$scene = Scene_PreDivest.new
elsif Input.trigger?(Input::C)
Sound.play_decision
$game_variables[BANK::MEMORIZE] = @number_window.number
$scene = Scene_Confirm.new(4 + @scene)
end
end
def create_main_windows
if @scene == 1 #Step Divest
@main = Window_BankMessage.new(BANK::MSGTEXT[14])
@number_window = Window_BankInput.new
@number_window.digits_max = 5
@number_window.active = true
@number_window.number = 0
@number_window.opacity = 255
@number_window.y = @main.height
elsif @scene == 2 #Time Divest
@main = Window_BankMessage.new(BANK::MSGTEXT[15])
@number_window = Window_BankInput.new
@number_window.digits_max = 5
@number_window.active = true
@number_window.number = 0
@number_window.opacity = 255
@number_window.y = @main.height
end
@sinvested = Window_SInvested.new
@sinvested.y = (416 - @sinvested.height)
@tinvested = Window_TInvested.new
@tinvested.x = @sinvested.width
@tinvested.y = (416 - @tinvested.height)
end
end #class
#===============================================================================
# Scene_Confirm
#===============================================================================
class Scene_Confirm < Scene_Base
def get_time_int(stocks)
time = Graphics.frame_count / Graphics.frame_rate - $game_variables[BANK::TGT]
return (time / 144) * stocks
end
def get_step_int(stocks)
steps = $game_party.steps - $game_variables[BANK::SSTEPS]
return (steps / 288) * stocks
end
def initialize(scene)
@scene = scene
end
def start
super
create_menu_background
create_main_windows
end
def terminate
super
dispose_menu_background
@main.dispose
@command_window.dispose
end
def update
super
@command_window.update
if @command_window.active
update_command
end
end
def create_main_windows
if @scene == 1 #deposit
@main = Window_BankMessage.new(BANK::MSGTEXT[2].gsub(/% &/) {$game_variables[BANK::MEMORIZE].to_s + " " + $data_system.terms.gold})
elsif @scene == 2 #withdraw
@main = Window_BankMessage.new(BANK::MSGTEXT[6].gsub(/% &/) {$game_variables[BANK::MEMORIZE].to_s + " " + $data_system.terms.gold})
elsif @scene == 3 #step_invest
@main = Window_BankMessage.new(BANK::MSGTEXT[16].gsub(/%/) {$game_variables[BANK::MEMORIZE].to_s})
elsif @scene == 4 #time_invest
@main = Window_BankMessage.new(BANK::MSGTEXT[17].gsub(/%/) {$game_variables[BANK::MEMORIZE].to_s})
elsif @scene == 5 #step_divest
@main = Window_BankMessage.new(BANK::MSGTEXT[20].gsub(/%/) {$game_variables[BANK::MEMORIZE].to_s})
elsif @scene == 6 #time_divest
@main = Window_BankMessage.new(BANK::MSGTEXT[21].gsub(/%/) {$game_variables[BANK::MEMORIZE].to_s})
end
@command_window = Window_Command.new(160, [BANK::CMDTEXT[5], BANK::CMDTEXT[6]])
@command_window.x = (544 - @command_window.width) / 2
@command_window.y = 200
end
def update_command
if Input.trigger?(Input::B)
if @scene == 1 #deposit
$scene = Scene_Deposit.new
elsif @scene == 2 #withdraw
$scene = Scene_Withdraw.new
elsif @scene == 3 #step_invest
$scene = Scene_Invest.new(1)
elsif @scene == 4 #time_invest
$scene = Scene_Invest.new(2)
elsif @scene == 5 #step_divest
$scene = Scene_Divest.new(1)
elsif @scene == 6 #time_divest
$scene = Scene_Divest.new(2)
end
elsif Input.trigger?(Input::C)
case @command_window.index
when 0
if @scene == 1 #deposit
if $game_variables[BANK::MEMORIZE] > $game_party.gold
Sound.play_buzzer
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[3].gsub(/% &/) {$game_variables[BANK::MEMORIZE].to_s + " " + $data_system.terms.gold})
Graphics.wait(60)
$scene = Scene_Deposit.new
elsif $game_variables[BANK::MEMORIZE] <= $game_party.gold
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_variables[BANK::DEPOSIT] += $game_variables[BANK::MEMORIZE]
$game_party.lose_gold($game_variables[BANK::MEMORIZE])
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[4])
Graphics.wait(60)
$scene = Scene_Bank.new
end #if
elsif @scene == 2 #withdraw
if $game_variables[BANK::MEMORIZE] > $game_variables[BANK::DEPOSIT]
Sound.play_buzzer
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[19].gsub(/% &/) {$game_variables[BANK::MEMORIZE].to_s + " " + $data_system.terms.gold})
Graphics.wait(60)
$scene = Scene_Withdraw.new
elsif $game_variables[BANK::MEMORIZE] <= $game_variables[BANK::DEPOSIT]
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_party.gain_gold($game_variables[BANK::MEMORIZE])
$game_variables[BANK::DEPOSIT] -= $game_variables[BANK::MEMORIZE]
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[7])
Graphics.wait(60)
$scene = Scene_Bank.new
end
elsif @scene == 3 #step_invest
if $game_variables[BANK::SSTOCKS] > 0
int = get_step_int($game_variables[BANK::SSTOCKS])
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_party.gain_gold(int)
Graphics.wait(60)
end
value = $game_variables[BANK::MEMORIZE] * 100
if value > $game_party.gold
Sound.play_buzzer
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[11].gsub(/% &/) {value.to_s + " " + $data_system.terms.gold})
Graphics.wait(60)
$scene = Scene_Invest.new(1)
elsif value <= $game_party.gold
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_variables[BANK::SSTOCKS] += $game_variables[BANK::MEMORIZE]
$game_party.lose_gold(value)
$game_variables[BANK::SSTEPS] = $game_party.steps
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[12])
Graphics.wait(60)
$scene = Scene_Bank.new
end #if
elsif @scene == 4 #time_invest
if $game_variables[BANK::TSTOCKS] > 0
int = get_time_int($game_variables[BANK::TSTOCKS])
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_party.gain_gold(int)
Graphics.wait(60)
end
value = $game_variables[BANK::MEMORIZE] * 100
if value > $game_party.gold
Sound.play_buzzer
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[11].gsub(/% &/) {value.to_s + " " + $data_system.terms.gold})
Graphics.wait(60)
$scene = Scene_Invest.new(2)
elsif value <= $game_party.gold
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_variables[BANK::TSTOCKS] += $game_variables[BANK::MEMORIZE]
$game_party.lose_gold(value)
$game_variables[BANK::TGT] = Graphics.frame_count / Graphics.frame_rate
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[12])
Graphics.wait(60)
$scene = Scene_Bank.new
end #if
elsif @scene == 5 #step_divest
if $game_variables[BANK::MEMORIZE] > $game_variables[BANK::SSTOCKS]
Sound.play_buzzer
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[22].gsub(/%/) {$game_variables[BANK::MEMORIZE].to_s})
Graphics.wait(60)
$scene = Scene_Divest.new(1)
elsif $game_variables[BANK::MEMORIZE] <= $game_variables[BANK::SSTOCKS]
int = get_step_int($game_variables[BANK::SSTOCKS])
int += 100 * $game_variables[BANK::MEMORIZE]
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_variables[BANK::SSTOCKS] -= $game_variables[BANK::MEMORIZE]
$game_party.gain_gold(int)
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[18])
Graphics.wait(60)
$scene = Scene_Bank.new
end
elsif @scene == 6 #time_divest
if $game_variables[BANK::MEMORIZE] > $game_variables[BANK::TSTOCKS]
Sound.play_buzzer
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[23].gsub(/%/) {$game_variables[BANK::MEMORIZE].to_s})
Graphics.wait(60)
$scene = Scene_Divest.new(2)
elsif $game_variables[BANK::MEMORIZE] <= $game_variables[BANK::TSTOCKS]
int = get_time_int($game_variables[BANK::TSTOCKS])
int += 100 * $game_variables[BANK::MEMORIZE]
Audio.se_play("Audio/SE/Shop", 100, 100)
$game_variables[BANK::TSTOCKS] -= $game_variables[BANK::MEMORIZE]
$game_party.gain_gold(int)
@main.dispose
@main = Window_BankMessage.new(BANK::MSGTEXT[18])
Graphics.wait(60)
$scene = Scene_Bank.new
end
end #if
when 1
if @scene == 1 #deposit
$scene = Scene_Deposit.new
elsif @scene == 2 #withdraw
$scene = Scene_Withdraw.new
elsif @scene == 3 #step_invest
$scene = Scene_Invest.new(1)
elsif @scene == 4 #time_invest
$scene = Scene_Invest.new(2)
elsif @scene == 5 #step_divest
$scene = Scene_Divest.new(1)
elsif @scene == 6 #time_divest
$scene = Scene_Divest.new(2)
end #if
end #case
end #if
end #def
end #class
BUG E CONFLITTI NOTI:
Nessuno