- WirethMembre
- Nombre de messages : 99
Distinction : aucune
Date d'inscription : 04/04/2017
Bug de menu
Sam 15 Avr 2017 - 19:30
Hey ! bon je suis un peu fatiguer je suis malade alors permettez moi d'aller droit au but,
quand j'ouvre mon jeu tout fonctionne correctement mais par contre quand je clique pour ouvrir le menu mon jeu crash m'indiquant qu'il y a un bug dans le script. Pourtant j'ai remit plusieur fois le script initiale du menu dans Windows_menucommand mais rien y faire, même crash, voici le screen du message d'erreur et des lignes en question
merci de m'aider ;-;
quand j'ouvre mon jeu tout fonctionne correctement mais par contre quand je clique pour ouvrir le menu mon jeu crash m'indiquant qu'il y a un bug dans le script. Pourtant j'ai remit plusieur fois le script initiale du menu dans Windows_menucommand mais rien y faire, même crash, voici le screen du message d'erreur et des lignes en question
merci de m'aider ;-;
- WirethMembre
- Nombre de messages : 99
Distinction : aucune
Date d'inscription : 04/04/2017
Re: Bug de menu
Sam 15 Avr 2017 - 20:49
- SpytjeAdministrateur
- Nombre de messages : 5935
Localisation : La terre
Distinction : Spiraliste [Korn']
Forestia : Projet du mois juillet 2014
Papy Pulkigrat [Yama']
Date d'inscription : 16/03/2008
Re: Bug de menu
Sam 15 Avr 2017 - 20:52
Est ce que tu as modifier des scripts dans ton projet ?
Si oui il faudrait que tu les donnes.
Apparemment la méthode "add_command" que tu appelles n'existe pas.
Si oui il faudrait que tu les donnes.
Apparemment la méthode "add_command" que tu appelles n'existe pas.
- WirethMembre
- Nombre de messages : 99
Distinction : aucune
Date d'inscription : 04/04/2017
Re: Bug de menu
Sam 15 Avr 2017 - 20:57
justement, je l'avais modifier, oui. Mais pas pour Window_choiceList ! Et même en remettant le script par défaut rien a faire le bug persiste, et j'ai peur que d'autre script soit corrompu...
Voici malgré tout les deux script en question
Voici malgré tout les deux script en question
- Choice list:
- #==============================================================================
# ** Window_ChoiceList
#------------------------------------------------------------------------------
# This window is used for the event command [Show Choices].
#==============================================================================
class Window_ChoiceList < Window_Command
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize(message_window)
@message_window = message_window
super(0, 0)
self.openness = 0
deactivate
end
#--------------------------------------------------------------------------
# * Start Input Processing
#--------------------------------------------------------------------------
def start
update_placement
refresh
select(0)
open
activate
end
#--------------------------------------------------------------------------
# * Update Window Position
#--------------------------------------------------------------------------
def update_placement
self.width = [max_choice_width + 12, 96].max + padding * 2
self.width = [width, Graphics.width].min
self.height = fitting_height($game_message.choices.size)
self.x = Graphics.width - width
if @message_window.y >= Graphics.height / 2
self.y = @message_window.y - height
else
self.y = @message_window.y + @message_window.height
end
end
#--------------------------------------------------------------------------
# * Get Maximum Width of Choices
#--------------------------------------------------------------------------
def max_choice_width
$game_message.choices.collect {|s| text_size(s).width }.max
end
#--------------------------------------------------------------------------
# * Calculate Height of Window Contents
#--------------------------------------------------------------------------
def contents_height
item_max * item_height
end
#--------------------------------------------------------------------------
# * Create Command List
#--------------------------------------------------------------------------
def make_command_list
$game_message.choices.each do |choice|
add_command(choice, :choice)
end
end
#--------------------------------------------------------------------------
# * Draw Item
#--------------------------------------------------------------------------
def draw_item(index)
rect = item_rect_for_text(index)
draw_text_ex(rect.x, rect.y, command_name(index))
end
#--------------------------------------------------------------------------
# * Get Activation State of Cancel Processing
#--------------------------------------------------------------------------
def cancel_enabled?
$game_message.choice_cancel_type > 0
end
#--------------------------------------------------------------------------
# * Call OK Handler
#--------------------------------------------------------------------------
def call_ok_handler
$game_message.choice_proc.call(index)
close
end
#--------------------------------------------------------------------------
# * Call Cancel Handler
#--------------------------------------------------------------------------
def call_cancel_handler
$game_message.choice_proc.call($game_message.choice_cancel_type - 1)
close
end
end
- Window command:
- #==============================================================================
# ** Window_MenuCommand
#------------------------------------------------------------------------------
# This command window appears on the menu screen.
#==============================================================================
class Window_MenuCommand < Window_Command
#--------------------------------------------------------------------------
# * Initialize Command Selection Position (Class Method)
#--------------------------------------------------------------------------
def self.init_command_position
@@last_command_symbol = nil
end
#--------------------------------------------------------------------------
# * Object Initialization
#--------------------------------------------------------------------------
def initialize
super(0, 0)
select_last
end
#--------------------------------------------------------------------------
# * Get Window Width
#--------------------------------------------------------------------------
def window_width
return 160
end
#--------------------------------------------------------------------------
# * Get Number of Lines to Show
#--------------------------------------------------------------------------
def visible_line_number
item_max
end
#--------------------------------------------------------------------------
# * Create Command List
#--------------------------------------------------------------------------
def make_command_list
add_main_commands
add_formation_command
add_original_commands
add_save_command
add_game_end_command
end
#--------------------------------------------------------------------------
# * Add Main Commands to List
#--------------------------------------------------------------------------
def add_main_commands
add_command(Vocab::item, :item, main_commands_enabled)
add_command(Vocab::status, :status, main_commands_enabled)
end
#--------------------------------------------------------------------------
# * Add Formation to Command List
#--------------------------------------------------------------------------
def add_formation_command
add_command(Vocab::formation, :formation, formation_enabled)
end
#--------------------------------------------------------------------------
# * For Adding Original Commands
#--------------------------------------------------------------------------
def add_original_commands
end
#--------------------------------------------------------------------------
# * Add Save to Command List
#--------------------------------------------------------------------------
def add_save_command
add_command(Vocab::save, :save, save_enabled)
end
#--------------------------------------------------------------------------
# * Add Exit Game to Command List
#--------------------------------------------------------------------------
def add_game_end_command
add_command(Vocab::game_end, :game_end)
end
#--------------------------------------------------------------------------
# * Get Activation State of Main Commands
#--------------------------------------------------------------------------
def main_commands_enabled
$game_party.exists
end
#--------------------------------------------------------------------------
# * Get Activation State of Formation
#--------------------------------------------------------------------------
def formation_enabled
$game_party.members.size >= 2 && !$game_system.formation_disabled
end
#--------------------------------------------------------------------------
# * Get Activation State of Save
#--------------------------------------------------------------------------
def save_enabled
!$game_system.save_disabled
end
#--------------------------------------------------------------------------
# * Processing When OK Button Is Pressed
#--------------------------------------------------------------------------
def process_ok
@@last_command_symbol = current_symbol
super
end
#--------------------------------------------------------------------------
# * Restore Previous Selection Position
#--------------------------------------------------------------------------
def select_last
select_symbol(@@last_command_symbol)
end
end
- SpytjeAdministrateur
- Nombre de messages : 5935
Localisation : La terre
Distinction : Spiraliste [Korn']
Forestia : Projet du mois juillet 2014
Papy Pulkigrat [Yama']
Date d'inscription : 16/03/2008
Re: Bug de menu
Sam 15 Avr 2017 - 22:12
Tu utilises quoi d'autres comme scripts ?
Tu en as ajoutés ?
Tu en as ajoutés ?
Re: Bug de menu
Dim 16 Avr 2017 - 9:40
Woopopop!!!!
Ton Spoiler Window command, contient le script Window_MenuCommand, ce qui est complètement différent.
Donc récupère bien la classe Window_Command et remet là en place dans le script Window_Command
Ton Spoiler Window command, contient le script Window_MenuCommand, ce qui est complètement différent.
Donc récupère bien la classe Window_Command et remet là en place dans le script Window_Command
- problème Iconset/script menu tournent /marchand/menu compétence/etc.... [résolu]
- [Menu, Keybind et Map] Script - Affichage de la carte par pression d'un bind ou menu.
- Nouveau menu en combat (reprise graphique) Edit: v2 du menu !!
- script menu (affichage du temps et du nom de la map dans le menu)
- Menu Parchemin 1.0 (Menu Principal personnalisé)
Permission de ce forum:
Vous ne pouvez pas répondre aux sujets dans ce forum
|
|