Wednesday, May 13, 2015

Virtual dice has been published in Google play

I have published the "PirateDice" android application in Google Play . The Application is very useful for sea board gaming where a special dice (looked like a compass) is needed, for instance such board games as "Merchants and marauders" and "Pirates". The Application works on Android 2.1+ platforms.

Monday, May 11, 2015

the Battleships game (E3 2001)


    In 2001 I took a part in very interesting project called "Battleships", the project was organized by Swedish company "Gamefederation" and the purpose of the project was to show the power of the GEX platform (multi-user game management platform, a product of the company) in E3 2001. During planned demo game session, a Motorola A008 user would start a game session with a PC  user through interfaces provided by the GEX server. The Well-known paper board game "Battleships" was selected as the base for the demo and we were sure that it would possible to implement demo project for 3 moths.  I didn't have any mobile development skills in that time but the project looked very interestingly especially because it was a client-server project involving a mobile device working through GPRS network (very new experimental technology in that time) and even with touch screen so I agreed my participation.  The Russian team part worked in bounds of RU-SOFT company.

Friday, May 8, 2015

Preprocessing of gradle android projects

Made some investigation how to use JCP with Gradle for Android projects, looks it works well, I have written some wiki

Sunday, May 3, 2015

J-J-JVM

I had found my old (2009) project of implementation a JVM interpreter in Java to play class files in J2ME (which didn't support class loaders), I made some changes, added tests and added support of long and double processing and moved the project to github, so that now it has been published under Apache License 2.0 and fully accessible
p.s.
also I renamed the project from M-JVM to J-J-JVM

Saturday, April 25, 2015

Javassist

Interesting detail about Javassist (as minimum 3.12.1.GA), it doesn't produce optimal Java code and for instance the switch keyword everytime produces lookupswitch instruction even if it is possible to use faster version - tableswitch. The Same situation with conditions, a condition like if (a==0) produces non-optimal code instead of ifeq

Friday, March 13, 2015

Farewell GoogleCode

Because Google Code is going to end its life, I have moved all my pet projects to GitHub and the repository link is https://github.com/raydac?tab=repositories

Wednesday, February 4, 2015

New version of Java Binary Block Parser (JBBP) 1.1.0 is out

The New version of JBBP 1.1.0 is out and accessible in the maven central, now it supports not only parsing of binary data and mapping them to classes but also and back operation - packing binary data blocks from mapped classes and even printing of mapped class  description, take a look at example


class Flags {
      @Bin(outOrder = 1, name = "f1", type = BinType.BIT, outBitNumber = JBBPBitNumber.BITS_1, comment = "It's flag one") byte flag1;
      @Bin(outOrder = 2, name = "f2", type = BinType.BIT, outBitNumber = JBBPBitNumber.BITS_2, comment = "It's second flag") byte flag2;
      @Bin(outOrder = 3, name = "f3", type = BinType.BIT, outBitNumber = JBBPBitNumber.BITS_1, comment = "It's 3th flag") byte flag3;
      @Bin(outOrder = 4, name = "f4", type = BinType.BIT, outBitNumber = JBBPBitNumber.BITS_4, comment = "It's 4th flag") byte flag4;
    }
    final int data = 0b10101010;
    Flags parsed = JBBPParser.prepare("bit:1 f1; bit:2 f2; bit:1 f3; bit:4 f4;", JBBPBitOrder.MSB0).parse(new byte[]{(byte)data}).mapTo(Flags.class);
    System.out.println(new JBBPTextWriter().Bin(parsed).Close().toString());
    assertEquals(data, JBBPOut.BeginBin(JBBPBitOrder.MSB0).Bin(parsed).End().toByteArray()[0] & 0xFF);
the code will parse the byte, then print its values

;--------------------------------------------------------------------------------
; START : Flags
;--------------------------------------------------------------------------------
    01; f1, It's flag one
    02; f2, It's second flag
    00; f3, It's 3th flag
    05; f4, It's 4th flag
;--------------------------------------------------------------------------------
; END : Flags
;--------------------------------------------------------------------------------
and again will pack parsed data into byte