Maker Palace

¡El Reino del RpgMaker y del Ocio!
 
ÍndiceBuscarGrupos de UsuariosScriptsRecursosTutorialesPalaceJuegosPalaceWikiFAQRegistrarseConectarse
Conectarse
Nombre de Usuario:
Contraseña:
Entrar automáticamente en cada visita: 
:: Recuperar mi contraseña
Temas similares
Buscar
 
 

Resultados por:
 
Rechercher Búsqueda avanzada
Últimos temas
» Reparación de Conjuros
por kyonides-arkanthos Jue Oct 12, 2017 12:22 am

» Screenshot del nuevo KUnits XP oon menú
por LinkLuis55 Sáb Sep 23, 2017 10:03 pm

» Dando una vuelta por acá
por LinkLuis55 Dom Ago 20, 2017 2:56 pm

» Heroes del Crimen 2 DEMO
por jasuso Mar Ago 01, 2017 12:04 am

» The Legend of Celestia II: A World of Twilight Shadows Demo
por Jlopez_96 Vie Jul 28, 2017 6:20 pm

» The Legend of Celestia: Four Cristals
por Jlopez_96 Mar Abr 25, 2017 4:59 pm

» [VXAce] Burando Doragon
por gantzer49 Dom Abr 23, 2017 7:43 pm

Recomendados
RPG en RPG Maker
La importancia de un Backup
Que requiere un sistema de Batalla para ser exitoso
9 Minutos de Juegos por fans
Guía de Subforos para Tontos de Maker Palace
Indice de Scripts Locales XP
Falcao Pearl ABS Liquid
¿Quién está en línea?
En total hay 10 usuarios en línea: 0 Registrados, 0 Ocultos y 10 Invitados :: 2 Motores de búsqueda

Ninguno

La mayor cantidad de usuarios en línea fue 179 el Mar Ago 30, 2011 10:06 pm.
MiniChat
Mejores posteadores
Raiden (3346)
 
DaviX (2740)
 
Frikilangelo (2461)
 
SagahonArturo (1806)
 
Falcao (1775)
 
kyonides-arkanthos (1768)
 
Mur-mai-der (1755)
 
Ares (1613)
 
LinkLuis55 (1558)
 
Webmaster24 (1354)
 
Afiliados
Crear foro Mundo Maker Foro de anime y RM2k3/XP/VX Computer mix
Flag Counter
free counters
Visitas


Comparte | 
 

 Anti-lag para Xas hero(cualquiera)

Ver el tema anterior Ver el tema siguiente Ir abajo 
AutorMensaje
kmilo123
Amateur
Amateur


Cantidad de envíos : 15
Miembro desde : 03/12/2010

MensajeTema: Anti-lag para Xas hero(cualquiera)   Lun Dic 20, 2010 1:07 am

iva navengando por la web y me encontre ste antilag para el xas hero creo que es compatible con clquier version y lo mejor si sirve xd yo lo probe ^^



creditos: en el script


Citación :
#===============================================================================
# ** AntiLag script
#-------------------------------------------------------------------------------
#
# f0tz!baerchen
# 0.71
# 06.01.2007
#-------------------------------------------------------------------------------
# Edited by Mr_Wiggles - Removed SDK and moved settings to the top.
#-------------------------------------------------------------------------------
#
# Credits:
# Chaosg1 (for testing Wink )
# NearFantastica (for the Event AntiLag I used and improved)
#
#-------------------------------------------------------------------------------
#
# Features:
# - Event AntiLag: Event (and their Sprites) which are not on the screen are
# not updated except they run on "Autostart" or "Parallel Process" or they
# have an empty comment in the first line
# - High Priority: Game can be run on high priority
# - Smooth Antilag: the Event AntiLag does only work fine if the events are
# distributed over the whole map, but when there are many events at the same
# place it lags again. If the script notices that the CPU utilization
# gets higher than $antilag.max_cpu_utilization it will slow down the game and
# reduce the framerate as long as needed.
#
#===============================================================================
# Settings:
#===============================================================================
module Anti_Lag
#-------------------------------------------------------------------------------
MAX_CPU_UTIL = 99 # the maximum CPU utilization, the script
# DEFAULT = 70 # try to stay under this value during changing
# changing the frame rate. The lower this
# value the higher the lag reduction will be
# (and the smoothness, too), a value > 100
# will disable this feature completely.
#-------------------------------------------------------------------------------
CPU_TOLERANCE = 20 # this value tells the script how many % of
# DEFAULT = 20 # the CPU utilization change should be ignored
# If you change it too a higher value you,
# your Frame Rate will be more constant but
# smaller lags will be ignored.
#-------------------------------------------------------------------------------
HIGH_PRIORITY = true # set this to true if you want the game to run
# DEFAULT = true # on high priority
#-------------------------------------------------------------------------------
EVENT = true # set this to true to enable anti-lag
# DEFAULT = true
#-------------------------------------------------------------------------------
end
#===============================================================================
# Class for Antilag Settings
#===============================================================================
class Antilag_Settings

attr_accessor :event
attr_accessor :max_cpu_utilization
attr_accessor :cpu_tolerance

#-----------------------------------------------------------------------------
# initializes default settings
#-----------------------------------------------------------------------------
def initialize
@event = true
@high_priority = true
@max_cpu_utilization = 100
@cpu_tolerance = 20
@SetPriorityClass = Win32API.new('kernel32', 'SetPriorityClass',
['p', 'i'], 'i')
@GetProcessTimes = Win32API.new('kernel32', 'GetProcessTimes',
['i','p','p','p','p'], 'i')
end

#-----------------------------------------------------------------------------
# turns high priority on/off
#-----------------------------------------------------------------------------
def high_priority=(value)
@high_priority = value

if @high_priority
@SetPriorityClass.call(-1, 0x00000080) # High Priority
else
@SetPriorityClass.call(-1, 0x00000020) # Normal Priority
end
end

#-----------------------------------------------------------------------------
# returns the current CPU Utilization
#-----------------------------------------------------------------------------
def get_cpu_utilization

# uses API Call to get the Kernel and User Time
creation_time = '0' * 10
exit_time = '0' * 10
kernel_time = '0' * 10
user_time = '0' * 10
@GetProcessTimes.call(-1, creation_time, exit_time, kernel_time, user_time)

# converts times into integer (in 100ns)
kernel_time = kernel_time.unpack('l2')
user_time = user_time.unpack('l2')
kernel_time = kernel_time[0] + kernel_time[1]
user_time = user_time[0] + user_time[1]

# takes differences to calculate cpu utilization
if @old_time != nil
timer_difference = Time.new - @old_timer
time_difference = kernel_time + user_time - @old_time
result = time_difference / timer_difference / 100000
else
result = $antilag.max_cpu_utilization
end

# saves values (to calculate the differences, s.a.)
@old_timer = Time.new
@old_time = kernel_time + user_time

return result

end

end

$antilag = Antilag_Settings.new

#===============================================================================
# Scene_Map class
#===============================================================================
class Scene_Map

#-----------------------------------------------------------------------------
# update method, smooth antilag has been added
#-----------------------------------------------------------------------------
alias f0tzis_anti_lag_scene_map_update update
def update

f0tzis_anti_lag_scene_map_update

if Graphics.frame_count % 20 == 0 and $antilag.max_cpu_utilization <= 100

# calculates difference between max utilization and current utilization
abs = $antilag.max_cpu_utilization - $antilag.get_cpu_utilization

# changes Frame Rate if difference is bigger than the tolerance
if abs.abs >= $antilag.max_cpu_utilization * $antilag.cpu_tolerance/100.0
Graphics.frame_rate = [[10, Graphics.frame_rate + abs / 2].max, 40].min
end

end

end

end


#===============================================================================
# Game_Event Class
#===============================================================================
class Game_Event

#-----------------------------------------------------------------------------
# for AntiLag, decides, if an event is on the screen or not.
#-----------------------------------------------------------------------------
def in_range?

# returns true if $event_antilag is false or the event is an
# Autostart/Parallel Process event or it has an empty
# comment in the first line
if not $antilag.event or (@trigger == 3 or @trigger == 4 or
(@list != nil and @list[0].code == 108 and @list[0].parameters == ['']))
return true
end

screne_x = $game_map.display_x
screne_x -= 256
screne_y = $game_map.display_y
screne_y -= 256
screne_width = $game_map.display_x
screne_width += 2816
screne_height = $game_map.display_y
screne_height += 2176

return false if @real_x <= screne_x
return false if @real_x >= screne_width
return false if @real_y <= screne_y
return false if @real_y >= screne_height
return true

end

#-----------------------------------------------------------------------------
# update method
#-----------------------------------------------------------------------------
alias f0tzis_anti_lag_game_event_update update
def update
return if not self.in_range?
f0tzis_anti_lag_game_event_update
end

end


#===============================================================================
# Sprite_Character Class
#===============================================================================
class Sprite_Character < RPG::Sprite

#-----------------------------------------------------------------------------
# update method, parameters added for Loop_Map, rebuild for 8dirs
#-----------------------------------------------------------------------------
alias f0tzis_anti_lag_sprite_char_update update
def update
return if @character.is_a?(Game_Event) and not @character.in_range?
f0tzis_anti_lag_sprite_char_update
end

end

#===============================================================================
# Settings - OLD
#===============================================================================

$antilag.max_cpu_utilization = Anti_Lag::MAX_CPU_UTIL
$antilag.cpu_tolerance = Anti_Lag::CPU_TOLERANCE
$antilag.high_priority = Anti_Lag::HIGH_PRIORITY
$antilag.event = Anti_Lag::EVENT

#===============================================================================
# Interpreter Class
#===============================================================================
class Interpreter

#-----------------------------------------------------------------------------
# * script
#-----------------------------------------------------------------------------
def command_355
# Set first line to script
script = @list[@index].parameters[0] + "\n"
# Loop
loop do
# If next event command is second line of script or after
if @list[@index+1].code == 655
# Add second line or after to script
script += @list[@index+1].parameters[0] + "\n"
# If event command is not second line or after
else
# Abort loop
break
end
# Advance index
@index += 1
end
# Evaluation
result = eval(script)
#---------------------------------------------------------------------------
# If return value is false
# NEW: the last word of the code mustnt be false!
#---------------------------------------------------------------------------
if result == false and script[script.length-6..script.length-2] != 'false'
# End
return false
end
# Continue
return true
end
end
[/code]
Volver arriba Ir abajo
Ver perfil de usuario
Raiden
Admin
Admin
avatar

Cantidad de envíos : 3346
Miembro desde : 01/03/2010
Edad : 24
Sexo : Masculino

Maker : RMXP

Logros MP :


MensajeTema: Re: Anti-lag para Xas hero(cualquiera)   Lun Dic 20, 2010 12:11 pm

Este es un buen aporte, gracias por el.
Volver arriba Ir abajo
Ver perfil de usuario
DaviX
Admin.
Admin.
avatar

Cantidad de envíos : 2740
Miembro desde : 08/07/2009
Edad : 23
Localización : España
Sexo : Masculino

Maker : RMXP

Logros MP :


MensajeTema: Re: Anti-lag para Xas hero(cualquiera)   Lun Dic 20, 2010 12:42 pm

Este Script creo que ya esta xD
Sinembargo el titulo me gusto y para aprovechar para decir una cosa, no lo cierro..

La cosa:
ESTE script practicamente es el Anti-Lag REAL. Yo mismo lo e testeado, y funciona, incluso ademas de quitar puede dar lag xD
Todo depende de la RAM y el PC que tengas y la configuracion que tengas al script:
Código:
module Anti_Lag
#-------------------------------------------------------------------------------
MAX_CPU_UTIL = 99 # the maximum CPU utilization, the script
# DEFAULT = 70 # try to stay under this value during changing
# changing the frame rate. The lower this
# value the higher the lag reduction will be
# (and the smoothness, too), a value > 100
# will disable this feature completely.
#-------------------------------------------------------------------------------
CPU_TOLERANCE = 20 # this value tells the script how many % of
# DEFAULT = 20 # the CPU utilization change should be ignored
# If you change it too a higher value you,
# your Frame Rate will be more constant but
# smaller lags will be ignored.
#-------------------------------------------------------------------------------
HIGH_PRIORITY = true # set this to true if you want the game to run
# DEFAULT = true # on high priority
#-------------------------------------------------------------------------------
EVENT = true # set this to true to enable anti-lag
# DEFAULT = true

Sin saber mucho ingles se puede saber que, cambiando los numeritos puedes quitar o dar lag.

de los mejores script inventados!

_________________
Soy puta y me gusta que me den por culo.
Hahhahaa

by:Ares
xDDDD
Volver arriba Ir abajo
Ver perfil de usuario
lordsebaxtian
Escudero Experimentado
Escudero Experimentado


Cantidad de envíos : 56
Miembro desde : 30/11/2010
Edad : 24
Sexo : Masculino

Maker : RMXP


MensajeTema: Re: Anti-lag para Xas hero(cualquiera)   Lun Dic 20, 2010 8:57 pm

si yo también lo estoy usando ^^ es bueno y creo q es el mismo script xD
Volver arriba Ir abajo
Ver perfil de usuario
Contenido patrocinado




MensajeTema: Re: Anti-lag para Xas hero(cualquiera)   

Volver arriba Ir abajo
 
Anti-lag para Xas hero(cualquiera)
Ver el tema anterior Ver el tema siguiente Volver arriba 
Página 1 de 1.
 Temas similares
-
» 3 Anti-lag para tu proyecto
» [Prologo] En un bar cualquiera
» Ayuda.para pasar datos del editor con el USB a otro ordenador
» Roberto Lopez resive ofertas para regresar a españa ...
» ¿Necesario update 1 para update2?

Permisos de este foro:No puedes responder a temas en este foro.
Maker Palace :: RGSS Scripts :: Scripts Maker XP-
Cambiar a: