[Aide] Super script customisable

La création de jeux indépendants/amateurs (tuto, entraide, questions...) sous les moteurs de la série RPG Maker.
Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

[Aide] Super script customisable

Message non lu par Ddken » mar. févr. 08, 2011 9:12 pm

Bonjour à tous. J'aimerais faire un menu customisable (c'est-à-dire qu'on peut le dessiner). Mais pas seulement: J'aimerais
-l'ajout d'un bestiaire,
-la suppression de l'option sauvegarder,
-l'ajout d'une musique pour menu.
Donc en gros, tu as peut-être "American Boy" en BGM de map. Puis, quand tu mets pause, ça s'arrête et puis la BGM "Stronger" débute. Dans le menu, "sauvegarder" est remplacé par "bestiaire". Quand tout est ok, j'enlève pause et la, la BGM "American boy" reprend.
Si vraiment, ce n'est pas trop vous demander... Merci d'avance.
Je suis celui qui marquera toute une génération!

Raytwo-x
Koruldia Master
Messages : 2041

Message non lu par Raytwo-x » mar. févr. 08, 2011 10:09 pm

Bah tout dépend de ce que tu veux faire, c'est pas très précis.

C'est le menu customisable que tu veux, ou seulement les ajouts?

Car par exemple le bestiaire y a déjà des scripts fais pour, c'est pas difficile de remplacer l'option "Sauvegarder" par "Bestiaire" et faire que ça ouvre le bestiaire, mais faut savoir si le bestiaire est fais toi même, si tu en as un déjà fais ou si il faut qu'on le fasse.

Bref, p'tet qu'avec plus de détails ça peut se faire ( par contre coder un bestiaire moi même je crois pas, j'ai déjà pas le temps de finir mes propres trucs... )

Avatar de l’utilisateur
Darxenas
Koruldia Divinity
Messages : 5138
Localisation : Kingersheim, France
Contact :

Message non lu par Darxenas » mar. févr. 08, 2011 10:18 pm

Je pense perso que j'aurai pas de problème =), mais si tu as le Bestiaire avec ce serait mieux parce que je saurais pas ce que tu cherches exactement.

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » mer. févr. 09, 2011 12:41 am

Bon, je vais réduire un peu ma demande. Tout ce que je veux c'Est:
-BGM de menu pause
-Pas d'option sauvegarder dans le menu pause.
Voilà. J'ai abandonné l'idée du super menu modifiable à Photoshop, car je suis tombé sur des scripts de menus trop intéressant pour être laissés. De même, les configurer avec le script que je demandais à la base serait trop compliqué.
Je suis celui qui marquera toute une génération!

zessirb
Koruldia God Warrior
Messages : 585

Message non lu par zessirb » mer. févr. 09, 2011 1:10 pm

Un BGM de menu pause, je pense que c'est facile à trouver un script comme ça (peut être que tu dois juste rajouter quelques lignes...).
Euh il me semble que tu peux désactiver les sauvegardes dans le menu, mais tu veux carrément le rayer du menu ?



Après si tu veux faire des gros trucs tu peux toujours apprendre le ruby, mais c'est bien chiant, et quand j'ai voulu apprendre je n'avais pas trouvé de bon tutoriel, ou pas attaché au langage (c'est possible qu'il y en ai un sur le site du zéro maintenant).

Ce que je te conseille, de faire un menu custom, c'est à dire fait toi-même via les évènements (afficher les images, tu fais attendre les évènements pour ne plus qu'ils bougent,...) ; ainsi tu pourras vraiment faire pas mal de chose.



Après, il est possible que l'on ait déjà exploré RPG Maker, et qu'on aimerait quelque chose de plus poussé... Dans ce cas il faudra se tourner vers d'autres logiciels de création de jeu, comme Game Maker.

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » mer. févr. 09, 2011 1:31 pm

zessirb a écrit : mais tu veux carrément le rayer du menu ?
Effectivement, c'Est ça que je veux. Ça sert à rien de le laisser affiché s'il ne sert jamais à rien.
Pour ton système d'events, je vais un peu réfléchir.
Je suis celui qui marquera toute une génération!

Giro Noden
Koruldia Divinity
Messages : 4619
Localisation : Lyon
Contact :

Message non lu par Giro Noden » mer. févr. 09, 2011 7:17 pm

Excuse moi, je vais peut-être passer pour un em******, mais je trouve que ta politesse se dégrade au fur et à mesure du topic...
D'autant que, je vais employer tes termes, tu "veux", quoi exactement ? Que les membres te pondent un script, ou recherchent des script sur internet pour toi ?
Parce que si c'est le cas, peut-être que quelqu'un aura la gentillesse de te le faire, mais je pense que tu pourrais quand même te débrouiller. Ça donne l'impression que les autres membres sont tes larbins.
Peut-être que je me trompe ( et j'espère me tromper !) et que la demande est d'un tout autre accabit, mais c'est... bizarre.
Giro

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » mer. févr. 09, 2011 9:53 pm

Effectivement tu te trompes.
"-Tu aimes cette fille?
-Oui je L'AIME"
"-Tu as faim?
-Oui, j'ai FAIM"
...
"-Mais tu veux carrément le rayer du menu?
-Effectivement, c'est ça que je VEUX"
C'était juste une façon de répondre...

Sinon, pour le reste, j'y connais rien en ruby. Si c'était possible, je viendrais pas vous déranger juste pour vous demander une BGM de menu et d'y enlever l'option "sauvegarder"...
Je ne recherche aucun script. J'en ai même un, mais il ne fonctionne pas et je ne comprend pas pourquoi. Rayer le l'option de sauvegarde, ça m'étonnerait qu'il existe un script pour ça. À la limite, on pourrait changer le script Scene_menu. Mais non seulement je sais pas le faire, mais en plus j'ai des scripts de menu qui porraient interférer avec mes essais.
Je suis celui qui marquera toute une génération!

Raytwo-x
Koruldia Master
Messages : 2041

Message non lu par Raytwo-x » jeu. févr. 10, 2011 12:52 am

Après, tout dépend des scripts que t'utilisent qui peuvent interférer dans le menu.

Si tu utilises le Scene_menu de base, c'est très simple de faire ça, mais si c'est un autre, il faudra le montrer pour qu'on s'adapte. ;)

Avatar de l’utilisateur
Darxenas
Koruldia Divinity
Messages : 5138
Localisation : Kingersheim, France
Contact :

Message non lu par Darxenas » jeu. févr. 10, 2011 1:01 am

Moi je suis modo, méchant, larbin et soumis mdrrr ! x) Sincèrement ça me dérange pas si t'as besoin d'aide. =) Mais Gigi n'a pas tout à fait tort, attention (écoutez bien mon Gigi !) !

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » jeu. févr. 10, 2011 7:08 am

Ok. Excusez-moi pour cette tournure du français malpolie que j'ai utilisée tout à l'heure...
Pour le script, je vous les fais parvenir. Malheureusement, c'est en anglais.
Spoiler!
#===============================================================================
#
# There's not a whole lot of reason for the player to visit the status menu.
# Not too much to see aside from things you can already view in other menus
# such as the equipment menu for stats. This script will provide additional
# functionality to the scene in addition to allowing the game maker to free
# up additional space in the main menu for the not actor-oriented stuff.
#
#===============================================================================
# Instructions
#===============================================================================
#
# This script is plug and play for the most part, but there's bound to be a lot
# things you may want to modify so scroll down and reach each of the individual
# instructions carefully for all sections and modify the constants properly.
#
#===============================================================================
#
# Compatibility
# - Works With: KGC scripts and others!
# - Alias: Scene_Equip: return_scene
# - Alias: Scene_Skill: return_scene
# - Alias: Scene_Title: create_game_objects
# - Alias: Game_Temp: initialize
# - Overwrites: Scene_Status: all
#
#===============================================================================

$imported = {} if $imported == nil
$imported["SceneStatusReDux"] = true

module YE
module REDUX
module STATUS

#------------------------------------------------------------------------
# Instructions on how to set up the STATUS_COMMANDS order.
#------------------------------------------------------------------------
# This array will let you determine how you want your status window
# commands to be ordered. They will appear in the number you order them.
# Each command is assigned a number and these are the following numbers.
#
# 0..Statistics 1..Biography 2..Skills 3..Equips
#
# The next couple are Yanfly Engine ReDux commands and require you to
# have the respective scripts before they will appear in the menu. Be
# sure to add them to STATUS_COMMANDS if you wish to display them.
#
# 4..Change Class .......... Requires Subclass Selection System
# 5..Learn Skills .......... Requires Subclass Selection System
# 6..Skill Slots ........... Requires Equip Skill Slots
#
# There are some pre-made imported functions for this script. Of them are
# the popular and powerful KGC scripts and others which I've also found
# to be rather interesting.
#
# 101..Distribute Parameter .. Requires KGC Distribute Parameter
# 102..Equip Learn Skill ..... Requires KGC Equip Learn Skill
# 103..Skill CP System ....... Requires KGC Skill CP System
# 201..Skill Growth .......... Requires Garlyle's Skill Growth System
# 301..Attributes ............ Requires 332211's Attribute System
# 302..Soul Pieces ........... Requires 332211's Soul Pieces System
# 303..Weapon by Ranks ....... Requires 332211's Weapon by Ranks System
#
# If you wish to add your own commands, you'll need to register them
# under the lunatic mode portion of the script.
#------------------------------------------------------------------------
STATUS_COMMANDS =[ # Make sure you've read the instructions above.
0, # Statistics
1, # Biography
2, # Skills
6, # Skill Slots
3, # Equips
4, # Change Class
5, # Learn Skills
] # Do not remove this.

# The constants below will determine the unique sound and strings made
# specificly for the Scene Status ReDux script.
SOUND = RPG::SE.new("Book", 80, 100)
STATUS = "Status"
BIO = "Biography"

# The following determines determines profile categories for various
# profile information.
BIRTHDAY = "Birthday: "
AGE = "Age: "
ORIGIN = "Origin: "
GENDER = "Gender: "
HEIGHT = "Height: "
WEIGHT = "Weight: "
UNKNOWN = "Unknown"

# This hash will let you determine what full names to give your
# individual actors. Use %s to indicate where the RPG name appears.
ACTOR_PROFILES1 ={
# Actor => [ Full Name, Origin, Gender, Height, Weight]
1 => [ "%s von Xiguel", "Pallia", "Male", "177.8 cm", "72.7 kg"],
2 => [ "Michelle %s", "Retvin", "Female", "170.2 cm", "Unknown"],
3 => [ "%s Manfred", "Namek", "Male", "182.9 cm", "68.2 kg"],
4 => [ "%s Fernaeus", "Yerd", "Female", "162.6 cm", "Secret~"],
} # Do not remove this.

# The following hash will determine the birthday information about the
# actor. The VarID is what stores the birthday. Change the variable to
# change the actor's age in the actual menu. The start age is what the
# variable initially sets the actor's age to. The birthday is just the
# date that the actor is born. Nothing else special about it.
ACTOR_PROFILES2 ={
# Actor => [ VarID, StartAge, Birthday]
1 => [ 21, 18, "May 26"],
2 => [ 22, 17, "Jan 14"],
3 => [ 23, 18, "Oct 31"],
4 => [ 24, 19, "June 3"],
} # Do not remove this.

# This will determine the size of the font used for the biography window.
BIO_FONT_SIZE = 20

# This section will allow you to type out the actor biographies. To
# cause a line break, use a | in the middle of the string. If the actors
# do not have a biography here, it will show actor 0 instead. For that
# reason, do NOT remove actor 0.
ACTOR_BIOGRAPHIES ={
# Actor => Biography
0 => "UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN|UNKNOWN UNKNOWN UNKNOWN",
1 => "Ralph has set off on a quest to save|Don Miguel from the clutches of the evil|witch Margaret. Accompanied by Ulrika,|Bennett, and Ylva, Ralph adventures|the world to find Don Miguel.||\"Let's hurry! Don Miguel cannot wait|much longer!\"",
2 => "Ulrika trained with Ralph before Don|Miguel was kidnapped. She always sees|Ralph as a rival, but also a source of|inspiration. Ulrika firmly believes that|training will let her get rid of her many|weaknesses.||\"Strength comes from a trained heart.\"",
3 => "Bennett choose the wrong profession|given his bursting personality. He and|his best friend Ralph give each other|motivation to strengthen themselves|and to become the ultimate tagteam|ever known to the world.||\"Their priest is a sissy! You heard me,|a sissy!\"",
4 => "Ylva studies in her free time about|various magic and locations. This is|why it seems like she knows a lot,|but the truth is that she only knows|what she has read in books.||\"Why risk your life to experience|something when you can read about|it in a book?\"",
} # Do not remove this.

# The following sets the statistical information for your actors.
# These are all of the information you'll see in the statistics window.
ICON_LVL = 62 # Icon for level
TEXT_LVL = "Level" # Text for level
ICON_EXP = 63 # Icon for experience
TEXT_EXP = "EXP" # Text for experience
ICON_NEXT = 142 # Icon for next level
TEXT_NEXT = "Next" # Text for next level

ICON_HP = 99 # Icon for HP
ICON_MP = 100 # Icon for MP

ICON_ATK = 2 # Icon for ATK
TEXT_ATK = "ATK" # Text for ATK
ICON_DEF = 52 # Icon for DEF
TEXT_DEF = "DEF" # Text for DEF
ICON_SPI = 21 # Icon for SPI
TEXT_SPI = "SPI" # Text for SPI
ICON_AGI = 48 # Icon for AGI
TEXT_AGI = "AGI" # Text for AGI

ICON_HIT = 135 # Icon for HIT
TEXT_HIT = "HIT" # Text for HIT
SHOW_HIT = true # Display HIT?
ICON_EVA = 158 # Icon for EVA
TEXT_EVA = "EVA" # Text for EVA
SHOW_EVA = true # Display EVA?
ICON_CRI = 119 # Icon for CRI
TEXT_CRI = "CRI" # Text for CRI
SHOW_CRI = true # Display CRI?
ICON_ODDS = 137 # Icon for ODDS
TEXT_ODDS = "LUK" # Text for ODDS
SHOW_ODDS = true # Display ODDS?

end # STATUS
end # REDUX
end # YE

#===============================================================================
# How to Use: Lunatic Mode
#===============================================================================
#
# If you do not understand hashes, I -STRONGLY- recommend that you stay away
# from this portion of the script as it affects the rest of the script if you
# make a slight mistake.
#
# - First, under IMPORTED_COMMANDS, fill out the hash properly. You will have
# to fill them out correctly given the categories.
#
# Swch? - Does this command require a switch to be on in order to be shown?
# SwID - If the previous was true, this is the Switch ID needed to be on.
# Title - This is the text that appears on the status command window.
# Scene - This is the name of the scene you wish to load.
#
# - Given that you've done everything correctly, return to the top and adjust
# the STATUS_COMMANDS array. Input number 101 or whatever number you've used
# to determine the scene you wish to launch from the status menu.
#
# Note that if you exit the imported scenes, they will return to the main menu
# rather than the status menu. It will remain that way until you edit those
# scripts's respective return_scene definitions.
#
#===============================================================================

module YE
module REDUX
module STATUS

# The following hash will govern the way the status menu will treat
# imported commands. If you do not follow the setup properly, do not
# expect the script to function correctly.
IMPORTED_COMMANDS ={
# -ID => [Swch?, SwID, ----Title----, -----------Scene-----------]
101 => [false, 0, "Level Up", "Scene_DistributeParameter"],
102 => [false, 0, "View AP", "Scene_APViewer"],
103 => [false, 0, "Skill CP", "Scene_SetBattleSkill"],
201 => [false, 0, "Grow Skill", "Scene_SkillGrowth"],
301 => [false, 0, "Attributes", "Scene_Attributes"],
302 => [false, 0, "Soul Pieces", "Scene_soulpieces"],
303 => [false, 0, "Weapon Rank", "Scene_weapon_by_ranks"],
} # Do not remove this.

end # STATUS
end # REDUX
end # YE

#===============================================================================
# Editting anything past this point may potentially result in causing computer
# damage, incontinence, explosion of user's head, coma, death, and/or halitosis.
# Therefore, edit at your own risk.
#===============================================================================

#===============================================================================
# Scene Status
#===============================================================================

class Scene_Status < Scene_Base

#--------------------------------------------------------------------------
# create command list
# --- This portion creates the commands for the status window.
#--------------------------------------------------------------------------
def create_command_list
commands = []
index_list = {}
YE::REDUX::STATUS::STATUS_COMMANDS.each_with_index { |c, i|
case c
when 0 # View Statistics
index_list[:stats] = commands.size
commands.push(YE::REDUX::STATUS::STATUS)

when 1 # View Biography
index_list[:bio] = commands.size
commands.push(YE::REDUX::STATUS::BIO)

when 2 # Skill Menu
index_list[:skill] = commands.size
commands.push(Vocab.skill)

when 3 # Equipment
index_list[:equip] = commands.size
commands.push(Vocab.equip)

when 4 # Change Class
next unless $imported["SubclassSelectionSystem"]
next unless $game_switches[YE::SUBCLASS::ENABLE_CLASS_CHANGE_SWITCH]
index_list[:classchange] = commands.size
commands.push(YE::SUBCLASS::MENU_CLASS_CHANGE_TITLE)

when 5 # Learn Skill
next unless $imported["SubclassSelectionSystem"]
next unless $game_switches[YE::SUBCLASS::ENABLE_LEARN_SKILLS_SWITCH]
index_list[:learnskill] = commands.size
commands.push(YE::SUBCLASS::LEARN_SKILL_TITLE)

when 6 # Skill Slots
next unless $imported["EquipSkillSlots"]
next unless $game_switches[YE::EQUIPSKILL::ENABLE_SLOTS_SWITCH]
index_list[:equipskill] = commands.size
commands.push(YE::EQUIPSKILL::MENU_TITLE)

else
command_array = YE::REDUX::STATUS::IMPORTED_COMMANDS
next unless command_array.include?(c)
command_array = command_array[c]
next if command_array[0] and !$game_switches[command_array[1]]
index_list[c] = commands.size
commands.push(command_array[2])

end
} # Do not remove this.
$game_temp.status_command_index = index_list
return commands
end # create_command_list

#--------------------------------------------------------------------------
# case_command_selection
#--------------------------------------------------------------------------
def case_command_selection(index)
case index
when $game_temp.status_command_index[:stats]
YE::REDUX::STATUS::SOUND.play
$game_temp.status_bio_flag = 0
start_visible_windows

when $game_temp.status_command_index[:bio]
YE::REDUX::STATUS::SOUND.play
$game_temp.status_bio_flag = 1
start_visible_windows

when $game_temp.status_command_index[:skill]
Sound.play_decision
$scene = Scene_Skill.new(@actor_index)

when $game_temp.status_command_index[:equip]
Sound.play_decision
$scene = Scene_Equip.new(@actor_index)

when $game_temp.status_command_index[:classchange]
Sound.play_decision
$scene = Scene_Class_Change.new(@actor_index)

when $game_temp.status_command_index[:learnskill]
Sound.play_decision
$scene = Scene_Learn_Skill.new(@actor_index)

when $game_temp.status_command_index[:equipskill]
Sound.play_decision
$scene = Scene_Equip_Skill.new(@actor_index)

else
return_check = true
for key in $game_temp.status_command_index
if $game_temp.status_command_index[key[0]] == index
return_check = false
found_key = key[0]
break
end
end
return if return_check
Sound.play_decision
command_array = YE::REDUX::STATUS::IMPORTED_COMMANDS[found_key]
$scene = eval(command_array[3] + ".new(@actor_index)")

end
end # case_command_selection

#--------------------------------------------------------------------------
# overwrite initialize
#--------------------------------------------------------------------------
def initialize(actor_index = 0, menu_index = 0)
@menu_index = menu_index
$game_temp.status_menu_flag = true
@actor_index = actor_index
@actor = $game_party.members[@actor_index]
end

#--------------------------------------------------------------------------
# overwrite start
#--------------------------------------------------------------------------
def start
super
create_menu_background
@status_window = Window_Status.new(@actor)
@status_mini_window = Window_Status_Mini.new(@actor)
@status_bio_window = Window_Status_Bio.new(@actor)
start_visible_windows
create_command_window
end

#--------------------------------------------------------------------------
# overwrite terminate
#--------------------------------------------------------------------------
def terminate
super
dispose_menu_background
@command_window.dispose if @command_window != nil
@status_window.dispose if @status_window != nil
@status_mini_window.dispose if @status_mini_window != nil
@status_bio_window.dispose if @status_bio_window != nil
end

#--------------------------------------------------------------------------
# overwrite return scene
#--------------------------------------------------------------------------
def return_scene
if $imported["CustomMenuCommand"] and
$game_temp.menu_command_index.has_key?(:status)
$scene = Scene_Menu.new($game_temp.menu_command_index[:status])
elsif $imported["CustomMenuCommand"]
$scene = Scene_Map.new
else
$scene = Scene_Menu.new(3)
end
$game_temp.status_menu_flag = false
end

#--------------------------------------------------------------------------
# overwrite next actor
#--------------------------------------------------------------------------
def next_actor
@actor_index += 1
@actor_index %= $game_party.members.size
$scene = Scene_Status.new(@actor_index, @command_window.index)
end

#--------------------------------------------------------------------------
# overwrite prev actor
#--------------------------------------------------------------------------
def prev_actor
@actor_index += $game_party.members.size - 1
@actor_index %= $game_party.members.size
$scene = Scene_Status.new(@actor_index, @command_window.index)
end

#--------------------------------------------------------------------------
# overwrite update
#--------------------------------------------------------------------------
def update
super
update_menu_background
@command_window.update
if Input.trigger?(Input::B)
Sound.play_cancel
return_scene
elsif Input.trigger?(Input::C)
$game_temp.status_menu_index = @command_window.index
case_command_selection(@command_window.index)
elsif Input.trigger?(Input::R)
Sound.play_cursor
next_actor
elsif Input.trigger?(Input::L)
Sound.play_cursor
prev_actor
end
end

#--------------------------------------------------------------------------
# create command window
#--------------------------------------------------------------------------
def create_command_window
commands = create_command_list
@command_window = Window_Command.new(160, commands)
@command_window.y = 128
@command_window.height = 288
@command_window.opacity = 0
@command_window.index = @menu_index
end

#--------------------------------------------------------------------------
# start visible windows
#--------------------------------------------------------------------------
def start_visible_windows
@status_mini_window.visible = false
@status_bio_window.visible = false
case $game_temp.status_bio_flag
when 0
@status_mini_window.visible = true
when 1
@status_bio_window.visible = true
end
end

end

#==============================================================================
# Game_Temp
#==============================================================================

class Game_Temp

#--------------------------------------------------------------------------
# Public Instance Variables
#--------------------------------------------------------------------------
attr_accessor :status_command_index
attr_accessor :status_menu_flag
attr_accessor :status_menu_index
attr_accessor :status_bio_flag

#--------------------------------------------------------------------------
# alias initialize
#--------------------------------------------------------------------------
alias initialize_statusrd initialize unless $@
def initialize
initialize_statusrd
@status_command_index = {}
@status_menu_flag = false
@status_menu_index = 0
@status_bio_flag = 0
end
end

#===============================================================================
# Scene Title
#===============================================================================

class Scene_Title < Scene_Base

#--------------------------------------------------------------------------
# alias create game objects
#--------------------------------------------------------------------------
alias create_game_objects_statusrd create_game_objects unless $@
def create_game_objects
create_game_objects_statusrd
for key in YE::REDUX::STATUS::ACTOR_PROFILES2
narray = key[1]
$game_variables[narray[0]] = narray[1]
end
end

end # Scene_Title

#===============================================================================
# return scene alias
#===============================================================================
unless $imported["SceneSkillReDux"]
class Scene_Skill < Scene_Base

#--------------------------------------------------------------------------
# alias return scene
#--------------------------------------------------------------------------
alias skill_return_scene_statusrd return_scene unless $@
def return_scene
if $game_temp.status_menu_flag
$scene = Scene_Status.new(@actor_index, $game_temp.status_menu_index)
else
skill_return_scene_statusrd
end
end

end
end
unless $imported["SceneEquipReDux"]
class Scene_Equip < Scene_Base

#--------------------------------------------------------------------------
# alias return scene
#--------------------------------------------------------------------------
alias equip_return_scene_statusrd return_scene unless $@
def return_scene
if $game_temp.status_menu_flag
$scene = Scene_Status.new(@actor_index, $game_temp.status_menu_index)
else
equip_return_scene_statusrd
end
end

end
end

#===============================================================================
# Window_Status
#===============================================================================

class Window_Status < Window_Base

#--------------------------------------------------------------------------
# initialize
#--------------------------------------------------------------------------
def initialize(actor)
super(0, 0, 544, 416)
@actor = actor
refresh
end

#--------------------------------------------------------------------------
# refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
draw_actor_face(@actor, 0, 0)
profile1 = YE::REDUX::STATUS::ACTOR_PROFILES1
profile2 = YE::REDUX::STATUS::ACTOR_PROFILES2
if profile1.include?(@actor.id)
text = sprintf(profile1[@actor.id][0], @actor.name)
else
text = @actor.name
end
self.contents.draw_text(112, 0, 180, WLH, text, 0)
#----
dx = 112
if $imported["SubclassSelectionSystem"]
if YE::SUBCLASS::CLASS_ICONS.include?(@actor.class.id)
icon = YE::SUBCLASS::CLASS_ICONS[@actor.class.id]
else
icon = YE::SUBCLASS::CLASS_ICONS[0]
end
draw_icon(icon, dx, 24)
dx += 24
if @actor.subclass != nil
if YE::SUBCLASS::CLASS_ICONS.include?(@actor.subclass.id)
icon = YE::SUBCLASS::CLASS_ICONS[@actor.subclass.id]
else
icon = YE::SUBCLASS::CLASS_ICONS[0]
end
draw_icon(icon, dx, 24)
dx += 24
end
end
draw_actor_class(@actor, dx, 24)
#----
self.contents.font.color = system_color
text1 = YE::REDUX::STATUS::BIRTHDAY
text2 = YE::REDUX::STATUS::AGE
self.contents.draw_text(112, 48, 90, WLH, text1, 2)
self.contents.draw_text(112, 72, 90, WLH, text2, 2)
if profile2.include?(@actor.id)
text1 = profile2[@actor.id][2]
text2 = $game_variables[profile2[@actor.id][0]]
else
text1 = YE::REDUX::STATUS::UNKNOWN
text2 = YE::REDUX::STATUS::UNKNOWN
end
self.contents.font.color = normal_color
self.contents.draw_text(202, 48, 90, WLH, text1, 0)
self.contents.draw_text(202, 72, 90, WLH, text2, 0)
#----
self.contents.font.color = system_color
text1 = YE::REDUX::STATUS::ORIGIN
text2 = YE::REDUX::STATUS::GENDER
text3 = YE::REDUX::STATUS::HEIGHT
text4 = YE::REDUX::STATUS::WEIGHT
self.contents.draw_text(292, 0, 90, WLH, text1, 2)
self.contents.draw_text(292, 24, 90, WLH, text2, 2)
self.contents.draw_text(292, 48, 90, WLH, text3, 2)
self.contents.draw_text(292, 72, 90, WLH, text4, 2)
if profile1.include?(@actor.id)
text1 = profile1[@actor.id][1]
text2 = profile1[@actor.id][2]
text3 = profile1[@actor.id][3]
text4 = profile1[@actor.id][4]
else
text1 = YE::REDUX::STATUS::UNKNOWN
text2 = YE::REDUX::STATUS::UNKNOWN
text3 = YE::REDUX::STATUS::UNKNOWN
text4 = YE::REDUX::STATUS::UNKNOWN
end
self.contents.font.color = normal_color
self.contents.draw_text(382, 0, 90, WLH, text1, 0)
self.contents.draw_text(382, 24, 90, WLH, text2, 0)
self.contents.draw_text(382, 48, 90, WLH, text3, 0)
self.contents.draw_text(382, 72, 90, WLH, text4, 0)
#----
end

end # Window_Status

#==============================================================================
# Window_Status_Mini
#==============================================================================

class Window_Status_Mini < Window_Base

#--------------------------------------------------------------------------
# initialize
#--------------------------------------------------------------------------
def initialize(actor)
super(160, 128, 384, 288)
@actor = actor
self.opacity = 0
self.visible = false
refresh
end

#--------------------------------------------------------------------------
# refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
self.contents.font.color = system_color
#---
sw = self.width - 32
dx = 0
dy = 0
draw_icon(YE::REDUX::STATUS::ICON_LVL, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_LVL)

dy += WLH
draw_icon(YE::REDUX::STATUS::ICON_NEXT, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_NEXT)
dy += WLH
draw_icon(YE::REDUX::STATUS::ICON_EXP, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_EXP)

dy = WLH * 3
draw_icon(YE::REDUX::STATUS::ICON_HP, dx, dy)
draw_actor_hp(@actor, dx+24, dy, 128)
dy += WLH
self.contents.font.color = system_color
draw_icon(YE::REDUX::STATUS::ICON_ATK, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_ATK)
dy += WLH
draw_icon(YE::REDUX::STATUS::ICON_DEF, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_DEF)
dy += WLH
draw_icon(YE::REDUX::STATUS::ICON_SPI, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_SPI)
dy += WLH
draw_icon(YE::REDUX::STATUS::ICON_AGI, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_AGI)
#---
dx = sw/2
dy = WLH * 3
draw_icon(YE::REDUX::STATUS::ICON_MP, dx, dy)
draw_actor_mp(@actor, dx+24, dy, 128)
dy += WLH
self.contents.font.color = system_color
if YE::REDUX::STATUS::SHOW_HIT
draw_icon(YE::REDUX::STATUS::ICON_HIT, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_HIT)
end
dy += WLH
if YE::REDUX::STATUS::SHOW_EVA
draw_icon(YE::REDUX::STATUS::ICON_EVA, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_EVA)
end
dy += WLH
if YE::REDUX::STATUS::SHOW_CRI
draw_icon(YE::REDUX::STATUS::ICON_CRI, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_CRI)
end
dy += WLH
if YE::REDUX::STATUS::SHOW_ODDS
draw_icon(YE::REDUX::STATUS::ICON_ODDS, dx, dy)
self.contents.draw_text(dx+24, dy, 60, WLH, YE::REDUX::STATUS::TEXT_ODDS)
end
#---
self.contents.font.color = normal_color
dw = sw - 84
dx = 84
dy = 0
self.contents.draw_text(dx, dy, 68, WLH, @actor.level); dy += WLH
self.contents.draw_text(dx, dy, dw, WLH, @actor.next_rest_exp_s); dy += WLH
self.contents.draw_text(dx, dy, dw, WLH, @actor.exp_s); dy += WLH

dy = WLH * 4
self.contents.draw_text(dx, dy, 68, WLH, @actor.atk, 0); dy += WLH
self.contents.draw_text(dx, dy, 68, WLH, @actor.def, 0); dy += WLH
self.contents.draw_text(dx, dy, 68, WLH, @actor.spi, 0); dy += WLH
self.contents.draw_text(dx, dy, 68, WLH, @actor.agi, 0); dy += WLH
dy = WLH * 4
dx = sw/2 + 84
if YE::REDUX::STATUS::SHOW_HIT
text = sprintf("%d%%", @actor.hit)
self.contents.draw_text(dx, dy, 68, WLH, text, 0)
end; dy += WLH
if YE::REDUX::STATUS::SHOW_EVA
text = sprintf("%d%%", @actor.eva)
self.contents.draw_text(dx, dy, 68, WLH, text, 0)
end; dy += WLH
if YE::REDUX::STATUS::SHOW_CRI
text = sprintf("%d%%", @actor.cri)
self.contents.draw_text(dx, dy, 68, WLH, text, 0)
end; dy += WLH
if YE::REDUX::STATUS::SHOW_ODDS
self.contents.draw_text(dx, dy, 68, WLH, @actor.odds, 0)
end; dy += WLH
end

end # Window_Status_Mini

#==============================================================================
# Window_Status_Bio
#==============================================================================

class Window_Status_Bio < Window_Base

#--------------------------------------------------------------------------
# initialize
#--------------------------------------------------------------------------
def initialize(actor)
super(160, 128, 384, 288)
@actor = actor
self.opacity = 0
refresh
end

#--------------------------------------------------------------------------
# refresh
#--------------------------------------------------------------------------
def refresh
self.contents.clear
self.contents.font.color = normal_color
self.contents.font.size = YE::REDUX::STATUS::BIO_FONT_SIZE
if YE::REDUX::STATUS::ACTOR_BIOGRAPHIES.include?(@actor.id)
text = YE::REDUX::STATUS::ACTOR_BIOGRAPHIES[@actor.id]
else
text = YE::REDUX::STATUS::ACTOR_BIOGRAPHIES[0]
end
y = 0
txsize = YE::REDUX::STATUS::BIO_FONT_SIZE + 4
nwidth = 544
buf = text.gsub(/\\N(\[\d+\])/i) { "\\__#{$1}" }
lines = buf.split(/(?:[|]|\\n)/i)
lines.each_with_index { |l, i|
l.gsub!(/\\__(\[\d+\])/i) { "\\N#{$1}" }
self.contents.draw_text(0, i * txsize + y, nwidth, WLH, l, 0)
}
end

end # Window_Status_Bio

#===============================================================================
#
# END OF FILE
#
#===============================================================================
... Et le plus con, c'est que je ne sais pas encore m'en servir :dent:
Je suis celui qui marquera toute une génération!

Giro Noden
Koruldia Divinity
Messages : 4619
Localisation : Lyon
Contact :

Message non lu par Giro Noden » jeu. févr. 10, 2011 7:22 am

En fait le truc, c'est que tu donnes l'impression (là par exemple en répondant à la limite du "j'ai raison, t'as tort.") de te considérer comme supérieur.
Je pense que c'est une attitude que j'ai pu (et que je pense parfois encore avoir) avoir dans le passé, et le fait de m'exprimer dans une communauté m'a permis de me refréner un peu. J'espère qu'il en serra de même pour toi :).
Giro

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » jeu. févr. 10, 2011 7:36 am

Aucun problème, Giro. J'ai souvent des problèmes pour exprimer ce que je pense. Je vais maintenant faire des efforts et faire attention à ce que j'écris.
Je suis celui qui marquera toute une génération!

Giro Noden
Koruldia Divinity
Messages : 4619
Localisation : Lyon
Contact :

Message non lu par Giro Noden » jeu. févr. 10, 2011 5:00 pm

Je vais répondre une dernière fois, même si ça ne sert plus vraiment à grand chose : C'est cool ! Je suis vraiment content que tu le prennes ainsi :) !
Giro

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » ven. févr. 11, 2011 1:10 am

Ok. Sinon, pour le script, ça se passe comment?
Je suis celui qui marquera toute une génération!

Raytwo-x
Koruldia Master
Messages : 2041

Message non lu par Raytwo-x » ven. févr. 11, 2011 2:55 am

Normalement je ne vais pas en cours ce matin ( maladie ), donc si je suis pas trop crevé, je me pencherai la dessus et tâcherai de t'expliquer au mieux comment t'en servir ( si j'y arrive moi même )

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » ven. févr. 11, 2011 3:50 am

Ok. Merci de ton aide. :clin:
Je suis celui qui marquera toute une génération!

Raytwo-x
Koruldia Master
Messages : 2041

Message non lu par Raytwo-x » lun. févr. 14, 2011 11:48 pm

Image

Héhé, c'est un script assez complet je trouve ^^

Y a moyen d'inventer une date de naissance, un nom de famille, un age, afficher la classe du perso, etc, comme une carte d'identité.
Bon, j'm'y met, je vais voir ce que j'peux faire sans m'écrouler de fatigue sur le clavier xD

Alors, pour ce qui est de l'option "supprimer la sauvegarde du menu", j'ai réussi très facilement ( j'fais souvent ce genre de truc faut dire ), mais pour ce qui est du BGM pendant "la pause", je comprends pas vraiment, tu souhaites un script qui met le jeu en pause quand tu appuyes sur un bouton, ou alors le BGM doit se jouer dans le menu?

Ddken
Koruldia Hunter
Messages : 72
Localisation : Montreal

Message non lu par Ddken » mar. févr. 15, 2011 12:40 am

Un BGM qui se joue dans le menu.
Merci pour ton aide Raytwo. Et surtout, guéris bien! :clin:
Je suis celui qui marquera toute une génération!

Raytwo-x
Koruldia Master
Messages : 2041

Message non lu par Raytwo-x » dim. févr. 20, 2011 10:17 pm

Petite question : c'est quoi le nom du BGM que tu veux utiliser dans ton menu? Que ça me facilite la tâche ^^ sinon j'pourrais faire plus simple mais faut que je regarde un peux mieux.

Deuxième question : c'est bien un BGM? ( On sait jamais xD )

Edit : 500 messages, enfin ! :D

Edit 2 : Pour enlever l'option sauvegarde de ton menu,remplace "Scene_Menu" par ce qu'il y a la dedans :

Code : Tout sélectionner

#==============================================================================
# ** Scene_Menu
#------------------------------------------------------------------------------
#  This class performs the menu screen processing.
#==============================================================================

class Scene_Menu < Scene_Base
  
  # Ajout de Raytwo - Module Fond
  module Fond
    # Insérer le titre du BGM entre les guillements
    Titre = "tera"
  end
    
  #--------------------------------------------------------------------------
  # * Object Initialization
  #     menu_index : command cursor's initial position
  #--------------------------------------------------------------------------
  def initialize(menu_index = 0)
    @menu_index = menu_index
  end
  #--------------------------------------------------------------------------
  # * Start processing
  #--------------------------------------------------------------------------
  def start
    super
    create_menu_background
    create_command_window
    # Ajout de Raytwo - Lecture du BGM du menu
    Audio.bgm_play("Audio/BGM/" + Fond::Titre)
    @gold_window = Window_Gold.new(0, 360)
    @status_window = Window_MenuStatus.new(160, 0)
  end
  #--------------------------------------------------------------------------
  # * Termination Processing
  #--------------------------------------------------------------------------
  def terminate
    super
    dispose_menu_background
    @command_window.dispose
    @gold_window.dispose
    @status_window.dispose
    # Ajout de Raytwo - Arret de la musique, reprise du BGM et du BGS de la map.
    RPG::BGM.stop
    $game_temp.map_bgm.play
    $game_temp.map_bgs.play
  end
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    super
    update_menu_background
    @command_window.update
    @gold_window.update
    @status_window.update
    if @command_window.active
      update_command_selection
    elsif @status_window.active
      update_actor_selection
    end
  end
  #--------------------------------------------------------------------------
  # * Create Command Window
  #--------------------------------------------------------------------------
  def create_command_window
    s1 = Vocab::item
    s2 = Vocab::skill
    s3 = Vocab::equip
    s4 = Vocab::status
    s5 = Vocab::game_end
    @command_window = Window_Command.new(160, [s1, s2, s3, s4, s5])
    @command_window.index = @menu_index
    if $game_party.members.size == 0          # If number of party members is 0
      @command_window.draw_item(0, false)     # Disable item
      @command_window.draw_item(1, false)     # Disable skill
      @command_window.draw_item(2, false)     # Disable equipment
      @command_window.draw_item(3, false)     # Disable status
    end
  end
  #--------------------------------------------------------------------------
  # * Update Command Selection
  #--------------------------------------------------------------------------
  def update_command_selection
    if Input.trigger?(Input::B)
      Sound.play_cancel
      $scene = Scene_Map.new
    elsif Input.trigger?(Input::C)
      if $game_party.members.size == 0 and @command_window.index < 4
        Sound.play_buzzer
        return
      elsif $game_system.save_disabled and @command_window.index == 4
        Sound.play_buzzer
        return
      end
      Sound.play_decision
      case @command_window.index
      when 0      # Item
        $scene = Scene_Item.new
      when 1,2,3  # Skill, equipment, status
        start_actor_selection
      when 4      # End Game
        $scene = Scene_End.new
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Start Actor Selection
  #--------------------------------------------------------------------------
  def start_actor_selection
    @command_window.active = false
    @status_window.active = true
    if $game_party.last_actor_index < @status_window.item_max
      @status_window.index = $game_party.last_actor_index
    else
      @status_window.index = 0
    end
  end
  #--------------------------------------------------------------------------
  # * End Actor Selection
  #--------------------------------------------------------------------------
  def end_actor_selection
    @command_window.active = true
    @status_window.active = false
    @status_window.index = -1
  end
  #--------------------------------------------------------------------------
  # * Update Actor Selection
  #--------------------------------------------------------------------------
  def update_actor_selection
    if Input.trigger?(Input::B)
      Sound.play_cancel
      end_actor_selection
    elsif Input.trigger?(Input::C)
      $game_party.last_actor_index = @status_window.index
      Sound.play_decision
      case @command_window.index
      when 1  # skill
        $scene = Scene_Skill.new(@status_window.index)
      when 2  # equipment
        $scene = Scene_Equip.new(@status_window.index)
      when 3  # status
        $scene = Scene_Status.new(@status_window.index)
      end
    end
  end
end
Pour définir la musique qui sera jouée dans le menu, lit tout en haut le module "Fond", les instructions sont inclues dedans.
Si il y a un truc à changer, dit le. :)