Just like lavaboy's footer

Alright here I go.

I’ve tried to make something like lavaboys / morse 's footer. But I have a problem

[AS]onClipEvent (load) {
y1 = getProperty(_root.pic1, _y);
}
onClipEvent (enterFrame) {
if (_root.pic1._y <= 65 && _root.pic1._y >= -95) {
speedy = -(-50+_xmouse)/8;
y1 = y1+speedy;
setProperty("_root.pic1", _y, y1);
}
}[/AS]

Pretty obvious I think, but when the pic gets lower then 65 (y) then the code totally stop.

Anybody knows a way to solve this?:sure:

why are you using depreciated code like that? you don’t need to use get/setProperty.

thats one thing


onClipEvent (load) {
        y1 = _root.pic1._y;
}
onClipEvent (enterFrame) {
        if (_root.pic1._y <= 65 && _root.pic1._y >= -95) {
                speedy = -(-50+_xmouse)/8;
                y1 = y1+speedy;
                _root.pic1._y =  y1;
        }
}

that should produce the same result as before and it doesn’t use old code. Can you attach the file so I could take a look at it? or e-mail it to me at jedick1@binghamton.edu

Sure, here with your code…

awesome I’ll take a look.

I guess your code is indeed a bit easier… Shorter…

I was thinking getproperty was needed, silly me…

try this code instead:


onClipEvent (enterFrame) {
	picHei = _root.pic1._height;
	_root.pic1._y = -(picHei * (_root._xmouse / (picHei * 2.2)));
}

i made the code even shorter. This works fine for me. let me know if you need it explained.

oh and you have to change the registration point of the MC to be at the very top. I think that is what you are going for…

oh and the code can be shortened to this


onClipEvent (enterFrame) {
	_root.pic1._y = -(_root._xmouse / 2.15);
}

here I’ll reattach the file so you can see what I mean:

Hold on, so I can reply

my mind is a little fragmented sometimes. Every time I hit the “Submit Reply” button I would remember something else. lol… sorry… :slight_smile:

Alright

Thnx a lot Jubba, cool! Such a little code an still such a cool effect…

I never tought about that! Thnx a lot

Really cool

you’re welcome. glad i helped… :slight_smile:

*Originally posted by Jubba *
**my mind is a little fragmented sometimes. Every time I hit the “Submit Reply” button I would remember something else. lol… sorry… :slight_smile: **

That’s Ok!:slight_smile:

It’s was pretty funny

Every time I wanted to respond a little text box (MSN Messenger) came and said “Some has just responded to your post”