Hi There, I'm new here and new to Director. I hope someone will take pity on me. I have produced a scrolling behaviour
using this code but when moving outside the sprite containing the behaviour, the behaviour continues and I want it to stop!
on mouseWithin me
ScrollVal = 0
MiddleVal = 400
NewV = 0
OffsetV = 0
ScrollVal = 300 - the mouseV
OffsetV = ScrollVal / 10
NewV = sprite(34).LocV + OffsetV
if NewV > -130 then
if NewV < 704 then
sprite(34).LocV = sprite(34).LocV + OffsetV
end if
end if
updateStage
end mouseWithin
Maybe I should use a standard scrollbar but I'd rather not.
Thanks in advance
Psymon
using this code but when moving outside the sprite containing the behaviour, the behaviour continues and I want it to stop!
on mouseWithin me
ScrollVal = 0
MiddleVal = 400
NewV = 0
OffsetV = 0
ScrollVal = 300 - the mouseV
OffsetV = ScrollVal / 10
NewV = sprite(34).LocV + OffsetV
if NewV > -130 then
if NewV < 704 then
sprite(34).LocV = sprite(34).LocV + OffsetV
end if
end if
updateStage
end mouseWithin
Maybe I should use a standard scrollbar but I'd rather not.
Thanks in advance
Psymon