Lingo Dictionary > A-C > centerRegPoint |
![]() ![]() ![]() |
centerRegPoint
Syntax
member(
whichCastMember
)
.
centerRegPoint
the centerRegPoint of member
whichCastMember
Description
Flash, vector shape, and bitmap cast member property; automatically centers the registration point of the cast member when you resize the sprite (TRUE,
default); or repositions the registration point at its current point value when you resize the sprite, set the defaultRect
property, or set the regPoint
property (FALSE
).
This property can be tested and set.
Example
This script checks to see if a Flash movie's centerRegPoint
property is set to TRUE
. If it is, the script uses the regPoint
property to reposition the sprite's registration point to its upper left corner. By checking the centerRegPoint
property, the script ensures that it does not reposition a registration point that had been previously set using the regPoint
property.
Dot syntax:
on beginSprite me if sprite(the spriteNum of me).member.centerRegPoint = TRUE then sprite(the spriteNum of me).member.regPoint = point(0,0) end if end"
Verbose syntax:
on beginSprite me if the centerRegPoint of member the memberNum of me = TRUE then set the regPoint of member the memberNum of me = point(0,0) end if end
See also
![]() ![]() ![]() |