Zurück   Flashforum > Flash > ActionScript > Softwarearchitektur und Entwurfsmuster

Antwort
 
LinkBack Themen-Optionen Ansicht
Alt 12-01-2005, 19:08   #106 (permalink)
Freizeitflasher
 
Registriert seit: Aug 2004
Ort: Hamburg
Beiträge: 32
Ha, ich hatte es gerade gepostet, da fiel mir ein, woran es liegen könnte. Jetzt läuft es.

Ich hatte nur probeweise bei einem Rechteck das easing eingefügt, beim anderen lief das mit 'rect_animator.run(200);'. Das kam sich wohl irgendwie in die Quere. Nun ja. (:

Gruß, gringle

Geändert von gringle (12-01-2005 um 19:17 Uhr)
gringle ist offline   Mit Zitat antworten
Alt 12-01-2005, 19:25   #107 (permalink)
Pixelschieber
 
Registriert seit: Aug 2004
Ort: Berlin
Beiträge: 41
@gringle: poste mal trotzdem pls, oder schicks privat, vielleicht komm ich durch Dich ja auf 'ne Lösung?! Bin leider immernoch kein Stück weiter...
Angehängte Dateien
Dateityp: zip resize.zip (6,9 KB, 8x aufgerufen)

Geändert von _chg (12-01-2005 um 20:09 Uhr)
Timo S. ist offline   Mit Zitat antworten
Alt 12-01-2005, 23:43   #108 (permalink)
Freizeitflasher
 
Registriert seit: Aug 2004
Ort: Hamburg
Beiträge: 32
@_chg: Ich glaube nicht, dass dir das helfen würde, bei genauerem Hinsehen ist dein Problem doch was ganz anderes. Ich hab mal ein wenig herumgebastelt, jetzt läuft es, dafür kommt es aber aber wieder zum Aufflackern von Rechtecken, wie bei mir vorher beschrieben. Vielleicht kannst du das ja lösen, oder jemand anderes weiss hier dazu Rat. Ich guck morgen auch nochmal.

Gruß, gringle.
Angehängte Dateien
Dateityp: rar resize.rar (6,9 KB, 10x aufgerufen)

Geändert von gringle (13-01-2005 um 00:11 Uhr)
gringle ist offline   Mit Zitat antworten
Alt 13-01-2005, 07:08   #109 (permalink)
Neuer User
 
Benutzerbild von K-Grabowski
 
Registriert seit: Jan 2003
Ort: Arminia!!!! Bielefeld
Beiträge: 1.138
das Problem ist das du bei jedem resizeClip-Aufruf einen neuen Scaler kreierst, und wenn man schnell klickt laufen die halt gleichzeitig ab und stören sich gegenseitig. Definiere deinen Scale ausserhalb deiner Funktion als MC-Variable, außerdem solltest du den Scaler explicit stoppen bevor du ihn überschreibst:

ActionScript:
  1. var myScale:Scale;
  2.  
  3. function resizeClip(newWidth,newHeight)
  4. {
  5.     myScale.stop();
  6.     myScale = new Scale(panelClip,newWidth,newHeight);
  7.     myScale.animationStyle(1000,[Elastic.easeOut,4]);
  8.     myScale.run();
  9.    
  10. }
__________________
Wieviel hätte ich also für dieses Fahrzeug zu investieren???
K-Grabowski ist offline   Mit Zitat antworten
Alt 13-01-2005, 07:11   #110 (permalink)
Neuer User
 
Benutzerbild von K-Grabowski
 
Registriert seit: Jan 2003
Ort: Arminia!!!! Bielefeld
Beiträge: 1.138
@_chg

so klappts
ActionScript:
  1. var myScale:Scale
  2.  
  3. function resizeClip(newWidth,newHeight)
  4. {
  5.     myScale.stop();
  6.     myScale = new Scale(panelClip,newWidth,newHeight);
  7.     myScale.addEventListener("onUpdate",this);
  8.     myScale.animationStyle(1000,[Elastic.easeOut,4]);
  9.     myScale.animate(0,100);
  10. }
__________________
Wieviel hätte ich also für dieses Fahrzeug zu investieren???
K-Grabowski ist offline   Mit Zitat antworten
Alt 13-01-2005, 10:07   #111 (permalink)
Pixelschieber
 
Registriert seit: Aug 2004
Ort: Berlin
Beiträge: 41
Thumbs up Tadaaaa!

Exquisit! Herzlichen Dank! Und schon macht das AP wieder Spass! Danke, K-Grabowski, Danke Alex! *so nun aber weiterbasteln*
Timo S. ist offline   Mit Zitat antworten
Alt 03-02-2005, 15:25   #112 (permalink)
Neuer User
 
Registriert seit: Sep 2003
Ort: Berlin
Beiträge: 20
problem mit Parallel/Shake/Blur

hi bin gerade am rumtesten mit dem animation package und hab da folgendes problem:

funktionert eigentlich alles ganz schick außer wenn ich parallel shake und blur benutze. kann mir das leider nicht erklären, denn wenn ich addChild nicht benutze funktionierts. was bedeutet: Typdiskrepanz.

this.shakeNBlurStart = function(mc){
#include "AnimationPackage.as"
APCore.initialize();
//
var myListener:Object = new Object();
APCore.addListener(myListener);
//
var myShake:Shake = new Shake(mc).run(.4,1000);
var myBlur:Blur = new Blur(mc).put(2,10,0,0);
var myParallel:Parallel = new Parallel();
myParallel.addChild(myShake);
myParallel.addChild(myBlur);
myParallel.animationStyle(2000,Circ.easeInOut,"onP arallelBlurShakeEnd");
myParallel.animate(0,100);
myListener.onParallelBlurShakeEnd = function(source) {
trace("onParallelBlurShakeEnd");
}
}
this.shakeNBlurStart(this.aa_mc.bb_mc);

diese fehlermeldung wird mir leider ausgespuckt:
**Fehler** Szene=Szene 1, Ebene=blur, Bild=1:Zeile 8: Typenkonflikt in Zuweisungsanweisung: Void gefunden, aber de.alex_uhlmann.animationpackage.animation.Shake wird benötigt.
var myShake:Shake = new Shake(mc).run(.4,1000);

**Fehler** Szene=Szene 1, Ebene=blur, Bild=1:Zeile 9: Typenkonflikt in Zuweisungsanweisung: Void gefunden, aber de.alex_uhlmann.animationpackage.animation.Blur wird benötigt.
var myBlur:Blur = new Blur(mc).put(2,10,0,0);

**Fehler** Szene=Szene 1, Ebene=blur, Bild=1:Zeile 11: Typdiskrepanz.
myParallel.addChild(myShake);

**Fehler** Szene=Szene 1, Ebene=blur, Bild=1:Zeile 12: Typdiskrepanz.
myParallel.addChild(myBlur);
cinco_caballero ist offline   Mit Zitat antworten
Alt 03-02-2005, 19:55   #113 (permalink)
Entwickler
 
Registriert seit: Apr 2002
Ort: Edinburgh, UK
Beiträge: 301
Moin,

2 Fehler:

Zitat:
Zitat von cinco_caballero
var myShake:Shake = new Shake(mc).run(.4,1000);
var myBlur:Blur = new Blur(mc).put(2,10,0,0);
falsche Syntax. Du weist den Rückgabewert von run() und put() (das wäre nichts, also Void) auf eine Shake und eine Blur Instanz. Das würde aber z.B. funktioneren:

ActionScript:
  1. var myShake:Shake = new Shake(mc);
  2. myShake.run(.4,1000);
  3. var myBlur:Blur = new Blur(mc)
  4. myBlur.put(2,10,0,0);

dann ist Blur und Shake noch nicht kompatibel zum IAnimatable Interface. Parallel nimmt aber nur IAnimatable Instanzen auf, weil bestimmte Funktionalität z.B. die animate Methode in Parallel benötigt wird. Ich muss mal schauen, vielleicht schaffe ich für nächstes Release das zu ändern. Ich werde in den nächsten Tagen hier die nächste Beta zu 1.05 posten.

Gruss,
Alex
__________________
Open Source ActionScript Lib AnimationPackage
Alex U. ist offline   Mit Zitat antworten
Alt 04-02-2005, 15:35   #114 (permalink)
Neuer User
 
Registriert seit: Sep 2003
Ort: Berlin
Beiträge: 20
danki well

danke für den tip. geht jetzt.

freu mich auf das update.
cinco_caballero ist offline   Mit Zitat antworten
Alt 06-02-2005, 22:40   #115 (permalink)
Entwickler
 
Registriert seit: Apr 2002
Ort: Edinburgh, UK
Beiträge: 301
Moin Leute,

habe gerade AnimationPackge 1.05 Beta 4 hochgeladen. Diesmal gibt es sehr viele Erweiterungen für ein Beta Update. AP 1.05 könnte ein insgesamt sehr umfangreiches Update werden.


Hier alle Updates:
http://www.alex-uhlmann.de/flash/ani...le/history.htm

Also, sagt Bescheid falls euch etwas aufällt. Noch ist AP in der Beta und die Dinge sind leichter zu ändern.

Gruss,
Alex
__________________
Open Source ActionScript Lib AnimationPackage
Alex U. ist offline   Mit Zitat antworten
Alt 07-04-2005, 11:21   #116 (permalink)
Entwickler
 
Registriert seit: Apr 2002
Ort: Edinburgh, UK
Beiträge: 301
Version 1.05 ist fertig:

http://www.alex-uhlmann.de/flash/ani...ge/history.htm

Viel Spass,
Alex
__________________
Open Source ActionScript Lib AnimationPackage
Alex U. ist offline   Mit Zitat antworten
Alt 07-04-2005, 12:00   #117 (permalink)
helpQLODhelp
 
Benutzerbild von bokel
 
Registriert seit: Feb 2002
Ort: Köln
Beiträge: 8.505
Herzlichen Glückwunsch zu dem neuen Release.
Die neuen Features sehen sehr gut aus.

mfg. r.
bokel ist offline   Mit Zitat antworten
Alt 23-09-2005, 20:31   #118 (permalink)
Entwickler
 
Registriert seit: Apr 2002
Ort: Edinburgh, UK
Beiträge: 301
Hi Leute,

hier ein kleines Update bevor eine Flash 8 Version von AP herauskommt.

http://www.alex-uhlmann.de/flash/ani...kage/unstable/

Doku kommt noch deshalb hier nur eine kurze Erklaerung was sich geaendert hat. Feedback ist wie immer sehr willkommen!!!






<schnipp>
This is the last version before a Flash 8 version comes up. The current version here

http://www.alex-uhlmann.de/flash/ani...kage/unstable/

doesn’t contain an updated documentation yet. So here’s what changed with a couple of questions to you:


There are two new features that might affect existing code and I'm therefore not too sure if it's a good idea. Let me know if you don't think it's a good idea.


Feature 1:

AP now by default stops instances, which animate on the same property/method and object. This might come in handy if you want quickly create button animations as in:

ActionScript:
  1. mc.onRollOver = function() {
  2.     var myScale:Scale = new Scale(this,150,150);
  3.     myScale.animationStyle(500, Circ.easeOut);
  4.     myScale.animate(0,100)
  5. }
  6.  
  7. mc.onRollOut = function() {
  8.     var myScale:Scale = new Scale(this,50,50);
  9.     myScale.animationStyle(500, Circ.easeIn);
  10.     myScale.animate(0,100);
  11. }

If one button event triggers a Scale instance and another Scale instance is still animating on the same properties of movieclip mc, the currently animating Scale instance will be stopped. Previously you had to do this yourself to prevent flickering, which requires to hold state of both Scale instances and invoke the stop() method yourself. Small thing you might say, but problems related to this was the most asked question I've received about AP.

In case you have some existing code using AP on your hand, it would be a help for me if you tell me if something unexpected happens with this version.

If it does you can switch back to
AnimationCore.setOverwriteModes(false);

And let me know if you have ideas for a better naming.


Feature 2:

Every IAnimatable instance can specifiy the tween engine to use for itself. That means either onEnterFrame - based or setInterval – based.

The new methods on IAnimatable are

ActionScript:
  1. public function getTweenMode(Void):String; public function setTweenMode(tweenMode:String):Boolean;
  2. public function getDurationMode(Void):String; public function setDurationMode(durationMode:String):Boolean;

In addition I've renamed the static properties on AnimationCore that affect all instances from i.e. setTweenMode to setTweenModes. So, old code using this functionality will break and should not compile.



Here's an example:

Default is INTERVAL, which means via setInterval (mx.effects.Tween), and durationMode MS, which means milliseconds.

ActionScript:
  1. //change globally to frame based tweening AnimationCore.setTweenModes(AnimationCore.FRAMES);
  2.  
  3. //tween in 100 frames
  4. var myScale:Scale = new Scale(mc,150,150);
  5. myScale.animationStyle(100, Circ.easeInOut);
  6. myScale.animate(0,100);
  7.  
  8. //override global tween mode with setInterval tweening.
  9. var myMove:Move = new Move(mc2,mc2._x+100,mc2._y); myMove.setTweenMode(AnimationCore.INTERVAL);
  10. myMove.animationStyle(1000, Circ.easeInOut);
  11. myMove.animate(0,100);
  12.  
  13. //use the global frame based tweening with a local duration mode var myRotation:Rotation = new Rotation(mc3,360); myRotation.setDurationMode(AnimationCore.MS);
  14. myRotation.animationStyle(duration, Circ.easeInOut); myRotation.animate(0,100);

Let me know if you have further ideas about naming here.

Furthermore there has been some bug fixing and minor improvements going on, especially in Animation. In case you ever had problems with that class, try again in this version.

</schnapp>

Gruss,
Alex
__________________
Open Source ActionScript Lib AnimationPackage
Alex U. ist offline   Mit Zitat antworten
Alt 27-09-2005, 14:22   #119 (permalink)
Neuer User
 
Benutzerbild von K-Grabowski
 
Registriert seit: Jan 2003
Ort: Arminia!!!! Bielefeld
Beiträge: 1.138
hi,

es hat sich durch die Änderungen in der ColorTransform und in der ColorDodge (andere nicht getestet) ein Fehler eingeschlichen.

bei folgendem Code verfärbt sich nur der dritte mc.

ActionScript:
  1. import de.alex_uhlmann.animationpackage.animation.*;
  2. import com.robertpenner.easing.*;
  3.  
  4. function mcColorDodge (but, color) {
  5.     but.anim = new ColorDodge(but);
  6.     but.anim.animationStyle(2000, Circ.easeOut);
  7.     but.anim.run(color);
  8. }
  9.  
  10. mcColorDodge(mc1, 0x00FF00);
  11. mcColorDodge(mc2, 0x00FF00);
  12. mcColorDodge(mc3, 0x00FF00);
__________________
Wieviel hätte ich also für dieses Fahrzeug zu investieren???

Geändert von K-Grabowski (27-09-2005 um 14:26 Uhr)
K-Grabowski ist offline   Mit Zitat antworten
Alt 27-09-2005, 14:30   #120 (permalink)
Entwickler
 
Registriert seit: Apr 2002
Ort: Edinburgh, UK
Beiträge: 301
Yo, das ist ein Bug und ich weis auch woran es liegt. Morgen kommt die naechste Version. Vielen Dank.

Alex
__________________
Open Source ActionScript Lib AnimationPackage
Alex U. 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 12:54 Uhr.

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


Copyright ©1999 – 2012 Marc Thiele