# Percentage preload and transition tutorial

**URL:** <https://forum.kirupa.com/t/percentage-preload-and-transition-tutorial/93665>\
**Category:** Uncategorized\
**Created:** [November 3, 2003, 4:56pm UTC](https://forum.kirupa.com/t/percentage-preload-and-transition-tutorial/93665 "2003-11-03T16:56:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ubik](https://avatars.discourse-cdn.com/v4/letter/u/b38774/32.png) [@Ubik](https://forum.kirupa.com/u/Ubik)\
**Post date:** [November 3, 2003, 4:56pm UTC](https://forum.kirupa.com/t/percentage-preload-and-transition-tutorial/93665/1 "2003-11-03T16:56:12Z")

</div>

Is it possible to apply a preloader with a progress bar and the percentage display on the transition effect instead of just having a animation and “loading”.  
I’m using a modified version a tutorial i found here, here’s the code of the preloader :  
[AS]bytes\_loaded = Math.round(this.getBytesLoaded());  
bytes\_total = Math.round(this.getBytesTotal());  
getPercent = bytes\_loaded/bytes\_total;  
this.loadBar.\_width = getPercent_this.loadBarBorder.\_width;  
this.loadText = Math.round(getPercent_100)+"%";  
this.loadingClip.gotoAndStop(Math.round(getPercent\*19)+1);  
if (getPercent == 1) {  
this.gotoAndStop(3);  
}  
[/AS]

My question is where to put this script and the preloader animation  
Here’s the two files (i’ll put them into file) :
