RMRK is retiring.
Server is paid up for the rest of 2026, but the forum may go after that. See here for more information. Please archive or save anything you would like to keep before 2027.
Main Menu
  • Welcome to The RPG Maker Resource Kit.

[RESOLVED] Splash logo script with skip function

Started by Mitsarugi, June 18, 2010, 12:04:21 PM

0 Members and 1 Guest are viewing this topic.

Mitsarugi

Updated the script with the skip logo patch by modern algebra ,so other people can use the script ^^
could an admin move this to the script sharing section plz? :)

i deserve no credit for this!


the script:

[Spoiler]
#==============================================================================
# ** Scene Logo  V1.7
# SceneLogo.rb von Dëvic, Isaacsol, Lux (24.12.2008)
#------------------------------------------------------------------------------
# http://www.rpg-studio.de/scriptdb/node/239
# http://www.rpg-studio.de/forum/index.php?page=Thread&threadID=64
# http://www.rpgvx.net/index.php/topic,481.0.html
# http://www.rpgmakervx.net/index.php?showtopic=974
#==============================================================================

#==============================================================================
# ** Scene_Logo 1.7 RGSS2
# Script and RGSS2 debugging by Dëvic
# Support and RGSS1 debuggin by Isaacsol
# Version history:
#   ~ 07.03.08 :: First version released with fade effects, image delaying and
#                 unlimited number of logo images.
#   ~ 10.03.08 :: Version 1.7 released with beta Audio processing; plays all
#                 types of Audio (BGM, BGS, SE & ME), but just one through all
#                 the Scene. It is possible to disable Audio.
#------------------------------------------------------------------------------
# Shows on the screen the logos on startup. Compatible only with RGSS2!
#   Questions, acknowledgments and requests should be taken on the Thread at:
#   English thread:
#   http://www.rpgmakervx.net/index.php?showtopic=974
#   Portuguese thread:
#   http://www.rpgmakerbrasil.com/forum/f43/rmvx-scene-logo-1-7-rgss2-552.html
#==============================================================================

class Scene_Logo
  # Audio types Constant; leave it as nil to disable Audio.
  # Standard value: %w( BGM BGS ME SE )
  AudioTypes = %w( nil )

  # The Method here the options are customised.
  def initialize
    # Include in this array the logo(s) image(s), there is no limit for the
    # array's size.
    @img = [ 'Enterbrain', 'logorpgmvx', 'Title2' ]
    # Here, set 'true' if you want to have a fade in and fade out effect,
    # otherwise set to 'false'.
    @fade = true
    # Choose the amount of time taken to make the fade in/out effects (in
    # frames).
    # Standard: 20 frames.
    @fade_delay = 20
    # Choose the wait time (in frames [1/60 seconds]) that a logo image shall
    # stay in the screen.
    # Standard: 120 frames.
    @delaying = 120
    # General audio instance variable array; first three values are:
    # "Audio name", "Volume" and "Pitch"; next one is the type, based on the
    # constant AudioTypes
  • , for x: 0: BGM; 1: BGS; 3: SE and 2: ME.
        @audio = [ '01', 100, 50, AudioTypes[0] ]
        main
      end

      # The Method where the image processing is made.
      def main
          # For each image in the Array...
        @img.each { |i|
          # Is made a new Sprite object...
          sprite = Sprite.new
          # The Sprite's image is loaded from "../Graphics/System/" folder...
          sprite.bitmap = Cache.system(i)
          # Check if Audio is enabled...
          if AudioTypes
            # Finds out Audio type and plays choosen Audio...
            case @audio[3]
            when 'BGM'
              Audio.bgm_play("Audio/BGM/#{@audio[0]}", @audio[1], @audio[2])
            when 'BGS'
              Audio.bgs_play("Audio/BGS/#{@audio[0]}", @audio[1], @audio[2])
            when 'ME'
              Audio.me_play("Audio/ME/#{@audio[0]}", @audio[1], @audio[2])
            when 'SE'
              Audio.se_play("Audio/SE/#{@audio[0]}", @audio[1], @audio[2])
            end
          end
       
          # Module's method transition is called...
          Graphics.transition
          # Fade in effect is done if fade is enabled...
          Graphics.fadein(@fade_delay) if @fade == true
          # Now wait command is done...
          @delaying.times do
      Graphics.update
      Input.update
      break if Input.trigger? (Input::C)
    end
          # Fade out effect is done is fade is enabled...
          Graphics.fadeout(@fade_delay) if @fade == true
          # Now the Sprite object is disposed...
          sprite.dispose
          # And the screen freezed...
          Graphics.freeze
         }
      end
    end


    # Here is the change in the Scene_Title class.
    class Scene_Title
      alias old_start start
      def start
        Scene_Logo.new
        old_start
      end
    end

    [/spoiler]

modern algebra

Try replacing this line:


Graphics.wait(@delaying)


with:


@delaying.times do
  Graphics.update
  Input.update
  break if Input.trigger? (Input::C)
end


I'm at work right now, so I can't test it or think about it, but give it a try.

Mitsarugi

#2
thank you my friend i'll try it right away ^^


EDIT: works like a charm, thanks :) love your scripts btw ^^