On Mon, Aug 20, 2012 at 4:39 AM, Paul Gestwicki
<
paul.ge...@gmail.com> wrote:
> I thought some of you might like to know that my entry to the ETS Math
> Assessment Game Challenge, Equations Squared, is powered by PlayN and
Looks awesome! I have notes lying around for an RPG where battles are
resolved by playing equations against one another using a supply of
numbers, operators and special magic items (code named Digitopolis). I
decided that it was too niche and opted for my current project instead
which is a (very light) RPG where battles are resolved via a
Scrabble-like mechanic (code named Dictionopolis). But I always hoped
to get back to Digitopolis. I like that you combine the grid-building
nature of Scrabble with equations instead of words.
> Also, if anyone has any ideas about why tripleplay is acting up on IE9, let
> me know!
IE9 must implement Canvas.arcTo incorrectly (or differently from other
browsers anyway). TPUI buttons use a round rect background by default
and on HTML5 fillRoundRect is implemented thusly:
private void addRoundRectPath(float x, float y, float width, float
height, float radius) {
float midx = x + width/2, midy = y + height/2, maxx = x + width,
maxy = y + height;
ctx.beginPath();
ctx.moveTo(x, midy);
ctx.arcTo(x, y, midx, y, radius);
ctx.arcTo(maxx, y, maxx, midy, radius);
ctx.arcTo(maxx, maxy, midx, maxy, radius);
ctx.arcTo(x, maxy, x, midy, radius);
ctx.closePath();
}
You can switch to a square rect background when creating your stylesheet:
int bgColor = 0xFFCCCCCC, ulColor = 0xFFEEEEEE, brColor = 0xFFAAAAAA;
Background butBg = Background.bordered(bgColor, ulColor, 5).inset(5, 6, 2, 6);
Background butSelBg = Background.bordered(ulColor, bgColor,
5).inset(6, 5, 1, 7);
Stylesheet sheet = SimpleStyles.newSheetBuilder().
add(Button.class,
Style.BACKGROUND.is(butBg)).
add(Button.class, Style.Mode.SELECTED,
Style.BACKGROUND.is(butSelBg)).
create();
--
m...@samskivert.com