Movie progress bar

  • garryd
  • Born
  • Born
  • garryd
  • Posts: 3

Post 3+ Months Ago

hey guys, is there a way I can create a movie progress bar with moving play head?

The movie the play head will control and show the progress of will be an externally loaded swf.
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • rynoe
  • Banned
  • Banned
  • User avatar
  • Posts: 17

Post 3+ Months Ago

Do you mean a preloader bar?
  • Sulfin
  • Graduate
  • Graduate
  • User avatar
  • Posts: 129
  • Loc: canada

Post 3+ Months Ago

This code is for the preloader percent:
Code: [ Select ]
this.onEnterFrame = function() {
  percentLoaded=Math.round((_root.getBytesLoaded()/_root.getBytesTotal())*100)+"%";
};
  1. this.onEnterFrame = function() {
  2.   percentLoaded=Math.round((_root.getBytesLoaded()/_root.getBytesTotal())*100)+"%";
  3. };

This code is for the progress percent:
Code: [ Select ]
this.onEnterFrame = function() {
  percentPlayed=Math.round((_root._currentframe/_root._totalframes)*100)+"%";
};
  1. this.onEnterFrame = function() {
  2.   percentPlayed=Math.round((_root._currentframe/_root._totalframes)*100)+"%";
  3. };

You have to put this code on the first frame of your movie and you can only put one of them unless you put them both together in the same onEnterFrame. Should work!
P.S. Post if you wan't more info.
  • OriginNO
  • Graduate
  • Graduate
  • User avatar
  • Posts: 137
  • Loc: the Glass City (Hometown: the NO)

Post 3+ Months Ago

This script will give you the percent loaded, KB loaded, and KB total.

You will need to make 3 dynamic text fields and make their vriable names c, d, e.

Add this script to the first frame.
Code: [ Select ]
a = getBytesLoaded();
b = getBytesTotal();
c = Math.ceil((a/b)*100)+"%";
d = Math.floor(a/1024)+"KB Has Loaded";
e = Math.floor(b/1024)+"KB Total";
if (A == B) {
  nextScene ();
}
  1. a = getBytesLoaded();
  2. b = getBytesTotal();
  3. c = Math.ceil((a/b)*100)+"%";
  4. d = Math.floor(a/1024)+"KB Has Loaded";
  5. e = Math.floor(b/1024)+"KB Total";
  6. if (A == B) {
  7.   nextScene ();
  8. }


Put this action in the second frame.
Code: [ Select ]
gotoAndPlay (1);
  • SharkShark
  • Guru
  • Guru
  • User avatar
  • Posts: 1013
  • Loc: Living In Today

Post 3+ Months Ago

Do an Ozzu search for preloaders. This type of question has been asked numerous times.

Post Information

  • Total Posts in this topic: 5 posts
  • Users browsing this forum: No registered users and 10 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.