- 930,638 hits
- The Superbook: an Interesting Idea
- Double Star in Indie Corner on Google Play
- Alien Commander to Appear in Rocket Rascal
- Improved Double Star
- More on the Thirty Second Hook
- Double Star game for Android
- New Code for Super Star Trek
- Screenshots from Latest Double Star Beta Release
- Fix to Double Star, Level 6
- Tutorial: How to Implement In-app Billing in Android - Part 1
- Android Images With Clickable Areas - Part 1
- Moving Views In Android - Part 2, Drag and Drop
- Tutorial: How to Implement In-app Billing in Android – Part 2
- Multitouch Panning and Zooming Examples for Android
- How To Build A Simple Help Screen in Android
- How to Export and Import Android Virtual Devices
- Drag-Drop for an Android GridView
- How To Build A Dashboard User Interface In Android
Tagsandroid app authentication authorization best practices css dashboard demo double-star drag-drop emulator example fragment game game board game design gomoku google google accounts google play gwt gwt-presenter how-to images in-app billing in-app purchase inspiring iphone iphone app java keyboard lessons learned mvp mvp example oauth pan performance space-war splash sst test touch trek Tridroid tutorial ui ui thread update video zoom
Tag Archives: java
Recently I have been trying to learn C#. C# and Java have a lot in common, so it’s hard for me to notice some of the subtle differences. Today, I found out that method overriding in C# takes extra effort. In Java, you define methods and then override them in subclasses by simply declaring a method with the same name and arguments. That is not the case in C#, but it took me a while to figure out why the Java code I was converting to C# was not working correctly.
With C#, you have to add the “virtual” keyword to any method you intend to override. In subclasses, you have to add the “override” keyword. This is illustrated below for a “makeMove” method for the game of Gomoku. Continue reading
I have updated the Java code for my port of the old Super Star Trek game. I first wrote about this about a year ago. See “Java Version of Super Star Trek”.
This update has many bug fixes and enhancements, including support for a deathray, a special kind of beacon planet, an alien home world, and firing phasers and torpedos at up to three targets at once. The new code is available on the SST2k page on Wglxy.com.
Android App. I have built an Android app based on this Java code. The app is more than just destroying alien ships, which is the main objective of Super Star Trek. The app has a storyline about searching the galaxy for the aliens’ home world. If you would like to try that game, more information is available here: Beta Test for Double Star.
SST2k website. The website where I originally found the C code for Super Star Trek is no longer around. I did locate the original SST2k manual in one of the places that caches old web pages. See SST2k game instructions.
Review on Space Game Junkie. The old game was recently reviewed on the Space Game Junkie website. That website is a fun place to visit if you like space games. Brian Rubin did a four part series on Super Star Trek. The link to the first of the series is here: Super Star Trek (entry 1). If you like the game, you will undoubtedly enjoy Brian’s entertaining attempt to learn the game. If you visit his Google+ game, you will find a post from me about movement, where I try to explain why his encounters with blackholes are not as unpredictable as he thought. Continue reading
I built a version of Super Star Trek in Java. This version of the Star Trek text game is based on the work of the SST2k project.
Star Trek, a text-based computer game, has a long history. It originated back in the 1970’s and there have been many variations of it since then. According to the Wikipedia article on the Star Trek text game, the SST2k project started in 2005. It is based on the C port of Tom Almy, which was done in the early 2000s.
A link to the Java source is provided. Continue reading
This is my guide to tuning performance of Java programs. It covers both cpu time and object memory analysis. I have found that this works for Java programs and for many Android applications. In the latter case, it helps if your Android application is structured so you can turn a section of an application into a standalone test case. Since many applications have background tasks, often implemented as subclasses of AsyncTask, this is usually easy to do.
The tool I prefer to use is HPROF. It is a simple profiling tool that is available with the Java SDK. It provides a variety of tools so you can address common performance problems, like the following: (1) you are allocating too many objects, which leads to a slow app because of too much garbage collection; (2) you are allocating objects and not properly releasing them, leading to a memory leak; (3) your computations are taking too long.
The topics I cover in this article include: (a) Getting started with HPROF in Eclipse, (b) HPROF Results (cpu times, object allocation), (c) Performance tuning suggestions, and (d) Other Android performance tuning tools. Continue reading
When you need to analyze performance of a running Java program, there is a simple profiling tool already built in to the Java runtime environment: HPROF It allows you to analyze both execution time and heap allocation. It’s really basic, but gets the job done — and it’s free and easy to use. Continue reading