Pagina 1 di 2 1 2 ultimoultimo
Visualizzazione dei risultati da 1 a 10 su 15

Discussione: Problemino MovieText

  1. #1

    Problemino MovieText

    Salve ragazzi,

    come posso far partire questo testo senza premere il pulsante btn3_1, ma in modo automatico?

    Codice PHP:
    btn3_1.onMouseMove = function() {
        
    typeWriter.effect1(4,yaz4,"Salve, come faccio a partire da solo. ");
    }; 

  2. #2
    dici partire all'avvio?

  3. #3
    Si appena apro il filmato

  4. #4
    allora nel primo frame metti il codice:
    Codice PHP:
    onLoad = function() {
    typeWriter.effect1(4,yaz4,"tua scritta"); 


  5. #5
    No. Non va

  6. #6
    Questo è il codice di typeWriter

    Codice PHP:
    prew._visible false//hide visible text (textWriter:)
    kontrol.gotoAndStop(15); //setting the moving point for effect
    //*****************************************************************************
    //tweening function ***********************************************************
    import mx.transitions.*;
    import mx.transitions.easing.*;
    function 
    hare(mcpropertYneWValueolDValuespeed) {
        new 
    Tween(mcpropertYStrong.easeInOutolDValueneWValuespeedtrue);
    }
    //end tweening function *******************************************************
    //*****************************************************************************
    var a:Number=1//create movie order
    var firstHand:MovieClip//current effect temporary movie for effect1
    var secondHand:MovieClip//current effect temporary movie for effect2
    var thirdHand:MovieClip//current effect temporary movie for effect3
    function effect1(spEed:NumbertextFielD:TextFieldinpuTText:String):Void {
        
    delete firstHand.onEnterFrame//delete the previous effect.
        
    firstHand.removeMovieClip(); //remove the old temporary movie clip.
        
    var mc this.createEmptyMovieClip("aa"+aa); //create a new temporary movie clip
        
    firstHand mc //adding the current temporary movie clip
        
    a++; //movie order increase
        
    var temporaryMc:MovieClip mc;
        var 
    cOunter:Number 1//counter for animate
        
    var temporaryText:String//create a temporary string object
        
    var animatedText:String textFielD.text//create a string object for slicing text
        
    var temporaryAnimatedText:String//create a temporary animated string object
        
    var tmp:String "";
        var 
    outpuTText:String ""//finally text.
        
    var stringLength:Number 50;
        if (
    inpuTText.length>animatedText.length) { //setting counter according to old or new text length.
            
    stringLength inpuTText.length//if new text length bigger then old text length, the length set new text length
        
    } else {
            
    stringLength animatedText.length//if old text length bigger then new text length, the length set old text lenght
        
    }
        
    temporaryMc.onEnterFrame = function():Void  
            
    temporaryText substring(inpuTTextcOunterspEed); //cutting current text
            
    temporaryAnimatedText animatedText.slice(cOunteranimatedText.length); //setting the animated text
            
    tmp += temporaryText//while animation, wrting the current text
            
    cOunter += spEed//sub, speed and counter
            
    textFielD.htmlText outpuTText.concat(tmptemporaryAnimatedText); //last process,  text is added to text field
            
    if (cOunter>(stringLength+spEed)) { //finishing the animation.
                
    delete temporaryMc.onEnterFrame;
                
    temporaryMc.removeMovieClip();
            }
        };
    }
    function 
    effect2(spEed:NumbertextFielD1:TextFieldtextFielD2:TextFieldinpuTText:String):Void {
        
    delete secondHand.onEnterFrame//delete the previous effect.
        
    secondHand.removeMovieClip(); //remove the old temporary movie clip.
        
    var mc this.createEmptyMovieClip("aa"+aa); //create a new temporary movie clip
        
    secondHand mc //adding the current temporary movie clip
        
    a++; //movie order increase
        
    var temporaryMc:MovieClip mc;
        var 
    cOunter:Number 1//counter for animate
        
    var temporaryText:String//create a temporary string object
        
    var animatedText:String textFielD1.text//create a string object for slicing text
        
    var temporaryAnimatedText:String//create a temporary animated string object
        
    var tmp:String "";
        var 
    outpuTText:String ""//finally text.
        
    var stringLength:Number 50;
        
    textFielD2.text animatedText;
        if (
    inpuTText.length>animatedText.length) { //setting counter according to old or new text length.
            
    stringLength inpuTText.length//if new text length bigger then old text length, the length set new text length
        
    } else {
            
    stringLength animatedText.length//if old text length bigger then new text length, the length set old text lenght
        
    }
        
    temporaryMc.onEnterFrame = function():Void  {
            
    temporaryText substring(inpuTTextcOunterspEed);//cutting current text
            
    temporaryAnimatedText animatedText.slice(cOunteranimatedText.length); //setting the animated text
            
    tmp += temporaryText//while animation, wrting the current text
            
    cOunter += spEed;  //sub, speed and counter
            
    textFielD1.htmlText tmp;
            
    textFielD2.htmlText outpuTText.concat(tmptemporaryAnimatedText); //last process,  text is added to text field
            
    if (cOunter>(stringLength+spEed)) { //finishing the animation.
                
    delete temporaryMc.onEnterFrame;
                
    temporaryMc.removeMovieClip();
            }
        };
    }
    function 
    effect3(spEed:NumbertextFielD1:TextFieldinpuTText:String):Void {
        
    delete thirdHand.onEnterFrame//delete the previous effect.
        
    thirdHand.removeMovieClip(); //remove the old temporary movie clip.
        
    var mc this.createEmptyMovieClip("aa"+aa); //create a new temporary movie clip
        
    thirdHand mc //adding the current temporary movie clip
        
    a++; //movie order increase
        
    var temporaryMc:MovieClip mc;
        var 
    cOunter:Number 1//counter for animate
        
    var temporaryText:String//create a temporary string object
        
    var animatedText:String textFielD1.text//create a string object for slicing text
        
    var temporaryAnimatedText:String//create a temporary animated string object
        
    var tmp:String "";
        var 
    outpuTText:String ""//finally text.
        
    var stringLength:Number 50;
        
    textFielD1.autoSize true;
        if (
    stringLength<inpuTText.length) { //setting counter according to old or new text length.
            
    if (inpuTText.length<animatedText.length) {
                
    stringLength animatedText.length//if new text length bigger then old text length, the length set new text length
            
    } else {
                
    stringLength inpuTText.length//if old text length bigger then new text length, the length set old text lenght
            
    }
        }
        
    kontrol.tekst textFielD1//setting, up down moving text box
        
    kontrol.play(); //animate start.
        
    temporaryMc.onEnterFrame = function():Void  {
            
    temporaryText substring(inpuTTextcOunterspEed); //cutting current text
            
    temporaryAnimatedText animatedText.slice(cOunteranimatedText.length);  //setting the animated text
            
    tmp += temporaryText//while animation, wrting the current text
            
    cOunter += spEed;  //sub, speed and counter
            
    textFielD1.htmlText outpuTText.concat(tmptemporaryAnimatedText);//last process,  text is added to text field
            
    if (cOunter>(stringLength+spEed)) {
                
    delete temporaryMc.onEnterFrame;
                
    temporaryMc.removeMovieClip();
                
    kontrol.gotoAndStop(15);
            }
        };


  7. #7
    che versione di action script usi?

  8. #8
    AS2

    ho notato una cosa.

    Se io i faccio un filmatino di prova e metto tutto sul primo frame funziona onLoad se pero tutto e messo in un'istanza non funziona più. Non se mi sono spiegato bene

  9. #9
    Però se c'è il pulsante anche se è dentro un'istanza funziona sempre

  10. #10
    prova a mettere:

    Codice PHP:
    nome_istanza.onLoad = function() {
    typeWriter.effect1(4,yaz4,"tua scritta");


Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.