Day.png);">
Apprendre


Vous êtes
nouveau sur
Oniromancie?

Visite guidée
du site


Découvrir
RPG Maker

RM 95
RM 2000/2003
RM XP
RM VX/VX Ace
RM MV/MZ

Apprendre
RPG Maker

Tutoriels
Guides
Making-of

Dans le
Forum

Section Entraide

Sorties: Star Trek: Glorious Wolf - (...) / Sorties: Dread Mac Farlane - episode 3 / News: Plein d'images cools créées par (...) / Sorties: Star Trek: Glorious Wolf - (...) / Jeux: Final Fantasy 2.0 / Chat

Bienvenue
visiteur !




publicité RPG Maker!

Statistiques

Liste des
membres


Contact

Mentions légales

329 connectés actuellement

29190945 visiteurs
depuis l'ouverture

5996 visiteurs
aujourd'hui



Barre de séparation

Partenaires

Indiexpo

Akademiya RPG Maker

Blog Alioune Fall

Fairy Tail Constellations

Le Temple de Valor

Hellsoft

Le Comptoir Du clickeur

RPG Fusion

Tous nos partenaires

Devenir
partenaire



forums

Index du forum > Entraide > [Vx Ace]je débute en scrip : Mon 1er bug ? :')


spyrojojo - posté le 02/11/2014 à 03:25:12 (773 messages postés)

❤ 0

schizophrène avec tendance cleptomane a votre service

Yop les gens, j'ai décidé de faire mon atlas pour mon projet en script (pour le fun) j'ai donc commencé à créer un petit script pour me faire la main .Mais celui-ci m'indique une erreur ligne 14 et j'ai beau chercher je ne la vois pas =s, peu t'ont M'aider ? ^^ (si je retire les @window selection.Sethandler sa marche mais je peux pas lire mes messages dans les p"" =s)

Portion de code : Tout sélectionner

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
class Scene_Test < Scene_Base
  # Lancement 
  def start
      super
      create_titre
      create_choix
    end
    def create_titre
      @title = Window_Help.new(1)
      @title.set_text("Atlas")
    end
  def create_choix
    @Window_selection = Window_monde.new(0, 48)
    @window_selection.set_handler(:ma, method(:ma))
    @window_selection.set_handler(:mb, method(:mb))
    @window_selection.set_handler(:mc, method(:mc))
    @window_selection.set_handler(:md, method(:md))
  end
  def ma
  p "test"
end
  def mb
  p "test"
end
  def mc
  p "test"
end
  def md
  p "test"
  end
end
  
  
class Window_monde < Window_Command
  def make_command_list
    add_command("Ile verdoyante", :ma)
    add_command("Ile boisée", :mb)
    add_command("Ile Givrée", :mc)
    add_command("Ile de Jester", :md)
 
  end
end



Merci d'avance .

Mes projets : Fall, Délirium | Mes scripts : BGM et BGS dans le menu | Mon deviantart


Rajang - posté le 02/11/2014 à 09:44:08 (68 messages postés)

❤ 0

Simple makeur. Mais c'est déja ça.

Je suis pas sur, mais je crois que mettre

Portion de code : Tout sélectionner

1
@window_selection.set_handler(:ma, :ma)



ça marche (le "method()" ne sert à rien)

EDIT : Dsl, j'ai éssayé, ca ne marche pas :-/
J'ai fait un script du même genre moi aussi, je te le mets pour que tu puisse comparer (le mien est légèrement plus complet :rit2

Portion de code : Tout sélectionner

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
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
#=============================================================================
#
#          Liste des clichés          v. 1.0
#          by MHRajang
#
#=============================================================================
 
# Scene journal
class Scene_MHRCliches < Scene_Base
  # Lancement de la scène
  def start
    super
    create_title
    create_commands
    create_window_message
  end
  # Création de la fenêtre de titre
  def create_title
    @title = Window_Help.new(1)
    @title.set_text("         Clichés des jeux de rôles")
  end
  # Création de la fenêtre de sélection
  def create_commands
    @window_selection = Window_List.new(0, 48)
    @window_selection.set_handler(:cliche1, method(:cliche1))
    @window_selection.set_handler(:cliche2, method(:cliche2))
    @window_selection.set_handler(:cliche3, method(:cliche3))
    @window_selection.set_handler(:cliche4, method(:cliche4))
    @window_selection.set_handler(:cliche5, method(:cliche5))
    @window_selection.set_handler(:cliche6, method(:cliche6))
    @window_selection.set_handler(:cliche7, method(:cliche7))
    @window_selection.set_handler(:cliche8, method(:cliche8))
    @window_selection.set_handler(:cliche9, method(:cliche9))
    @window_selection.set_handler(:cliche10, method(:cliche10))
    @window_selection.set_handler(:cliche11, method(:cliche11))
    @window_selection.set_handler(:cliche12, method(:cliche12))
    @window_selection.set_handler(:cliche13, method(:cliche13))
    @window_selection.set_handler(:cliche14, method(:cliche14))
    @window_selection.set_handler(:cliche15, method(:cliche15))
    @window_selection.set_handler(:cliche16, method(:cliche16))
    @window_selection.set_handler(:cancel, method(:return_scene))
    @window_selection.set_handler(:unknowcliche, method(:unknowcliche))
  end
 
  def create_window_message
    @message = Window_Base.new(160, 48, 480, 432)
  end
  
  def display_message(number, text, text2, text3, text4,
    text5, text6, text7, text8, text9, text10)
    # Description =
    @message.draw_text(0, 20, 600, 80, text)
    @message.draw_text(100, 70, 600, 38, "_____________________")
    @message.draw_text(0, 120, 600, 38, text2)
    @message.draw_text(0, 145, 600, 38, text3)
    @message.draw_text(0, 170, 600, 38, text4)
    @message.draw_text(0, 195, 600, 38, text5)
    @message.draw_text(0, 220, 600, 38, text6)
    @message.draw_text(0, 245, 600, 38, text7)
    @message.draw_text(0, 270, 600, 38, text8)
    @message.draw_text(0, 295, 600, 38, text9)
    @message.draw_text(0, 320, 600, 38, text10)
    # Si accompli (3), ou non (1) =
    if number <= 1
      message = "A accomplir :"
    else message = "ACCOMPLI !"
    end
    @message.draw_text(120, 0, 280, 38, message)
    @message.show
  end
 
  def cliche1
    display_message($game_variables[103], "Titre",
    "Description ligne 1",
    "",
    "",
    "",
    "",
    "",
    "",
    "",
    "")
    SceneManager.call(Scene_MHRCliches)
  end
  def cliche2
    display_message($game_variables[104], "Titre",
    "Description ligne 1",
    "",
    "",
    "",
    "",
    "",
    "",
    "",
    "")
    SceneManager.call(Scene_MHRCliches)
  end
  def cliche3
    display_message($game_variables[105], "Titre",
    "Description ligne 1",
    "",
    "",
    "",
    "",
    "",
    "",
    "",
    "")
    SceneManager.call(Scene_MHRCliches)
  end
  def cliche4
    display_message($game_variables[106], "Titre",
    "Description ligne 1",
    "",
    "",
    "",
    "",
    "",
    "",
    "",
    "")
    SceneManager.call(Scene_MHRCliches)
  end
  def cliche5
    display_message($game_variables[107], "Titre",
    "Description ligne 1",
    "",
    "",
    "",
    "",
    "",
    "",
    "",
    "")
    SceneManager.call(Scene_MHRCliches)
  end
  def cliche6
  end
  def cliche7
  end
  def cliche8
  end
  def cliche9
  end
  def cliche10
  end
  def cliche11
  end
  def cliche12
  end
  def cliche13
  end
  def cliche14
  end
  def cliche15
  end
  def cliche16
  end
  def unknowcliche
    display_message($game_variables[120], "Inconnu",
    "",
    "A decouvrir !",
    "",
    "",
    "",
    "",
    "",
    "",
    "")
    SceneManager.call(Scene_MHRCliches)
  end
  
  # Attente de la pression du bouton C
  def pre_terminate
    super
    loop do
      Graphics.update
      Input.update
      break if Input.trigger?(:C)
    end
  end
end
 
 
# Fenêtre de sélection d'arme
class Window_List < Window_Command
  # Création de la liste de selection
  def make_command_list
    if $game_variables[103] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[103] == 1 
           add_command(" Cliché 01 ", :cliche1)
         else add_command("-Cliché 01-", :cliche1)
         end
    end
    
    if $game_variables[104] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[104] == 1 
           add_command(" Cliché 02 ", :cliche2)
         else add_command("-Cliché 02-", :cliche2)
         end
    end
    
    if $game_variables[105] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[105] == 1 
           add_command(" Cliché 03 ", :cliche3)
         else add_command("-Cliché 03-", :cliche3)
         end
    end
    
    if $game_variables[106] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[106] == 1 
           add_command(" Cliché 04 ", :cliche4)
         else add_command("-Cliché 04-", :cliche4)
         end
    end
    
    if $game_variables[107] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[107] == 1 
           add_command(" Cliché 05 ", :cliche5)
         else add_command("-Cliché 05-", :cliche5)
         end
    end
    
    if $game_variables[108] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[108] == 1 
           add_command(" Cliché 06 ", :cliche6)
         else add_command("-Cliché 06-", :cliche6)
         end
    end
    
    if $game_variables[109] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[109] == 1 
           add_command(" Cliché 07 ", :cliche7)
         else add_command("-Cliché 07-", :cliche7)
         end
    end
    
    if $game_variables[110] == 0
      add_command("inconnu", :unknowcliche)
   else if $game_variables[110] == 1 
           add_command(" Cliché 08 ", :cliche8)
         else add_command("-Cliché 08-", :cliche8)
         end
    end
    
    if $game_variables[111] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[111] == 1 
           add_command(" Cliché 09 ", :cliche9)
         else add_command("-Cliché 09-", :cliche9)
         end
    end
    
    if $game_variables[112] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[112] == 1 
           add_command(" Cliché 10 ", :cliche10)
         else add_command("-Cliché 10-", :cliche10)
         end
    end
    
    if $game_variables[113] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[113] == 1 
           add_command(" Cliché 11 ", :cliche11)
         else add_command("-Cliché 11-", :cliche11)
         end
    end
    
    if $game_variables[114] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[114] == 1 
           add_command(" Cliché 12 ", :cliche12)
         else add_command("-Cliché 12-", :cliche12)
         end
    end
    
    if $game_variables[115] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[115] == 1 
           add_command(" Cliché 13 ", :cliche13)
         else add_command("-Cliché 13-", :cliche13)
         end
    end
    
    if $game_variables[116] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[116] == 1 
           add_command(" Cliché 14 ", :cliche14)
         else add_command("-Cliché 14-", :cliche14)
         end
    end
    
    if $game_variables[117] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[117] == 1 
           add_command(" Cliché 15 ", :cliche15)
         else add_command("-Cliché 15-", :cliche15)
         end
    end
    
    if $game_variables[118] == 0
      add_command("inconnu", :unknowcliche)
    else if $game_variables[118] == 1 
           add_command(" Cliché 16 ", :cliche16)
         else add_command("-Cliché 16-", :cliche16)
         end
    end
    
    add_command("Revenir au menu", :cancel)
  end
end



Mon histoire interactive : https://amethysts.itch.io/coalescence


spyrojojo - posté le 02/11/2014 à 13:36:03 (773 messages postés)

❤ 0

schizophrène avec tendance cleptomane a votre service

^^ Merci beaucoup , je continurais mes tests tous à l'heure .J'y arriverais un jour , J'y arriverais.

Mes projets : Fall, Délirium | Mes scripts : BGM et BGS dans le menu | Mon deviantart


Rajang - posté le 02/11/2014 à 13:42:32 (68 messages postés)

❤ 0

Simple makeur. Mais c'est déja ça.

Courage ! :lol

Mon histoire interactive : https://amethysts.itch.io/coalescence


Nukidoudi - posté le 02/11/2014 à 17:49:20 (733 messages postés) -

❤ 0

yo

Ligne 13, t'as mis une majuscule à @Window... il faut retirer la majuscule.

https://xvw.lol


spyrojojo - posté le 02/11/2014 à 22:18:40 (773 messages postés)

❤ 0

schizophrène avec tendance cleptomane a votre service

Merci Nuki ^^, rendez vous au prochain bug =)

Mes projets : Fall, Délirium | Mes scripts : BGM et BGS dans le menu | Mon deviantart

Index du forum > Entraide > [Vx Ace]je débute en scrip : Mon 1er bug ? :')

repondre up

Suite à de nombreux abus, le post en invités a été désactivé. Veuillez vous inscrire si vous souhaitez participer à la conversation.

Haut de page

Merci de ne pas reproduire le contenu de ce site sans autorisation.
Contacter l'équipe - Mentions légales

Plan du site

Communauté: Accueil | Forum | Chat | Commentaires | News | Flash-news | Screen de la semaine | Sorties | Tests | Gaming-Live | Interviews | Galerie | OST | Blogs | Recherche
Apprendre: Visite guidée | RPG Maker 95 | RPG Maker 2003 | RPG Maker XP | RPG Maker VX | RPG Maker MV | Tutoriels | Guides | Making-of
Télécharger: Programmes | Scripts/Plugins | Ressources graphiques / sonores | Packs de ressources | Midis | Eléments séparés | Sprites
Jeux: Au hasard | Notre sélection | Sélection des membres | Tous les jeux | Jeux complets | Le cimetière | RPG Maker 95 | RPG Maker 2000 | RPG Maker 2003 | RPG Maker XP | RPG Maker VX | RPG Maker VX Ace | RPG Maker MV | Autres | Proposer
Ressources RPG Maker 2000/2003: Chipsets | Charsets | Panoramas | Backdrops | Facesets | Battle anims | Battle charsets | Monstres | Systems | Templates
Ressources RPG Maker XP: Tilesets | Autotiles | Characters | Battlers | Window skins | Icônes | Transitions | Fogs | Templates
Ressources RPG Maker VX: Tilesets | Charsets | Facesets | Systèmes
Ressources RPG Maker MV: Tilesets | Characters | Faces | Systèmes | Title | Battlebacks | Animations | SV/Ennemis
Archives: Palmarès | L'Annuaire | Livre d'or | Le Wiki | Divers