Zurück   Flashforum > Flash > ActionScript > ActionScript 1

Antwort
 
LinkBack Themen-Optionen Ansicht
Alt 28-07-2004, 11:11   #1 (permalink)
Flashnoob<-->CS PG
 
Registriert seit: Jul 2004
Beiträge: 63
LOL mal wieder ne Frage...x und y positionen

Hallo,

ich möchte jetzt, dass sich 2 Bilder über meine Bühne bewegen, allerdings soll das 2. erst anfangen wenn das erste beim ende der Bühne ist.

habs mir so gedacht:
_root._x=-252.0
_root._y=225.0
_root.auto2._x+=0;
_root.auto2._y+=0;
_root.auto._x+=10;

if(_root.auto_x!=500){
_root.auto2._x+=10;
}

nur irgendwie funzt dat nich!
__________________
90% aller Pc Probleme sitzen 20 cm vorm Monitor!
Sash^noob ist offline   Mit Zitat antworten
Alt 28-07-2004, 11:23   #2 (permalink)
Achim Math.PI
 
Benutzerbild von bloba
 
Registriert seit: Jul 2001
Ort: cool Colonia
Beiträge: 11.642
mach es doch so
PHP-Code:
var tl this;
MovieClip.prototype.move = function(speed) {
    if (
this._x<=Stage.width) {
        
this._x += speed;
    }
};
tl.onEnterFrame = function() {
    if (
car1._x<=Stage.width) {
        
car1.move(25);
    } else {
        
car2.move(25);
    }
}; 
__________________
gruß bloba

2 x onkel² b_d
bloba ist offline   Mit Zitat antworten
Alt 28-07-2004, 11:27   #3 (permalink)
Flashnoob<-->CS PG
 
Registriert seit: Jul 2004
Beiträge: 63
das funzt irgendwie auch nich!
__________________
90% aller Pc Probleme sitzen 20 cm vorm Monitor!
Sash^noob ist offline   Mit Zitat antworten
Alt 28-07-2004, 12:11   #4 (permalink)
Achim Math.PI
 
Benutzerbild von bloba
 
Registriert seit: Jul 2001
Ort: cool Colonia
Beiträge: 11.642
so
PHP-Code:
var tl this;
MovieClip.prototype.move = function(speed) {
    if (
this._x<=Stage.width-50) {
        
this._x += speed;
    }
};
tl.onEnterFrame = function() {
    if (
car1._x<=Stage.width-50) {
        
car1.move(5);
    } else {
        
car2.move(15);
    }
}; 
Angehängte Dateien
Dateityp: rar geht.rar (2,2 KB, 2x aufgerufen)
__________________
gruß bloba

2 x onkel² b_d
bloba ist offline   Mit Zitat antworten
Alt 28-07-2004, 12:20   #5 (permalink)
Flashnoob<-->CS PG
 
Registriert seit: Jul 2004
Beiträge: 63
kannste mir auch erklären wie dat funktioniert???

var tl = this; //<-- was bedeuted das?
MovieClip.prototype.move = function(speed) {//<-- was bedeuted das?
if (this._x<=Stage.width-50) {//<-- warum -50?
this._x += speed;
}
};
tl.onEnterFrame = function() { //<--versteh ich auch nicht ganz!
if (car1._x<=Stage.width-50) {
car1.move(5);
} else {
car2.move(15);
}
};

Wäre dir sehr dankbar!
__________________
90% aller Pc Probleme sitzen 20 cm vorm Monitor!
Sash^noob ist offline   Mit Zitat antworten
Alt 28-07-2004, 12:44   #6 (permalink)
Flashnoob<-->CS PG
 
Registriert seit: Jul 2004
Beiträge: 63
Exclamation

-50 hat sich erledigt....bin im moment ne bischen begriffsstutzig!

Aber die anderen bitte! Wenn es geht! Dann biste mein Held...wenn ichs auch noch versteh küss ich dir die Füße!"
__________________
90% aller Pc Probleme sitzen 20 cm vorm Monitor!
Sash^noob ist offline   Mit Zitat antworten
Alt 28-07-2004, 13:02   #7 (permalink)
Flashnoob<-->CS PG
 
Registriert seit: Jul 2004
Beiträge: 63
Gibt es eigentlich eine Möglichkeit, dass die Bilder quasi geloopt werden, dass die beiden Hintereinander durchfahren aber dann die Platz zwischen denen entsteht?
__________________
90% aller Pc Probleme sitzen 20 cm vorm Monitor!
Sash^noob ist offline   Mit Zitat antworten
Antwort

Lesezeichen

Themen-Optionen
Ansicht

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks sind an
Pingbacks sind an
Refbacks sind an



Alle Zeitangaben in WEZ +1. Es ist jetzt 19:03 Uhr.

Domains, Webhosting & Vserver von Host Europe
Unterstützt das Flashforum!
Adobe User Group


Copyright ©1999 – 2012 Marc Thiele