移动目标:
基础动作
基础动作会修改精灵的一些基础属性,比如:
坐标
MoveBy
MoveTo
JumpBy
JumpTo
Bezier
Place
比例
ScaleBy
ScaleTo
旋转
RotateBy
RotateTo
是否可见
Show
Hide
Blink
ToggleVisibility
淡入淡出
FadeIn
FadeOut
FadeTo
特殊动作
时间相关:在一段时间内待命
Delay
RandomDelay
流程控制:调用一个指定的函数
CallFunc
CallFuncS
网格助手:帮忙执行一些网格动作
StopGrid
ReuseGrid
摄影机相关:
OrbitCamera
move = MoveBy((200,0), duration=5) # Moves 200 pixels to the right in 5 seconds.
move = MoveTo((320,240), duration=5) # Moves to the pixel (320,240) in 5 seconds
jump = JumpBy((320,0), 100, 5, duration=5) # Jumps to the right 320 pixels
# doing 5 jumps of 100 pixels
# of height in 5 seconds
accel_move = Accelerate(move) # accelerates action move 可以将上面的两个move变量合起来同事操作
当然还可以用
move = MoveTo((200, 200), 2) + MoveTo((400, 200), 3) + MoveTo((100, 300), 1)
-------------------------------------------------------------------------------
这样的方式
# Move the sprite to coords x=50, y=10 in 8 seconds
action = MoveTo((50,10), 8)
# Move the sprite 50 pixels to the left in 8 seconds
action = MoveBy((-50,0), 8)
----------------------------------------------------------
action = Jump(50,200, 5, 6) # Move the sprite 200 pixels to the right
spr