• Anmelden

1

Samstag, 25. Oktober 2008, 13:43

Titel Skript ???

Hi

Ich würde ein Skript brauchen indem ich vor den Titel Splas Screens abspielen kann die was sich einblenden lassen

Dazu würd ich ein simples Skript suchen wo man 2 Buttons hat der eine der was ausgewählt ist sieht man der unausgewählte ist verblasst ...

[img]http://img58.imageshack.us/my.php?image=titeljy7.jpg[/img]

Kann mir pls wer helfen x.x ?
~ The Road So Far...

2

Samstag, 25. Oktober 2008, 20:26

Hey!
Ich habe letztens was von Caeser gefunden.
Du musst dafür die Scene_Title mit der hier ersetzen:

Spoiler: Scene_Title

Quellcode

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
#///////////////////////////////////////////Scene_Title////////////////////////////////////////
#///////////////////////////////////////////Mit Bildern\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
#~~~~~~~~~~~~~~~~~~~~~~by Caesar~~~~~~~~~~~~~~~~~~~~~
#\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
class Scene_Title
  def main
    if $BTEST
      battle_test
      return
    end
    $data_actors        = load_data("Data/Actors.rxdata")
    $data_classes       = load_data("Data/Classes.rxdata")
    $data_skills        = load_data("Data/Skills.rxdata")
    $data_items         = load_data("Data/Items.rxdata")
    $data_weapons       = load_data("Data/Weapons.rxdata")
    $data_armors        = load_data("Data/Armors.rxdata")
    $data_enemies       = load_data("Data/Enemies.rxdata")
    $data_troops        = load_data("Data/Troops.rxdata")
    $data_states        = load_data("Data/States.rxdata")
    $data_animations    = load_data("Data/Animations.rxdata")
    $data_tilesets      = load_data("Data/Tilesets.rxdata")
    $data_common_events = load_data("Data/CommonEvents.rxdata")
    $data_system        = load_data("Data/System.rxdata")
    $game_system = Game_System.new
    @sprite = Sprite.new
    @sprite.bitmap = RPG::Cache.title($data_system.title_name)
    #++++++++++++++++++++++++++
    s1 = "newgame"
    s2 = "continue"
    s3 = "exit"
    #++++++++++++++++++++++++++
    @command_window = Window_ImgSelection.new(290, [s1, s2, s3])
    @command_window.contents.font.color = Color.new(0, 0, 0)
    @command_window.back_opacity = 160
    @command_window.x = 320 - @command_window.width / 2
    @command_window.y = 288
    @continue_enabled = false
    for i in 0..3
      if FileTest.exist?("Save#{i+1}.sav")
        @continue_enabled = true
      end
    end
    if @continue_enabled
      @command_window.index = 1
    else
      @command_window.disable_item(1)
    end
    @command_window.refresh();    #edit by kiba
    $game_system.bgm_play($data_system.title_bgm)
    Audio.me_stop
    Audio.bgs_stop
    Graphics.transition
    loop do
      Graphics.update
      Input.update
      update
      if $scene != self
        break
      end
    end
    Graphics.freeze
    @command_window.dispose
    @sprite.bitmap.dispose
    @sprite.dispose
  end
  #-----------------------
  def update
    @command_window.update
    if Input.trigger?(Input::C)
      case @command_window.index
      when 0
        command_new_game
      when 1
        command_continue
      when 2
        command_shutdown
      end
    end
  end
  #-----------------------
  def command_new_game
    $game_system.se_play($data_system.decision_se)
    Audio.bgm_stop
    Graphics.frame_count = 0
    $game_temp          = Game_Temp.new
    $game_system        = Game_System.new
    $game_switches      = Game_Switches.new
    $game_variables     = Game_Variables.new
    $game_self_switches = Game_SelfSwitches.new
    $game_screen        = Game_Screen.new
    $game_actors        = Game_Actors.new
    $game_party         = Game_Party.new
    $game_troop         = Game_Troop.new
    $game_map           = Game_Map.new
    $game_player        = Game_Player.new
    #::::::::::::::::::
    $game_party.setup_starting_members
    $game_map.setup($data_system.start_map_id)
    $game_player.moveto($data_system.start_x, $data_system.start_y)
    $game_player.refresh
    $game_map.autoplay
    $game_map.update
    $scene = Scene_Map.new
  end
  #-----------------------
  def command_continue
    unless @continue_enabled
      $game_system.se_play($data_system.buzzer_se)
      return
    end
    $game_system.se_play($data_system.decision_se)
    $scene = Scene_Load.new
  end
  #-----------------------
  def command_shutdown
    $game_system.se_play($data_system.decision_se)
    Audio.bgm_fade(800)
    Audio.bgs_fade(800)
    Audio.me_fade(800)
    $scene = nil
  end
  #-----------------------
  def battle_test
    $data_actors        = load_data("Data/BT_Actors.rxdata")
    $data_classes       = load_data("Data/BT_Classes.rxdata")
    $data_skills        = load_data("Data/BT_Skills.rxdata")
    $data_items         = load_data("Data/BT_Items.rxdata")
    $data_weapons       = load_data("Data/BT_Weapons.rxdata")
    $data_armors        = load_data("Data/BT_Armors.rxdata")
    $data_enemies       = load_data("Data/BT_Enemies.rxdata")
    $data_troops        = load_data("Data/BT_Troops.rxdata")
    $data_states        = load_data("Data/BT_States.rxdata")
    $data_animations    = load_data("Data/BT_Animations.rxdata")
    $data_tilesets      = load_data("Data/BT_Tilesets.rxdata")
    $data_common_events = load_data("Data/BT_CommonEvents.rxdata")
    $data_system        = load_data("Data/BT_System.rxdata")
    #:::::::::::::::::
    Graphics.frame_count = 0
    #:::::::::::::::::
    $game_temp          = Game_Temp.new
    $game_system        = Game_System.new
    $game_switches      = Game_Switches.new
    $game_variables     = Game_Variables.new
    $game_self_switches = Game_SelfSwitches.new
    $game_screen        = Game_Screen.new
    $game_actors        = Game_Actors.new
    $game_party         = Game_Party.new
    $game_troop         = Game_Troop.new
    $game_map           = Game_Map.new
    $game_player        = Game_Player.new
    #::::::::::::::::::::
    $game_party.setup_battle_test_members
    $game_temp.battle_troop_id = $data_system.test_troop_id
    $game_temp.battle_can_escape = true
    $game_map.battleback_name = $data_system.battleback_name
    $game_system.se_play($data_system.battle_start_se)
    $game_system.bgm_play($game_system.battle_bgm)
    $scene = Scene_Battle.new
  end
end
#========================
class Window_ImgSelection < Window_Base
  IMGHEIGHT = 49
  attr_reader :index
  #--------------
  def initialize(width, images)
    super(0, 0, width, (images.size+1)*IMGHEIGHT)
    @images = images
    @enabled = Array.new(@images.size, true)
    self.contents = Bitmap.new(width-32, height-32)
    self.opacity = 0
    @index = 0
    refresh
  end
  #-----------------
  def refresh
    self.contents.clear
    @images.size.times {|i| draw_item(i)}
  end
  #-----------------
  def draw_item(index)
    img = @images[index]
    img += "_active" if @index == index
    img += "_disabled" unless @enabled[index]
    bitmap = RPG::Cache.picture(img)
    self.contents.blt(0, index*IMGHEIGHT, bitmap, bitmap.rect)
  end
  #------------------
  def update
    super
    if Input.repeat?(Input::DOWN)
      @index = (@index + 1) % @images.size
      refresh
    end
    if Input.repeat?(Input::UP)
      @index = (@index + @images.size - 1) % @images.size
      refresh
    end
  end
  #-----------------
  def disable_item(index)
    @enabled[index] = false
  end
  #-----------------
  def index=(index)
    @index = index
    refresh
  end
end
zum Lesen den Text mit der Maus markieren


Ich habe dazu leider keine "Beschreibung" mehr.
Aber in Zeile 28-30 kannst du halt die Englischen Begriffe ins Deutsche umwandeln.
Achso und man brauch auch mehrere Pictures, die man in den Picture ordner tut. Also die Buttons (s. Demo ;) )
Hier mal ne Demo, die ich noch aufm PC hatte:

Titelmenü mit Pictures.rar

Hoffe, du kannst was damit anfangen ;P

~Kairi

3

Sonntag, 26. Oktober 2008, 19:42

Geht das auch mit weniger als 8 Bildern ich brauch doch nur Neues Spiel ausgewählt / unausgewählt und Spiel laden ausgewählt / unausgewählt das wären 4 Bilder x.x ?
~ The Road So Far...

Social Bookmarks