コード例 #1
0
  public void run() {
    animation.trigger();

    if (animation.shouldIncrement()) {

      Selection selection = window.getSelection();

      // Override the default duration
      if (selection != null) {
        animation.setDuration(selection.duration);
        window.getMaster().getShowManager().play();
      }

      double startTime = System.currentTimeMillis() / 1000.0;

      double time;
      while (startTime + animation.getDuration() > (time = (System.currentTimeMillis() / 1000.0))) {
        animation.increment((time - startTime) / animation.getDuration());
        Thread.yield();
        PartyToolkit.sleep(10);
      }

      window.getMaster().getShowManager().pause();
    }
  }
コード例 #2
0
ファイル: UCEditor.java プロジェクト: bjackson/Party-Master
 public LightMaster getMaster() {
   return main.getMaster();
 }