Zurück   Flashforum > Flash > ActionScript > ActionScript 1

Antwort
 
LinkBack Themen-Optionen Ansicht
Alt 10-03-2004, 01:07   #1 (permalink)
Neuer User
 
Registriert seit: Mar 2004
Beiträge: 1
watch() & setInterval()

hallo zusammen,
Ich habe folgende laufen Code. Vom dem moeschte ich noch ein/mehr function schreiben um wenn setInterval() ist ende, es wirk eine dynamic text blablabla unter dem bild display.
Wie ich weiss that watch() oder listener() koente das controlliert, aber weiss ich nicht wie ich dass machen kann.
Koennter Ihr bitte mir helfen,
vielen dank.

Cynthia

hier ist mein Code
**************************
_root.img = 0;
j=0;
picName = "cartoons0178_flash.jpg";

function loadjpg (picName) {
if (j<6){
this.createEmptyMovieClip("holder"+j, 1);
this["holder"+j]._x=0;
this["holder"+j]._y=j*45;
this["holder"+j].loadMovie(picName);
}
j++;
}

function addImg()
{
if (_root.img < 6){
loadjpg(picName);
_root.img++;
}
else{
clearInterval(idImg);
}
}
idImg = setInterval(addImg, 1000);
Cynthia ist offline   Mit Zitat antworten
Alt 10-03-2004, 10:55   #2 (permalink)
Flashaholic
 
Benutzerbild von atothek
 
Registriert seit: Feb 2003
Ort: Berlin
Beiträge: 1.459
well i think its better to talk in english.
because your german is a little confuse!

so i think what you need is a AsBroadcaster. An "own" Eventhandler thats send a broadcastmassage to every registerd listener.

search for ASBroadcaster
__________________
TVNEXT Solutions
atothek ist offline   Mit Zitat antworten
Alt 10-03-2004, 11:41   #3 (permalink)
Neuer User
 
Benutzerbild von the binary
 
Registriert seit: Jul 2001
Ort: Berlin | Friedrichshain
Beiträge: 3.561
please put your code in the 'AS'-tags in the future...


ActionScript:
  1. _root.img = 0;
  2. j=0;
  3. picName = "cartoons0178_flash.jpg";
  4.  
  5. function loadjpg (picName) {
  6. if (j<6){
  7. this.createEmptyMovieClip("holder"+j, [B] j [/B]);
  8. this["holder"+j]._x=0;
  9. this["holder"+j]._y=j*45;
  10. this["holder"+j].loadMovie(picName);
  11. }
  12. j++;
  13. }
  14.  
  15. function addImg() {
  16. if (_root.img < 6) {
  17.  loadjpg(picName);
  18. _root.img++;
  19. }
  20. else {
  21.  clearInterval( idImg);
  22. }
  23. }
  24. idImg = setInterval(addImg, 1000);


du musst die tiefe, in der di emc´s erstellt werden sollen aucg dybnamisch machen. so erstellst du alle mc´s in ebene '1'...

ausserdem werden die bilder im web sicherlich nicht innerhalb von einer minute geladen.

solltest du beachten...

gruss
__________________
8bm | join ff@BOINC
formpackage.org | audiohunter.de | problematica.de | 8ball-media.de/blog | taikonauten.cn

Geändert von the binary (10-03-2004 um 11:45 Uhr)
the binary 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 13:18 Uhr.

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


Copyright ©1999 – 2012 Marc Thiele