Plein de scripts pour Rpg Maker VX

Section pour les scripts RPG Maker VX !

Plein de scripts pour Rpg Maker VX

Message par Lawrence » 25 Jan 2008, 18:51

Temps de jeu + nom de la carte dans les menus


Script a placer au dessus du script Main.
Ajoute donc le temps de jeu plus le nom de la map ou se trouve le héros.
Nommé ce script comme vous voulez (moi nommé "Temps_Lieux" ça marche).

Code : Tout sélectionner
################################################### Mog Basic Menu Plus V 1.0 #
##################################################

# By Moghunter
# http://www.atelier-rgss.com
###################################################Menu padrão VX com adição de alguns extras, neste#script vocêpoderá trabalhar em cima dele e adaptá-lo
#facilmente ao seu jogo.#-------------------------------------------------
############### Game_Actor #
##############
class Game_Actor < Game_Battler
def now_exp
return @exp - @exp_list[@level„
end
def next_exp
return @exp_list[@level+1„ > 0 ? @exp_list[@level+1„ - @exp_list[@level„ : 0
end
end
###############
# Window_Base #
###############
class Window_Base < Window
def draw_actor_level_menu(actor, x, y)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 32, WLH, Vocab::level_a)
self.contents.font.color = normal_color
self.contents.draw_text(x + 16, y, 24, WLH, actor.level, 2)
end
def draw_actor_class_menu(actor, x, y)
self.contents.font.color = normal_color
self.contents.draw_text(x, y, 85, WLH, actor.class.name)
end
def exp_gauge_color1
return text_color(30)
end
def exp_gauge_color2
return text_color(31)
end
def draw_actor_exp_meter(actor, x, y, width = 100)
if actor.next_exp != 0
exp = actor.now_exp
else
exp = 1
end
gw = width * exp / [actor.next_exp, 1„.max
gc1 = exp_gauge_color1
gc2 = exp_gauge_color2
self.contents.fill_rect(x, y + WLH - 8, width, 6, gauge_back_color)
self.contents.gradient_fill_rect(x, y + WLH - 8, gw, 6, gc1, gc2)
self.contents.font.color = system_color
self.contents.draw_text(x, y, 30, WLH, "Exp")
self.contents.font.color = normal_color
xr = x + width
self.contents.draw_text(xr - 60, y, 60, WLH, actor.next_rest_exp_s, 2)
end
end
#####################
# Window_MenuStatus #
#####################
class Window_MenuStatus < Window_Selectable
def initialize(x, y)
super(x, y, 384, 416)
refresh
self.active = false
self.index = -1
end
def refresh
self.contents.clear
@item_max = $game_party.members.size
for actor in $game_party.members
draw_actor_face(actor, 2, actor.index * 96 + 2, 92)
x = 104
y = actor.index * 96 + WLH / 2
draw_actor_name(actor, x, y)
draw_actor_class_menu(actor, x + 120, y)
draw_actor_level_menu(actor, x + 200, y)
draw_actor_state(actor, x, y + WLH * 2)
draw_actor_hp(actor, x + 120, y + WLH * 1)
draw_actor_mp(actor, x + 120, y + WLH * 2)
draw_actor_exp_meter(actor, x , y + WLH * 1)
end
end
def update_cursor
if @index < 0
self.cursor_rect.empty
elsif @index < @item_max
self.cursor_rect.set(0, @index * 96, contents.width, 96)
elsif @index >= 100
self.cursor_rect.set(0, (@index - 100) * 96, contents.width, 96)
else
self.cursor_rect.set(0, 0, contents.width, @item_max * 96)
end
end
end
############
# Game_Map #
############
class Game_Map
attr_reader :map_id
def mpname
$mpname = load_data("Data/MapInfos.rvdata")
$mpname[@map_id„.name
end
end
###############
# Window_Time #
###############
class Window_Mapname < Window_Base
def initialize(x, y)
super(x, y, 160, WLH + 64)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(4, 0, 120, 32, "Location")
self.contents.font.color = normal_color
self.contents.draw_text(4, 32, 120, 32, $game_map.mpname.to_s, 2)
end
end
###############
# Window_Time #
###############
class Window_Time < Window_Base
def initialize(x, y)
super(x, y, 160, WLH + 64)
refresh
end
def refresh
self.contents.clear
self.contents.font.color = system_color
self.contents.draw_text(4, 0, 120, 32, "Play Time")
@total_sec = Graphics.frame_count / Graphics.frame_rate
hour = @total_sec / 60 / 60
min = @total_sec / 60 % 60
sec = @total_sec % 60
text = sprintf("%02d:%02d:%02d", hour, min, sec)
self.contents.font.color = normal_color
self.contents.draw_text(4, 32, 120, 32, text, 2)
end
def update
super
if Graphics.frame_count / Graphics.frame_rate != @total_sec
refresh
end
end
end
##############
# Scene_Menu #
##############
class Scene_Menu
def main
start
perform_transition
Input.update
loop do
Graphics.update
Input.update
update
break if $scene != self
end
Graphics.update
pre_terminate
Graphics.freeze
terminate
end
def initialize(menu_index = 0)
@menu_index = menu_index
end
def create_menu_background
@menuback_sprite = Sprite.new
@menuback_sprite.bitmap = $game_temp.background_bitmap
@menuback_sprite.color.set(16, 16, 16, 128)
update_menu_background
end
def create_menu_background
@menuback_sprite = Sprite.new
@menuback_sprite.bitmap = $game_temp.background_bitmap
@menuback_sprite.color.set(16, 16, 16, 128)
update_menu_background
end
def dispose_menu_background
@menuback_sprite.dispose
end
def update_menu_background
end
def perform_transition
Graphics.transition(10)
end
def start
create_menu_background
create_command_window
@gold_window = Window_Gold.new(0, 360)
@status_window = Window_MenuStatus.new(160, 0)
@playtime_window = Window_Time .new(0, 270)
@mapname_window = Window_Mapname.new(0, 178)
@status_window.openness = 0
@playtime_window.openness = 0
@mapname_window.openness = 0
@gold_window.openness = 0
@status_window.open
@playtime_window.open
@mapname_window.open
@gold_window.open
end
def pre_terminate
@status_window.close
@playtime_window.close
@mapname_window.close
@gold_window.close
@command_window.close
begin
@status_window.update
@playtime_window.update
@mapname_window.update
@gold_window.update
@command_window.update
Graphics.update
end until @status_window.openness == 0
end
def terminate
dispose_menu_background
@command_window.dispose
@gold_window.dispose
@status_window.dispose
@playtime_window.dispose
@mapname_window.dispose
end
def update
update_menu_background
@command_window.update
@gold_window.update
@status_window.update
@mapname_window.update
@playtime_window.update
if @command_window.active
update_command_selection
elsif @status_window.active
update_actor_selection
end
end
def create_command_window
s1 = Vocab::item
s2 = Vocab::skill
s3 = Vocab::equip
s4 = Vocab::status
s5 = Vocab::save
s6 = Vocab::game_end
@command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6„)
@command_window.index = @menu_index
@command_window.openness = 0
@command_window.open
if $game_party.members.size == 0
@command_window.draw_item(0, false)
@command_window.draw_item(1, false)
@command_window.draw_item(2, false)
@command_window.draw_item(3, false)
end
if $game_system.save_disabled
@command_window.draw_item(4, false)
end
end
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
$scene = Scene_Item.new
when 1,2,3
start_actor_selection
when 4
$scene = Scene_File.new(true, false, false)
when 5
$scene = Scene_End.new
end
end
end
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
def end_actor_selection
@command_window.active = true
@status_window.active = false
@status_window.index = -1
end
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
$scene = Scene_Skill.new(@status_window.index)
when 2
$scene = Scene_Equip.new(@status_window.index)
when 3
$scene = Scene_Status.new(@status_window.index)
end
end
end
end
$mogscript = {} if $mogscript == nil
$mogscript["basic_menu_plus"„ = true



Pour avoir les combats à la FF like


Voici un script réalisé par Claimh version 1.0.0
Lien de l'article original pour les combats à la vue "FF like".
Compatible avec le script Backgroun battle présent.

N.B:Quelqu'un à déjà testé ce script, il paraît que cela marche parfaitement

3 scripts. A placer au dessus de Main. (Respecter les noms des scripts)


1er script:
sideview_formation

Code : Tout sélectionner
#==============================================================================
# ¦ VX-RGSS2-6 Side-View Battle System [Formation] [Ver.1.0.0] by Claimh
#------------------------------------------------------------------------------
# English Translation By: Elemental Crisis [http://www.rpgcrisis.net]
#------------------------------------------------------------------------------
# Actor location [Formation]
# The same amount of damage will be given regardless of formation setup.
#==============================================================================

module Battle_Formation
#------------------------------------------------------------------------------
# [Formation Setup]
# $game_system.battle_formation = Formation ID
# It’s possible to change the formation (Even an event script is possible).
FORM = {
# Formation ID => [[Member 1 x?y], [Member2 x, y],
# [Member 3 x, y], [Member 4 x, y]]
0 => [[380,150], [400, 230], [460, 170], [480, 250]]
}
#------------------------------------------------------------------------------
end

#==============================================================================
# ¦ Game_System
#==============================================================================
class Game_System
attr_accessor :battle_formation # Formation ID
#--------------------------------------------------------------------------
# ? Object initialization
#--------------------------------------------------------------------------
alias init_game_system initialize
def initialize
init_game_system
@battle_formation = 0 # Initial formation
end
end

#==============================================================================
# ¦ Game_Actor
#==============================================================================
class Game_Actor < Game_Battler
#--------------------------------------------------------------------------
# ? Are sprites used? [Redefinition]
#--------------------------------------------------------------------------
def use_sprite?
return true
end
#--------------------------------------------------------------------------
# ? Battle screen Acquiring X Coordinate
#--------------------------------------------------------------------------
def screen_x
return Battle_Formation::FORM[$game_system.battle_formation][self.index][0]
end
#--------------------------------------------------------------------------
# ? Battle screen Acquiring Y Coordinate
#--------------------------------------------------------------------------
def screen_y
return Battle_Formation::FORM[$game_system.battle_formation][self.index][1]
end
#--------------------------------------------------------------------------
# ? Battle screen Acquiring Z Coordinate
#--------------------------------------------------------------------------
def screen_z
bitmap = Cache.character(self.character_name)
# Height +Y Coordinates
return screen_y + bitmap.height / 4
end
end



#==============================================================================
# ¦ Game_Enemy
#==============================================================================
class Game_Enemy < Game_Battler
#--------------------------------------------------------------------------
# ? Battle screen Acquiring Z Coordinate [Redefinition]
#--------------------------------------------------------------------------
def screen_z
bitmap = Cache.battler(self.battler_name, self.battler_hue)
# Height +Y Coordinates
return screen_y + bitmap.height
end
end


2éme script:
sideview_motion_ctrl

Code : Tout sélectionner
#==============================================================================
# ¦ VX-RGSS2-6 Side-View Battle System [MotionCtrl] [Ver.1.0.0] by Claimh
#------------------------------------------------------------------------------
# English Translation By: Elemental Crisis [http://www.rpgcrisis.net]
#------------------------------------------------------------------------------
# This script carries out the movement controls of the actors.
#==============================================================================

#==============================================================================
# ¦ Scene_Battle
#==============================================================================
class Scene_Battle < Scene_Base
#--------------------------------------------------------------------------
# ? Battle Start Process
#--------------------------------------------------------------------------
alias process_battle_start_sideview process_battle_start
def process_battle_start
for battler in $game_party.members + $game_troop.members
battler.move_mode = SideView::M_MODE_WAIT
end
process_battle_start_sideview
end
#--------------------------------------------------------------------------
# ? Victory Process
#--------------------------------------------------------------------------
alias process_victory_sideview process_victory
def process_victory
for actor in $game_party.members
actor.move_mode = SideView::M_MODE_WIN
end
process_victory_sideview
end
#--------------------------------------------------------------------------
# ? Wait Until Motion Control Is Finished
#--------------------------------------------------------------------------
def wait_for_motion
while @active_battler.motion_stop
update_basic
end
end
#--------------------------------------------------------------------------
# ? Execute Combat Operations: Attack [Redefinition]
#--------------------------------------------------------------------------
def execute_action_attack
text = sprintf(Vocab::DoAttack, @active_battler.name)
@message_window.add_instant_text(text)
targets = @active_battler.action.make_targets
#---Enemy attack sound reproduced.
if @active_battler.is_a?(Game_Enemy)
Sound.play_enemy_attack
wait(15, true)
end
#--- Proximity (Going)
SideView.set_target_point(@active_battler, targets[0])
@active_battler.move_mode = SideView::M_MODE_ATK1
@active_battler.motion_stop = true
wait_for_motion
#--- Attack
wait(5)
@active_battler.move_mode = SideView::M_MODE_ATK2
#---
display_attack_animation(targets)
wait(20)
for target in targets
target.attack_effect(@active_battler)
display_action_effects(target)
end
#--- Proximity (Return)
@active_battler.move_mode = SideView::M_MODE_ATK3
@active_battler.motion_stop = true
wait_for_motion
#---Wait
for target in targets
target.move_mode = SideView::M_MODE_WAIT
end
@active_battler.move_mode = SideView::M_MODE_WAIT
#---
end
#--------------------------------------------------------------------------
# ? Execute Combat Operations: Skill [Redefinition]
#--------------------------------------------------------------------------
def execute_action_skill
skill = @active_battler.action.skill
text = @active_battler.name + skill.message1
@message_window.add_instant_text(text)
unless skill.message2.empty?
wait(10)
@message_window.add_instant_text(skill.message2)
end
#--- Enemy attack sound reproduced.
if @active_battler.is_a?(Game_Enemy)
Sound.play_enemy_attack
wait(15, true)
end
#--- Long distance attack
@active_battler.move_mode = SideView::M_MODE_MAGI
#---
targets = @active_battler.action.make_targets
display_animation(targets, skill.animation_id)
@active_battler.mp -= @active_battler.calc_mp_cost(skill)
$game_temp.common_event_id = skill.common_event_id
for target in targets
target.skill_effect(@active_battler, skill)
display_action_effects(target, skill)
end
#---Wait
for target in targets
target.move_mode = SideView::M_MODE_WAIT
end
@active_battler.move_mode = SideView::M_MODE_WAIT
#---
end
#--------------------------------------------------------------------------
# ? Execute Combat Operations: Item [Redefinition]
#--------------------------------------------------------------------------
def execute_action_item
item = @active_battler.action.item
text = sprintf(Vocab::UseItem, @active_battler.name, item.name)
@message_window.add_instant_text(text)
#--- Enemy attack sound reproduced.
if @active_battler.is_a?(Game_Enemy)
Sound.play_enemy_attack
wait(15, true)
end
#--- Long distance attack
@active_battler.move_mode = SideView::M_MODE_MAGI
#---
targets = @active_battler.action.make_targets
display_animation(targets, item.animation_id)
$game_party.consume_item(item)
$game_temp.common_event_id = item.common_event_id
for target in targets
target.item_effect(@active_battler, item)
display_action_effects(target, item)
end
#---Wait
for target in targets
target.move_mode = SideView::M_MODE_WAIT
end
@active_battler.move_mode = SideView::M_MODE_WAIT
#---
end
#--------------------------------------------------------------------------
# ? Attack Animation Display [Redefinition]
# Targets : Object's Arrangement
#--------------------------------------------------------------------------
# ?Changed part?
# Enemy sound effect is changed so it can be used in each phase of operation.
# However, it changes so that the attack animation of an enemy can be displayed.
#--------------------------------------------------------------------------
def display_attack_animation(targets)
display_normal_animation(targets, @active_battler.atk_animation_id, false)
display_normal_animation(targets, @active_battler.atk_animation_id2, true)
wait_for_animation
end
#--------------------------------------------------------------------------
# ? HP Damage display [Redefinition]
# target : Candidate
# obj : Skill or item
#--------------------------------------------------------------------------
def display_hp_damage(target, obj = nil)
if target.hp_damage == 0 # No damage
return if obj != nil and obj.damage_to_mp
return if obj != nil and obj.base_damage == 0
fmt = target.actor? ? Vocab::ActorNoDamage : Vocab::EnemyNoDamage
text = sprintf(fmt, target.name)
elsif target.absorbed # Absorption
fmt = target.actor? ? Vocab::ActorDrain : Vocab::EnemyDrain
text = sprintf(fmt, target.name, Vocab::hp, target.hp_damage)
elsif target.hp_damage > 0 # Damage
if target.actor?
text = sprintf(Vocab::ActorDamage, target.name, target.hp_damage)
Sound.play_actor_damage
$game_troop.screen.start_shake(5, 5, 10)
target.blink = true # Only adds here
else
text = sprintf(Vocab::EnemyDamage, target.name, target.hp_damage)
Sound.play_enemy_damage
target.blink = true
end
else # Recovery
fmt = target.actor? ? Vocab::ActorRecovery : Vocab::EnemyRecovery
text = sprintf(fmt, target.name, Vocab::hp, -target.hp_damage)
Sound.play_recovery
end
@message_window.add_instant_text(text)
wait(30)
end
end


3éme script:
sideview_motion_exe
Code : Tout sélectionner
#==============================================================================
# ¦ VX-RGSS2-6 Side-View Battle System[MotionExe] [Ver.1.0.0] by Claimh
#------------------------------------------------------------------------------
# English Translation By: Elemental Crisis [http://www.rpgcrisis.net]
#------------------------------------------------------------------------------
# This script executes movement controls of the actors.
#==============================================================================

module SideView
#----------------------------------------------------------------------------
#-----[Operation Setup]-----
# Operation Speed
MOTION_SPEED = 20

#-----[Animation Setup]-----
# Usual enemy attack animation setup.
E_ANIME = {
# EnemyID => [Usually atttack and additional attack animations.]
1 => [1, 0]
}

#----------------------------------------------------------------------------
#----------------------------------------------------------------------------
# Motion Control Mode
M_MODE_WAIT = 0 # Standby
M_MODE_MAGI = 1 # Attack
M_MODE_DAMG = 2 # Non-Damage Attack
M_MODE_WIN = 3 # Victory
M_MODE_ATK1 = 4 # Direct Attack (Approaching)
M_MODE_ATK2 = 5 # Direct Attack (Attacking)
M_MODE_ATK3 = 6 # Direct Attack (Returning)

module_function
#--------------------------------------------------------------------------
# ? Movement-Zone Calculation
#--------------------------------------------------------------------------
def set_target_point(attacker, target)
case target
when Game_Actor
bits = Cache.character(target.character_name)
attacker.target_x = target.screen_x + (bits.width / 8)
attacker.target_y = target.screen_y
when Game_Enemy
bits = Cache.battler(target.battler_name, target.battler_hue)
attacker.target_x = target.screen_x + (bits.width / 2)
attacker.target_y = target.screen_y
end
end
end

class Game_Battler
attr_accessor :move_mode # Operation Mode
# 0:Standby 1:Attack 2: Un-useless 3:Victory
attr_accessor :motion_stop # Operation Stop Flag (Under Movement Flag)
attr_accessor :target_x # Move Position(x)
attr_accessor :target_y # Move Position(y)
#--------------------------------------------------------------------------
# ? Object Initialization
#--------------------------------------------------------------------------
alias initialize_sdva_corpse initialize
def initialize
initialize_sdva_corpse
@move_mode = 0
@motion_stop = false
@target_x = 0
@target_y = 0
end
end

#==============================================================================
# ¦ Game_Enemy
#==============================================================================
class Game_Enemy < Game_Battler
#--------------------------------------------------------------------------
# ? Attack Animation ID Acquisition
#--------------------------------------------------------------------------
def atk_animation_id
return 0 if SideView::E_ANIME[@enemy_id].nil?
return SideView::E_ANIME[@enemy_id][0]
end
#--------------------------------------------------------------------------
# ? Attack Animation ID Acquisition (2 Sword Style:2 Weapons )
#--------------------------------------------------------------------------
def atk_animation_id2
return 0 if SideView::E_ANIME[@enemy_id].nil?
return SideView::E_ANIME[@enemy_id][1]
end
end



#==============================================================================
# ¦ Sprite_Battler
#==============================================================================
class Sprite_Battler < Sprite_Base
#--------------------------------------------------------------------------
# ? Object Initialization
# viewport : View Port
# battler : Battler (Game_Battler)
#--------------------------------------------------------------------------
alias initialize_sideview initialize
def initialize(viewport, battler = nil)
initialize_sideview(viewport, battler)
init_direct_attack
end
#--------------------------------------------------------------------------
# ? Set Proximity Value For Attack
#--------------------------------------------------------------------------
def init_direct_attack
@direct_attack_cnt = 0
@direct_attack_phase = 0
@direct_move_cnt = 0
@battler_x_plus = 0
@battler_y_plus = 0
@moving_mode = 0
@pattern = 0
@direction = 0
end
#--------------------------------------------------------------------------
# ? Frame Renewal [Redefinition]
#--------------------------------------------------------------------------
def update
super
if @battler == nil
self.bitmap = nil
else
@use_sprite = @battler.use_sprite?
if @use_sprite
self.x = @battler.screen_x + @battler_x_plus
self.y = @battler.screen_y + @battler_y_plus
self.z = @battler.screen_z
update_battler_bitmap
end
setup_new_effect
update_effect
end
end
#--------------------------------------------------------------------------
# ? Bitmap Transfer Source Renewal
#--------------------------------------------------------------------------
alias update_battler_bitmap_sideview update_battler_bitmap
def update_battler_bitmap
case @battler
when Game_Actor
if @battler.character_name != @battler_name or
@battler.character_index != @battler_hue
@battler_name = @battler.character_name
@battler_hue = @battler.character_index
draw_pre_character
draw_character
if (@battler.dead? or @battler.hidden) and !@battler.dead_delay
self.opacity = 0
end
end
when Game_Enemy
if @battler.battler_name != @battler_name or
@battler.battler_hue != @battler_hue
@battler_name = @battler.battler_name
@battler_hue = @battler.battler_hue
draw_battler
if (@battler.dead? or @battler.hidden) and !@battler.dead_delay
self.opacity = 0
end
end
end
motion_control
end
#--------------------------------------------------------------------------
# ? Battler Drawing
#--------------------------------------------------------------------------
def draw_battler
self.bitmap = Cache.battler(@battler_name, @battler_hue)
@width = bitmap.width
@height = bitmap.height
self.ox = @width / 2
self.oy = @height
end
#--------------------------------------------------------------------------
# ? Pre-Character Drawing [Common]
#--------------------------------------------------------------------------
def draw_pre_character
self.bitmap = Cache.character(@battler_name)
sign = @battler_name[/^[\!\$]./]
if sign != nil and sign.include?('$')
@width = bitmap.width / 3
@height = bitmap.height / 4
else
@width = bitmap.width / 12
@height = bitmap.height / 8
end
self.ox = @width / 2
self.oy = @height
end
#--------------------------------------------------------------------------
# ? Character Drawing [Common]
#--------------------------------------------------------------------------
def draw_character
index = @battler_hue
pattern = @pattern < 3 ? @pattern : 1
sx = (index % 4 * 3 + pattern) * @width
sy = (index / 4 * 4 + (@direction - 2) / 2) * @height
self.src_rect.set(sx, sy, @width, @height)
end
#--------------------------------------------------------------------------
# ? Motion Control
#--------------------------------------------------------------------------
def motion_control
# Memory Operation Mode
@moving_mode = @battler.move_mode
# Battler Drawing
case @battler
when Game_Actor # Actor
actor_motion_control
when Game_Enemy # Enemy
enemy_motion_control
end
end
#--------------------------------------------------------------------------
# ? Motion Control (Actor)
#--------------------------------------------------------------------------
def actor_motion_control
# Operation Change
case @moving_mode
when SideView::M_MODE_WAIT # Standby
init_direct_attack
@battler_x_plus = 0
@direction = 4
@pattern = 1
when SideView::M_MODE_MAGI # Attack
@battler_x_plus = -10
@direction = 4
@pattern = 3
when SideView::M_MODE_DAMG # Non-Damage Attack
@battler_x_plus = 10
@direction = 4
@pattern = 3
when SideView::M_MODE_WIN # Victory
@direction = 2
@pattern = 1
when SideView::M_MODE_ATK1 # Direct Attack (Approaching)
exe_moving_attack_start
@end_pos_x = @battler_x_plus
when SideView::M_MODE_ATK2 # Direct Attack (Attacking)
@battler_x_plus = @end_pos_x - 10
when SideView::M_MODE_ATK3 # Direct Attack (Returning)
exe_moving_attack_end
else
p "error:Sprite_Battler>> @moving_mode"
end
draw_character
end
#--------------------------------------------------------------------------
# ? Motion Control (Enemy)
#--------------------------------------------------------------------------
def enemy_motion_control
# ??????
case @moving_mode
when SideView::M_MODE_WAIT # Standby
init_direct_attack
when SideView::M_MODE_MAGI # Attack
@battler_x_plus = 10
when SideView::M_MODE_DAMG # Non-Damage Attack
@battler_x_plus = -10
@shake_flg = true
when SideView::M_MODE_ATK1 # Direct Attack (Approaching)
exe_moving_attack_start
@end_pos_x = @battler_x_plus
when SideView::M_MODE_ATK2 # Direct Attack (Attacking)
@battler_x_plus = @end_pos_x + 10
when SideView::M_MODE_ATK3 # Direct Attack (Returning)
exe_moving_attack_end
else
p "error:Sprite_Battler>> @moving_mode", @moving_mode
end
end
#--------------------------------------------------------------------------
# ? Proximity Attack Execution Method
#--------------------------------------------------------------------------
def exe_moving_attack_start
return unless @battler.motion_stop
case @direct_attack_phase
when 0 # Start Operation Preparation
diratk_start
when 1 # Move Operation (Going)
diratk_move
when 2 # After-Movement Wait
diratk_wait
end
end
def exe_moving_attack_end
case @direct_attack_phase
when 0 # Attack Operation
diratk_attack
when 1 # Move Operation (Return)
diratk_back
when 2 # Operation End
diratk_end
end
end
#--------------------------------------------------------------------------
# ? Proximity Attack Execution [Start Operation Preparation]
#--------------------------------------------------------------------------
def diratk_start
# Pose Change
@pattern = 1
# The number of frames needed is the distance between current position
# and target position.
pos_x = @battler.target_x - self.x
pos_y = @battler.target_y - self.y
# Caculation for ammount of frames needed.
@direct_move_cnt = @direct_attack_cnt = (pos_x.abs / SideView::MOTION_SPEED).round
# NEXT Phase
@direct_attack_phase += 1
end
#--------------------------------------------------------------------------
# ? Proximity Attack Execution [Move Operation (Going)]
#--------------------------------------------------------------------------
def diratk_move
case @battler
when Game_Actor
x_plus = @width
y_plus = -@height / 4
when Game_Enemy
x_plus = -@width - 10
y_plus = @height / 4
end
# The next movement location is figured out by the distance between
# current position and target position.
pos_x = @battler.target_x - self.x + x_plus
pos_y = @battler.target_y - self.y + y_plus
@battler_x_plus += pos_x / @direct_attack_cnt if @direct_attack_cnt != 0
@battler_y_plus += pos_y / @direct_attack_cnt if @direct_attack_cnt != 0
# End count
@direct_attack_cnt -= 1
# Last movement (Insurance: Last correction)
if @direct_attack_cnt <= 0
@battler_x_plus = @battler.target_x - @battler.screen_x + x_plus
@battler_y_plus = @battler.target_y - @battler.screen_y + y_plus
# NEXT Phase
@direct_attack_cnt = 5
@direct_attack_phase += 1
end
end
#--------------------------------------------------------------------------
# ? Proximity Attack Execution [Attack Operation Return]
#--------------------------------------------------------------------------
def diratk_wait
# End Count
@direct_attack_cnt -= 1
# Last Movement
if @direct_attack_cnt <= 0
# Pose Change
@pattern = 3
# END Phase
@direct_attack_phase = 0
@battler.motion_stop = false
end
end
#--------------------------------------------------------------------------
# ? Proximity Attack Execution [Attack Operation Return]
#--------------------------------------------------------------------------
def diratk_attack
# Pose Change
@pattern = 1
# End Wait Count
@direct_attack_cnt = @direct_move_cnt
# NEXT Phase
@direct_attack_phase += 1
end
#--------------------------------------------------------------------------
# ? Proximity Attack Execution [Move Operation (Return)]
#--------------------------------------------------------------------------
def diratk_back
# The next movement location is figured out by the distance between
# current position and target position.
pos_x = @battler.screen_x - self.x
pos_y = @battler.screen_y - self.y
@battler_x_plus += pos_x / @direct_attack_cnt if @direct_attack_cnt != 0
@battler_y_plus += pos_y / @direct_attack_cnt if @direct_attack_cnt != 0
# End Count
@direct_attack_cnt -= 1
# Last Movement
if @direct_attack_cnt == 0
@battler_x_plus = 0
@battler_y_plus = 0
# NEXT Phase
@direct_attack_phase += 1
end
end
#--------------------------------------------------------------------------
# ? Proximity attack execution [Operation End]
#--------------------------------------------------------------------------
def diratk_end
init_direct_attack
@battler.motion_stop = false
# END Phase
@direct_attack_phase = 0
end
end


Pour éliminer le bord noir


Voici un script pour
éliminer les bords noirs.
Attention la résolution ne change pas.
Cela reste des carreaux de 32 pixel.

Par contre vous devez changer les dimensions des pictures comme l'ecran
titres, game over, des combats, ....
La dimension initial du script c'est 640*480. Comme XP. Bien sur vous
pouvez modifier cela.

Lien du topic original


D'après l'auteur, avec ce script, vous ne pouvez pas
commercialiser vôtre jeu. Mais il propose une
"licence" Aller voir sur le lien donné en haut.

Au dessus du scipt main.

Code : Tout sélectionner
WIDTH = 640
HEIGHT = 480
DELTA_WIDTH = (WIDTH - 544).abs
DELTA_HEIGHT = (HEIGHT - 416).abs
class Spriteset_Map
def create_viewports
@viewport1 = Viewport.new(0, 0, WIDTH, HEIGHT)
@viewport2 = Viewport.new(0, 0, WIDTH, HEIGHT)
@viewport3 = Viewport.new(0, 0, WIDTH, HEIGHT)
@viewport2.z = 50
@viewport3.z = 100
end
end

class Spriteset_Battle
def create_viewports
@viewport1 = Viewport.new(0, 0, WIDTH, HEIGHT)
@viewport2 = Viewport.new(0, 0, WIDTH, HEIGHT)
@viewport3 = Viewport.new(0, 0, WIDTH, HEIGHT)
@viewport2.z = 50
@viewport3.z = 100
end
end

class Window_Base < Window
def x=(x)
super(x + DELTA_WIDTH / 2)
end
def y=(y)
super(y + DELTA_HEIGHT/ 2)
end
end


class Scene_Battle < Scene_Base
def create_info_viewport
@info_viewport = Viewport.new(0, 288, WIDTH,
HEIGHT)
@info_viewport.z = 100
@status_window = Window_BattleStatus.new
@party_command_window = Window_PartyCommand.new
@actor_command_window = Window_ActorCommand.new
@status_window.viewport = @info_viewport
@party_command_window.viewport = @info_viewport
@actor_command_window.viewport = @info_viewport
@status_window.x = 128
@actor_command_window.x = 544
@info_viewport.visible = false
end
end

class Scene_Item < Scene_Base
def start
super
create_menu_background
@viewport = Viewport.new(0, 0, WIDTH, HEIGHT)
@help_window = Window_Help.new
@help_window.viewport = @viewport
@item_window = Window_Item.new(0, 56, 544, 360) @item_window.help_window = @help_window
@item_window.active = false
@target_window =
Window_MenuStatus.new(0, 0)
hide_target_window
end

def show_target_window(right)
@item_window.active = false
width_remain = WIDTH - @target_window.width
@target_window.x = right ? width_remain : 0
@target_window.visible = true
@target_window.active = true
if right
@viewport.rect.set(0, 0, width_remain,
HEIGHT)
@viewport.ox = 0
else

@viewport.rect.set(@target_window.width, 0, width_remain, HEIGHT)

@viewport.ox = @target_window.width
end
end
def hide_target_window
@item_window.active = true
@target_window.visible = false
@target_window.active = false
@viewport.rect.set(0, 0, WIDTH, HEIGHT)
@viewport.ox = 0
end
end

class Scene_Skill < Scene_Base
def start
super
create_menu_background
@actor = $game_party.members[@actor_index]
@viewport = Viewport.new(0, 0, WIDTH, HEIGHT)
@help_window = Window_Help.new
@help_window.viewport = @viewport
@status_window = Window_SkillStatus.new(0, 56,
@actor)
@status_window.viewport = @viewport
@skill_window = Window_Skill.new(0, 112, 544,
304, @actor)

@skill_window.viewport = @viewport
@skill_window.help_window = @help_window
@target_window = Window_MenuStatus.new(0, 0)
hide_target_window
end
def show_target_window(right)
@skill_window.active = false
width_remain = WIDTH - @target_window.width
@target_window.x = right ? width_remain : 0 @target_window.visible = true
@target_window.active = true
if right
@viewport.rect.set(0, 0, width_remain,
HEIGHT)
@viewport.ox = 0
else
@viewport.rect.set(@target_window.width, 0, width_remain, HEIGHT)
@viewport.ox = @target_window.width
end
end
def hide_target_window
@skill_window.active = true
@target_window.visible = false
@target_window.active = false
@viewport.rect.set(0, 0, WIDTH, HEIGHT)
@viewport.ox = 0
end
end

Et voici ce que vous devez placer sur la 1er ligne du script Main.

Code:
Graphics.resize_screen(WIDTH, HEIGHT)


Pour Flasher les ennemis dans les combats


Ce script permet de flasher l'ennemi sélectionné en combat.
A placer avant le Script "Main":

target_flash

Code : Tout sélectionner
#==============================================================================
# ¦ ?????????  Ver1.00 (??:2008.01.12)
#
# URL : http://f53.aaa.livedoor.jp/~momomo/
#------------------------------------------------------------------------------
#   ????????????????????????????????
#==============================================================================

#==============================================================================
# ¦ Scene_Battle
#==============================================================================
class Scene_Battle < Scene_Base
  #--------------------------------------------------------------------------
  # ? ???????????
  #--------------------------------------------------------------------------
  alias momo_target_flash_update_target_enemy_selection :update_target_enemy_selection
  def update_target_enemy_selection
    # ???????
    momo_target_flash_update_target_enemy_selection
   
    # ?????????????????
    if @target_enemy_window != nil
      # ?????????????????????true?
      @target_enemy_window.enemy.white_flash = true
    end
  end
end


Script pour avoir des fonds de combat.


Complément info:
Ce script fonctionne.


Ce script ce place au dessus du script Main.
Il vous permet afficher un fond de combat par carte que vous placerez dans le dossier picture.
Voici comment on nomme la picure:

Citation:
001-nom


Le 001 c'est le numéro de la carte.
Ensuite dans le script il faut aussi paramétrer cela.

Citation:
1 => "001-Grassland01",
2 => "001-Grassland01"


Au début vous avez cette portion de code.
Changer cela par le nom de la picture.
Et garder le 1-2 après 3.
Et surtout la virgule aussi.

Voici l'article original en anglais plus le script.


Script Name: Battle Backgrounds
Ecrit par: Synthesize
Version actuel: Version 1.00A
Date: January 20, 2008

What is this script?
This simple script allows you to have a battle background instead of the abstract background which is the default for RPG Maker VX. Simply define the Background filename in the customization section, along with your Map_ID.

Features:
- Simple
- Easy to use
- Turn ON/OFF the battlefloor
- Once RMVX is released, I will interpret more features

Version :
V1.00
- Script is released

Code : Tout sélectionner
#===============================================================================

# Battle Backgrounds - RMVX

#===============================================================================

# Written by Synthesize

# January 20, 2008

# Version 1.00A

#===============================================================================

#                       * This script is untested. *

#===============================================================================

module SynBattleB

  # Place your battle backgrounds in the 'Pictures' folder (Graphics/Pictures)

  # Format = {map_id => Battleback Name}

  Battle_background =

  {

  1 => "001-Grassland01",

  2 => "001-Grassland01"

  }

  #-----------------------------------------------------------------------------

  # Create the battlefloor?

  Create_battlefloor = false

  #-----------------------------------------------------------------------------

  # This was being requested on quite a fe forums now, so I threw a quick script

  # together. It is nice and simple, and does what it is suppsoed to do. Once

  # RMVX is released in English, then I will add additional features into this.

  #-----------------------------------------------------------------------------

end

#-------------------------------------------------------------------------------

# Spriteset_Battle

#-------------------------------------------------------------------------------

class Spriteset_Battle

  alias syn_create_battlefloor create_battlefloor

  #-----------------------------------------------------------------------------

  # Create Battleback

  #-----------------------------------------------------------------------------

  def create_battleback

    image = SynBattleB::Battle_background[$game_map.map_id„

    @battleback_sprite = Sprite.new(@viewport1)

    @battleback_sprite.bitmap = Cache.picture(image)

  end

  def create_battlefloor

    @battlefloor_sprite = Sprite.new(@viewport1)

    syn_create_battlefloor if SynBattleB::Create_battlefloor == true

  end

end

#===============================================================================

#                        * This script is untested *

#=============================================================================== 

# Version 1.00A

# January 20, 2008

# Written by Synthesize

#===============================================================================

# Battle Backgrounds - RMVX

#===============================================================================


Enfin, j'ai terminer. Je n'ai fait qu'un copier-coller d'un site (voir ressource). Je remercie quand même le site de Oniromancie de pouvoir publier ces ressources.

Ressource:Oniromancie
Avatar de l’utilisateur
Lawrence
Membre privilégié
Membre privilégié
 
Message(s) : 359
Inscription : 07 Nov 2007, 19:05
Localisation : Marseille

Re: Script pur Rpg Maker VX

Message par Shaolan » 25 Jan 2008, 21:00

ça n'a rien avoir mais

est ce que les scripts de rpgmaker XP sont compatible avec RPG Maker VX ?
Avatar de l’utilisateur
Shaolan
Maitre
Maitre
 
Message(s) : 1710
Inscription : 25 Déc 2006, 21:37

Re: Script pur Rpg Maker VX

Message par Martial » 25 Jan 2008, 21:58

Merci pour tout ces scripts !

Par contre, le premier n'a pas l'air de fonctionner :cry: C'est moi, ou ça le fait à tout le monde ? :?:

EDIT:

"Maintenant, nous ne pouvons assurer que les jeux issus de la première version RPG Maker XP soient fonctionnels avec la dernière version. Les scripts nommés RGSS ne sont plus utilisés de la même façon."
L'important n'est pas de connaître mais de savoir trouver !
La gentillesse ou la franchise ? Que choisir ?
Vive les otakus !!
Retourner sur le site
Avatar de l’utilisateur
Martial
Administrateur
Administrateur
 
Message(s) : 2520
Inscription : 10 Nov 2006, 23:41
Localisation : Rambouillet
Meilleurs scores: 12

Re: Plein de scripts pour Rpg Maker VX

Message par D@nOver » 09 Juil 2009, 10:07

Non les scripte pour RPG Maker VX ne sont pas compatible avec RPGM XP.
Cependant j'avais vue sur un site anglais que des amateur en programmation RUBY avec fait un scripte que tu inséré dans VX et tu pouvais ensuite mettre les scripte de XP !
Sa servait en gros comme une sorte de traducteur de XP ver VX ! (Cependant ce n' était pas très au point, et le projet été en cour de développement a l'époque. (environ 6 moins)

Je t'explique rapidement le principe :
Dans VX les appellation du hero ne sont pas les mem que dans XP, se qui va posser probleme quand tu va coller ton scripte de XP dans VX !
L'appellation du héro n' étend pas la méme ! VX ne reconnait donc pas ce scripte comme un scripte valide et donc il y a BUG !
C'est allor que des p'tit gas made in England on eu l'idée de proposé une sorte de "traducteur d'appellation " qui rendrai les thermes des scripte utiliser dans RPG Maker XP ; compréhensible dans RPG Maker VX !! :bien:

Mais je n'est malheureusement plus ce scripte en ma possession mais je vais rechercher, si je le retrouve je le poste dans ce même TOPIC ! :+1:

Sa donner un truc du genre:

Terme de XP = Ce therme sous VX
appellation du menu sous XP = Cette appellation sous VX
terme en référence avec le "héros1" = ce terme en référence avec appellation "heros1" sous VX

Sa parait pas peut-être facile a maitre en place mais c'est extrêmement compliquer ! Y faut avoir de très bonne connaissance non seulement en RUBY mais aussi en RGSS1 et RGSS2 pour pouvoir les rendre compréhensible l'un de l'autre !
J'avais tentai de modifier ce scripte ( "traducteur") pour mon usage perso mais y avait trop de boulot !

A+
Avatar de l’utilisateur
D@nOver
Fréquent
Fréquent
 
Message(s) : 10
Inscription : 09 Juil 2009, 07:27
Localisation : France chez moi, et juste devant t'es yeux sur ton ecran ! =)

Re: Plein de scripts pour Rpg Maker VX

Message par Martial » 09 Juil 2009, 16:14

Ah, je savais qu'il y avait une histoire de différence avec un mot-clé du langage, mais je n'avais encore jamais entendu parlé du changement de l'appellation du Héros ! Merci pour l'info ! :bien:

Puis si jamais tu retrouves le script "traducteur", je suis preneur ! :)
L'important n'est pas de connaître mais de savoir trouver !
La gentillesse ou la franchise ? Que choisir ?
Vive les otakus !!
Retourner sur le site
Avatar de l’utilisateur
Martial
Administrateur
Administrateur
 
Message(s) : 2520
Inscription : 10 Nov 2006, 23:41
Localisation : Rambouillet
Meilleurs scores: 12

Re: Plein de scripts pour Rpg Maker VX

Message par D@nOver » 10 Juil 2009, 08:40

Oui ok je le poste si je le retrouve !
Hier j'ai chercher sans résultat... O_o mais je continue .
:bien:
Avatar de l’utilisateur
D@nOver
Fréquent
Fréquent
 
Message(s) : 10
Inscription : 09 Juil 2009, 07:27
Localisation : France chez moi, et juste devant t'es yeux sur ton ecran ! =)

Re: Plein de scripts pour Rpg Maker VX

Message par D@nOver » 10 Juil 2009, 08:51

Hé bien réjouissé vous es gas !
J'ai regarder dans un vieux projet sous RPG Maker VX et soudain ques que je trouve ! ? O_o
LE scripte ! qui rend compatible les scriptes RPGM XP ver RPGM VX !
:ah: :ah:
Code : Tout sélectionner
#==========================================================================
# ** RMXP to RMVX Compatibility Patch
#==========================================================================
# by sandgolem & Solstice for gamebaker.com
# Version 3 [VX]
# March 9th, 2008
#==========================================================================

module GameBaker
  BattleCompatibilityType = 2
end

#==========================================================================
#
# To check for updates or find more scripts, visit:
#       http://www.gamebaker.com/rmvx/scripts/
# Our RMXP scripts: http://www.gamebaker.com/rmxp/scripts/
#
# This script was meant to be exclusive to GameBaker.com
#
# Instructions: http://www.gamebaker.com/rmvx/scripts/e/compatibility-patch.php
# Discussion/Help: http://forums.gamebaker.com/showthread.php?t=1380
#
#==========================================================================

$DEBUG = $TEST

module Cache
  def self.battleback(filename); Cache.parallax(filename); end
  def self.fog(filename); Cache.system(filename); end
  def self.gameover(filename); Cache.system(filename); end
  def self.icon(filename); Cache.system(filename); end
  def self.panorama(filename); Cache.parallax(filename); end
end

module RPG
  class Armor
    def guard_element_set; return @element_set; end
  end
   
  class System
    def cursor_se; return @sounds[0]; end
    def decision_se; return @sounds[1]; end
    def cancel_se; return @sounds[2]; end
    def buzzer_se; return @sounds[3]; end
    def equip_se; return @sounds[4]; end
    def shop_se; return @sounds[17]; end
    def save_se; return @sounds[5]; end
    def load_se; return @sounds[6]; end
    def battle_start_se; return @sounds[7]; end
    def escape_se; return @sounds[8]; end
    def enemy_collapse_se; return @sounds[11]; end
    def actor_collapse_se; return @sounds[13]; end
    def windowskin_name; return 'Window'; end
  end
end

class Game_Actor
  def equip(type,id,test = false); change_equip_by_id(type,id,test); end
end
 
class Game_Battler
  attr_accessor :animation_hit, :critical, :damage, :damage_pop
 
  def current_action; return @action; end
  def sp; return @mp; end
  def sp=(num); mp = num; end
end
 
class Game_Character
  attr_accessor :character_hue
end

class Game_Interpreter
  def command_106; command_230; end
  def command_207; command_212; end
  def command_208; command_211; end
  def command_209; command_205; end
end

class Game_Map
  attr_accessor :autotile_names, :battleback_name, :priorities, :tileset_name
  attr_accessor :fog_blend_type, :fog_hue, :fog_opacity, :fog_ox, :fog_oy,
                :fog_name, :fog_sx, :fog_sy, :fog_tone, :fog_zoom
  attr_accessor :panorama_hue, :terrain_tags
 
  def panorama_name; return parallax_name; end
  def panorama_name=(num); @parallax_name = num; end
  end
  #MODIFICATION faite par moi
  class Game_Map
def panorama; return parallax; end
def panorama=(num); @parallax= num; end
end 

class Game_Map
def battleback_name; return parallax_name; end
def battleback_name=(num); @parallax_name= num; end
end

class Game_Map
def battleback; return parallax; end
def battleback=(num); @parallax= num; end
end
#Fin de modification faite par moi
class Game_Party
  def actors; members; end
  def gain_armor(id,num); gain_item($data_armors[id],num); end
  def gain_weapon(id,num); gain_item($data_weapons[id],num); end

  def gain_item(id,num,something = false)
    id = $data_items[id] if id.is_a?(Integer)
    gain_item(id,num,something)
  end
end

class Game_Player
  attr_accessor :transferring, :new_map_id, :new_x, :new_y, :new_direction
end

class Game_System
  attr_accessor :magic_number, :message_frame
 
  def battle_interpreter; return $game_troop.interpreter; end
  def bgm_play(name); gamebaker_compatibility_sound(name,'RPG::BGM'); end
  def bgs_play(name); gamebaker_compatibility_sound(name,'RPG::BGS',80); end
  def map_interpreter; return $game_map.interpreter; end
  def me_play(name); gamebaker_compatibility_sound(name,'RPG::ME'); end
  def message_position; return $game_message.position; end
  def message_position=(num); $game_message.position = num; end
  def se_play(name); gamebaker_compatibility_sound(name,'RPG::SE',80); end
 
  def gamebaker_compatibility_sound(name,type,vol = 100)
    begin
      name.play
    rescue
      pitch = 100
      if name.is_a?(RPG::AudioFile)
        vol = name.volume
        pitch = name.pitch
        name = name.name
      end
      temp = eval(type + '.new(name,' + vol.to_s + ',' + pitch.to_s + ')')
      temp.play
    end
  end
end

class Game_Temp
  attr_accessor :gamebaker_compat_gameover2, :battle_main_phase,
    :transition_name, :transition_processing, :battleback_name
 
  def gameover; return @gamebaker_compat_gameover2; end
  def gameover=(num)
    if num == true
      if @in_battle
        $scene.call_gameover
      else
        @next_scene = 'gameover'
      end
      return
    end
    @gamebaker_compat_gameover2 = nil
    @next_scene = nil if @next_scene == 'gameover'
  end
 
  def gamebaker_compat_scenecall(num,name)
    if num == true
      @next_scene = name
    elsif @next_scene == name
      @next_scene = nil
    end
  end
 
  def battle_calling; return @next_scene == 'battle'; end
  def battle_calling=(num); gamebaker_compat_scenecall(num,'battle'); end
  def debug_calling; return @next_scene == 'debug'; end
  def debug_calling=(num); gamebaker_compat_scenecall(num,'debug'); end
  def menu_calling; return @next_scene == 'menu'; end
  def menu_calling=(num); gamebaker_compat_scenecall(num,'menu'); end
  def name_calling; return @next_scene == 'name'; end
  def name_calling=(num); gamebaker_compat_scenecall(num,'name'); end
  def save_calling; return @next_scene == 'save'; end
  def save_calling=(num); gamebaker_compat_scenecall(num,'save'); end
  def shop_calling; return @next_scene == 'shop'; end
  def shop_calling=(num); gamebaker_compat_scenecall(num,'shop'); end
  def to_title; return @next_scene == 'title'; end
  def to_title=(num); gamebaker_compat_scenecall(num,'title'); end

  def battle_abort; return @next_scene == 'map'; end
  def battle_abort=(num); $game_temp.next_scene = "map" if num == true; end
  def battle_can_escape; return $game_troop.can_escape; end
  def battle_can_escape=(num); $game_troop.can_escape = num; end
  def battle_can_lose; return $game_troop.can_lose; end
  def battle_can_lose=(num); $game_troop.can_lose = num; end
  def battle_event_flags; return $game_troop.event_flags; end
  def battle_event_flags=(num); $game_troop.event_flags = num; end
  def battle_forcing_battler; return $game_troop.forcing_battler; end
  def battle_forcing_battler=(num); $game_troop.forcing_battler = num; end 
  def battle_troop_id; return $game_troop.troop_id; end
  def battle_troop_id=(num); $game_troop.gamebaker_compat_id = num; end
  def battle_turn; return $game_troop.turn_count; end
  def battle_turn=(num); $game_troop.turn_count = num; end
 
  def choice_cancel_type; return $game_message.choice_cancel_type; end
  def choice_cancel_type=(num); $game_message.choice_cancel_type = num; end
  def choice_max; return $game_message.choice_max; end
  def choice_max=(num); $game_message.choice_max = num; end
  def choice_proc; return $game_message.choice_proc; end
  def choice_proc=(num); $game_message.choice_proc = num; end
  def choice_start; return $game_message.choice_start; end
  def choice_start=(num); $game_message.choice_start = num; end
  def message_proc; return $game_message.main_proc; end
  def message_proc=(num); $game_message.main_proc = num; end
  def message_text; return $game_message.texts.to_s; end
  def message_text=(num); $game_message.texts = num.to_a; end
  def message_window_showing; return $game_message.visible; end
  def message_window_showing=(num); $game_message.visible = num; end
  def num_input_digits_max; return $game_message.num_input_digits_max; end
  def num_input_digits_max=(num); $game_message.num_input_digits_max = num; end
  def num_input_variable_id; return $game_message.num_input_variable_id; end
  def num_input_variable_id=(num); $game_message.num_input_variable_id = num; end
   
  def player_new_direction; return $game_player.new_direction; end
  def player_new_direction=(num); $game_player.new_direction = num; end
  def player_new_map_id; return $game_player.new_map_id; end
  def player_new_map_id=(num); $game_player.new_map_id = num; end
  def player_new_x; return $game_player.new_x; end
  def player_new_x=(num); $game_player.new_x = num; end
  def player_new_y; return $game_player.new_y; end
  def player_new_y=(num); $game_player.new_y = num; end
  def player_transferring; return $game_player.transferring; end
  def player_transferring=(num); $game_player.transferring = num; end
end

class Game_Troop
  attr_accessor :event_flags, :gamebaker_compat_id, :troop_id, :turn_count
 
  alias_method :gamebaker_compatibility_setup, :setup
  def setup(troop_id)
    if @gamebaker_compat_id
      troop_id = @gamebaker_compat_id
      @gamebaker_compat_id = nil
    end
    gamebaker_compatibility_setup(troop_id)
  end
end

class Scene_Battle
  alias_method :gamebaker_compatibility_gameoverjudge, :judge_win_loss
  def judge_win_loss
    if $game_temp.in_battle && $game_party.all_dead?
      $game_temp.gamebaker_compat_gameover2 = true
    else
      $game_temp.gamebaker_compat_gameover2 = nil
    end
    return gamebaker_compatibility_gameoverjudge
  end
 
  # Many of these are -not- the same as the original methods.
  # However, simple aliases -may- make some incompatible scripts work.
 
  def update_phase4_step3; end
  def update_phase4_step4; end
  def update_phase4_step5; end
   
  alias_method :gamebaker_compatibility_dispaction, :display_action_effects
  def display_action_effects(target, action = nil)
    gamebaker_compatibility_dispaction(target, action)
    update_phase4_step5
  end
 
  alias_method :gamebaker_compatibility_displayanim, :display_animation
  def display_animation(targets, animation_id)
    update_phase4_step3
    gamebaker_compatibility_displayanim(targets, animation_id)
    update_phase4_step4
  end   

  if GameBaker::BattleCompatibilityType == 1
   
    def end_actor_select; end_target_actor_selection; end
    def end_enemy_select; end_target_enemy_selection; end
    def end_item_select; end_item_selection; end
    def end_skill_select; end_skill_selection; end
    def judge; return judge_win_loss; end
    def make_item_action_result; execute_action_item; end
    def make_skill_action_result; execute_action_skill; end
    def phase3_next_actor; next_actor; end
    def phase3_prior_actor; prior_actor; end
    def phase3_setup_command_window; start_actor_command_selection; end
    def start_actor_select; start_target_actor_selection; end
    def start_enemy_select; start_target_enemy_selection; end
    def start_item_select; start_item_selection; end
    def start_phase2; start_party_command_selection; end
    def start_phase4; start_main; end
    def start_phase5; process_victory; end
    def start_skill_select; start_skill_selection; end
    def update_phase2; update_party_command_selection; end
    def update_phase2_escape; process_escape; end
    def update_phase3; update_actor_command_selection; end
    def update_phase3_actor_select; update_target_actor_selection; end
    def update_phase3_basic_command; update_actor_command_selection; end
    def update_phase3_enemy_select; update_target_enemy_selection; end
    def update_phase3_item_select; update_item_selection; end
    def update_phase3_skill_select; update_skill_selection; end
    def update_phase4_step1; process_action; end
    def update_phase4_step2; execute_action; end
    def update_phase4_step6; process_action; end
     
  elsif GameBaker::BattleCompatibilityType == 2
     
    def end_actor_select; end
    def end_enemy_select; end
    def end_item_select; end
    def end_skill_select; end
    def make_item_action_result; end
    def make_skill_action_result; end
    def phase3_next_actor; end
    def phase3_prior_actor; end
    def phase3_setup_command_window; end
    def start_actor_select; end
    def start_enemy_select; end
    def start_item_select; end
    def start_phase2; end
    def start_phase4; end
    def start_phase5; end
    def start_skill_select; end
    def update_phase2; end
    def update_phase2_escape; end
    def update_phase3; end
    def update_phase3_actor_select; end
    def update_phase3_basic_command; end
    def update_phase3_enemy_select; end
    def update_phase3_item_select; end
    def update_phase3_skill_select; end
    def update_phase4_step1; end
    def update_phase4_step2; end
    def update_phase4_step6; end
     
    alias_method :gamebaker_compatibility_endactor, :end_target_actor_selection
    def end_target_actor_selection
      gamebaker_compatibility_endactor
      end_actor_select
    end
   
    alias_method :gamebaker_compatibility_endenemy, :end_target_enemy_selection
    def end_target_enemy_selection
      gamebaker_compatibility_endenemy
      end_enemy_select
    end
   
    alias_method :gamebaker_compatibility_enditem, :end_item_selection
    def end_item_selection
      gamebaker_compatibility_enditem
      end_item_select
    end
   
    alias_method :gamebaker_compatibility_endskill, :end_skill_selection
    def end_skill_selection
      gamebaker_compatibility_endskill
      end_skill_select
    end
   
    alias_method :gamebaker_compatibility_judge, :judge_win_loss
    def judge; return gamebaker_compatibility_judge; end
    def judge_win_loss; return judge; end

    alias_method :gamebaker_compatibility_execitem, :execute_action_item
    def execute_action_item
      gamebaker_compatibility_execitem
      make_item_action_result
    end   

    alias_method :gamebaker_compatibility_execskill, :execute_action_skill
    def execute_action_skill
      gamebaker_compatibility_execskill
      make_skill_action_result
    end   

    alias_method :gamebaker_compatibility_nextactor, :next_actor
    def next_actor
      gamebaker_compatibility_nextactor
      phase3_next_actor
    end   

    alias_method :gamebaker_compatibility_prioractor, :prior_actor
    def prior_actor
      gamebaker_compatibility_prioractor
      phase3_prior_actor
    end   

    alias_method :gamebaker_compatibility_startactorc, :start_actor_command_selection
    def start_actor_command_selection
      gamebaker_compatibility_startactorc
      phase3_setup_command_window
    end   

    alias_method :gamebaker_compatibility_startactor, :start_target_actor_selection
    def start_target_actor_selection
      gamebaker_compatibility_startactor
      start_actor_select
    end   

    alias_method :gamebaker_compatibility_startenemy, :start_target_enemy_selection
    def start_target_enemy_selection
      gamebaker_compatibility_startenemy
      start_enemy_select
    end   

    alias_method :gamebaker_compatibility_startitem, :start_item_selection
    def start_item_selection
      gamebaker_compatibility_startitem
      start_item_select
    end

    alias_method :gamebaker_compatibility_startskill, :start_skill_selection
    def start_skill_selection
      gamebaker_compatibility_startskill
      start_skill_select
    end

    alias_method :gamebaker_compatibility_startparty, :start_party_command_selection
    def start_party_command_selection
      gamebaker_compatibility_startparty
      start_phase2
    end

    alias_method :gamebaker_compatibility_startmain, :start_main
    def start_main
      gamebaker_compatibility_startmain
      start_phase4
    end

    alias_method :gamebaker_compatibility_procvictory, :process_victory
    def process_victory
      gamebaker_compatibility_procvictory
      start_phase5
    end

    alias_method :gamebaker_compatibility_partycom, :update_party_command_selection
    def update_party_command_selection
      gamebaker_compatibility_partycom
      update_phase2
    end

    alias_method :gamebaker_compatibility_procescape, :process_escape
    def process_escape
      gamebaker_compatibility_procescape
      update_phase2_escape
    end

    alias_method :gamebaker_compatibility_procaction, :process_action
    def process_action
      update_phase4_step6
      gamebaker_compatibility_procaction
      update_phase4_step1
    end

    alias_method :gamebaker_compatibility_execaction, :execute_action
    def execute_action
      gamebaker_compatibility_execaction
      update_phase4_step2
    end   
   
    alias_method :gamebaker_compatibility_updactor, :update_actor_command_selection
    def update_actor_command_selection
      gamebaker_compatibility_updactor
      update_phase3
      update_phase3_basic_command
    end

    alias_method :gamebaker_compatibility_updtactor, :update_target_actor_selection
    def update_target_actor_selection
      gamebaker_compatibility_updtactor
      update_phase3_actor_select
    end

    alias_method :gamebaker_compatibility_updenemy, :update_target_enemy_selection
    def update_target_enemy_selection
      gamebaker_compatibility_updenemy
      update_phase3_enemy_select
    end

    alias_method :gamebaker_compatibility_upditem, :update_item_selection
    def update_item_selection
      gamebaker_compatibility_upditem
      update_phase3_item_select
    end

    alias_method :gamebaker_compatibility_updskill, :update_skill_selection
    def update_skill_selection
      gamebaker_compatibility_updskill
      update_phase3_skill_select
    end

  elsif GameBaker::BattleCompatibilityType == 3
     
    def end_actor_select; gamebaker_compatibility_endactor; end
    def end_enemy_select; gamebaker_compatibility_endenemy; end
    def end_item_select; gamebaker_compatibility_enditem; end
    def end_skill_select; gamebaker_compatibility_endskill; end
    def make_item_action_result; gamebaker_compatibility_execitem; end
    def make_skill_action_result; gamebaker_compatibility_execskill; end
    def phase3_next_actor; gamebaker_compatibility_nextactor; end
    def phase3_prior_actor; gamebaker_compatibility_prioractor; end
    def phase3_setup_command_window; gamebaker_compatibility_startactorc; end
    def start_actor_select; gamebaker_compatibility_startactor; end
    def start_enemy_select; gamebaker_compatibility_startenemy; end
    def start_item_select; gamebaker_compatibility_startitem; end
    def start_phase2; gamebaker_compatibility_startparty; end
    def start_phase4; gamebaker_compatibility_startmain; end
    def start_phase5; gamebaker_compatibility_procvictory; end
    def start_skill_select; gamebaker_compatibility_startskill; end
    def update_phase2; gamebaker_compatibility_partycom; end
    def update_phase2_escape; gamebaker_compatibility_procescape; end
    def update_phase3; gamebaker_compatibility_updactor; end
    def update_phase3_actor_select; gamebaker_compatibility_updtactor; end
    def update_phase3_basic_command; end
    def update_phase3_enemy_select; gamebaker_compatibility_updenemy; end
    def update_phase3_item_select; gamebaker_compatibility_upditem; end
    def update_phase3_skill_select; gamebaker_compatibility_updskill; end
    def update_phase4_step1; gamebaker_compatibility_procaction; end
    def update_phase4_step2; gamebaker_compatibility_execaction; end
    def update_phase4_step6; end
     
    alias_method :gamebaker_compatibility_endactor, :end_target_actor_selection
    def end_target_actor_selection
      end_actor_select
    end
   
    alias_method :gamebaker_compatibility_endenemy, :end_target_enemy_selection
    def end_target_enemy_selection
      end_enemy_select
    end
   
    alias_method :gamebaker_compatibility_enditem, :end_item_selection
    def end_item_selection
      end_item_select
    end
   
    alias_method :gamebaker_compatibility_endskill, :end_skill_selection
    def end_skill_selection
      end_skill_select
    end
   
    alias_method :gamebaker_compatibility_judge, :judge_win_loss
    def judge; return gamebaker_compatibility_judge; end
    def judge_win_loss; return judge; end

    alias_method :gamebaker_compatibility_execitem, :execute_action_item
    def execute_action_item
      make_item_action_result
    end   

    alias_method :gamebaker_compatibility_execskill, :execute_action_skill
    def execute_action_skill
      make_skill_action_result
    end   

    alias_method :gamebaker_compatibility_nextactor, :next_actor
    def next_actor
      phase3_next_actor
    end   

    alias_method :gamebaker_compatibility_prioractor, :prior_actor
    def prior_actor
      phase3_prior_actor
    end   

    alias_method :gamebaker_compatibility_startactorc, :start_actor_command_selection
    def start_actor_command_selection
      phase3_setup_command_window
    end   

    alias_method :gamebaker_compatibility_startactor, :start_target_actor_selection
    def start_target_actor_selection
      start_actor_select
    end   

    alias_method :gamebaker_compatibility_startenemy, :start_target_enemy_selection
    def start_target_enemy_selection
      start_enemy_select
    end   

    alias_method :gamebaker_compatibility_startitem, :start_item_selection
    def start_item_selection
      start_item_select
    end

    alias_method :gamebaker_compatibility_startskill, :start_skill_selection
    def start_skill_selection
      start_skill_select
    end

    alias_method :gamebaker_compatibility_startparty, :start_party_command_selection
    def start_party_command_selection
      start_phase2
    end

    alias_method :gamebaker_compatibility_startmain, :start_main
    def start_main
      start_phase4
    end

    alias_method :gamebaker_compatibility_procvictory, :process_victory
    def process_victory
      start_phase5
    end

    alias_method :gamebaker_compatibility_partycom, :update_party_command_selection
    def update_party_command_selection
      update_phase2
    end

    alias_method :gamebaker_compatibility_procescape, :process_escape
    def process_escape
      update_phase2_escape
    end

    alias_method :gamebaker_compatibility_procaction, :process_action
    def process_action
      update_phase4_step6
      update_phase4_step1
    end

    alias_method :gamebaker_compatibility_execaction, :execute_action
    def execute_action
      update_phase4_step2
    end   
   
    alias_method :gamebaker_compatibility_updactor, :update_actor_command_selection
    def update_actor_command_selection
      update_phase3
      update_phase3_basic_command
    end

    alias_method :gamebaker_compatibility_updtactor, :update_target_actor_selection
    def update_target_actor_selection
      update_phase3_actor_select
    end

    alias_method :gamebaker_compatibility_updenemy, :update_target_enemy_selection
    def update_target_enemy_selection
      update_phase3_enemy_select
    end

    alias_method :gamebaker_compatibility_upditem, :update_item_selection
    def update_item_selection
      update_phase3_item_select
    end

    alias_method :gamebaker_compatibility_updskill, :update_skill_selection
    def update_skill_selection
      update_phase3_skill_select
    end
  end
end
 
class Scene_Equip
  alias_method :gamebaker_compatibility_init, :initialize
  def initialize
    gamebaker_compatibility_init
    @right_window = @equip_window
  end
end
 
class Scene_Load
  def initialize; $scene = Scene_File.new(false,true,false); end
end

class Scene_Save
  def initialize; $scene = Scene_File.new(true,false,false); end
end
 
class Spriteset_Battle
  attr_reader :viewport1, :viewport2
end

class Window_InputNumber < Window_NumberInput
end

class Window_Selectable
  attr_accessor :column_max, :item_max
end

#==========================================================================
# End of file! You can find more of our scripts at http://www.gamebaker.com
#==========================================================================


:love2:

Bien evidament je remércie l'equipe qui a réaliser ce travaille magnifique est fort utile ! :+2:

*PS:
Je vais rechercher une version plus récente de ce scripte(il est de mars 2008) car comme certain vont le remarquer il n'est pas compatible a 100% avec tout les scripte RPGM XP ! Je sais pérsonne n'est parfait , meme les scripte ! :-p
Je vous tien au courant !
*PS2: Ce scripte a été modifier par mes soin a l'époque, malheureusement je ne sait plus ce que j'y ai fait exactement, c'est pourquoi je vous poste les "version original" :+1:

Voila ++ :))


EDIIT:
Le site d'origine n'existe plus, il va donc être extrêmement difficile de retrouver une version amélioré de ce scripte !
(Si toute fois il y en a une ! )
Je vais chercher des poste ressent des auteur de ce scripte et avec un peut de chance je trouverai surement des scripte fait par eux, et avec énormément de chance une MAJ de celui ci ! :envie: :envie:
Avatar de l’utilisateur
D@nOver
Fréquent
Fréquent
 
Message(s) : 10
Inscription : 09 Juil 2009, 07:27
Localisation : France chez moi, et juste devant t'es yeux sur ton ecran ! =)

Re: Plein de scripts pour Rpg Maker VX

Message par D@nOver » 10 Juil 2009, 09:06

Et un autre scripte qui permet de metre des bar de HUD (MP et PV avec bar de couleur en haut a droitede l'ecran)
Code : Tout sélectionner
#=============================================================================
# Window Hud
#=============================================================================

class Window_Hud < Window_Base
  def initialize
    super(0,0,128,96)
    self.opacity = 0
#    self.visible = false
    refresh
  end
  def refresh
    self.contents.clear
      actor = $game_actors[1]
      draw_actor_hp(actor, 0, 0, 96)
      draw_actor_mp(actor, 0, 32, 96)
   end
   def update
#     self.visible = true if $game_switches[1] == true # 1=interruptor que activa y desactiva el HUD
     refresh
   end
end

class Scene_Map
  alias hud_main main
  alias hud_update update
  alias hud_terminate terminate
  def main
    @hud = Window_Hud.new
    hud_main
  end
  def update
    @hud.update
    hud_update
  end
  def terminate
    @hud.dispose
  end
end

;)
Voila sa peut etre facilment customisable vue "l'extréme longueur de ce scripte! " :mdr:
a vous de voire !
ps: J'ai un scripte que grâce a un evenement (invisible) permet de faire un effet de lumiere! (utile pour les lampe, feu...) Demander moi si vous le voulez ! :close: :close:
Tchuss les mec ! :close:
Avatar de l’utilisateur
D@nOver
Fréquent
Fréquent
 
Message(s) : 10
Inscription : 09 Juil 2009, 07:27
Localisation : France chez moi, et juste devant t'es yeux sur ton ecran ! =)

Re: Plein de scripts pour Rpg Maker VX

Message par Martial » 11 Juil 2009, 01:26

Merci beaucoup pour ces scripts ! Bon, faudra faire un peu de tri, mais c'est déjà ça ! (essaye de poster un nouveau sujet pour chaque script !). Avec le système de script qui devrait arriver bientôt, on va très bien pouvoir ranger tout ça ! :)
L'important n'est pas de connaître mais de savoir trouver !
La gentillesse ou la franchise ? Que choisir ?
Vive les otakus !!
Retourner sur le site
Avatar de l’utilisateur
Martial
Administrateur
Administrateur
 
Message(s) : 2520
Inscription : 10 Nov 2006, 23:41
Localisation : Rambouillet
Meilleurs scores: 12


Retour vers Scripts (RGSS2)

Qui est en ligne ?

Utilisateur(s) parcourant ce forum : Aucun utilisateur inscrit et 1 invité

cron