Mercurial > hg > ristipolku
changeset 30:60a4579a79df dev-0_1
Moar work.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 02 Feb 2011 22:45:53 +0200 |
parents | 4a0f8dcdaa3f |
children | 8dbc79294106 |
files | game/Engine.java game/Piece.java |
diffstat | 2 files changed, 35 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/game/Engine.java Tue Feb 01 22:38:42 2011 +0200 +++ b/game/Engine.java Wed Feb 02 22:45:53 2011 +0200 @@ -77,6 +77,38 @@ } */ +class IDMWidget +{ + public IDMWidget() + { + } + + public void paint(Graphics2D g) + { + } + + public boolean hit(float x, float y) + { + return false; + } +} + +class IDMButton +{ + public IDMButton(float x, float y, String text) + { + } + + public void paint(Graphics2D g) + { + } + + public boolean hit(float x, float y) + { + return false; + } +} + class GameBoard { public static final int boardSize = 9; @@ -95,7 +127,7 @@ moveX = boardMiddle; moveY = boardMiddle - 1; - movePoint = 0; + movePoint = 5; pieceFinishTurn();
--- a/game/Piece.java Tue Feb 01 22:38:42 2011 +0200 +++ b/game/Piece.java Wed Feb 02 22:45:53 2011 +0200 @@ -81,7 +81,7 @@ public int getConnection(int in) { - return connections[in]; + return connections[(in + (currRotation * 2)) % 8]; } public void rotate(boolean dir) @@ -120,6 +120,7 @@ public void setActiveConnection(int index) { active[index] = true; + active[connections[index]] = true; activeChanged = true; }