#======================================================= # * Game_System Add-on v 1.1 # Adaptado a Script Tiempo de Juego Con Día y Noche # por shadowball # 11. - 10.01.2008, Adaptación 08.02.2008 #======================================================= # Podrás definir los minutos, las horas, los días y los meses en ese mismo orden class Game_System def set_time(alter = 0, minuto = 0, hora = 0, dia = 0, mes = 0, year = 0) if minuto >= 0 if minuto >= 60 minuto = 59 end set_min = Graphics.frame_rate * minuto end if hora >= 0 if hora >= 24 hora = 23 end set_hour = Graphics.frame_rate * 60 * hora end if dia >= 0 if dia >= 31 dia = 30 end set_day = Graphics.frame_rate * 60 * 24 * dia end if mes >= 0 if mes > 11 mes = 11 end set_mon = Graphics.frame_rate * 60 * 60 * 24 * 31 * mes end if year >= 0 && year < 2 set_mon = Graphics.frame_rate * 60 * 60 * 24 * 31 * 12 * year end case alter when 0 Graphics.frame_count = 0 + set_mon + set_day + set_hour + set_min when 1 Graphics.frame_count = Graphics.frame_count + set_mon + set_day + set_hour + set_min when 2 Graphics.frame_count = Graphics.frame_count - set_mon - set_day - set_hour - set_min end end end