Per 2016, RMID pindah ke RMID Discord (Invite link dihapus untuk mencegah spambot -Theo @ 2019). Posting sudah tidak bisa dilakukan lagi.
Mohon maaf atas ketidaknyamanannya dan mohon kerjasamanya.

Share | 
 

 [SOLVED] Adding Options in Title Screen

Topik sebelumnya Topik selanjutnya Go down 
[SOLVED] Adding Options in Title Screen Empty2012-05-01, 20:51
Post[SOLVED] Adding Options in Title Screen
#1
barlieuy 
Novice
Novice
barlieuy

Level 5
Posts : 139
Thanked : 1
Engine : RMVX Ace
Skill : Beginner
Type : Jack of All Trades

[SOLVED] Adding Options in Title Screen Vide
kawan2 yang handal scripting, bantuin sedikit dong sy lagi nyoba2 pengen nambahin command "Options" di title screen trus pas di pencet keluar window yang ada pilihannya lagi : "Game Controls", "Back" dll.

ini SS nya :
Spoiler:

Nah, yang pengen sy tanya gmn caranya pas di pilih "Game Controls" (pake Input Trigger Button C), trus keluar gambar (show pic gitu, posisinya di center), trus pas pencet Button B/Escape balik lagi ke Scene_Title.new

gambar ini :
Spoiler:

ini script yang kupake hasil modif dari script yg udah ada dr RTP (copy paste) dan juga tutorial dr internet.
Code:
#==============================================================================
# ** Scene_Title
#------------------------------------------------------------------------------
#  This class performs the title screen processing.
#==============================================================================

class Scene_Title < Scene_Base
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    super
    @command_window.update
    if Input.trigger?(Input::C)
      case @command_window.index
      when 0    #New game
        command_new_game
      when 1    # Continue
        command_continue
      when 2    # Options
        command_options
      when 3    # Shutdown
        command_shutdown
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Create Command Window
  #--------------------------------------------------------------------------
  def create_command_window
    s1 = Vocab::new_game
    s2 = Vocab::continue
    s3 = "Options"
    s4 = Vocab::shutdown
    @command_window = Window_Command.new(185, [s1, s2, s3, s4]) #172
    @command_window.x = (544 - @command_window.width) / 2
    @command_window.y = 250 #288
    if @continue_enabled                    # If continue is enabled
      @command_window.index = 1            # Move cursor over command
    else                                    # If disabled
      @command_window.draw_item(1, false)  # Make command semi-transparent
    end
    @command_window.openness = 0
    @command_window.open
  end
  #--------------------------------------------------------------------------
  # * Command: Options
  #--------------------------------------------------------------------------
  def command_options
      Sound.play_decision
      $scene = Scene_Options.new
  end
end

#==============================================================================
# ** Scene_Options
#------------------------------------------------------------------------------
#  This class performs the options screen processing.
#==============================================================================

class Scene_Options < Scene_Base
  def initialize(options_index = 0)
    @options_index = options_index
  end

  def start
    super 
    create_menu_background
    create_window_command_options
  end

  def terminate
    super
    dispose_menu_background
    @window_command_options.dispose
  end

  def update
    super 
    update_menu_background
    @window_command_options.update
    if Input.trigger?(Input::B)
      Sound.play_cancel
      $scene = Scene_Title.new
    elsif Input.trigger?(Input::C)
      Sound.play_decision
      case @window_command_options.index
      when 0
      print "Game Controls"
      when 1
      print "Advanced Options"
      when 2
      print "Back"
      end
    end
  end

  def create_window_command_options
    opt1 = "Game Controls"
    opt2 = "Advanced Options"
    opt3 = "Back"
    @window_command_options = Window_Command.new(260,[opt1,opt2,opt3])
    @window_command_options.index = @options_index
    @window_command_options.x = Graphics.width/2 - @window_command_options.width/2
    @window_command_options.y = Graphics.height/2 - @window_command_options.height/2
  end
end

mohon bantuannya :D


Terakhir diubah oleh barlieuy tanggal 2012-05-08, 12:06, total 1 kali diubah
[SOLVED] Adding Options in Title Screen Empty2012-05-01, 21:14
PostRe: [SOLVED] Adding Options in Title Screen
#2
ViperRed 
Novice
Novice
ViperRed

Level 5
Posts : 107
Thanked : 0
Engine : RM2k3
Skill : Beginner
Type : Writer

[SOLVED] Adding Options in Title Screen Vide
Lol susah amat jadi scripter buat kepala pusing aja!
BTW, Aku nggak tahu caranya :ngacay: tapi kalau udah ada yang jawab langsung saya lihat lah!
Tapi satu jam ini kok nggak ada yang reply?
[SOLVED] Adding Options in Title Screen Empty2012-05-01, 22:16
PostRe: [SOLVED] Adding Options in Title Screen
#3
baszto 
Advance
Advance
baszto

Level 5
Posts : 317
Thanked : 2

[SOLVED] Adding Options in Title Screen Vide
wah gw lupa cara masukin gambar om, tapi nanti klo gw tau pasti gw kasitau.
nih skarang pke window dulu aja ya,,
nanti jadi gini
[SOLVED] Adding Options in Title Screen Untitl10
ini scriptny
Code:
#==============================================================================
# ** Scene_Title
#------------------------------------------------------------------------------
#  This class performs the title screen processing.
#==============================================================================

class Scene_Title < Scene_Base
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    super
    @command_window.update
    if Input.trigger?(Input::C)
      case @command_window.index
      when 0    #New game
        command_new_game
      when 1    # Continue
        command_continue
      when 2    # Options
        command_options
      when 3    # Shutdown
        command_shutdown
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Create Command Window
  #--------------------------------------------------------------------------
  def create_command_window
    s1 = Vocab::new_game
    s2 = Vocab::continue
    s3 = "Options"
    s4 = Vocab::shutdown
    @command_window = Window_Command.new(185, [s1, s2, s3, s4]) #172
    @command_window.x = (544 - @command_window.width) / 2
    @command_window.y = 250 #288
    if @continue_enabled                    # If continue is enabled
      @command_window.index = 1            # Move cursor over command
    else                                    # If disabled
      @command_window.draw_item(1, false)  # Make command semi-transparent
    end
    @command_window.openness = 0
    @command_window.open
  end
  #--------------------------------------------------------------------------
  # * Command: Options
  #--------------------------------------------------------------------------
  def command_options
      Sound.play_decision
      $scene = Scene_Options.new
  end
end

#==============================================================================
# ** Scene_Instructions
#------------------------------------------------------------------------------

#==============================================================================

class Scene_GC < Scene_Base
  #--------------------------------------------------------------------------
  # * Object Initialization
  #    actor_index : actor index
  #--------------------------------------------------------------------------
  def initialize(from_title=false)
    @from_title = from_title
  end
  #--------------------------------------------------------------------------
  # * Start processing
  #--------------------------------------------------------------------------
  def start
    super
    create_menu_background
    @gc_window = Window_GC.new
  end
  #--------------------------------------------------------------------------
  # * Termination Processing
  #--------------------------------------------------------------------------
  def terminate
    super
    dispose_menu_background
    @gc_window.dispose
  end
  #--------------------------------------------------------------------------
  # * Return to Original Screen
  #--------------------------------------------------------------------------
  def return_scene
      $scene = Scene_Title.new
  end
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    update_menu_background
    @gc_window.update
    if Input.trigger?(Input::B)
      Sound.play_cancel
      return_scene
    end
    super
  end
end
[SOLVED] Adding Options in Title Screen Empty2012-05-01, 23:11
PostRe: [SOLVED] Adding Options in Title Screen
#4
LiTTleDRAgo 
Senior
Senior
LiTTleDRAgo

Level 5
Posts : 712
Thanked : 27
Engine : RMXP
Skill : Skilled
Type : Scripter
Awards:
[SOLVED] Adding Options in Title Screen Vide
Code:
#==============================================================================
# ** Scene_Title
#------------------------------------------------------------------------------
#  This class performs the title screen processing.
#==============================================================================

class Scene_Title < Scene_Base
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    super
    create_things if @window_command_options.nil?
    @command_window.update
    if @command_window.active
      update_command
    elsif @window_command_options.active
      update_command_windows
    elsif  @game_control.visible
      update_sprite_control
    end
    @window_command_options.update
  end
  #--------------------------------------------------------------------------
  # * Update Command
  #--------------------------------------------------------------------------
  def update_command
    if Input.trigger?(Input::C)
      case @command_window.index
      when 0    #New game
        command_new_game
      when 1    # Continue
        command_continue
      when 2    # Options
        command_options
      when 3    # Shutdown
        command_shutdown
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Create Command Window
  #--------------------------------------------------------------------------
  def create_command_window
    s1 = Vocab::new_game
    s2 = Vocab::continue
    s3 = "Options"
    s4 = Vocab::shutdown
    @command_window = Window_Command.new(185, [s1, s2, s3, s4]) #172
    @command_window.x = (544 - @command_window.width) / 2
    @command_window.y = 250 #288
    if @continue_enabled                    # If continue is enabled
      @command_window.index = 1            # Move cursor over command
    else                                    # If disabled
      @command_window.draw_item(1, false)  # Make command semi-transparent
    end
    @command_window.openness = 0
    @command_window.open
    @command_window.active = true
  end
  #--------------------------------------------------------------------------
  # * Create Things
  #--------------------------------------------------------------------------
  def create_things
    create_window_command_options
    create_game_controls
  end
  #--------------------------------------------------------------------------
  # * Terminate
  #--------------------------------------------------------------------------
  alias drg130_term terminate
  def terminate
    drg130_term
    @window_command_options.dispose
    @command_window.dispose
    @game_control.dispose
  end
  #--------------------------------------------------------------------------
  # * Update Command Windows
  #--------------------------------------------------------------------------
  def update_command_windows
    if Input.trigger?(Input::B)
      Sound.play_cancel
      @window_command_options.active = false
      @window_command_options.visible = false
      @command_window.visible = true
      @command_window.active = true
      @game_control.visible = false
    elsif Input.trigger?(Input::C)
      Sound.play_decision
      case @window_command_options.index
      when 0
        @window_command_options.active = false
        @window_command_options.visible = false
        @command_window.visible = false
        @command_window.active = false
        @game_control.visible = true
      when 1
      print "Advanced Options"
      when 2
        @game_control.visible = false
        @window_command_options.active = false
        @window_command_options.visible = false
        @command_window.visible = true
        @command_window.active = true
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Command: Options
  #--------------------------------------------------------------------------
  def command_options
    Sound.play_decision
    @command_window.visible = false
    @command_window.active = false
    @game_control.visible = false
    @window_command_options.active = true
    @window_command_options.visible = true
  end
  #--------------------------------------------------------------------------
  # * Update Control
  #--------------------------------------------------------------------------
  def update_sprite_control
    if Input.trigger?(Input::B)
      Sound.play_cancel
      @game_control.visible = false
      @command_window.visible = false
      @command_window.active = false
      @window_command_options.active = true
      @window_command_options.visible = true
    end
  end
  #--------------------------------------------------------------------------
  # * UCreate Window Command Options
  #--------------------------------------------------------------------------
  def create_window_command_options
    opt1 = "Game Controls"
    opt2 = "Advanced Options"
    opt3 = "Back"
    @window_command_options = Window_Command.new(260,[opt1,opt2,opt3])
    @window_command_options.x = Graphics.width/2 - @window_command_options.width/2
    @window_command_options.y = Graphics.height/2 - @window_command_options.height/2
    @window_command_options.active = false
    @window_command_options.visible = false
  end
  #--------------------------------------------------------------------------
  # * Create Game Controls
  #--------------------------------------------------------------------------
  def create_game_controls
    @game_control = Sprite.new
    control = Cache.picture('test2')
    bitmap = Bitmap.new(control.width,control.height)
    bitmap.stretch_blt(bitmap.rect, control, control.rect)
    @game_control.visible = false
    @game_control.bitmap = bitmap
    @game_control.x = 130
    @game_control.y = 110
  end
 
end

begini kah?
[SOLVED] Adding Options in Title Screen Empty2012-05-06, 16:20
PostRe: [SOLVED] Adding Options in Title Screen
#5
barlieuy 
Novice
Novice
barlieuy

Level 5
Posts : 139
Thanked : 1
Engine : RMVX Ace
Skill : Beginner
Type : Jack of All Trades

[SOLVED] Adding Options in Title Screen Vide
@baszto :

iya klo pake window udah bisa cuma pengen show picture biar ada variasi.

@LiTTleDRAgo :

hmm, iya nanti saya coba, skrang lg g ada d rmh. :D
[SOLVED] Adding Options in Title Screen Empty2012-05-06, 18:13
PostRe: [SOLVED] Adding Options in Title Screen
#6
LiTTleDRAgo 
Senior
Senior
LiTTleDRAgo

Level 5
Posts : 712
Thanked : 27
Engine : RMXP
Skill : Skilled
Type : Scripter
Awards:
[SOLVED] Adding Options in Title Screen Vide
oh iya biar ga lupa itu di skrip kk ada advanced option
tp gw ga tau apa fungsinya jadi gw biarin

Code:
      when 1
      print "Advanced Options"
      when 2
[SOLVED] Adding Options in Title Screen Empty2012-05-08, 10:57
PostRe: [SOLVED] Adding Options in Title Screen
#7
barlieuy 
Novice
Novice
barlieuy

Level 5
Posts : 139
Thanked : 1
Engine : RMVX Ace
Skill : Beginner
Type : Jack of All Trades

[SOLVED] Adding Options in Title Screen Vide
wah iya bener kaya gitu.

kalo yang Advanced Options emang sengaja di kosongin dulu, masih proses.

jd ngerti sekarang.
hehe
nambah ilmu lg

makasih :)

Spoiler:


[SOLVED] Adding Options in Title Screen Empty2012-05-08, 11:09
PostRe: [SOLVED] Adding Options in Title Screen
#8
LiTTleDRAgo 
Senior
Senior
LiTTleDRAgo

Level 5
Posts : 712
Thanked : 27
Engine : RMXP
Skill : Skilled
Type : Scripter
Awards:
[SOLVED] Adding Options in Title Screen Vide
sama-sama :)

Spoiler:
[SOLVED] Adding Options in Title Screen Empty2012-05-08, 11:54
PostRe: [SOLVED] Adding Options in Title Screen
#9
barlieuy 
Novice
Novice
barlieuy

Level 5
Posts : 139
Thanked : 1
Engine : RMVX Ace
Skill : Beginner
Type : Jack of All Trades

[SOLVED] Adding Options in Title Screen Vide
udah solved, bisa di lock.
[SOLVED] Adding Options in Title Screen Empty2012-05-09, 09:18
PostRe: [SOLVED] Adding Options in Title Screen
LowlingLife 
Administrator
Administrator
LowlingLife

Kosong
Posts : 2000
Thanked : 25
Engine : Multi-Engine User
Awards:

[SOLVED] Adding Options in Title Screen Vide
Berhubung udah solved dan saya lihat sepertinya tidak ada yang ingin ditambahkan lagi, maka saya akan me-lock thread ini. Kalau TS atau member lain ingin menambahkan, harap hubungi admin atau moderator setempat. Terima kasih.

~Locked Since Solved~
[SOLVED] Adding Options in Title Screen Empty
PostRe: [SOLVED] Adding Options in Title Screen
Sponsored content 




[SOLVED] Adding Options in Title Screen Vide
 

[SOLVED] Adding Options in Title Screen

Topik sebelumnya Topik selanjutnya Kembali Ke Atas 

Similar topics

+
Halaman 1 dari 1

Permissions in this forum:Anda tidak dapat menjawab topik
RPGMakerID :: Engines :: RMVX :: RMVX Archive-