#43 Inviato 20 October 2009 - 20:04 PM
cosa devo fare??
#44 Inviato 20 October 2009 - 21:08 PM
Scusate ma ho provato in tutti i modi ...ma mi dice sempre Error a Window_PlayTime riga 18 (SyntaxError)
cosa devo fare??
Oltre a quell'errore , ce ne sono diversi , tutti di sintassi . Prova cosi :
Da inserire al posto di " Sprite_Timer " :
#==================================================================== # ** Sprite_Clock #------------------------------------------------------------------- # This sprite is used to display the clock. It observes the $game_system # class and automatically changes sprite conditions. # Compiled by GAM modificato da Friday #================================================== class Sprite_Timer < Sprite #----------------------------------------------------------------- # * Object Initialization #----------------------------------------------------------------- def initialize super self.bitmap = Bitmap.new(88, 48) self.bitmap.font.name = "Arial" #Replace with whatever font you self.bitmap.font.size = 32 self.x = 640 - self.bitmap.width self.y = 0 self.z = 500 update end #----------------------------------------------------------------- # * Dispose #----------------------------------------------------------------- def dispose if self.bitmap != nil self.bitmap.dispose end super end #----------------------------------------------------------------- # * Frame Update #----------------------------------------------------------------- def update super self.visible = true if Graphics.frame_count / Graphics.frame_rate != @total_sec @total_sec = Graphics.frame_count / Graphics.frame_rate $min = @total_sec / 60 % 24 @sec = @total_sec % 60 if $min == 00 $night = 1 $game_variables[3]+=1 end if $min == 12 $night = 2 end #---------------------------------------------------------------- # Inside/Outside # Day / Night # mod these for different tones, faster/slower tones, # or more tones #---------------------------------------------------------------- if $game_switches[1] #==true $game_screen.start_tone_change(Tone.new(0,0,0), 5) else if $min < 5 $game_screen.start_tone_change(Tone.new(-170,-170,68), 20) elsif $min >= 5 and $min < 7 $game_screen.start_tone_change(Tone.new(-51,-102,-102), 20) elsif $min >= 7 and $min < 9 $game_screen.start_tone_change(Tone.new(0,-51,-68), 20) elsif $min >= 9 and $min < 18 $game_screen.start_tone_change(Tone.new(0,0,0), 20) elsif $min >= 18 and $min < 21 $game_screen.start_tone_change(Tone.new(-34,-68,-119), 20) elsif $min >= 21 $game_screen.start_tone_change(Tone.new(-170,-170,68), 20) end end #---------------------------------------------------------------- # Am / Pm # #---------------------------------------------------------------- if $night == 2 ampm = " PM" mins = $min - 12 $day = 0 else ampm = "AM" mins = $min end #---------------------------------------------------------------- # Makes the clock more clock looking # #---------------------------------------------------------------- if $min == 0 or $min == 12 mins = 12 end if $min == 10 clock = sprintf("d:d", mins, @sec) elsif $min == 11 clock = sprintf("d:d", mins, @sec) elsif $min == 12 clock = sprintf("d:d", mins, @sec) else clock = sprintf("d:d", mins, @sec) end clock += ampm $clock = clock # Clear window contents self.bitmap.clear if $clock != nil text = clock # Draw clock self.bitmap.font.color.set(255, 255, 255) self.bitmap.draw_text(self.bitmap.rect, text, 1) @timer = clock end end end end
Da inserire al posto di "Window_PlayTime" :
class Window_PlayTime < Window_Base #----------------------------------------------------------------- # * Object Initialization #----------------------------------------------------------------- def initialize super(0, 0, 160, 96) self.contents = Bitmap.new(width - 32, height - 32) refresh end #----------------------------------------------------------------- # * Refresh #----------------------------------------------------------------- def refresh self.contents.clear self.contents.font.color = system_color self.contents.draw_text(4, 0, 120, 32, "World Clock") @total_sec = Graphics.frame_count / Graphics.frame_rate $min = @total_sec / 60 % 24 @sec = @total_sec % 60 if $min == 00 $night = 1 $day =+ 1 end if $min == 12 $night = 2 end if $night == 2 ampm = " PM" mins = $min - 12 else ampm = " AM" mins = $min end if $min == 0 or $min == 12 mins = 12 end if $min == 10 clock = sprintf("d:d", mins, @sec) elsif $min == 11 clock = sprintf("d:d", mins, @sec) elsif $min == 12 clock = sprintf("d:d", mins, @sec) else clock = sprintf("d:d", mins, @sec) end clock += ampm self.contents.font.color = normal_color self.contents.draw_text(4, 32, 120, 32, clock, 2) $clock = clock end #----------------------------------------------------------------- # * Frame Update #----------------------------------------------------------------- def update super if Graphics.frame_count / Graphics.frame_rate != @total_sec refresh end end end
Modificato da Guardian of Irael, 27 March 2013 - 16:16 PM.
Screen Contest
X 2
Progetti
Gioco in sviluppo: Decay.
Team:
( MasterSion,Mercury,SimonRPG )
Direct Link:Decay-project
Tool : RpgMaker VX
Titolo : Nova Planet
Status : Lento
In cerca di un qualsiasi tipo di aiuto per dividere il lavoro
in gemellaggio con :
#45 Inviato 20 October 2009 - 22:12 PM
come posso fare??
#46 Inviato 29 December 2009 - 19:06 PM
#47 Inviato 29 December 2009 - 19:28 PM
#48 Inviato 23 March 2010 - 12:51 PM
#49 Inviato 23 March 2010 - 13:14 PM
$game_screen.start_tone_change
cambiando i 3 valori all'interno delle parentis cambi il colore in ordine sono Red-Green-Blue
Un uomo senza religione č come un pesce senza bicicletta.
#50 Inviato 23 March 2010 - 13:26 PM
Ho provato ma non cambia nulla. Questa e' la sezione dello script:
if $game_switches[1] #==true
$game_screen.start_tone_change(Tone.new(0,0,0), 5)
else
if $min < 5
$game_screen.start_tone_change(Tone.new(-170,-170,68), 20)
elsif $min >= 5 and $min < 7
$game_screen.start_tone_change(Tone.new(-51,-102,-102), 20)
elsif $min >= 7 and $min < 9
$game_screen.start_tone_change(Tone.new(0,-51,-68), 20)
elsif $min >= 9 and $min < 18
$game_screen.start_tone_change(Tone.new(0,0,0), 20)
elsif $min >= 18 and $min < 21
$game_screen.start_tone_change(Tone.new(-34,-68,-119), 20)
elsif $min >= 21
$game_screen.start_tone_change(Tone.new(-170,-170,68), 20)
La prima volta ho provato sulla prima parentesi con gli zeri ma non e' cambiato nulla, idem per entrambe,sia quella iniziale che quella sopra 18-21...o.o
Modificato da The_Grey, 23 March 2010 - 13:43 PM.
#51 Inviato 30 April 2010 - 13:12 PM
#53 Inviato 07 March 2011 - 12:21 PM
Ma adesso mi da questo errore
????? 'Sprite_Timer' ? 21 ??? SyntaxError ????????
Che cosa faccio?? Aiutoo!!! :(
#54 Inviato 07 March 2011 - 15:57 PM
Nella riga 21 c'č scritto che devi sostituire la scritta con il nome del font che usi...lo hai fatto?
^ ^
(\_/)
(^ ^) <----coniglietto rosso, me!
(> <)
Il mio Tumblr dove seguire i miei progetti, i progetti della Reverie : : Project ^ ^
disponibile su Google Play, qui i dettagli! ^ ^
completo! Giocabile online, qui i dettagli! ^ ^
REVERIE : : RENDEZVOUS (In allenamento per apprendere le buone arti prima di cominciarlo per bene ^ ^) Trovate i dettagli qui insieme alla mia intervista (non utilizzerò più rpgmaker) ^ ^
#55 Inviato 12 April 2011 - 20:50 PM
anche io ci ho provato ma non riesco a cambiare colore in nessun modo!cerca queste riga nel codice
$game_screen.start_tone_change
cambiando i 3 valori all'interno delle parentis cambi il colore in ordine sono Red-Green-Blue
#56 Inviato 02 June 2011 - 01:35 AM
cos'č che non va ?? :(
#57 Inviato 02 June 2011 - 03:07 AM
#58 Inviato 02 June 2011 - 14:46 PM
1. Non fare doppipost sono contro regolamento!
2. Se ti dā un errore specifico... posta il tipo di errore che ti dā o non possiamo aiutarti.
3. Come ti ho detto dillā la miglior cura č usare meno script possibili!
^ ^"
(\_/)
(^ ^) <----coniglietto rosso, me!
(> <)
Il mio Tumblr dove seguire i miei progetti, i progetti della Reverie : : Project ^ ^
disponibile su Google Play, qui i dettagli! ^ ^
completo! Giocabile online, qui i dettagli! ^ ^
REVERIE : : RENDEZVOUS (In allenamento per apprendere le buone arti prima di cominciarlo per bene ^ ^) Trovate i dettagli qui insieme alla mia intervista (non utilizzerò più rpgmaker) ^ ^
#59 Inviato 06 June 2012 - 19:10 PM
comunque lo script a me funziona, gli unici problemi sono:
cambio la tonalità dei colori per la notte ma, al posto di venere un colore nero rimane blu e aumenta/diminuisce di intesità O_o
partecipante a gli eventi:
PROGETTI SOSPESI:
#60 Inviato 06 June 2012 - 22:11 PM
Quando si usa uno script di ciclo giorno-notte nella maggior parte dei casi non è più possibile impostare lo screen tone tramite eventi . . .
Da un'occhiata superficiale, sembra essere così anche per questo script . . . Se mi posti la versione che usi, magari rendo disattivabile l'impostazione automatica dello screen tone basata sulla fase del giorno . . . Dovrebbe bastare l'aggiunta di un altro switch . . .