Alucard Posted August 29, 2007 Share Posted August 29, 2007 Buon giorno raga Volevo chiedere si qualcuno può dirmi come fare a mostrare un’animazione da Script. Grazie http://cdn.last.fm/coverart/300x300/1422666.jpg Link to comment Share on other sites More sharing options...
0 amivaleo Posted December 6, 2008 Share Posted December 6, 2008 riesumo questo topic dopo 1 anno.sento puzza di muffa e c'è aria viziata... vorrei sapere se qualcuno... sa rispondere al tizio qui sopra! :Dio in particolare vorrei mostrare le animazioni degli oggetti anche quando sono usati dal menu. Link to comment Share on other sites More sharing options...
0 mikb89 Posted December 6, 2008 Share Posted December 6, 2008 sento puzza di muffa e c'è aria viziata...eeh... XD comunque se da script vuoi mostrare un animazione puoi farlo su un evento, sul/i giocatore/i e/o sui nemici con l'attributo .animation_id, per farla vedere su menu devo guardare come si può fare Script!http://pociotosi.altervista.org/_altervista_ht/RM/BarSPOP.png http://pociotosi.altervista.org/_altervista_ht/RM/Bar2P.png http://pociotosi.altervista.org/_altervista_ht/RM/BarAPU_FMOD.png http://pociotosi.altervista.org/_altervista_ht/RM/BarPBS.png http://pociotosi.altervista.org/_altervista_ht/RM/BarRM2K.png http://pociotosi.altervista.org/_altervista_ht/RM/BarAMBISOUND.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXAceOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPOK.png http://pociotosi.altervista.org/_altervista_ht/RM/RVXAceNo.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPPause.png http://pociotosi.altervista.org/_altervista_ht/RM/RVXAceOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPNo.png http://pociotosi.altervista.org/_altervista_ht/RM/RVXAceWIP.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPNo.png http://pociotosi.altervista.org/_altervista_ht/RM/RVXAceOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPSoon.png http://pociotosi.altervista.org/_altervista_ht/RM/RVXAceOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPNo.png http://pociotosi.altervista.org/_altervista_ht/RM/BarVDEBUG.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXAceOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RVXOK.pnghttp://pociotosi.altervista.org/_altervista_ht/RM/RXPOK.png http://pociotosi.altervista.org/_altervista_ht/RM/RXPOK.png Personaggi animati nei menu ¦ Tecniche combinate stile Chrono Trigger ¦ Equipaggiamento dal menù oggettihttp://pociotosi.altervista.org/_altervista_ht/RM/RVXAceOK.png Mappatura tasti ¦ Leader indipendente dal gruppo ¦ Movimenti limitati giocatore ¦ Memorizzazione permanente switch e variabili ¦ Direzione fissa avanzata ¦ Prezzo vendita oggetti personalizzato Roba scritta, guide:Un mio vecchio corso base di Ruby Link al passo 1 2 3 4 5 6 ¦ Tutorial su seno, coseno e resto Applicazioni:http://img849.imageshack.us/img849/5003/charamake64.pngmikb89's Character Maker ¦ http://img402.imageshack.us/img402/7794/rcp64.pngRM CopyPaste ¦ http://img804.imageshack.us/img804/4681/scripttemplater64.pngScript Templater ¦ http://img171.imageshack.us/img171/8703/icoconv.pngRM Chara Converter NEW Progetti!http://img69.imageshack.us/img69/2143/userbarctaf.png http://img641.imageshack.us/img641/5227/userbartemplateb.pnghttp://i46.tinypic.com/ac6id0.png Link to comment Share on other sites More sharing options...
0 Sleeping Leonhart Posted December 6, 2008 Share Posted December 6, 2008 Da quello che ho capito io le animazioni possono essere mostrate solo su degli sprite appartenti alla classe RPG::Sprite o che comunque ereditano questa classe, purtroppo non ne ho la certezza. http://img296.imageshack.us/img296/8784/csuserbarew2.pngScarica la Demo!Tutti i miei script(o quasi) li trovi Qui! Link to comment Share on other sites More sharing options...
0 giver Posted December 7, 2008 Share Posted December 7, 2008 (edited) Da quello che ho capito io le animazioni possono essere mostrate solo su degli sprite appartenti alla classe RPG::Sprite o che comunque ereditano questa classe, purtroppo non ne ho la certezza.Guardando la documentazione, ho avuto anch'io la stessa impressione . . . Comunque, uno "sprite" in rpg maker xp può essere anche un'immagine fissa/statica e vuota, cioè con solo il colore di trasparenza . . . Edited December 7, 2008 by giver SCRIPT RGSS (RPG Maker XP) VINTAGE LIBRARY [2018+]http://www.rpg2s.net/forum/index.php/topic/21892-vintagevisualsrewrite-enhanced-revised-victory-screen-v-35-da-autori-vari-a-giver/ http://www.rpg2s.net/forum/index.php/topic/21868-eventing-utility-simple-last-battle-events-fix-v-30-by-giver/ http://www.rpg2s.net/forum/index.php/topic/21853-vintagerewrite-constance-menu-per-4-personaggi-da-team-constance-a-giver/ http://www.rpg2s.net/forum/index.php/topic/22126-vintagedoveroso-necroedit-dummy-title-22u-update-per-crearlo-ad-eventi-su-mappa-by-giver/ http://www.rpg2s.net/forum/index.php/topic/22127-vintagevisuals-tale-chapters-save-system-20-by-giver/ Breaking (in ogni senso) News: "Treno deraglia per via del seno di Sakurai Aoi . . ." - Info nello spoiler !! http://afantasymachine.altervista.org/_altervista_ht/NOOOOOOOOOilMIOtreninooooo_500.gifNon riesco a smettere di essere affascinato da immagini come questa . . .http://anime.vl-vostok.ru/art/photos2011/17/78049800/wall_VladAnime_WWA_1885-1680x1050.jpgAlcuni wallpapers che faccio ruotare sul mio vecchio PC . . .http://afantasymachine.altervista.org/_altervista_ht/gits_window.jpghttp://afantasymachine.altervista.org/_altervista_ht/madoka_group01.jpghttp://afantasymachine.altervista.org/_altervista_ht/arisu_picipici_01.jpghttp://afantasymachine.altervista.org/_altervista_ht/phantom_wp01_einzwei.jpg La parte più spassosa della mia vita è quando gli altri cercano di spiegarmi i miei pensieri . . . BBCode TestingTypeface & Size Link to comment Share on other sites More sharing options...
0 Sleeping Leonhart Posted December 7, 2008 Share Posted December 7, 2008 (edited) Ci ho dormito un po sopra e ho trovato la soluzione!Allora per prima cosa ti crei uno sprite vuoto ma non con Sprite.new ma bensì con RPG::Sprite.new, poi te lo posizioni alle cordinate che vuoi tu.Dentro l'update della scena ovviamente fai l'update anche dello sprite, e quando devi richiamare un animazione usi:@sprite.animation($data_animations[ID_ANIMAZIONE], true)Ecco un esempio applicato al menu: #============================================================================== # ** Scene_Menu #------------------------------------------------------------------------------ # This class performs menu screen processing. #============================================================================== class Scene_Menu #-------------------------------------------------------------------------- # * Object Initialization # menu_index : command cursor's initial position #-------------------------------------------------------------------------- def initialize(menu_index = 0) @menu_index = menu_index end #-------------------------------------------------------------------------- # * Main Processing #-------------------------------------------------------------------------- def main # Make command window s1 = $data_system.words.item s2 = $data_system.words.skill s3 = $data_system.words.equip s4 = "Status" s5 = "Save" s6 = "End Game" @command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6]) @command_window.index = @menu_index # If number of party members is 0 if $game_party.actors.size == 0 # Disable items, skills, equipment, and status @command_window.disable_item(0) @command_window.disable_item(1) @command_window.disable_item(2) @command_window.disable_item(3) end # Crea uno sprite sul quale verrà visualizzata l'animazione @sprite = RPG::Sprite.new @sprite.x = 320 @sprite.y = 240 # If save is forbidden if $game_system.save_disabled # Disable save @command_window.disable_item(4) end # Make play time window @playtime_window = Window_PlayTime.new @playtime_window.x = 0 @playtime_window.y = 224 # Make steps window @steps_window = Window_Steps.new @steps_window.x = 0 @steps_window.y = 320 # Make gold window @gold_window = Window_Gold.new @gold_window.x = 0 @gold_window.y = 416 # Make status window @status_window = Window_MenuStatus.new @status_window.x = 160 @status_window.y = 0 # Execute transition Graphics.transition # Main loop loop do # Update game screen Graphics.update # Update input information Input.update # Frame update update # Abort loop if screen is changed if $scene != self break end end # Prepare for transition Graphics.freeze # Dispose of windows @command_window.dispose @playtime_window.dispose @steps_window.dispose @gold_window.dispose @status_window.dispose # Cancella lo sprite @sprite.dispose end #-------------------------------------------------------------------------- # * Frame Update #-------------------------------------------------------------------------- def update # Update windows @command_window.update @playtime_window.update @steps_window.update @gold_window.update @status_window.update # Aggiorna lo sprite @sprite.update # If command window is active: call update_command if @command_window.active update_command return end # If status window is active: call update_status if @status_window.active update_status return end end #-------------------------------------------------------------------------- # * Frame Update (when command window is active) #-------------------------------------------------------------------------- def update_command # If B button was pressed if Input.trigger?(Input::B) # Play cancel SE $game_system.se_play($data_system.cancel_se) # Switch to map screen $scene = Scene_Map.new return end if Input.trigger?(Input::A) # Mostra l'animazione 1 @sprite.animation($data_animations[1], true) return end # If C button was pressed if Input.trigger?(Input::C) # If command other than save or end game, and party members = 0 if $game_party.actors.size == 0 and @command_window.index < 4 # Play buzzer SE $game_system.se_play($data_system.buzzer_se) return end # Branch by command window cursor position case @command_window.index when 0 # item # Play decision SE $game_system.se_play($data_system.decision_se) # Switch to item screen $scene = Scene_Item.new when 1 # skill # Play decision SE $game_system.se_play($data_system.decision_se) # Make status window active @command_window.active = false @status_window.active = true @status_window.index = 0 when 2 # equipment # Play decision SE $game_system.se_play($data_system.decision_se) # Make status window active @command_window.active = false @status_window.active = true @status_window.index = 0 when 3 # status # Play decision SE $game_system.se_play($data_system.decision_se) # Make status window active @command_window.active = false @status_window.active = true @status_window.index = 0 when 4 # save # If saving is forbidden if $game_system.save_disabled # Play buzzer SE $game_system.se_play($data_system.buzzer_se) return end # Play decision SE $game_system.se_play($data_system.decision_se) # Switch to save screen $scene = Scene_Save.new when 5 # end game # Play decision SE $game_system.se_play($data_system.decision_se) # Switch to end game screen $scene = Scene_End.new end return end end #-------------------------------------------------------------------------- # * Frame Update (when status window is active) #-------------------------------------------------------------------------- def update_status # If B button was pressed if Input.trigger?(Input::B) # Play cancel SE $game_system.se_play($data_system.cancel_se) # Make command window active @command_window.active = true @status_window.active = false @status_window.index = -1 return end # If C button was pressed if Input.trigger?(Input::C) # Branch by command window cursor position case @command_window.index when 1 # skill # If this actor's action limit is 2 or more if $game_party.actors[@status_window.index].restriction >= 2 # Play buzzer SE $game_system.se_play($data_system.buzzer_se) return end # Play decision SE $game_system.se_play($data_system.decision_se) # Switch to skill screen $scene = Scene_Skill.new(@status_window.index) when 2 # equipment # Play decision SE $game_system.se_play($data_system.decision_se) # Switch to equipment screen $scene = Scene_Equip.new(@status_window.index) when 3 # status # Play decision SE $game_system.se_play($data_system.decision_se) # Switch to status screen $scene = Scene_Status.new(@status_window.index) end return end end end Premendo Shift si vede l'animazione 1 al centro dello schermo. Edited December 7, 2008 by Sleeping Leonhart http://img296.imageshack.us/img296/8784/csuserbarew2.pngScarica la Demo!Tutti i miei script(o quasi) li trovi Qui! Link to comment Share on other sites More sharing options...
0 amivaleo Posted December 21, 2008 Share Posted December 21, 2008 grazie leon! funziona e l'effetto non è niente male!il tuo è il nick che appare più spesso tra i miei crediti! Link to comment Share on other sites More sharing options...
Question
Alucard
Buon giorno raga
Volevo chiedere si qualcuno può dirmi come fare a mostrare un’animazione da Script. Grazie
Link to comment
Share on other sites
6 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now