Portals Published to Android Market

Portals is a location based GPS game that can be played anywhere.  The action takes place in the virtual Needham, Ma. townsquare.  If you are a geocacher there is a real logbook to sign and a secret codeword but that’s not necessary to play the anywhere game. Play anywhere allows unlimited gameplay while you figure out how to play the game.  There is a topten players score screen TopTenScores so you can see how you are doing compared to the other players.  Geocachers and others can journey to Needham and play on the actual town common. Scoring is detemined by starting out with 13000 points, as the game time increases the score decreases, and when you complete a task the score increases. As you play, your strategy may change to be more efficient. The final game panel allows you to enter a team name, the codeword(“Virtual” if playing anywhere), and a few lines of comment.

Posted in adventure, android, androidpapers, basic4android, geocaching, Uncategorized | Tagged | Comments Off on Portals Published to Android Market

Portals Android Update

The command processors are working as expected.  The Android sends a command request to the server at thomasofneedham.com/android/portals and the server answers back

Sample interaction:

First command is “init”

http://thomasofneedham.com/android/portals/portals_engine.php?android=newgame,init,,,,,,,,,

Response is to put Android in Roaming mode

httpResponse roamer,AVMW8Y,1,42.28067,-071.23669

Test Resume interrupted game:

ResumeGame android=resume,AVMW8Y,stuff,

httpResponse OC_Next,R8WTYJ,2,East,,,,,,grade7math.png,D
The Android then picks up where the game left off.

Currently working on MySQL database to store last command response.

2011-08-17 My surprise.  I had some perfectly good MySQL routines that I wanted to use on Portals.  I thought I only needed to change a few variables that had changed in the database.  No So!  This release of MySQL uses back-quote” `  ” to separate database column names whereas before single quotes worked fine.  It still uses single quotes on the data passed.  Previous flavors of MySQL allowed single quotes.  I don’t know what remote server would like.  After changing single quotes to back-quotes here and there the routines began to work as expected.

2011-08-22 Monday Debugging continued.  Had a strange MySQL error (valid gameid returning empty set)  This was a case for NuSphere debugger.  After a certain amount of setup fooling around,  debug_break() stopped at the right place in the code when the command was entered into the browser “http://localhost/thomasofneedham/android/portals/portals_engine.php?android=resume,R8WTYJJ,South”  It turns out I had the MySQL modules looking for the wrong variable.  NuSphere changes error tracking from a series of print statements to set a breakpoint where you think the offending logic begins and then single stepping through the program.

Posted in androidpapers, basic4android, geocaching | Tagged | Comments Off on Portals Android Update

Portals An Android Adventure – Field Testing

Went off to Needham Center today to test the revised logic and images. The start image displayed and guided me to the circle where the portals could be opened.  Each of the doors opened and the roamer logic took me to the right spot.  I exited each in turn and proceed to find the next portal.  Now the next step is to put some question logic to display after the door is open.

Here’s the revised direction pointer.  The previous one was from the Vampire of Needham and was a brainscan of a migraine.

Posted in android, androidpapers, geocaching | Tagged | Leave a comment

Art Theft – An Android Adventure

Just an idea for now.  Maybe you are a detective and and maybe you are the art thief

Posted in adventure, android, androidpapers, basic4android | Tagged | Leave a comment

Portals – An Android Adventure

Portals is a geocaching game that asks the player to work through a virtual maze in Needham center.

Portals on-going: 2011-08-01 The Zircons,  that cheap but flashy race is still here but fading.  I’m working on the outer circle of portals. The opening panel is at the right.  Eventually you complete the circle and open the portals.     Imagine if you will that the Zircons a cheap but flashy bunch of aliens have captured you but they in their cruel way have decided you can go free if you can find your way through the maze of portals, gain your freedom, and sign the geocaching log there in in the common.  On by the way, they have included a timer to encourage you.  Yesterday, I went out and took some photos and gps locations to start the project.  If you cannot come to Needham, Ma to play,  Portals is a Play-Anywhere so if you can play from anywhere there is GPS reception and an Internet connection.  I’ve tested the opening scenes here and there around Mass.  Here’s one of  the portals you have to find and open to go into the virtual room. Once you are there you will be asked to answer a question.  Eventually, you visit all of the portals in the outer circle and the inner circle is revealed.  The questions then become harder.  But fear not,  you and your trusty Android will prevail.

Android Functions Server Functions
Compass Direction Receives Request
GPS location Lat Lon Returns String
Task completed Returns Next Task

The logic is divided between the Android and the server.  The Android determines GPS location distance between points and compass bearing.  The server keeps track of the game.  When some event occurs, the server receives the Android command asking for a new task and the server responds with a new Android command. Remember everything in the Android is asynchronous with events coming as they may.  The compass reports minute changes in the Androids magnetic position which must be filtered into Cardinal points, the GPS position changes constantly even standing still, and the user may press a button or enter some data at any time.  The server must respond to any number of commands from various levels  of game play with one or many player being involved.

Portals    Notes. July 12, 2011  and earlier.

Concept

Player must complete a number of tasks, getting a high enough score to open final portal to cache or if virtual –  send a message of completion Post player and score and time to play calculate % of some sort

Portals are physical locations around Needham center identified by door images.  Game play starts with a choice of 4 portals to enter (Rotatating the Android brings up a different Portal view according to which Cardinal postion the player is physically facing.  Selecting a Portal presents the player with the distance and bearing screen.  When player reachs the Portal Zone, (Timer starts) he is given a choice of several rooms to enter.  Some have messages and other have questions.  When the player starts out he has a 0 or no score at all.  The questions are easy.  3+5 = ?,  misssing letter  A,B,C, E, multiple choice etc. One choice is Jump to another portal.  Possible message “Time is running out”  Running our of time in a Portal is bad as the player loses points and is jumped back to start.  He may choose to return and answer old questions (Possible game questions are never repeated but are easy or hard depending upon score.

One Portal is the neutral zone where a player can stop.  Player must visit all Portals in order to find the cache and must get a minimum score as well.

Controls

Initial Panel  Play, Mark, Menu and welcome message

Play starts game  – presents first Portal choices

Mark set Game Play relative to where the Player is physically standing. It’s an GPS lat/lon offset.

Menu Panel has Satellite view, About, Settings such as force/don’t force AnyWhere

Help ?

Send Email Message

 

 

When the player answer correctly there is an immediate success feedback, and the score is incremented.  Back to portal choices

 

Game Play Inital

Start with SD file check old game present  Would player like to resume Yes/No

Yes  Go to server get Portal position, restore score

Fly-with-me has some php logic interacting with a PhoneGap project.  Android_New

Polo MySQL database is used to keep track of user ID last postion, etc. Looks for a game to restore or it will crsate a  new game.

 

Android FunctionsSingle Player PHP serverMultiplayer
GPS Location Maintains  MySQL database
Compass location Keeps track of active portal, visited portalsDate/time game began
Maybe lookup, look down Keeps running score, statistics
Session/User ID
InZone test
Timers – How long in Room?, Zone = Portal

 

 

Posted in adventure, android, androidpapers, basic4android, geocaching | Tagged | Comments Off on Portals – An Android Adventure

Vampire Of Needham – Game Play

Download from Android Market
Geocaching.com  http://www.geocaching.com/seek/cache_details.aspx?wp=GC2EK9T

Begin by pressing Start.  Follow the direction and pointer to the capture Zone

 

 

 

Once in the capture zone, press OK to change to the scan view

 

 

After you captured the Vampire, the view changes as you rotate the scanner around the Compass Cardinal Points.  (N, E, S, W).  When you spot the vampire in one of the views you can press Capture and confine the vampire.  Be warned once you capture the vampire your lifeforce begins to drain away.

 

If it goes to zero, you lose.

 

 

 

 

Here’s one of the  views from the tomb zone scanner.  Note the Life Force Index ( L.F.I.)

One of the Tomb views has the name of a God that kills vampires.  At least in comic books anyway.  Find the name of the God and enter it before your life force runs out.

 

Your reward is to live and play another day.  Oh, by the way,  you have saved Needham, Ma, and the known universe.  You are the living image of the Super Hero.

Posted in android, androidpapers, geocaching | Tagged , | Comments Off on Vampire Of Needham – Game Play

Vampire of Needham – Play AnyWhere

Download from Android Market
Geocaching.com       http://www.geocaching.com/seek/cache_details.aspx?wp=GC2EK9T

2011-07-19.  PlayAnywhere feature updated to use a smaller play area about 100ft x 250 ft. 

This allows the use of smaller areas. The older version needed about 1000 feet.

 

After the GPS enabled screen, Press Mark to put the game in AnyWhere mode.  Press Start to begin the game.  You should be aware that the game is played on a South to North direction and the vampire capture place is about 60 feet S.E. of whereever you pressed Mark.  The first time I tried the location was in the middle of the interstate highway.  So don’t press Mark at the edge of a body of water unless there is an island 250 feet north of you.   It is possible to have the point in the middle of someone’s living room.  The game resets to regular play when  you exit.

 

Posted in adventure, android, androidpapers | Tagged | Leave a comment

“You Are So Remote Android” app

Recently I rewrote “You Are So Remote” using Basic4Android because I’m experimenting with the language.  The app controls a slideshow of Dale Chihuly’s  blown glass art from when he was exhibiting at the Museum of Fine Art in Boston in 2010.  You don’t need an Android to view the slideshow at http://thomasofneedham.com/slideshow/chuhuly The app is available on Android Market.

 

 

Posted in android, androidpapers, basic4android | Tagged | Leave a comment

Download Android Apps.

All apps can be found on Android Market.  Just search for the name and click on the name to download the apk file and then click on install/Run to complete the process.

FlyAwayHome,  YouAreSoRemote,  VampireofNeedham

 

Posted in android, androidpapers | Tagged | Leave a comment

Fly Away Home part 2

Mark saves the current location if you have your location enabled. If the system has not determined the location,  you get a small message “Looking for Satellites try again.”  Clicking on OK on the Saving Location saves that position and the system will display your distance and location.  It doesn’t matter if you are only 2 feet away.  While off shopping, it is useful to preserve battery life by exiting Fly Away Home if you are not using it.

Items  on the  Menu button are there for the  curious.   It should be remembered pressing Menu stops any GPS searches in progress. Find will not work until the GPS has been re-enabled via the Sat button.  Pressing Menu Exit returns to the top bar but nothing is enabled. 

You must press Sat to re-enable the application.

Compass displays a magnetic compass

Menu Button Sat starts the looking for satellites process which will continue until the current location is determined.

Posted in Uncategorized | Tagged | Comments Off on Fly Away Home part 2