equal
deleted
inserted
replaced
468 with moveAnim do |
468 with moveAnim do |
469 if animate then |
469 if animate then |
470 if RealTicks > (startTime + MOVE_ANIM_TIME) then |
470 if RealTicks > (startTime + MOVE_ANIM_TIME) then |
471 begin |
471 begin |
472 startTime:= 0; |
472 startTime:= 0; |
|
473 animate:= false; |
473 frame.x:= target.x; |
474 frame.x:= target.x; |
474 frame.y:= target.y; |
475 frame.y:= target.y; |
|
476 active.x:= active.x + (target.x - source.x); |
|
477 active.y:= active.y + (target.y - source.y); |
475 end |
478 end |
476 else |
479 else |
477 begin |
480 begin |
478 frame.x:= source.x + Round((target.x - source.x) * ((RealTicks - startTime) / MOVE_ANIM_TIME)); |
481 frame.x:= source.x + Round((target.x - source.x) * ((RealTicks - startTime) / MOVE_ANIM_TIME)); |
479 frame.y:= source.y + Round((target.y - source.y) * ((RealTicks - startTime) / MOVE_ANIM_TIME)); |
482 frame.y:= source.y + Round((target.y - source.y) * ((RealTicks - startTime) / MOVE_ANIM_TIME)); |