-- apply the drop shadow effect
on beginSprite me
set sNum = the spriteNum of me
set animMode = #relativeToPoint
dropShadow(sprite sNum, [#animMode: animMode, #transparency: transparency, #red: red, #green: green, #blue: blue, #feather: feather, #xOffSet: offsetX, #yOffSet: offsetY])
Add(the actorList, me)
end
on endSprite me
set pos = getone(the actorList, me)
if pos then
deleteAt(the actorList, pos)
end if
end
on StopEffect me, sym
-- removes this behavior from the actorList
if not voidP(sym) then
if sym <> #dropShadow then exit
end if
set pos = getone(the actorList, me)
if pos then
deleteAt(the actorList, pos)
end if
end
on ResumeEffect me, sym
-- adds this behavior to the actorList
if not voidP(sym) then
if sym <> #dropShadow then exit
end if
set pos = getone(the actorList, me)
if pos = 0 then
Add(the actorList, me)
end if
end
-- new light settings if needed
on setShadow me
if mode = #Mouse then
set x = the mouseH
set y = the mouseV
else if mode = #Sprite then
-- IF YOU GET A SCRIPT ERROR HERE, YOU HAVE PROBABLY SPECIFIED
-- AN INVALID SPRITE FOR THIS BEHAVIOR
set x = the locH of sprite lightSprite
set y = the locV of sprite lightSprite
end if
dropShadow(sprite sNum, [#lightLocX: x, #lightLocY: y])
end
on stepFrame me
setShadow(me)
end
Contact
MMI
36 South Court Sq
Suite 300
Newnan, GA 30263
USA