Creato da:
Me (Mew47)
Utilità:
Integra la pausa stile giochi platform o la sostituisce il menu di base
istruzioni:
Nello script
Script:
Spoiler
=begin
Script di Mew47
Integra la funzione di pausa stile super mario
Per sostituirlo al menu di base modificare la riga 232 di Scene_Map cosi:
$scene = Scena_Pausa.new
Se invece si vuole mantenere il menu di base ed implementare questa funzione aggiungere cio che segue nella riga 167
def update_call_pausa
if Input.trigger?(Input::Y) #io ho impostato il tasto S,ma si puo cambiare a piacimento
return if $game_map.interpreter.running? # ????????
return if $game_system.menu_disabled # ????????
$game_temp.menu_beep = true # SE ???????
$game_temp.next_scene = "pausa"
end
end
e aggiungere cio che segue nella riga 197
when "pausa"
call_pausa
e aggiungere cio che segue nella riga 276
def call_pausa
if $game_temp.menu_beep
Sound.play_decision
$game_temp.menu_beep = false
end
$game_temp.next_scene = nil
$scene = Scena_Pausa.new
end
=end
class Finestra_Pausa < Window_Base
def initialize
super(220,180,85,60)
@testo = "Pausa"
refresh
end
def refresh
self.contents.clear
self.contents.draw_text(0,0,50,25,@testo,1)
end
def testo=(testo)
@testo = testo
refresh
end
end
class Scena_Pausa < Scene_Base
def start
super
create_background
@Finestra = Finestra_Pausa.new
@Finestra.testo = "Pausa"
end
def create_background
@background_sprite = Sprite.new
@background_sprite.bitmap = $game_temp.background_bitmap
@background_sprite.color.set(16, 16, 16, 128)
end
def dispose_background
@background_sprite.dispose
end
def update
super
fine_pausa if Input.trigger?(Input::B)#io ho impostato il tasto X/ESC,ma si puo cambiare a piacimento
end
def fine_pausa
Sound.play_cancel
$scene = Scene_Map.new
end
def terminate
super
@Finestra.dispose
dispose_background
end
end
Script di Mew47
Integra la funzione di pausa stile super mario
Per sostituirlo al menu di base modificare la riga 232 di Scene_Map cosi:
$scene = Scena_Pausa.new
Se invece si vuole mantenere il menu di base ed implementare questa funzione aggiungere cio che segue nella riga 167
def update_call_pausa
if Input.trigger?(Input::Y) #io ho impostato il tasto S,ma si puo cambiare a piacimento
return if $game_map.interpreter.running? # ????????
return if $game_system.menu_disabled # ????????
$game_temp.menu_beep = true # SE ???????
$game_temp.next_scene = "pausa"
end
end
e aggiungere cio che segue nella riga 197
when "pausa"
call_pausa
e aggiungere cio che segue nella riga 276
def call_pausa
if $game_temp.menu_beep
Sound.play_decision
$game_temp.menu_beep = false
end
$game_temp.next_scene = nil
$scene = Scena_Pausa.new
end
=end
class Finestra_Pausa < Window_Base
def initialize
super(220,180,85,60)
@testo = "Pausa"
refresh
end
def refresh
self.contents.clear
self.contents.draw_text(0,0,50,25,@testo,1)
end
def testo=(testo)
@testo = testo
refresh
end
end
class Scena_Pausa < Scene_Base
def start
super
create_background
@Finestra = Finestra_Pausa.new
@Finestra.testo = "Pausa"
end
def create_background
@background_sprite = Sprite.new
@background_sprite.bitmap = $game_temp.background_bitmap
@background_sprite.color.set(16, 16, 16, 128)
end
def dispose_background
@background_sprite.dispose
end
def update
super
fine_pausa if Input.trigger?(Input::B)#io ho impostato il tasto X/ESC,ma si puo cambiare a piacimento
end
def fine_pausa
Sound.play_cancel
$scene = Scene_Map.new
end
def terminate
super
@Finestra.dispose
dispose_background
end
end