Wow? Are you coding for Flash 4?
I am going to go through this with Flash 5+ syntax, but please feel free to revert it back to what you had before.
_root timeline Frame 1 actions…
// initial direction of drop_dateClip
direction = 0;
// date/time
days = new Array('Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday');
months = new Array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');
timedate = new Date();
todaydate = timedate.getDate();
day = timedate.getDay();
month = timedate.getMonth();
year = timedate.getFullYear();
dayname = days[day];
monthname = months[month];
clockH = timedate.getHours();
clockM = timedate.getMinutes();
clockS = timedate.getSeconds();
if (clockH<10) {
clockH = "0"+clockH;
}
if (clockM<10) {
clockM = "0"+clockM;
}
if (clockS<10) {
clockS = "0"+clockS;
}
drop_dateClip.fulldate.text = dayname+", "+monthname+" "+todaydate+", "+year;
timeClip.fulltime.text = clockH+": "+clockM+": "+clockS;
drop dateClip frame 1 actions…
stop();
_parent.drop_dateClip = this;
originalPos = _y;
openPos = _y+_height;
drop dateClip frame 2 actions…
oldPos = _y;
newPos = oldPos+(direction*5);
if (direction == -1 and newPos>=originalPos) {
this._y = newPos;
}
if (direction == 1 and newPos<=openPos) {
this._y = newPos;
}
Timeclip frame 1 actions
_parent._parent.timeClip = this;
(requires 2 _parents because it is located in a clip in a clip).
Time Layer Button…
on (rollOver) {
drop_dateClip.play();
drop_dateClip.direction = 1;
}
on (rollOut) {
drop_dateClip.play();
drop_dateClip.direction = -1;
}
That is all. It worked great for me. Just had to change all the locators. And that old syntax (unless your coding for Flash 4) had to go :-\