diff --git a/scripts/FastTravel.rb b/scripts/FastTravel.rb index 4924493..9d17039 100644 --- a/scripts/FastTravel.rb +++ b/scripts/FastTravel.rb @@ -97,7 +97,7 @@ class FastTravel #WME def update_location_name_text - if ZONES[$game_fasttravel.zone].locations == nil || ZONES[$game_fasttravel.zone].maps[@selected_location] == nil || Settings[:fasttravel_ui] == "Original" + if ZONES[$game_fasttravel.zone].locations == nil || ZONES[$game_fasttravel.zone].maps[@selected_location] == nil || (Settings[:fasttravel_ui] == 0) return end @location_name_text.bitmap.clear @@ -159,7 +159,7 @@ class FastTravel self.opacity = 0 #WME - if !Settings[:fasttravel_ui] == "Original" + if !(Settings[:fasttravel_ui] == 0) @niko_icon.opacity = @location_name_text.opacity = @arrow_top.opacity = @arrow_bottom.opacity = @arrow_left.opacity = @arrow_right.opacity = 0 @@ -185,7 +185,7 @@ class FastTravel # Create menu options @data.each_with_index do |item, i| - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) #WME spr = Sprite.new(@viewport) spr.bitmap = RPG::Cache.load_bitmap("Graphics/Menus/Minimap/", "#{$game_fasttravel.zone}_#{item}") @@ -208,7 +208,7 @@ class FastTravel end end - if Settings[:fasttravel_ui] == "Original" + if (Settings[:fasttravel_ui] == 0) return end @@ -228,7 +228,7 @@ class FastTravel def update zone = ZONES[$game_fasttravel.zone] zone = zone == nil ? Zone.new("", {}, {}) : zone - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) @arrows_timer += 1 if @arrows_timer >= 30 @arrows_timer = 0 @@ -239,7 +239,7 @@ class FastTravel if @fade_in self.opacity += 20 - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) #WME @niko_icon.opacity += 20 @location_name_text.opacity += 20 @@ -258,7 +258,7 @@ class FastTravel active_spr = spr if !active_spr && spr.x < MARGIN * 2 end #WME - if !Settings[:fasttravel_ui] == "Original" + if !(Settings[:fasttravel_ui] == 0) @data_locations.each do |name, spr| spr.opacity += 20 spr.opacity = 255 if spr.opacity > 255 @@ -277,7 +277,7 @@ class FastTravel if @fade_out self.opacity -= 20 - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) #WME @niko_icon.opacity -= 20 @location_name_text.opacity -= 20 @@ -294,7 +294,7 @@ class FastTravel end #WME - if !Settings[:fasttravel_ui] == "Original" + if !(Settings[:fasttravel_ui] == 0) @data_locations.each do |name, spr| spr.opacity -= 20 end @@ -309,7 +309,7 @@ class FastTravel end #WME - if !Settings[:fasttravel_ui] == "Original" + if !(Settings[:fasttravel_ui] == 0) @data_locations.each do |name, spr| spr.dispose end @@ -337,7 +337,7 @@ class FastTravel return if !self.visible #WME noik - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) @niko_target_pos_x = (zone.locations[@selected_location].x.to_f + zone.locations[@selected_location].niko_x.to_f) @niko_target_pos_y = (zone.locations[@selected_location].y.to_f + zone.locations[@selected_location].niko_y.to_f) @@ -359,7 +359,7 @@ class FastTravel @arrow_bottom.opacity += @data.include?(location.next_bottom) ? 40 : -40 @arrow_left.opacity += @data.include?(location.next_left) ? 40 : -40 @arrow_right.opacity += @data.include?(location.next_right) ? 40 : -40 - elsif !Settings[:fasttravel_ui] == "Original" + elsif !(Settings[:fasttravel_ui] == 0) @niko_icon.opacity = @arrow_top.opacity = @arrow_bottom.opacity = @arrow_left.opacity = @arrow_right.opacity = 0 @@ -383,7 +383,7 @@ class FastTravel end end - if !Settings[:fasttravel_ui] == "Original" + if !(Settings[:fasttravel_ui] == 0) #WME @data_locations.each do |name, spr| set_color(name) @@ -391,7 +391,7 @@ class FastTravel end if Input.trigger?(Input::UP) - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) next_location = zone.locations[@selected_location].next_top if @data_locations.has_key?(next_location) @selected_location = next_location @@ -404,7 +404,7 @@ class FastTravel end end if Input.trigger?(Input::DOWN) - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) next_location = zone.locations[@selected_location].next_bottom if @data_locations.has_key?(next_location) @selected_location = next_location @@ -418,7 +418,7 @@ class FastTravel end if Input.trigger?(Input::LEFT) - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) next_location = zone.locations[@selected_location].next_left if @data_locations.has_key?(next_location) @selected_location = next_location @@ -428,7 +428,7 @@ class FastTravel end end if Input.trigger?(Input::RIGHT) - if zone.locations != nil && !Settings[:fasttravel_ui] == "Original" + if zone.locations != nil && !(Settings[:fasttravel_ui] == 0) next_location = zone.locations[@selected_location].next_right if @data_locations.has_key?(next_location) @selected_location = next_location @@ -441,7 +441,7 @@ class FastTravel if Input.trigger?(Input::ACTION) $game_system.se_play($data_system.decision_se) choice = $game_fasttravel.unlocked_maps[@selected_location] - if zone.locations == nil || Settings[:fasttravel_ui] == "Original" + if zone.locations == nil || (Settings[:fasttravel_ui] == 0) choice = $game_fasttravel.unlocked_maps[@data[@index]] end if choice.id != $game_map.map_id diff --git a/scripts/Window_Settings.rb b/scripts/Window_Settings.rb index 683b8b9..b07f6c1 100644 --- a/scripts/Window_Settings.rb +++ b/scripts/Window_Settings.rb @@ -132,7 +132,7 @@ class Window_Settings # navigation if Input.wheel_y != 0 if (Input::key_press?(Input::key_from_name("Left Shift"))) - for i in 0...Input.wheel_y.round.abs + for _ in 0...Input.wheel_y.round.abs Input.wheel_y.round > 0 ? @content.parameter_right : @content.parameter_left end else