Changes reflecting refactoring of the DynMath library.

master
Ondřej Hruška 10 years ago
parent a3d0c945bc
commit b384d7a70a
  1. 6
      src/mightypork/gamecore/gui/components/BaseComponent.java
  2. 2
      src/mightypork/gamecore/gui/components/LayoutComponent.java
  3. 2
      src/mightypork/gamecore/gui/components/LinearComponent.java
  4. 4
      src/mightypork/gamecore/gui/components/PluggableRenderable.java
  5. 2
      src/mightypork/gamecore/gui/components/layout/ColumnLayout.java
  6. 2
      src/mightypork/gamecore/gui/components/layout/ConstraintLayout.java
  7. 2
      src/mightypork/gamecore/gui/components/layout/FlowColumnLayout.java
  8. 2
      src/mightypork/gamecore/gui/components/layout/FlowRowLayout.java
  9. 2
      src/mightypork/gamecore/gui/components/layout/GridLayout.java
  10. 2
      src/mightypork/gamecore/gui/components/layout/RowLayout.java
  11. 4
      src/mightypork/gamecore/gui/components/layout/linear/LinearLayout.java
  12. 2
      src/mightypork/gamecore/gui/screens/Screen.java
  13. 2
      src/mightypork/gamecore/input/events/MouseButtonEvent.java
  14. 2
      src/mightypork/gamecore/render/DisplaySystem.java
  15. 3
      src/mightypork/gamecore/util/math/timing/TimedTask.java
  16. 2
      src/mightypork/rogue/screens/FpsOverlay.java
  17. 2
      src/mightypork/rogue/screens/game/IngameNav.java
  18. 2
      src/mightypork/rogue/world/level/render/TileRenderContext.java
  19. 8
      src/mightypork/rogue/world/tile/DroppedItemRenderer.java

@ -3,9 +3,9 @@ package mightypork.gamecore.gui.components;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.rect.caching.AbstractRectCache;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.proxy.RectBoundAdapter;
import mightypork.dynmath.rect.proxy.RectProxy;
import mightypork.gamecore.gui.Enableable;
import mightypork.gamecore.gui.events.LayoutChangeEvent;
import mightypork.gamecore.gui.events.LayoutChangeListener;
@ -41,7 +41,7 @@ public abstract class BaseComponent extends AbstractRectCache implements Compone
@Override
public void setRect(RectBound rect)
{
this.source = new RectBoundAdapter(rect);
this.source = new RectProxy(rect);
}

@ -4,7 +4,7 @@ package mightypork.gamecore.gui.components;
import java.util.Collection;
import java.util.LinkedList;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.core.modules.AppSubModule;
import mightypork.gamecore.eventbus.EventBus;

@ -3,7 +3,7 @@ package mightypork.gamecore.gui.components;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.vect.Vect;
import mightypork.dynmath.vect.proxy.VectAdapter;

@ -1,9 +1,9 @@
package mightypork.gamecore.gui.components;
import mightypork.dynmath.rect.PluggableRectBound;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.PluggableRectBound;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.render.Renderable;

@ -1,7 +1,7 @@
package mightypork.gamecore.gui.components.layout;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.components.Component;

@ -1,7 +1,7 @@
package mightypork.gamecore.gui.components.layout;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.components.Component;
import mightypork.gamecore.gui.components.LayoutComponent;

@ -3,7 +3,7 @@ package mightypork.gamecore.gui.components.layout;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.AlignX;
import mightypork.gamecore.gui.components.Component;

@ -3,7 +3,7 @@ package mightypork.gamecore.gui.components.layout;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.AlignY;
import mightypork.gamecore.gui.components.Component;

@ -1,8 +1,8 @@
package mightypork.gamecore.gui.components.layout;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.rect.builders.TiledRect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.components.Component;
import mightypork.gamecore.gui.components.LayoutComponent;

@ -1,7 +1,7 @@
package mightypork.gamecore.gui.components.layout;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.components.Component;

@ -2,8 +2,8 @@ package mightypork.gamecore.gui.components.layout.linear;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.num.NumSum;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.num.batch.NumSum;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.vect.Vect;
import mightypork.dynmath.vect.proxy.VectAdapter;
import mightypork.gamecore.core.modules.AppAccess;

@ -2,7 +2,7 @@ package mightypork.gamecore.gui.screens;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.core.modules.AppSubModule;
import mightypork.gamecore.gui.events.LayoutChangeEvent;

@ -1,7 +1,7 @@
package mightypork.gamecore.input.events;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.vect.Vect;
import mightypork.dynmath.vect.VectConst;
import mightypork.gamecore.eventbus.BusEvent;

@ -6,7 +6,7 @@ import static org.lwjgl.opengl.GL11.*;
import java.nio.ByteBuffer;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.vect.Vect;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.core.modules.AppModule;

@ -1,8 +1,7 @@
package mightypork.gamecore.util.math.timing;
import mightypork.gamecore.util.math.timing.animation.NumAnimated;
import mightypork.gamecore.util.math.timing.animation.NumAnimated;
/**

@ -2,7 +2,7 @@ package mightypork.rogue.screens;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.dynmath.vect.Vect;
import mightypork.gamecore.core.Config;
import mightypork.gamecore.core.modules.AppAccess;

@ -2,7 +2,7 @@ package mightypork.rogue.screens.game;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.core.modules.AppAccess;
import mightypork.gamecore.gui.AlignX;
import mightypork.gamecore.gui.components.LayoutComponent;

@ -2,7 +2,7 @@ package mightypork.rogue.world.level.render;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBound;
import mightypork.dynmath.rect.RectBound;
import mightypork.gamecore.util.math.algo.Coord;
import mightypork.gamecore.util.math.algo.Move;
import mightypork.gamecore.util.math.noise.NoiseGen;

@ -4,9 +4,9 @@ package mightypork.rogue.world.tile;
import java.util.Collection;
import mightypork.dynmath.num.Num;
import mightypork.dynmath.num.proxy.NumBoundAdapter;
import mightypork.dynmath.num.proxy.NumProxy;
import mightypork.dynmath.rect.Rect;
import mightypork.dynmath.rect.proxy.RectBoundAdapter;
import mightypork.dynmath.rect.proxy.RectProxy;
import mightypork.gamecore.util.math.Easing;
import mightypork.gamecore.util.math.timing.animation.Animator;
import mightypork.gamecore.util.math.timing.animation.AnimatorBounce;
@ -19,8 +19,8 @@ public class DroppedItemRenderer {
private final Animator itemAnim = new AnimatorBounce(2, Easing.SINE_BOTH);
// prepared constraints, to avoid re-building each frame
private final RectBoundAdapter tileRectAdapter = new RectBoundAdapter();
private final NumBoundAdapter offsAdapter = new NumBoundAdapter();
private final RectProxy tileRectAdapter = new RectProxy();
private final NumProxy offsAdapter = new NumProxy();
private final Rect itemRect = tileRectAdapter.shrink(tileRectAdapter.height().perc(12)).moveY(offsAdapter.neg().mul(tileRectAdapter.height().mul(0.2)));

Loading…
Cancel
Save