¡Bienvenido a Universo Maker!
¿Es esta la primera vez que visitas el foro? Si es así te recomendamos que te registres para tener completo acceso a todas las áreas y secciones del foro, así también podrás participar activamente en la comunidad. Si ya tienes una cuenta, conéctate cuanto antes.
Iniciar Sesión Registrarme

No estás conectado. Conéctate o registrate

Universo Maker » Búsqueda avanzada

Se encontraron 6 resultados para --------------------------------------------------------------------------

Necesito a alguien que sepa de scripts - Dom Ene 10, 2016 4:06 pm

Hola buenas quisiera que alguien me explicara como hacer funcionar este script como esta en ingles me cuesta un poco se les agradece la ayuda Opalo Hola



#==============================================================================
# ** Victor Engine - State Graphics
#------------------------------------------------------------------------------
# Author : Victor Sant
#
# Version History:
# v 1.00 - 2012.12.13 > First relase
# v 1.01 - 2012.12.15 > Fixed issue with Defend skill
#------------------------------------------------------------------------------
# This script allows to setup states that changes the battler graphic when
# the battle is under certain states. You can use that to create transformation
# states, such as the 'Toad' state from the Final Fantasy series.
#------------------------------------------------------------------------------
# Compatibility
# Requires the script 'Victor Engine - Basic Module' v 1.30 or higher
# If used with 'Victor Engine - Animated Battle' place this bellow it.
# If used with 'Victor Engine - Actors Battlers' place this bellow it.
#
# * Overwrite methods
# class Game_Actor < Game_Battler
# def battler_name
# def character_name
# def character_index
#
# class Game_Enemy < Game_Battler
# def battler_name
# def character_name
#
# * Alias methods
# class Game_BattlerBase
# def erase_state(state_id)
#
# class Game_Battler < Game_BattlerBase
# def add_new_state(state_id)
#
# class Game_Enemy < Game_Battler
# def character_index
#
#------------------------------------------------------------------------------
# Instructions:
# To instal the scr&#105;pt, open you scr&#105;pt editor and paste this scr&#105;pt on
# a new section bellow the Materials section. This scr&#105;pt must also
# be bellow the scr&#105;pt 'Victor Engine - Basic'
#
#------------------------------------------------------------------------------
# States note tags:
# Tags to be used on the States note box in the database
#
#
#
# Adding this tag on the state will make the battle, charset and face graphic
# to be directly replaced by the one set with this tag
# x : character filename
# y : character index (for 8 charset files)
#
#
# Adding this tag on the state will make the battle, charset and face graphic
# to be replaced by one with the same filename + the extension
# x : character filename extension
#
#------------------------------------------------------------------------------
# Additional instructions:
#
# The / tag uses
# always the same graphic no matter who is the state target.
# This will also change the face index to the same index as the charset
#
# The allows to setup different graphics based
# on the target. The graphic must have the same filename + the extension.
# The charset index will not be changed using this tag.
# Ex.: A battler with a graphic named 'Actor1' when inflicted with a state with
# the tag will need a filename
# named 'Actor1[toad].
# This sufix must be the first one when used together with the Animated Battle
# sufixes.
# This doesn't change the index for faces and charsets, so the new file must
# have a matching graphic for that index.
#
# If the battler state graphic don't exist the graphic will not be changed.
#
#==============================================================================

#==============================================================================
# ** Victor Engine
#------------------------------------------------------------------------------
# Setting module for the Victor Engine
#==============================================================================

module Victor_Engine
#--------------------------------------------------------------------------
# * Change Map Graphic
# When true, the on map charset will be changed when under states that
# change the graphic. If false, only in battle graphics will be changed.
# Note: if using the Animated Battle with charset template, this option
# must be set true, since the battlers are actually map charsets.
#--------------------------------------------------------------------------
Change_Map_Graphic = true
#--------------------------------------------------------------------------
# * required
# This method checks for the existance of the basic module and other
# VE scripts required for this scr&#105;pt to work, don't edit this
#--------------------------------------------------------------------------
def self.required(name, req, version, type = nil)
if !&#36;imported[:ve_basic_module]
msg = "The scr&#105;pt '%s' requires the scr&#105;pt\n"
msg += "'VE - Basic Module' v%s or higher above it to work properly\n"
msg += "Go to http://victorenginescripts.wordpress.com/ to download this scr&#105;pt."
msgbox(sprintf(msg, self.scr&#105;pt_name(name), version))
exit
else
self.required_scr&#105;pt(name, req, version, type)
end
end
#--------------------------------------------------------------------------
# * scr&#105;pt_name
# Get the scr&#105;pt name base on the imported value
#--------------------------------------------------------------------------
def self.scr&#105;pt_name(name, ext = "VE")
name = name.to_s.gsub("_", " ").upcase.split
name.collect! {|char| char == ext ? "#{char} -" : char.capitalize }
name.join(" ")
end
end

&#36;imported ||= {}
&#36;imported[:ve_state_graphics] = 1.00
Victor_Engine.required(:ve_state_graphics, :ve_basic_module, 1.30, :above)

#==============================================================================
# ** RPG::State
#------------------------------------------------------------------------------
# This is the data class for states
#==============================================================================

class RPG::State < RPG::BaseItem
#--------------------------------------------------------------------------
# * New method: graphic_replace
#--------------------------------------------------------------------------
def graphic_replace
regexp = /<,]*)(?:, *(\d+))?>/i
note =~ regexp ? [&#36;1.to_s, &#36;2 ? &#36;2.to_i - 1 : 0] : nil
end
#--------------------------------------------------------------------------
# * New method: graphic_extension
#--------------------------------------------------------------------------
def graphic_extension
note =~ /<]*)>/i ? &#36;1.to_s : nil
end
#--------------------------------------------------------------------------
# * New method: state_graphic?
#--------------------------------------------------------------------------
def state_graphic?
graphic_replace || graphic_extension
end
end

#==============================================================================
# ** Game_BattlerBase
#------------------------------------------------------------------------------
# This class handles battlers. It's used as a superclass of the Game_Battler
# classes.
#==============================================================================

class Game_BattlerBase
#--------------------------------------------------------------------------
# * Alias method: erase_state
#--------------------------------------------------------------------------
alias :erase_state_ve_state_graphic :erase_state
def erase_state(state_id)
erase_state_ve_state_graphic(state_id)
&#36;game_player.refresh if &#36;data_states[state_id].state_graphic? && actor?
end
#--------------------------------------------------------------------------
# * New method: check_state_extension
#--------------------------------------------------------------------------
def check_state_extension
list = states.sort {|a,b| b.priority <=> a.priority }
list.each {|st| return st.graphic_extension if st.graphic_extension }
return nil
end
#--------------------------------------------------------------------------
# * New method: check_state_replace
#--------------------------------------------------------------------------
def check_state_replace
list = states.sort {|a,b| b.priority <=> a.priority }
list.each {|st| return st.graphic_replace if st.graphic_replace }
return nil
end
end

#==============================================================================
# ** Game_Battler
#------------------------------------------------------------------------------
# This class deals with battlers. It's used as a superclass of the Game_Actor
# and Game_Enemy classes.
#==============================================================================

class Game_Battler < Game_BattlerBase
#--------------------------------------------------------------------------
# * Alias method: add_new_state
#--------------------------------------------------------------------------
alias :add_new_state_ve_state_graphic :add_new_state
def add_new_state(state_id)
add_new_state_ve_state_graphic(state_id)
&#36;game_player.refresh if &#36;data_states[state_id].state_graphic? && actor?
end
end

#==============================================================================
# ** Game_Actor
#------------------------------------------------------------------------------
# This class handles actors. It's used within the Game_Actors class
# (&#36;game_actors) and referenced by the Game_Party class (&#36;game_party).
#==============================================================================

class Game_Actor < Game_Battler
#--------------------------------------------------------------------------
# * Overwrite method: battler_name
#--------------------------------------------------------------------------
def battler_name
@battler_name = actor_battler_name
extension = check_state_extension
replace = check_state_replace
name = @battler_name + extension if extension
name = replace.first if replace
@battler_name = name if name && battler_exist?(name)
@battler_name
end
#--------------------------------------------------------------------------
# * Overwrite method: face_name
#--------------------------------------------------------------------------
def face_name
face_name = @face_name
extension = check_state_extension
replace = check_state_replace
name = face_name + extension if extension
name = replace.first if replace
face_name = name if name && character_exist?(name)
face_name
end
#--------------------------------------------------------------------------
# * Overwrite method: character_name
#--------------------------------------------------------------------------
def character_name
character_name = @character_name
extension = check_state_extension
replace = check_state_replace
name = character_name + extension if extension
name = replace.first if replace
character_name = name if name && character_exist?(name)
character_name
end
#--------------------------------------------------------------------------
# * Overwrite method: character_index
#--------------------------------------------------------------------------
def character_index
character_index = @character_index
replace = check_state_replace
index = replace.last if replace
character_index = index if index
character_index
end
#--------------------------------------------------------------------------
# * Overwrite method: face_index
#--------------------------------------------------------------------------
def face_index
face_index = @face_index
replace = check_state_replace
index = replace.last if replace
face_index = index if index
face_index
end
end

#==============================================================================
# ** Game_Enemy
#------------------------------------------------------------------------------
# This class handles enemy characters. It's used within the Game_Troop class
# (&#36;game_troop).
#==============================================================================

class Game_Enemy < Game_Battler
#--------------------------------------------------------------------------
# * Overwrite method: battler_name
#--------------------------------------------------------------------------
def battler_name
@battler_name = enemy.battler_name
extension = check_state_extension
replace = check_state_replace
name = @battler_name + extension if extension
name = replace.first if replace
@battler_name = name if name && battler_exist?(name)
@battler_name
end
#--------------------------------------------------------------------------
# * Overwrite method: character_name
#--------------------------------------------------------------------------
def character_name
@character_name = battler_name
extension = check_state_extension
replace = check_state_replace
name = @character_name + extension if extension
name = replace.first if replace
@character_name = name if name && character_exist?(name)
@character_name
end
#--------------------------------------------------------------------------
# * Alias method: character_index
#--------------------------------------------------------------------------
alias :character_index_ve_state_graphic :character_index if &#36;imported[:ve_animated_battle]
def character_index
@character_index = character_index_ve_state_graphic
replace = check_state_replace
name = replace.last if replace
@character_index = index if index
@character_index
end
end
Buscar en: Ayuda  Argumento: Necesito a alguien que sepa de scripts   Respuestas: 6  Vistos: 856

Ayuda con un script - Jue Dic 10, 2015 8:14 pm

El scr&#105;pt en cuestin:
#===============================================================================
# +++ MOG - Chain Commands (v1.4) +++
#===============================================================================
# By Moghunter
# https://atelierrgss.wordpress.com/
#===============================================================================
# Sistema de sequência de botões para ativar switchs.
#
# Serão necessárias as seguintes imagens. (Graphics/System)
#
# Chain_Cursor.png
# Chain_Command.png
# Chain_Layout.png
# Chain_Timer_Layout.png
# Chain_Timer_Meter.png
#
#===============================================================================
#
# Para ativar o script use o comando abaixo. (*Call Script)
#
# chain_commands(ID)
#
# ID - Id da switch.
#
#===============================================================================

#==============================================================================
# ● Histórico (Version History)
#==============================================================================
# v 1.4 - Correção do crash aleatório.
# v 1.3 - Melhoria no sistema de dispose
# v 1.2 - Melhoria na codificação e correção de alguns glitches.
# v 1.1 - Animação de fade ao sair da cena de chain.
# - Opção de definir a prioridade da hud na tela.
#==============================================================================

module MOG_CHAIN_COMMANDS
#==============================================================================
# CHAIN_COMMAND = { SWITCH_ID => [COMMAND] }
#
# SWITCH_ID = ID da switch
# COMMANDS = Defina aqui a sequência de botões.
# (Para fazer a sequência use os comandos abaixo)
#
# "Down" ,"Up" ,"Left" ,"Right" ,"Shift" ,"D" ,"S" ,"A" ,"Z" ,"X" ,"Q" ,"W"
#
# Exemplo de utilização
#
# CHAIN_SWITCH_COMMAND = {
# 25=>["Down","D","S","Right"],
# 59=>["Down","Up","Left","Right","Shift","D","S","A","Z","X","Q","W"],
# 80=>["Shift","D"]
# }
#==============================================================================
CHAIN_SWITCH_COMMAND = {
5=>["X","Right","Left","Z","Z"],
6=>["Left","Right","Left","Right","Left","Right","Q","Z","Up","A","S",
"Down","D","Z","Right","Up","Up","Z","W","Left","Down","D","A","W"],
8=>["Up","Down","Left","Right","Z"]
}
#Durao para colocar os comandos. (A durao multiplicado pela quantidade
#de comandos) *60 = 1 sec
CHAIN_INPUT_DURATION = 30
#Som ao acertar.
CHAIN_RIGHT_SE = "Chime1"
#Som ao errar.
CHAIN_WRONG_SE = "Buzzer1"
#Switch que ativa o modo automtico.
CHAIN_AUTOMATIC_MODE_SWITCH_ID = 20
#Definio da prioridade da hud na tela
CHAIN_HUD_Z = 300
end


#===============================================================================
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Chain Commands
#===============================================================================
class Chain_Commands
include MOG_CHAIN_COMMANDS
#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Initialize
#--------------------------------------------------------------------------
def initialize
@action_id = &#36;game_temp.chain_switch_id
@chain_command = CHAIN_SWITCH_COMMAND[@action_id]
@chain_command = ["?"] if @chain_command == nil
duration = [[CHAIN_INPUT_DURATION, 1].max, 9999].min
@timer_max = duration * @chain_command.size
@timer = @timer_max
@slide_time = [[60 / duration, 10].max, 60].min
@change_time = 0
if &#36;game_switches[CHAIN_AUTOMATIC_MODE_SWITCH_ID]
@auto = true
else
@auto = false
end
@com = 0
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Main
#--------------------------------------------------------------------------
def main
dispose
@background_sprite = Sprite.new
@background_sprite.bitmap = SceneManager.background_bitmap2
create_chain_command
create_cusrsor
create_layout
create_meter
create_text
create_number
Graphics.transition
loop do
Graphics.update
Input.update
update
break if SceneManager.scene != self
end
dispose
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Create Cursor
#--------------------------------------------------------------------------
def create_cusrsor
@fy_time = 0
@fy = 0
@com_index = 0
@cursor = Sprite.new
@cursor.bitmap = Cache.system("Chain_Cursor")
@cursor.z = 4 + CHAIN_HUD_Z
@cursor_space = ((@bitmap_cw + 5) * @chain_command.size) / 2
if @chain_command.size <= 20
@cursor.x = (544 / 2) - @cursor_space + @cursor_space * @com_index
else
@cursor.x = (544 / 2)
end
@cursor.y = (416 / 2) + 30
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Create Chain Command
#--------------------------------------------------------------------------
def create_chain_command
@image = Cache.system("Chain_Command")
width_max = ((@image.width / 13) + 5) * @chain_command.size
@bitmap = Bitmap.new(width_max,@image.height * 2)
@bitmap_cw = @image.width / 13
@bitmap_ch = @image.height
index = 0
for i in @chain_command
command_list_check(i)
bitmap_src_rect = Rect.new(@com * @bitmap_cw, 0, @bitmap_cw, @bitmap_ch)
if index == 0
@bitmap.blt(index * (@bitmap_cw + 5) , 0, @image, bitmap_src_rect)
else
@bitmap.blt(index * (@bitmap_cw + 5) , @bitmap_ch, @image, bitmap_src_rect)
end
index += 1
end
@sprite = Sprite.new
@sprite.bitmap = @bitmap
if @chain_command.size <= 15
@sprite.x = (544 / 2) - ((@bitmap_cw + 5) * @chain_command.size) / 2
@new_x = 0
else
@sprite.x = (544 / 2)
@new_x = @sprite.x
end
@sprite.y = (416 / 2) + 30 - @bitmap_ch - 15
@sprite.z = 3 + CHAIN_HUD_Z
@sprite.zoom_x = 1.5
@sprite.zoom_y = 1.5
end

#--------------------------------------------------------------------------
# * create_layout
#--------------------------------------------------------------------------
def create_layout
@back = Plane.new
@back.bitmap = Cache.system("Chain_Layout")
@back.z = 0
@layout = Sprite.new
@layout.bitmap = Cache.system("Chain_Timer_Layout")
@layout.z = 1 + CHAIN_HUD_Z
@layout.x = 160
@layout.y = 150
end

#--------------------------------------------------------------------------
# * create_meter
#--------------------------------------------------------------------------
def create_meter
@meter_flow = 0
@meter_image = Cache.system("Chain_Timer_Meter")
@meter_bitmap = Bitmap.new(@meter_image.width,@meter_image.height)
@meter_range = @meter_image.width / 3
@meter_width = @meter_range * @timer / @timer_max
@meter_height = @meter_image.height
@meter_src_rect = Rect.new(@meter_range, 0, @meter_width, @meter_height)
@meter_bitmap.blt(0,0, @meter_image, @meter_src_rect)
@meter_sprite = Sprite.new
@meter_sprite.bitmap = @meter_bitmap
@meter_sprite.z = 2 + CHAIN_HUD_Z
@meter_sprite.x = 220
@meter_sprite.y = 159
update_flow
end

#--------------------------------------------------------------------------
# ● Create Text
#--------------------------------------------------------------------------
def create_text
@text = Sprite.new
@text.bitmap = Bitmap.new(200,32)
@text.z = 2 + CHAIN_HUD_Z
@text.bitmap.font.name = "Georgia"
@text.bitmap.font.size = 25
@text.bitmap.font.bold = true
@text.bitmap.font.italic = true
@text.bitmap.font.color.set(255, 255, 255,220)
@text.x = 230
@text.y = 100
end

#--------------------------------------------------------------------------
# ● Create Number
#--------------------------------------------------------------------------
def create_number
@combo = 0
@number = Sprite.new
@number.bitmap = Bitmap.new(200,64)
@number.z = 2 + CHAIN_HUD_Z
@number.bitmap.font.name = "Arial"
@number.bitmap.font.size = 24
@number.bitmap.font.bold = true
@number.bitmap.font.color.set(0, 255, 255,200)
@number.bitmap.draw_text(0, 0, 200, 32, "Ready",1)
@number.x = 30
@number.y = 100
end

#--------------------------------------------------------------------------
# ● Pre Dispose
#--------------------------------------------------------------------------
def exit
loop do
Graphics.update
@sprite.x += 5
@layout.x -= 5
@meter_sprite.x -= 5
@text.x -= 2
@text.opacity -= 5
@sprite.opacity -= 5
@layout.opacity -= 5
@meter_sprite.opacity -= 5
@number.opacity -= 5
@back.opacity -= 5
@cursor.visible = false
break if @sprite.opacity == 0
end
SceneManager.call(Scene_Map)
end

#--------------------------------------------------------------------------
# ● Dispose
#--------------------------------------------------------------------------
def dispose
return if @layout == nil
Graphics.freeze
@background_sprite.bitmap.dispose
@background_sprite.dispose
@bitmap.dispose
@sprite.bitmap.dispose
@sprite.dispose
@cursor.bitmap.dispose
@cursor.dispose
@meter_image.dispose
@meter_bitmap.dispose
@meter_sprite.bitmap.dispose
@meter_sprite.dispose
@layout.bitmap.dispose
@layout.dispose
@layout = nil
@back.bitmap.dispose
@back.dispose
@text.bitmap.dispose
@text.dispose
@number.bitmap.dispose
@number.dispose
@image.dispose
end

#--------------------------------------------------------------------------
# ● Update
#--------------------------------------------------------------------------
def update
update_command
update_cursor_slide
update_flow
update_change_time
end

#--------------------------------------------------------------------------
# ● Change_Time
#--------------------------------------------------------------------------
def update_change_time
return unless @auto
@change_time += 1
check_command(-1) if @change_time >= CHAIN_INPUT_DURATION - 1
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Update Flow
#--------------------------------------------------------------------------
def update_flow
@timer -= 1
@meter_sprite.bitmap.clear
@meter_width = @meter_range * @timer / @timer_max
@meter_src_rect = Rect.new(@meter_flow, 0, @meter_width, @meter_height)
@meter_bitmap.blt(0,0, @meter_image, @meter_src_rect)
@meter_flow += 20
@meter_flow = 0 if @meter_flow >= @meter_image.width - @meter_range
wrong_command if @timer == 0 and @auto == false
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Update Command
#--------------------------------------------------------------------------
def update_command
return if @auto
if Input.trigger?(Input::X)
check_command(0)
elsif Input.trigger?(Input::Z)
check_command(1)
elsif Input.trigger?(Input::Y)
check_command(2)
elsif Input.trigger?(Input::A)
check_command(3)
elsif Input.trigger?(Input::C)
check_command(4)
elsif Input.trigger?(Input::B)
check_command(5)
elsif Input.trigger?(Input::L)
check_command(6)
elsif Input.trigger?(Input::R)
check_command(7)
elsif Input.trigger?(Input::RIGHT)
check_command(Cool
elsif Input.trigger?(Input::LEFT)
check_command(9)
elsif Input.trigger?(Input::DOWN)
check_command(10)
elsif Input.trigger?(Input::UP)
check_command(11)
end
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> command_list_check
#--------------------------------------------------------------------------
def command_list_check(command)
case command
when "A"
@com = 0
when "D"
@com = 1
when "S"
@com = 2
when "Shift"
@com = 3
when "Z"
@com = 4
when "X"
@com = 5
when "Q"
@com = 6
when "W"
@com = 7
when "Right"
@com = 8
when "Left"
@com = 9
when "Down"
@com = 10
when "Up"
@com = 11
else
@com = 12
end
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> check_command
#--------------------------------------------------------------------------
def check_command(com)
index = 0
if com != -1
right_input = false
for i in @chain_command
if index == @com_index
command_list_check(i)
right_input = true if @com == com
end
index += 1
end
else
command_list_check(@com_index)
@change_time = 0
right_input = true
end
if right_input
refresh_number
next_command
else
wrong_command
end
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Next Command
#--------------------------------------------------------------------------
def next_command
@com_index += 1
Audio.se_play("Audio/SE/" + CHAIN_RIGHT_SE, 100, 100)
if @com_index == @chain_command.size
&#36;game_switches[@action_id] = true
exit
&#36;game_map.need_refresh = true
end
refresh_command
refresh_text(0)
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> wrong_command
#--------------------------------------------------------------------------
def wrong_command
Audio.se_play("Audio/SE/" + CHAIN_WRONG_SE, 100, 100)
refresh_text(1)
exit
&#36;game_player.jump(0,0)
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Refresh Command
#--------------------------------------------------------------------------
def refresh_command
@sprite.bitmap.clear
index = 0
for i in @chain_command
command_list_check(i)
bitmap_src_rect = Rect.new(@com * @bitmap_cw, 0, @bitmap_cw, @bitmap_ch)
if @com_index == index
@bitmap.blt(index * (@bitmap_cw + 5) , 0, @image, bitmap_src_rect)
else
@bitmap.blt(index * (@bitmap_cw + 5) , @bitmap_ch, @image, bitmap_src_rect)
end
index += 1
end
if @chain_command.size > 15
@new_x = (544 / 2) - ((@bitmap_cw + 5) * @com_index)
else
@cursor.x = (544 / 2) - @cursor_space + ((@bitmap_cw + 5) * @com_index)
end
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Refresh Text
#--------------------------------------------------------------------------
def refresh_text(type)
@text.bitmap.clear
if type == 0
if @com_index == @chain_command.size
@text.bitmap.font.color.set(55, 255, 55,220)
@text.bitmap.draw_text(0, 0, 200, 32, "Perfect!",1)
else
@text.bitmap.font.color.set(55, 155, 255,220)
@text.bitmap.draw_text(0, 0, 200, 32, "Success!",1)
end
else
@text.bitmap.font.color.set(255, 155, 55,220)
if @timer == 0
@text.bitmap.draw_text(0, 0, 200, 32, "Time Limit!",1)
else
@text.bitmap.draw_text(0, 0, 200, 32, "Fail!",1)
end
end
@text.x = 230
@text.opacity = 255
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Refresh Number
#--------------------------------------------------------------------------
def refresh_number
@combo += 1
@number.bitmap.clear
@number.bitmap.font.size = 34
@number.bitmap.draw_text(0, 0, 200, 32, @combo.to_s,1)
@number.opacity = 255
@number.zoom_x = 2
@number.zoom_y = 2
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Update Cursor Slide
#--------------------------------------------------------------------------
def update_cursor_slide
@sprite.zoom_x -= 0.1 if @sprite.zoom_x > 1
@sprite.zoom_y -= 0.1 if @sprite.zoom_y > 1
@text.x -= 2 if @text.x > 210
@text.opacity -= 5 if @text.opacity > 0
@sprite.x -= @slide_time if @sprite.x > @new_x and @chain_command.size > 15
if @number.zoom_x > 1
@number.zoom_x -= 0.1
@number.zoom_y -= 0.1
end
if @fy_time > 15
@fy += 1
elsif @fy_time > 0
@fy -= 1
else
@fy = 0
@fy_time = 30
end
@fy_time -= 1
@cursor.oy = @fy
end
end

#==============================================================================
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Game Temp
#==============================================================================
class Game_Temp

attr_accessor :chain_switch_id

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Initialize
#--------------------------------------------------------------------------
alias mog_chain_commands_initialize initialize
def initialize
@chain_switch_id = 0
mog_chain_commands_initialize
end

end

#==============================================================================
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Game_Interpreter
#==============================================================================
class Game_Interpreter

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Chain Commands
#--------------------------------------------------------------------------
def chain_commands(switch_id = 0)
return if switch_id <= 0
&#36;game_temp.chain_switch_id = switch_id
SceneManager.call(Chain_Commands)
wait(1)
end

end

#===============================================================================
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> SceneManager
#===============================================================================
class << SceneManager
@background_bitmap2 = nil

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Snapshot For Background2
#--------------------------------------------------------------------------
def snapshot_for_background2
@background_bitmap2.dispose if @background_bitmap2
@background_bitmap2 = Graphics.snap_to_bitmap
end

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Background Bitmap2
#--------------------------------------------------------------------------
def background_bitmap2
@background_bitmap2
end

end

#===============================================================================
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Scene Map
#===============================================================================
class Scene_Map < Scene_Base

#--------------------------------------------------------------------------
# .1621448769014E+21;pan style="color:#aa0000" class="coloradmin"> Terminate
#--------------------------------------------------------------------------
alias mog_chain_commands_terminate terminate
def terminate
SceneManager.snapshot_for_background2
mog_chain_commands_terminate
end

end

&#36;mog_rgss3_chain_commands = true


Tag -------------------------------------------------------------------------- en Universo Maker CAQNRUJ
Buscar en: Ayuda  Argumento: Ayuda con un script  Respuestas: 15  Vistos: 2687

[RMXP] efecto de respiracion - Vie Oct 02, 2015 7:30 pm

Hola mis amigos de Universo Maker esta vez les traigo este scr&#105;pt que simula un pequeo movimiento en tu personaje, como si estubiera respirando

Scr&#105;pt:

#==============================================================================
# ** DRG - Breath Effect
# Version : 1.00
# Author : LiTTleDRAgo
#==============================================================================
#==============================================================================
# ** Sprite_Character
#------------------------------------------------------------------------------
# This sprite is used to display the character.It observes the Game_Character
# class and automatically changes sprite conditions.
#==============================================================================
class Sprite_Character
#--------------------------------------------------------------------------
# * Alias Method
#--------------------------------------------------------------------------
alias_method :drg1732013_update, :update
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
drg1732013_update
update_breath
end
#--------------------------------------------------------------------------
# * Update Breath
#--------------------------------------------------------------------------
def update_breath
if sprite_controlable?(@character)
@zoom_wait,b = [(@zoom_wait||0)-1,0].max, 1.05
if self.zoom_y < b && !@up && @zoom_wait == 0
       self.zoom_y += 0.005
       @up, @zoom_wait = true, 20 if self.zoom_y >= b
     elsif self.zoom_y >= 1.0 && @up && @zoom_wait == 0
self.zoom_y -= 0.005
@up, @zoom_wait = false,60 if self.zoom_y <= 1.0
end
else
self.zoom_y = @character.instance_variable_get(:@zoom_y) || 1
end
end
#--------------------------------------------------------------------------
# * sprite_controlable?
#--------------------------------------------------------------------------
def sprite_controlable?(character)
return false if &#36;game_system.map_interpreter.running?
return false if character.move_route_forcing
return false if &#36;game_temp.message_window_showing
return false if character.moving?
return false if character.transparent
return false if !character.is_a?(Game_Player)
return true
end
end


Instrucciones:

Pegar encima de main.

Creditos:

dadle creditos a LiTTleDRAgo, el creador del scr&#105;pt Opalo Hola

Acerca del scr&#105;pt:

El scr&#105;pt permite que el personaje principal tenga un pequeo movimiento, como si estuviera respirando, asi tu personaje no estara tan estatico y tendra un pelin ms de realismo Ópalo Contento

Bueno, esto es todo Opalo Triste pero pronto volvere a publicar muchas cosas ms, !!!nos vemos en el siguiente post!!! Opalo Hola Opalo Hola Opalo Hola

(Scr&#105;pt 100% funcional, probado por mi, algn inconveniente con el scr&#105;pt, me avisan)
Buscar en: Scripts  Argumento: [RMXP] efecto de respiracion  Respuestas: 0  Vistos: 786

Ayuda con script - Lun Jul 27, 2015 5:06 am

quise publicar todo en un solo mensaje pero me decia que estaba muy largo, he aca el scr&#105;pt
Scr&#105;pt:

#==============================================================================
# ** Melly-Mel's Calendar System
#------------------------------------------------------------------------------
# by DerVVulfman
# version 1.7
# 06-01-2012
# RGSS / RPGMaker XP
#==============================================================================
#
# INTRODUCTION:
#
# Based on designs by Kylock and features employed by Near Fantastica in his
# original system, this Day Night system gives the user mastery over the time
# system in his project.
#
# By manipulating the scr&#105;pt's configuration section, one can control how fast
# time runs in the game, the actual increments used, and even how many months
# there are in a year. The creator has full control over the game's calendar.
#
# Not only that, you can program weather patterns based on months or dates of
# your choice. Of course, using a [SET WEATHER EFFECTS] event works as normal.
#
#------------------------------------------------------------------------------
#
# INSTRUCTIONS:
#
# The configurables are fairly self explanatory, and each heading and value has
# enough instructions alone to assist the user of this scr&#105;pt.
#
# ^_^ Probably more instructions than most Day/Night scripts anyway.
#
#
#------------------------------------------------------------------------------
#
# SCR&#73;PT CALLS:
# The following calls are used to retrieve calendar information that is
# used by this system. All data, even the numeric values, are passed as
# strings. If used for numeric calculations, conversion to integers is
# advised.
#
# * &#36;game_time.get_weekday_number Returns a numeric value of the weekday
# * &#36;game_time.get_weekday_name Returns the actual text of the weekday
# * &#36;game_time.get_day_of_year Returns the day of the year (ex: 1-365)
# * &#36;game_time.get_month_name Returns the name of the current month
# * &#36;game_time.get_month_number Returns the month as a number (ex:1-12)
# * &#36;game_time.get_day_of_month Returns the day for that month (ex 1-31)
# * &#36;game_time.get_light_setting_name Returns text describing the day (Dawn)
# * &#36;game_time.get_light_setting_number Returns a numeric value for the time of day
# * &#36;game_time.get_year Returns the current year
# * &#36;game_time.get_total_days Returns the total number of days
#
# . . . . . . . . . . . . . . . . . . .
#
# The following values are used to retrieve clock/time information that is
# used by this system.
# * &#36;game_time.clock_seconds Returns the current seconds(ex 1-60)
# * &#36;game_time.clock_minutes Returns the current minutes(ex 1-60)
# * &#36;game_time.clock_hours