Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

2 Pages V   1 2 >  
Reply to this topicStart new topic
> ~[Day/Night System]~, Not made by me, just translated.
Rory
post Jan 31 2008, 11:38 PM
Post #1


GFX Pro
Group Icon

Group: +Gold Member
Posts: 409
Type: Artist
RM Skill: Skilled




Day/Night System
It took me an hour to translate this massive code, all the comments and code are 100% English, if I didn't miss anything. This script contains a Day, Month and Week System.

Author: KGC
Translator: Magdreamer
Original Source:
http://f44.aaa.livedoor.jp/~ytomy/tkool/rp...p;tech=daynight

Screenshot


#_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
#_/ ◆ Day/Night System - KGC_DayNight ◆ VX ◆
#_/ ◆ Author: KGC ◆
#_/ ◆ Translator: Magdreamer ◆
#_/ ◇ Last update : 2008/01/30 ◇
#_/----------------------------------------------------------------------------
#_/ A Day & Night System which is based on in-game time
#_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/

#==============================================================================
# ★ Customize ★
#==============================================================================

module KGC
module DayNight
# ◆ Day and night change System
# ◆ Time lapse 1. Step several 2. Actual time (sensitivity)
METHOD = 1

# ◆ In the variable which is appointed number
# ◆ here of the variable which retains the phase, present phase is housed.
PHASE_VARIABLE = 11
# ◆ Number of the variable which retains the days
# ◆ In the variable which is appointed here, the days when it elapses are housed.
PASS_DAYS_VARIABLE = 12

# ◆ In the event phase is not modified
STOP_ON_EVENT = true
# ◆When fighting, only the background applies the color tone
# ◆ false which applies the color tone, it means that the night is outrageous.
TONE_BACK_ONLY_IN_BATTLE = true

# ◆ Setting of each phase
# [" Name " The color tone (Tone), switching time],
# It draws up with the prescribed form,
# It is possible also to increase phase, but while being accustomed, the male be completed it does not do.
# [name] The name of phase.There is no meaning in the name itself.
# [color tone] picture color.
# Please do not modify unless you know what you are doing.
# The [until switching time] it moves to the following phase, time.
# When change system time elapses, when second, it is the number of steps, the number of steps that way.
# In case you are using "actual time", the time which is changed to the following state (24 hour systems).

PHASE = [
["Noon", Tone.new( 0, 0, 0), 300], # Phase 0
["Evening", Tone.new( -32, -96, -96), 100], # Phase 1
["Night", Tone.new(-128, -128, -32), 250], # Phase 2
["Morning", Tone.new( -48, -48, -16), 100], # Phase 3
] # Do not turn this off!

# When using of actual time,
# ["Noon", Tone.new( 0, 0, 0), 16], # Phase 0 (at 16 o'clock evening)
# ["Evening", Tone.new( 0, -96, -96), 20], # Phase 1 (at 20 o'clock night)
# ["Night", Tone.new(-96, -96, -64), 6], # Phase 2 (at 6 o'clock morning)
# ["Morning", Tone.new(-48, -48, -16), 10], # Phase 3 (at 10 o'clock noon)

# ◆When becoming the phase which is appointed phase
# here where the date change, days are added.
# In case of # initial condition 0. Noon 1. Evening 2. Night 3.
# In case of the morning actual time, because it is not same days as actuality, note.
PASS_DAY_PHASE = 3

# ◆ Fading time at the time of the status switching (the frame)
# the default value is used
PHASE_DURATION = 60

# ◆ Fading time at the time of the status switching (the frame) the default # this value is used.
# There is no meaning in the number of days in the week itself.
# When the actual time are used, please make 7.
WEEK_NAME = ["Day", "Month", "Fire", "Water", "Wood", "Metal", "Earth"]
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

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

if $data_mapinfos == nil
$data_mapinfos = load_data("Data/MapInfos.rvdata")
end

module KGC::DayNight
METHOD_TIME = 0 # Time lapse
METHOD_STEP = 1 # Step several
METHOD_RTIME = 2 # Actual times

# Regular expression
module Regexp
# Map information
module MapInfo
# You stop transition
DAYNIGHT_STOP = /\[DN_STOP\]/i
# Day and night effect invalidity
DAYNIGHT_VOID = /\[DN_VOID\]/i
end

# Enemy group
module Troop
# Appearance phase
APPEAR_PHASE = /\[DN((?:[ ]*[\-]?\d+(?:[ ]*,)?)+)\]/i
end
end

#--------------------------------------------------------------------------
# ○ 敵グループ出現判定
# troop : 判定対象の敵グループ
# phase : 判定するフェーズ
#--------------------------------------------------------------------------
def self.troop_appear?(troop, phase = $game_system.daynight_phase)
# 出現判定
unless troop.appear_daynight_phase.empty?
return false unless troop.appear_daynight_phase.include?(phase)
end
# 非出現判定
unless troop.nonappear_daynight_phase.empty?
return false if troop.nonappear_daynight_phase.include?(phase)
end

return true
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# □ KGC::Commands
#==============================================================================

module KGC::Commands
module_function
#--------------------------------------------------------------------------
# ○ Stopping day and night change
#--------------------------------------------------------------------------
def stop_daynight
$game_system.daynight_change_enabled = false
end
#--------------------------------------------------------------------------
# ○ Day and night change starting
#--------------------------------------------------------------------------
def start_daynight
$game_system.daynight_change_enabled = true
end
#--------------------------------------------------------------------------
# ○ present phase name acquisition
#--------------------------------------------------------------------------
def get_daynight_name
return KGC::DayNight::PHASE[get_daynight_phase][0]
end
#--------------------------------------------------------------------------
# ○ present day of the week acquisition
# variable_id: The variable ID which it substitutes
#--------------------------------------------------------------------------
def get_daynight_week(variable_id = 0)
if KGC::DayNight::METHOD == KGC::DayNight::METHOD_RTIME
week = Time.now.wday
else
days = $game_variables[KGC::DayNight::PASS_DAYS_VARIABLE]
week = (days % KGC::DayNight::WEEK_NAME.size)
end

if variable_id > 0
$game_variables[variable_id] = week
end
return week
end
#--------------------------------------------------------------------------
# ○ Acquiring present day of the week name
#--------------------------------------------------------------------------
def get_daynight_week_name
return KGC::DayNight::WEEK_NAME[get_daynight_week]
end
#--------------------------------------------------------------------------
# ○ Phase change
# phase : Phase after the changing
# duration : Switching time (frame)
# pass_days : The days when it elapses (the default: 0)
#--------------------------------------------------------------------------
def change_daynight_phase(phase,
duration = KGC::DayNight::PHASE_DURATION,
pass_days = 0)
$game_temp.manual_daynight_duration = duration
$game_system.daynight_counter = 0
$game_system.daynight_phase = phase
$game_variables[KGC::DayNight::PASS_DAYS_VARIABLE] += pass_days
end
#--------------------------------------------------------------------------
# ○ To the following phase transition
# duration : Switching time (frame)
#--------------------------------------------------------------------------
def transit_daynight_phase(duration = KGC::DayNight::PHASE_DURATION)
$game_screen.transit_daynight_phase(duration)
end
#--------------------------------------------------------------------------
# ○ Reset to the color tone of default
# duration : Switching time (frame)
#--------------------------------------------------------------------------
def set_daynight_default(duration = KGC::DayNight::PHASE_DURATION)
$game_screen.set_daynight_default(duration)
end
#--------------------------------------------------------------------------
# ○ Reconstructing present phase
# duration : Switching time (frame)
#--------------------------------------------------------------------------
def restore_daynight_phase(duration = KGC::DayNight::PHASE_DURATION)
$game_screen.restore_daynight_phase(duration)
end
end

class Game_Interpreter
include KGC::Commands
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ RPG::MapInfo
#==============================================================================

class RPG::MapInfo
#--------------------------------------------------------------------------
# ● Map name acquisition
#--------------------------------------------------------------------------
def name
return @name.gsub(/\[.*\]/) { "" }
end
#--------------------------------------------------------------------------
# ○ Original map name acquisition
#--------------------------------------------------------------------------
def original_name
return @name
end
#--------------------------------------------------------------------------
# ○ Day and night change stop
#--------------------------------------------------------------------------
def daynight_stop
return @name =~ KGC::DayNight::Regexp::MapInfo::DAYNIGHT_STOP
end
#--------------------------------------------------------------------------
# ○ Day and night effect invalidity
#--------------------------------------------------------------------------
def daynight_void
return @name =~ KGC::DayNight::Regexp::MapInfo::DAYNIGHT_VOID
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ RPG::Area
#==============================================================================

unless $@
class RPG::Area
#--------------------------------------------------------------------------
# ○ Acquisition of [enkauntorisuto]
#--------------------------------------------------------------------------
alias encounter_list_KGC_DayNight encounter_list
def encounter_list
list = encounter_list_KGC_DayNight.clone

# 出現条件判定
list.each_index { |i|
list[i] = nil unless KGC::DayNight.troop_appear?($data_troops[list[i]])
}
return list.compact
end
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ RPG::Troop
#==============================================================================

class RPG::Troop
#--------------------------------------------------------------------------
# ○ Cash formation of day and night change
#--------------------------------------------------------------------------
def create_daynight_cache
@__appear_daynight_phase = []
@__nonappear_daynight_phase = []

# 出現するフェーズ
if @name =~ KGC::DayNight::Regexp::Troop::APPEAR_PHASE
$1.scan(/[\-]?\d+/).each { |num|
phase = num.to_i
if phase < 0
# 出現しない
@__nonappear_daynight_phase << phase.abs
else
# 出現する
@__appear_daynight_phase << phase
end
}
end
end
#--------------------------------------------------------------------------
# ○ The phase which appears
#--------------------------------------------------------------------------
def appear_daynight_phase
create_daynight_cache if @__appear_daynight_phase == nil
return @__appear_daynight_phase
end
#--------------------------------------------------------------------------
# ○ The phase which does not appear
#--------------------------------------------------------------------------
def nonappear_daynight_phase
create_daynight_cache if @__nonappear_daynight_phase == nil
return @__nonappear_daynight_phase
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ Game_Temp
#==============================================================================

class Game_Temp
#--------------------------------------------------------------------------
# ● Open instance variable
#--------------------------------------------------------------------------
attr_accessor :manual_daynight_duration # Manual phase modification flag
#--------------------------------------------------------------------------
# ● Object initialization
#--------------------------------------------------------------------------
alias initialize_KGC_DayNight initialize
def initialize
initialize_KGC_DayNight

@manual_daynight_duration = nil
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ Game_System
#==============================================================================

class Game_System
#--------------------------------------------------------------------------
# ● Open instance variable
#--------------------------------------------------------------------------
attr_writer :daynight_counter # Phase transition counter
attr_writer :daynight_change_enabled # Day and night change validity
#--------------------------------------------------------------------------
# ● Object initialization
#--------------------------------------------------------------------------
alias initialize_KGC_DayNight initialize
def initialize
initialize_KGC_DayNight

@daynight_counter = 0
@daynight_change_enabled = true
end
#--------------------------------------------------------------------------
# ○ Acquiring the phase transition counter
#--------------------------------------------------------------------------
def daynight_counter
@daynight_counter = 0 if @daynight_counter == nil
return @daynight_counter
end
#--------------------------------------------------------------------------
# ○ Acquiring present phase
#--------------------------------------------------------------------------
def daynight_phase
return $game_variables[KGC::DayNight::PHASE_VARIABLE]
end
#--------------------------------------------------------------------------
# ○ Modifying present phase
#--------------------------------------------------------------------------
def daynight_phase=(value)
$game_variables[KGC::DayNight::PHASE_VARIABLE] = value
end
#--------------------------------------------------------------------------
# ○ Acquiring the day and night change effective flag
#--------------------------------------------------------------------------
def daynight_change_enabled
@daynight_change_enabled = 0 if @daynight_change_enabled == nil
return @daynight_change_enabled
end
#--------------------------------------------------------------------------
# ○ Phase advance
#--------------------------------------------------------------------------
def progress_daynight_phase
@daynight_phase += 1
if @daynight_phase >= KGC::DayNight::PHASE.size
@daynight_phase = 0
end
end
#--------------------------------------------------------------------------
# ○ Acquiring present phase object
#--------------------------------------------------------------------------
def daynight_phase_object
return KGC::DayNight::PHASE[daynight_phase]
end
#--------------------------------------------------------------------------
# ○ Acquiring the phase object of the time previously
#--------------------------------------------------------------------------
def previous_daynight_phase_object
return KGC::DayNight::PHASE[daynight_phase - 1]
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ Game_Screen
#==============================================================================

class Game_Screen
#--------------------------------------------------------------------------
# ● Open instance variable
#--------------------------------------------------------------------------
attr_reader :daynight_tone # Color tone of day and night
#--------------------------------------------------------------------------
# ● Clearing
#--------------------------------------------------------------------------
alias clear_KGC_DayNight clear
def clear
clear_KGC_DayNight

clear_daynight
end
#--------------------------------------------------------------------------
# ○ Clearing the variable for day and night change
#--------------------------------------------------------------------------
def clear_daynight
@default_tone = Tone.new(0, 0, 0)

# Coordinate initialization for movement decision
@daynight_x = 0
@daynight_y = 0

# Count initialization for frame renewal
@frame_count = Graphics.frame_count
@daynight_tone_duration = 0

apply_daynight
end
#--------------------------------------------------------------------------
# ○ Applying the color tone of day and night
#--------------------------------------------------------------------------
def apply_daynight
return if $game_map == nil

# In case of the map which nullifies change
if $game_map.daynight_void?
if @daynight_tone_changed
# You reset to the early color tone
@tone = @default_tone.clone
@daynight_tone = @tone.clone
@daynight_tone_changed = false
end
return
end

# Applying the present color tone
@tone = $game_system.daynight_phase_object[1].clone
@daynight_tone = @tone.clone

# In case of actual time transition
if KGC::DayNight::METHOD == KGC::DayNight::METHOD_RTIME
time = Time.now
# Transition to the phase which matches
KGC::DayNight::PHASE.each_with_index { |phase, i|
if phase[2] <= time.hour
start_tone_change(phase[1], 1)
$game_system.daynight_phase = i
break
end
}
end

@daynight_tone_changed = true
end
#--------------------------------------------------------------------------
# ○ Acquisition of color tone
#--------------------------------------------------------------------------
def tone
if $game_temp.in_battle && KGC::DayNight::TONE_BACK_ONLY_IN_BATTLE
return @default_tone
else
return @tone
end
end
#--------------------------------------------------------------------------
# ● Start of color tone modification
# tone : Color tone
# duration : Time
#--------------------------------------------------------------------------
alias start_tone_change_KGC_DayNight start_tone_change
def start_tone_change(tone, duration)
duration = [duration, 1].max
start_tone_change_KGC_DayNight(tone, duration)

@daynight_tone_target = tone.clone
@daynight_tone_duration = duration
end
#--------------------------------------------------------------------------
# ● Frame renewal
#--------------------------------------------------------------------------
alias update_KGC_DayNight update
def update
update_KGC_DayNight

update_daynight_transit
end
#--------------------------------------------------------------------------
# ● Renewal of color tone
#--------------------------------------------------------------------------
alias update_tone_KGC_DayNight update_tone
def update_tone
update_tone_KGC_DayNight

if @daynight_tone_duration >= 1
d = @daynight_tone_duration
target = @daynight_tone_target
@daynight_tone.red = (@daynight_tone.red * (d - 1) + target.red) / d
@daynight_tone.green = (@daynight_tone.green * (d - 1) + target.green) / d
@daynight_tone.blue = (@daynight_tone.blue * (d - 1) + target.blue) / d
@daynight_tone.gray = (@daynight_tone.gray * (d - 1) + target.gray) / d
@daynight_tone_duration -= 1
end
end
#--------------------------------------------------------------------------
# ○ Renewal of phase transition
#--------------------------------------------------------------------------
def update_daynight_transit
# When manual change is done,
if $game_temp.manual_daynight_duration
start_tone_change($game_system.daynight_phase_object[1],
$game_temp.manual_daynight_duration)
$game_temp.manual_daynight_duration = nil
@daynight_tone_changed = true
end

return unless $game_system.daynight_change_enabled # Change
return if $game_map.daynight_stop? # In the midst of stop

if KGC::DayNight::STOP_ON_EVENT
interpreter = ($game_temp.in_battle ? $game_troop.interpreter :
$game_map.interpreter)
return if interpreter.running? # In the midst of event execution
end

case KGC::DayNight::METHOD
when KGC::DayNight::METHOD_TIME # Time
update_daynight_pass_time
when KGC::DayNight::METHOD_STEP # The number of steps
update_daynight_step
when KGC::DayNight::METHOD_RTIME # Actual time
update_daynight_real_time
end
end
#--------------------------------------------------------------------------
# ○ Transition: Time lapse
#--------------------------------------------------------------------------
def update_daynight_pass_time
# Count growth calculation
inc_count = Graphics.frame_count - @frame_count
# When the addition quantity is strange, it returns
if inc_count >= 100
@frame_count = Graphics.frame_count
return
end
# Count addition
$game_system.daynight_counter += inc_count
@frame_count = Graphics.frame_count

# State transition decision
count = $game_system.daynight_counter / Graphics.frame_rate
if count >= $game_system.daynight_phase_object[2]
transit_daynight_next
end
end
#--------------------------------------------------------------------------
# ○ Transition: The number of steps
#--------------------------------------------------------------------------
def update_daynight_step
# If it is not moving, it returns
return if @daynight_x == $game_player.x && @daynight_y == $game_player.y

@daynight_x = $game_player.x
@daynight_y = $game_player.y
# Count addition
$game_system.daynight_counter += 1
# State transition decision
count = $game_system.daynight_counter
if count >= $game_system.daynight_phase_object[2]
transit_daynight_next
end
end
#--------------------------------------------------------------------------
# ○ Transition: Actual time
#--------------------------------------------------------------------------
def update_daynight_real_time
time = Time.now
# State transition decision
time1 = $game_system.daynight_phase_object[2]
transit = (time1 <= time.hour)
if $game_system.previous_daynight_phase_object != nil
time2 = $game_system.previous_daynight_phase_object[2]
if time1 < time2
transit &= (time.hour < time2)
end
end

if transit
transit_daynight_next
end
end
#--------------------------------------------------------------------------
# ○ It transits to the following state
# duration : Transition duration
#--------------------------------------------------------------------------
def transit_daynight_next(duration = KGC::DayNight::PHASE_DURATION)
$game_system.daynight_counter = 0
$game_system.progress_daynight_phase
# Days lapse decision
if $game_system.daynight_phase == KGC::DayNight::PASS_DAY_PHASE
$game_variables[KGC::DayNight::PASS_DAYS_VARIABLE] += 1
end
# Color tone change
start_tone_change($game_system.daynight_phase_object[1], duration)
@daynight_tone_changed = true
end
#--------------------------------------------------------------------------
# ○ State of default (0, 0 and 0) it resets
# duration : Transition duration
#--------------------------------------------------------------------------
def set_daynight_default(duration)
start_tone_change(@default_tone, duration)
end
#--------------------------------------------------------------------------
# ○ Reconstructing present phase
# duration : Transition duration
#--------------------------------------------------------------------------
def restore_daynight_phase(duration)
start_tone_change($game_system.daynight_phase_object[1], duration)
@daynight_tone_changed = true
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ Game_Map
#==============================================================================

class Game_Map
#--------------------------------------------------------------------------
# ● Setup
# map_id : Map ID
#--------------------------------------------------------------------------
alias setup_KGC_DayNight setup
def setup(map_id)
setup_KGC_DayNight(map_id)

@screen.apply_daynight
end
#--------------------------------------------------------------------------
# ○ Check if the day and night change stopped
#--------------------------------------------------------------------------
def daynight_stop?
info = $data_mapinfos[map_id]
return false if info == nil
return (info.daynight_stop || info.daynight_void)
end
#--------------------------------------------------------------------------
# ○ Check the validity of the Day and night change
#--------------------------------------------------------------------------
def daynight_void?
info = $data_mapinfos[map_id]
return false if info == nil
return info.daynight_void
end
#--------------------------------------------------------------------------
# ● Acquisition of [enkauntorisuto]
#--------------------------------------------------------------------------
alias encounter_list_KGC_DayNight encounter_list
def encounter_list
list = encounter_list_KGC_DayNight.clone

# Appearance conditional decision
list.each_index { |i|
list[i] = nil unless KGC::DayNight.troop_appear?($data_troops[list[i]])
}
return list.compact
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ Spriteset_Battle
#==============================================================================

if KGC::DayNight::TONE_BACK_ONLY_IN_BATTLE
class Spriteset_Battle
#--------------------------------------------------------------------------
# ● Renewal of battle floor
#--------------------------------------------------------------------------
alias update_battlefloor_KGC_DayNight update_battlefloor
def update_battlefloor
update_battlefloor_KGC_DayNight

@battlefloor_sprite.tone = $game_troop.screen.daynight_tone
end
end
end

#★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★

#==============================================================================
# ■ Scene_Map
#==============================================================================

class Scene_Map < Scene_Base
#--------------------------------------------------------------------------
# ● Start processing
#--------------------------------------------------------------------------
alias start_KGC_DayNight start
def start
$game_map.screen.clear_daynight

start_KGC_DayNight
end
end


[Show/Hide] Instructions Manual
Disabling Day/Night Change (Freezing Time)
When [DN_STOP] is inserted in map name, with that map day and night change stops.
You use, with the map where such as in town we would not like to modify phase.

Disabling Map Color Tone (Removing Noon, Night, Dusk Effects in indoor maps)
When [DN_VOID] is inserted in map name, with that map also modification of the color tone with present phase in addition to the stop of day and night change, becomes invalid.
You use at the bright place without, distinction of day and night such as in the building.



Setting of enemy group

In enemy group name [DN…]When it adds, appearance condition of the enemy can be set.
… The phase which appears that group is input with comma pause.
When - you insert before the numerical value, the phase which is appointed is excluded from appearance condition.

- When “the night” only it appears -
Monster *2 [DN 2]
- “noon morning” when it does not appear -
skeleton *2 [DN -0, - 3]

The group with nothing written appears with all phases.

Setting of phase

PHASE = [
["Noon", Tone.new( 0, 0, 0), 300], # Phase 0
["Evening", Tone.new( -32, -96, -96), 100], # Phase 1
["Night", Tone.new(-128, -128, -32), 250], # Phase 2
["Morning", Tone.new( -48, -48, -16), 100], # Phase 3
] # Do not turn this off!


Setting of each phase is modified.
As for phase,


Thats as much I will translate, if you want more instructions translate the japanese page with babelfish or something.

This post has been edited by Magdreamer: Jan 31 2008, 11:42 PM


__________________________

THE SAVAGE NYMPH
Note: this is Magdreamer, I'm using my real name for my forum name now.
Go to the top of the page
 
+Quote Post
   
ERZENGEL
post Feb 1 2008, 06:34 AM
Post #2


Level 8
Group Icon

Group: Revolutionary
Posts: 127
Type: None
RM Skill: Undisclosed




Good work, Magdreamer!
I wanted to start my translation today but now its in english and easier for me to post it in german. Its a very good work of KGC too.
Go to the top of the page
 
+Quote Post
   
Koru-chan
post Feb 1 2008, 10:10 AM
Post #3


Level 7
Group Icon

Group: Revolutionary
Posts: 102
Type: Event Designer
RM Skill: Advanced




Babelfish is terrible, people use it all the time to make funny Engrish sayings, that's how bad the grammer is. No offense, but any English that isn't code that you put into this sounds like it just came straight from Babelfish onto the post. I can barely understand any of it.

EDIT: After playing with Babelfish a moment, it seems that's exactly what you did, but Babelfish's grammer stinks, you need to take a bit more of your own work to make it understandable.

This post has been edited by Koru-chan: Feb 1 2008, 10:13 AM


__________________________



PM me if you want your own graph, please do NOT take and alter for your own.
Go to the top of the page
 
+Quote Post
   
Rory
post Feb 1 2008, 10:12 AM
Post #4


GFX Pro
Group Icon

Group: +Gold Member
Posts: 409
Type: Artist
RM Skill: Skilled




Thats only the post, I didn't bother with it. But the code is fine.


__________________________

THE SAVAGE NYMPH
Note: this is Magdreamer, I'm using my real name for my forum name now.
Go to the top of the page
 
+Quote Post
   
Koru-chan
post Feb 1 2008, 10:53 AM
Post #5


Level 7
Group Icon

Group: Revolutionary
Posts: 102
Type: Event Designer
RM Skill: Advanced




Yes, but I'm not a scripter. I don't understand things just from scripting and some parts of it are confusing me.

- When “the night” only it appears -
Monster *2 [DN 2]
- “noon morning” when it does not appear -
skeleton *2 [DN -0, - 3]

So what you're saying is that if I want a monster to appear only at night, I put [DN 2]. If I don't want a monster to appear in noon or morning, use [DN -0] or [DN -3]. Isn't that the same as night? Further, is it [DN -0, -3] for noon and morning collectively, or is it [DN 0] for noon and [DN -3] for morning?

At any rate, I've gone to the main japanese site and am translating it for myself, so it's fine.

This post has been edited by Koru-chan: Feb 1 2008, 10:54 AM


__________________________



PM me if you want your own graph, please do NOT take and alter for your own.
Go to the top of the page
 
+Quote Post
   
Rory
post Feb 1 2008, 09:06 PM
Post #6


GFX Pro
Group Icon

Group: +Gold Member
Posts: 409
Type: Artist
RM Skill: Skilled




Yeah, you got it =)


__________________________

THE SAVAGE NYMPH
Note: this is Magdreamer, I'm using my real name for my forum name now.
Go to the top of the page
 
+Quote Post
   
Koru-chan
post Feb 1 2008, 10:49 PM
Post #7


Level 7
Group Icon

Group: Revolutionary
Posts: 102
Type: Event Designer
RM Skill: Advanced




Um, except I asked two different things and you're saying I got it. :/

At any rate, I went through and translated the entire webpage myself and now have a much more thorough understanding of that script. Took several hours, but was worth it.


__________________________



PM me if you want your own graph, please do NOT take and alter for your own.
Go to the top of the page
 
+Quote Post
   
Twilight27
post Apr 6 2008, 09:50 AM
Post #8


Level 19
Group Icon

Group: Revolutionary
Posts: 371
Type: Event Designer
RM Skill: Beginner




I am deeply sorry for bumping this topic, but how do you make night time and day time only events?
This will also include being unable to enter houses and the cities being almost vacant.


__________________________

Fall to the power of the Emo!
We have cookies!


Notice!! Check out my topic (http://www.rpgrevolution.com/forums/index.php?showtopic=45736&st=0#entry454175) if you're interested in helping me make a script that limits the number of characters & items you use in battle AND also an item durability feature! Thanks for any help in advance!
Go to the top of the page
 
+Quote Post
   
WaywardPheasant
post Apr 7 2008, 09:26 AM
Post #9


Level 1
Group Icon

Group: Member
Posts: 7
Type: None
RM Skill: Undisclosed




Koru, I haven't studied Japanese in a year in a half, except for the linguistics (the marvels of anthropology), and I was wondering if you could post a better Instruction Manual than the current. This is a very appealing script, but I doubt I can handle the Japanese myself, and you mentioned having taken the time to decipher the site. Anyway, just a request; it would be greatly appreciated, but I also understand that time is hard to come by.
Go to the top of the page
 
+Quote Post
   
Twilight27
post Apr 7 2008, 12:46 PM
Post #10


Level 19
Group Icon

Group: Revolutionary
Posts: 371
Type: Event Designer
RM Skill: Beginner




QUOTE (Twilight27 @ Apr 6 2008, 01:04 PM) *
I am deeply sorry for bumping this topic, but how do you make night time and day time only events?
This will also include being unable to enter houses and the cities being almost vacant.


Or which variable is for what? (I think it's variables I have to use... confused.gif )


__________________________

Fall to the power of the Emo!
We have cookies!


Notice!! Check out my topic (http://www.rpgrevolution.com/forums/index.php?showtopic=45736&st=0#entry454175) if you're interested in helping me make a script that limits the number of characters & items you use in battle AND also an item durability feature! Thanks for any help in advance!
Go to the top of the page
 
+Quote Post
   
matty0828
post Apr 17 2008, 12:14 AM
Post #11


Level 4
Group Icon

Group: Member
Posts: 54
Type: None
RM Skill: Beginner




Yeah I'm kinda having the same problem as Twilight... I don't get how to make things happen at certain times!
I also don't really get how to alter the length of each period - as in, how to make dawn/daytime/dusk/night etc. last longer. I feel it's a little too short.

Oh and Koru-chan... I know you're probably very busy and stuff but it would be great if you could post somewhat easier-to-understand instructions!
Go to the top of the page
 
+Quote Post
   
Twilight27
post Apr 20 2008, 01:03 PM
Post #12


Level 19
Group Icon

Group: Revolutionary
Posts: 371
Type: Event Designer
RM Skill: Beginner




Sorry, but...BUMP!
There're two of us (or maybe more) that requires help with the same thing =p
Though, take your time to help happy.gif. No need to hussle you...


__________________________

Fall to the power of the Emo!
We have cookies!


Notice!! Check out my topic (http://www.rpgrevolution.com/forums/index.php?showtopic=45736&st=0#entry454175) if you're interested in helping me make a script that limits the number of characters & items you use in battle AND also an item durability feature! Thanks for any help in advance!
Go to the top of the page
 
+Quote Post
   
Oralom
post May 1 2008, 04:17 AM
Post #13


Level 3
Group Icon

Group: Member
Posts: 34
Type: Event Designer
RM Skill: Beginner




I to would like to know how you can make events happen during a certain time. I figured out how to make monsters apear during a certain time, but as for events I'm stumped. I want to make it so at night you can't go into stores because they are closed.
Go to the top of the page
 
+Quote Post
   
Namio
post Jun 8 2008, 09:43 PM
Post #14


Level 1
Group Icon

Group: Member
Posts: 11
Type: None
RM Skill: Beginner




How do I make the BGM change when it is at night time?
Go to the top of the page
 
+Quote Post
   
Guest_From_Ariel_*
post Jun 9 2008, 01:32 AM
Post #15





Guests





How would people compare this to like kylocks time im kinda trying to decide which one to use.

Go to the top of the page
 
+Quote Post
   
drebenk
post Jun 24 2008, 05:58 PM
Post #16


Level 20
Group Icon

Group: Revolutionary
Posts: 405
Type: Event Designer
RM Skill: Skilled




Ok I put the script above Main but what do I need to do in order to start this scirpt? When I start my game and wait for a while nothing happens. Do you need to set up some events in order for the script to work or what? There is no explanation on what do you need to do so that the script can work. At least with Kylocks script you just put it above Main and add [KTS] to the map name and the script starts to work. Can somebody give some directions on how to start this script?


__________________________
Nobody dies a virgin. Sooner or later life f***s everybody.
Go to the top of the page
 
+Quote Post
   
Netto
post Jun 24 2008, 10:17 PM
Post #17


芸術家
Group Icon

Group: Revolutionary
Posts: 708
Type: None
RM Skill: Skilled




QUOTE (drebenk @ Jun 24 2008, 06:12 PM) *
Ok I put the script above Main but what do I need to do in order to start this scirpt? When I start my game and wait for a while nothing happens. Do you need to set up some events in order for the script to work or what? There is no explanation on what do you need to do so that the script can work. At least with Kylocks script you just put it above Main and add [KTS] to the map name and the script starts to work. Can somebody give some directions on how to start this script?

If you chose method 1, the script is running according to your game time, play around for about 5mins and the time of day should change, also put [DN_VOID] in map names of which you do not wish the day/night system to apply to.


__________________________
Current Project[RC]: Twilight Realm 3DMMORPG w/dx9, and char creation through mysql after I get a server, now C++ scripting
Current Project[VX]: Obsidian Trilogy just started 08/12/2008
Current Project[XP&RM2K3]: none
Go to the top of the page
 
+Quote Post
   
drebenk
post Jun 25 2008, 03:29 AM
Post #18


Level 20
Group Icon

Group: Revolutionary
Posts: 405
Type: Event Designer
RM Skill: Skilled




@Netto well ok thank you for the explanation mate. ^^


__________________________
Nobody dies a virgin. Sooner or later life f***s everybody.
Go to the top of the page
 
+Quote Post
   
keyonne
post Jun 27 2008, 06:48 AM
Post #19


Level 3
Group Icon

Group: Member
Posts: 35
Type: Artist
RM Skill: Advanced




I keep getting an error...

QUOTE
Script 'Day and Night' line 389: NoMethodError occured.
Undefined method '+' for nil: NilClass



I know nothing of scripting and I'm afraid I'll make it worse if I try to fix it. :/
Go to the top of the page
 
+Quote Post
   
karu89
post Jul 20 2008, 09:38 AM
Post #20


Level 4
Group Icon

Group: Member
Posts: 45
Type: Event Designer
RM Skill: Beginner




I get the same error, and my game can't run properly if i don't get it fixed
Go to the top of the page
 
+Quote Post
   

2 Pages V   1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 18th May 2013 - 05:16 PM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker