Building an XNA Game Studio XBox360 Indie Game.

[page 0049] ~ AI ~ Prelude:

Updates – just Windows.

And the theme this month is ???.

Pheromone Fantasia.

Now that everything, or nearly everything, is set up so that, from the programming, the concept of chess can be mnemonically conveyed from the code page to the computer screen.  From there I can begin to delineate the basic assumptions and leaps of faith a human player would use to play the game, from what a Reactionary AI and its accompanying algorithms, would need to collate, compare and correlate what can be done with what needs to be done to play, and hopefully win, a game of chess.  So far this game can be played by people who understand the concepts of chess.  That being said, it cannot be played, at all, by an Algorithmic Reactionary Artificial Intelligents.  Seeing that I haven’t built an ARAI, (spoken: “are-eye”), before and have no idea of where to start I will use a strategy from the Music Man, the “Think System”.

BackUp_00, Start this game with “X ~ Change” as its base template.

BackUp_01, the first thing to do is to clean up a few more items.  Speed is always a good thing, or at least alleviating the necessity for needless waiting, so then to have game play where it then seems to be moving along more quickly than before.  The possibility to have the game move just a little bit faster than practical would probably be good enough.  The first thing I can think of is, if I were to select a piece to move, but then change my mind to select another piece.  Currently, to select another piece I need to right click on the same piece, which the game considers not exactly a move but a trigger to rescan the chess board and thereby wastes just a little more time with each calculation because of the reselection.  What I may be able to do here is to check to see if the starting location is the same as the finishing location and if they are the same, bypass the scan, because the pieces on the board have not changed.  Nothing has changed so nothing needs to be checked for change.  But, what variables would be needed to do this and where would this check of equality take place.  Then further, how would this information be given to some position in the code so that it would not disturb the regular flow of logic that would transpire from what exists as normal game play.  Per usual, I’ll start off with some more global variables, it’s simple, they are easy to access and stay resident throughout the game.  What I’ve noticed is, is that one of the if() statements has some arithmetic computations going on inside of it, which may or may not be any big deal.  But, prior to that if() switch I may be able to consolidate that computation into one variable and give that to the if() statement and as a bonus, have that variable accessible for what I am trying to accomplish, which is adding speed within the playability.  Once again it sounds simple, in theory.  One other thing that needs to come under consideration is if or when those global variables need to be reset.  At second glance it seems that the variables I’m looking to utilize are only used as an output to the screen and are not in the if() conditional itself.  So working my way back up the function chain I find where they originate and may be able to create the variable contents there.  This would make two variables from that same point that are built from and of the same meaning but would then diverge from that point to be applied for differing usage.  For good or ill, that’s how I will work it for now.

OK, the variables have been switched out W/B SP X/Y 1/2, being four sets of coordinate pairs (WSPX1, WSPY1), (BSPX2, BSPY2) … , and still have the results appear on the screen that still look the same.  Now to find the placement where a check for either a conditional function that brings about the full chess board scan begins, or to find if it is found somewhere else in the body of logic that streams by perpetually and occurs without trigger with each draw() call of the games cycle.  So what is supposto happen?  I left click on a piece to select it.  The mode switches over to single piece view.  Time is ticking away. My strategy changes because I notice something more advantageous.  Here?  I would like to change the piece I am currently working with and must change to another piece.  Yup, here.  I right click on my same piece, and I have some time wasted by waiting while the scan goes off rereading what is already known and will not change the outcome of this turn, a non-move.  What I would like to happen is, I right click on my same piece and the game recognizes that the origin is the same as the destination and there is nothing that needs to be rescanned, and so it doesn’t.  That right click on the same piece in the same position will immediately allow me to left click on another piece and enter the game state where a single piece view mode becomes available again.  Sounds good, but where, and how.  And for some reason, I hear Jabba the Hutt laughing in the background, “Muwah hoah ah ha ha ha ha”, slowly and ominously.  The way it looks, after the right click on the same piece, I’m given the chess board tile piece coordinates almost immediately in the bottom left or right sides of the game screen, then thereafter the scan goes off.  So there might be a chance to place a, “hey you don’t need to scan”, flag, somewhere before it does start the scan somewhere around there, maybe.  Yes I will try that old Jedi mind trick, “These are not the voids you are looking for, move along”.  But first to move all of the Pawn_3.mask(Pawn_2); and similar piece stuff into the setup(); function so it is only accessed once.  Oh yeah, this will take a while to refigure out.  There is nothing obvious as to where this flag might be set.  There is a mouseButton == LEFT in an if() switch inside another that might have potential.  But no, and yes.  The check, it seems, is to be put inside of, void CurrentlyMoved(int X, int Y, int House, int Piece).  And from playing a couple of games, with the change in position of, DualScan = 0; from void mousePressed() : (mouseButton == RIGHT) to the function CurrentlyMoved, the apparent game play does move slightly faster.  Now, when a piece is selected and then clicked on itself again to be deselected, the full chess board scan is not activated and by the simple nonfunctioning of a function and not doing something in lieu of actually doing something the concept of speed is given to the players of the game.  Now that that is done, what comes next?  How about another save.

BackUp_02, done.

BackUp_03, now that this chess game is a little bit faster and continues to work with no new noticeable errors from this upgrade, I’ll need to start thinking about a data backbone as some type of grid and/or array matrix that will store which pieces are moved each turn.  Right now I can’t think of any type of AI that would have any way to “see” the game beyond some random movement schema.  For all practical purposes any AI for this game would be quite blind and conceptless in concern to what is to be achieved or expected of it.  But before anything like this will begin to happen I’ll need to build something where, I either can’t have a King move into check, which may prove to be a somewhat difficult thing to do.  Or I could build something that will let me undo a move out of check that has put me into check from a piece moved out of the way and which may have taken another piece off the board and thereby put my King into check, another invalid move.  In either of any case, I’ll need to address this issue and a couple of more issues before I get into an AI pipeline production model.  But, this King/Check issue would more than likely come from some variable array that will store the piece movements for at least one turn prior to what needs to be restored.  So, to get the chess board back to how it was before the erroneous move was made sounds like something that would be useful in the short term and possibly in the long term for that AI stuff later on.

Ok, what do I want to do today?  What is the game plan.  Where to start.  Well, the game is initialized and asks which team will begin with the first move.  At the starting point, without giving any thought about what variable arrays will be holding any of this supposed AI information, I’ll just think of what and how the forthcoming scenario will commence turn by turn.  And the first thing that comes to mind is another little tweaker tool that would be helpful up top within the time line area.  Having a < or > sign in either black or white on either side of the count down time to Victory timer, might help the players keep track of which direction that timer is moving for whichever player is currently active.  The way that timer is set up is, when the time has moved into whites side of the timeline the timer/counter is drawn in white even though black is the active player and visa versa.  And, that time would then be greater than 3 minutes and 30 seconds, which is the center mark for the timeline.  As it is, the timer always counts down from any time that is less than 6 minutes and 59 seconds.  When that timer reaches zero on either end of the timeline the other team wins.  OK, that’s done, so now there are two arrow heads, one black that appears when it’s blacks turn and one white that appears when it’s whites turn.  The black arrow head is, instead, positioned to the left of the light gray full game time timer, which is the centered top most timer, while the white arrow head is also positioned to the right of that same timer.  It does provide a little more clarity as to who is going that turn and which way that timer is running when the Minimal HUD is the only utility that is being used and seen on the game screen.  This is good enough for BackUp_03.

BackUp_04, having gone through this timeline directional addition, and having been left and right clicking on the same piece over and over while watching the results, I’ve noticed that the semitransparent green “Next Move” signal is not quite right.  A more appropriate term would be “Next Turn”.  But after a little research the term “Move” does seem to be sufficient because, for most rules of play, a move does signal the end of that players turn, and therefore is the action that relinquishes that turn back to the opposing player.  Move stays, Turn, not, done.  But there still is a problem here because at each start of a players turn the “Next Move” signal and button is not viewable, but once a piece is moved to another tile the “Next Move” signal appears, which is good and how it should be.  Then, for some odd reason or other, probably because I haven’t worked on that part yet, if that piece is selected again and then unselected, just because or just to see what happens or what would happen, while not moving, the “Next Move” signal and button disappears and does not reappear.  The game then, in so not doing, makes the current player unable to leave the board open for the next player to select any piece.  The table becomes locked with the current player and leaves that same teams timeline active to tick against that player moving towards the opponents Victory.  Hmm, what to do.

I think I’m finally getting to the point where only a few more puzzles are missing, sure.  And shortly after that point I’ll be able to begin to start working backwards into the information given and collected, where the games AI will begin to take shape.  But until then I think I’ll need a couple of other checks and flags to wheedle this puzzle into submission.

So, I left click on a piece to move it.  The screen changes to the view single piece statistic mode.  The path that that piece is able to take is shown.  The name of the piece is shown in either of the upper corners of the game screen.  In the lower corner is the Start position with a picture of the piece that is selected.  The Finish position is empty, (  ,  ).  The selected piece has the cyan selected wide square highlight around it in the tile and a thin Start move highlight directly inside the cyan highlight.  The next thing to do is to move that piece somewhere along the available paths seen on the chessboard.  The mouse is positioned over another tile and the right mouse button is clicked.  The automation process begins and the piece moves from the Start position to the Finish position.  The Finish position, in either of the bottom corners of the screen is now filled out with the actual coordinate pair, (x, y).  The Selected Piece highlight is turned off, because the piece is no longer selected.  The automation has deselected it.  The Start position highlight tile still has the highlight on, although the tile is now empty, and another highlight, the Finish position highlight, surrounds the piece that has just moved to the new tile position.  At that point the “Next Move” signal and button becomes viewable.  That’s a lot of stuff happening just to move a piece on the board, and also to get me to this point so I can begin to correct the affor mentioned idiosyncrasies that are posing these newly observable problems, whew!

But of course there is more to do, such as, figuring out what needs to be done with what and where that what, might take place.  Then there is the creation of some variables, and to give them their names to reflect the facilitation for just which what needs to be done where.  Once again I’m thinking I’m done with the administrative, yadda, yadda and will be getting back to the fun stuff, management and supervision, so I can tell myself what to do, with what where, and hopefully how, shortly.

Kinda getting back to the build, the “Next Move” signal and button can become nonviewable.  This is a major flaw that a human player may run across and one that needs to be rectified.  But how.  What needs to happen so only one move of one piece will become a valid registered move.  Thus far the game itself is built to be manipulatable.  Many permutations and combinations are currently possible, although not valid.  Any piece of one team can be moved to almost any tile on the board.  A path for any given piece of that particular type is shown on the game board, when selected, but there are no rules that state that those paths are the only place that that piece may move.  Validity of piece placement are still conceptual in nature.  An ARAI will need rules that are to be followed so there will be consistency when an ARAI moves a piece on the chess board.  The ideals of the upcoming ARAI are beginning to show themselves, and those rules will be many and varied.

For simplicity sake, lets start out with two ARAI’s playing a game of chess.  The ARAI’s will not be the ones to start the game, but once the game begins they will “see” the game as a set of rules that run to their logical conclusion.  The three major conclusions for this game of chess will be: 1.) Victory, because time has run out for one team leaving the other team victorious, 2.) Stale Mate, because it is not possible to put the opposing teams King into Check within a given number of moves, or 3.) Check Mate, because the opposing teams King has found itself in a position where it will be taken from the chess board because of the inability of that player, ARAI, to remove that impending danger from all of the possible valid moves remaining of that team for that turn.  Yup, simple.  But where to start.  The more rules based this game becomes to facilitate the ARAI the more ridged in format the structure will also become, not to mention the increasing derivation testing that evolves from the processes involved as a result of those restrictive reactionary rules.  Yeah, that’s what I say, WHAT?

The plan, in theory.  An ARAI will need to adhere to a basic set of rules.  So I would guess the best question to ask is what rules are currently present, at least in concept, that pertain to a chess pieces movement.  Apart from all that left-click right-click stuff, the ARAI will need its own automation system to facilitate an action that can come about from what is seen as the current mouse movement model.  That’s one part, but it’s not exactly what I’m looking to get at right now.  I need something more simple than that.  Such as, what happens before the first move of the game.  What is the objective that the ARAI will seek.  How will it utilize the movement plot, that is, the hexes seen as Green: a clear path, Red: a potential opponent kill and Cyan: a current ally protectorate.  From these three movement potentials there must be some directive that will assume an objective.  And the plot thickens.

Again, at the beginning of the game, in chess terms the “opening“, the ARAI will be able to “look” at the statistics, somehow, and formulate an initial reactive strategy.  It would seem, from all prior observable instances, that there would be no pieces to take of the opponent on the first move, so that part of the equation would become null, not zero, but null.  That would leave only two parts of this formulated stratagem needed, which would provide some material to advance this first piece off to somewhere as the starting move for the first ARAI.  The first move would consist of, “Can I move at all”, while the second is, “Do I want to move out of protection, or not.”  So far this does sound rather simple, but what would be the impetus to promote this first move.  And thereafter, would that be perpetuated or relinquished.  Ah, the impetuous human player, always looking into obscurity.  Which brings about the idea of foresight, which in turn brings about the reality of CPU cycles, logic flow and apparent game speed.  Yup, from AI concept, hammer-thrown all the way to the provisions of playability in one flail swoop.  Thoughts do tend to move quite quickly when concept and theory collide.

Back to ye olde solace within.  My ARAI wants to move a piece on the chess board.  “Wee!  Oh-boy, which piece shall I move?”, says the first ARIA.  I guess that could come from a plain old crapshoot.  Some random act that again takes into account the two remaining, hmm, what should I call them, accrual arguments?  The two of the three path plots of a piece consisting of, what, Green, Red and Cyan, as colors.  But what exactly are those.  For one, they are the three parts of a teams piece movement potential that are now named the accrual arguments.  As a side note: the remainder of the full accrual argument formula comes also from the manipulation of time that is used per player turn, which culminates in a representation as the bar graph chart.  So anyway, each hex away from the piece is an open step and/or a terminus.  Each step, because of the type of piece it originates from, will move according to its given schema, and the distance it can go from its origin which is determined by its proximity to the chess board border or another piece.  Well that’s nice to know.  But what does it get me.  Another day older and deeper in debt, and ya’ put ’em in the water and they don’t get wet.  Sure, yeah right, nighty night, I go now.

I’m back.  Wow, I was digging pretty deep there last night with that one, all the way back to a song mom and dad had us kids singing on our road trips back in the day.

The Ditty:

Boom boom,

aint it great to be,


Boom boom,

aint it great to be nuts like us.

Silly and foolish all day long.

Boom boom,

aint it great t’ be,


Sittin’ on a corner sellin’ socks.

A dollar a pair a nickle a box.

The longer ya’ wear ’em the shorter they get.

An’ ya put ’em in the water an’ they don’t get wet.

Chorus: … et. al.

This ARAI stuff, hmm, well I don’t seem to be charging head long into the coding aspects of this pipeline.  No I don’t, no I’m not.  I think I’ll get back to the “Next Move” problem that has come to surface.  But first I’ll address the concept of the ARAI, that being the Algorithmic Reactionary Artificial Intelligents, just to clear up within my own minds eye what it is composed of, the purpose and its composite ideals.  The way it looks, the power that will drive the positioning of the pieces will come from objectives derived of the components of the statistics.  Like most strategy games, there are some predefined default settings that an AI can follow, usually offensive, defensive or neutral.  So what I will need are some choices that allow for selection of how the team will react to the current statistics.  Will I keep my pieces protected?  And if so, to what degree?  What about peril?  Should my piece move out of peril only if not protected?  Should my piece ever move into peril?  Then to get even more basic than that, how should the AI look for a path of that selected piece where the capacity of any of the above mentioned actions will move it into an uncompromised destination.  What direction should that piece move and also how far along that path should it move before it should stop?  These questions and many more will need to be algorithmically answered so the AI will react with some degree of consistency as the game progresses.  This degree might be achieved by constructing combinations and turning them into ratio sets.  These ratio sets could be built and tested empirically, then thereafter, allow the AI to be ‘tweaked’ out with other tested parameters.  Chess, has three phases being the opening, middle game and end game.  Ratio sets may be made up of objectives such as “Move towards the enemy”, “Move along your path until a piece is in peril”, or combinations of ratio sets such as 1.) “Move towards the enemy” but 2.) “Do not move out of protection.”  I think I said something before about the metrics matrix, but maybe not exactly, but now I have, so I guess I’ll continue.

What I’ll need to do is play a couple games of chess and write down some of these simple actions to see if they can be fit, as combinations, into that which will become these fabled ratio sets.  So after getting an Excel SpreadSheet set up for this, it’s back to “Next Move”.  There is an if() conditional that triggers, or keeps from triggering, the gate that prints “Next Move” to the screen and allows for other things to happen.  This whole game is being built piecemeal, so all of this will more than likely end up as a very strange and convoluted longhand logic, nothing tidy, but fully unoptimized and technically inefficient, code thing, but so what.  With that, there must be a way to build a signal flag that is switched on and off if a piece is moved thus ending that players turn.  I’ll get to Castling and Pawn Evolution as two exceptions later on.  For now, what makes a move a move.  The only piece that can move is the one that is selected.  That selected piece is Start (x, y) where x and y are known when the piece is selected.  What happens is when deselected x1 equates to x2 as does y1 and y2.  This is what keeps the “Next Move” signal and button nonviewable, which was a good idea at the time.  But the situation has changed, through the testing process, and now I’m concerned beyond getting the initial move to work properly and am off to allowing for reselection that doesn’t break the game play experience.  Man oh man, derived leaps of faith and truth in linearity inside convoluted code constructs is a rather tumultuous state, but like in the game of Monopoly, Just Visiting.  Then moving in silently down wind and out of sight you need to strike when the moment is right, without thinking … Then after a while …  What I seem to be working on is, if I put the piece that I had just moved back to its starting position, then the “Next Move” will vanish once again because a piece has not been moved yet this turn.  But like many things inside this code page, much is too easily overwritten.  But I gotta say, this game can be decked out like a little happy confetti patch, for as dry a game that chess is.

So, Merry Christmas to all.  And to all a good night.


December 26, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0048] ~ X ~ Change:

Updates – Adobe Flash Player: Version 11.9.900.152 and Firefox 25.0.1 from 19.0.2

And the theme this month is CHANGE.

To find the change, “Two above else and second above last.”, really!

Reactionary AI.

This game will be a mile stone in that it is the start of my journey into Artificial Intelligents, for this game, actually, the next game or so.  So far, automation has been the mechanism that has moved the pieces about the chess board.  As the mouse pointer hovers over a chess piece, there is an opportunity to left click on that position and therefore the underlying chess piece icon.  This begins the process of automation that switches the game mode from view all chess piece statistics to view a singular chess piece statistic.  This change affords to the player a second point of view and the option to move the selected piece within this current modality.  This is done by simply pointing at a new position and right clicking on the chess board.  Automation takes care of the rest such as: moving the piece to a new tile, removing a piece of the opposing team and replacing that piece with the selected piece, ‘Evolving’ a Pawn to another previously taken piece once it reaches the other side of the chess board, or showing that that piece has put the King into check, just to name a few.  These processes are a result of automation and allows the game to be played more smoothly.  This alleviates the players who are taken away from the game mechanics and to raise their continuity within the game as they can become more concerned with the strategy used in the game of chess itself.  This also begins to lay the framework for reactionary artificial intelligents where rules of play can be followed by an algorithm of an opposing player, that being the games newly found AI.  As for now, it will come to no issue, seeing it is only but perceived, and as yet only a theory.  But this game does put to use enough Multiplicative Inverse, and some Logarithmic stuff.  And with that …

The Builds, the Saves.

BackUp_00.  Start this game with “Confection de Logic” as its base template.

BackUp_01.  The base template for this new game is essentially the full code page from the last game, “Confection de Logic”.  With that in mind the first order of the day will be code consolidation and optimization.  The reasoning behind this is that the scan speed of the chess pieces are slow.  Initially only one player would have their pieces scanned per turn which took roughly one second per piece.  Even for me this was an excruciatingly long time to wait so I could move another chess piece on the board.  Then I decided that there wasn’t enough valid information given in concern to both teams, being the white and black pieces, so I had both sides scanned each time the player relinquished their turn to the other player.  At one piece per second, because I was using the second() function to flag each piece to run its algorithm that would find the movement plot, any pieces that are protected by that piece and any piece that is in peril of being taken by that piece became a long time gone.  That algorithm needed to be run sixteen times per side which comes out to be thirty-two times per players turn.  After becoming very disheartened with all the waiting between turns I decided that using the millis() function, which gives an updated time in milliseconds since the start of the games namespace, would be a better choice.  This optimization took the time per turn from about 30 seconds to about 6 seconds per turn.

The need now is to bring down the run time of the full chess board scan down to below 6 seconds between player turns.  Essentially what happens is that there is a triple nested loop that calls the chess pieces from both players sides that are placed inside dual switch/case structures.  But inside these, are conditionals that require values of the increment portion from the nested for/loop structures.  Where this all happens is the first game state, that being the portion of the game that is instantiated when a player clicks on either button given the title Black or White which rests on either side of the <== Next Move ==> label on the top of the screen, and that state continues through the scan to the point were all the values of the full chess board scan shows all of the possible positions a piece can move, for all the pieces on the board, along with a qualifier that shows if a piece is protected or if it could be taken that turn.  That is the first game state.  The second game state is when a player selects a chess piece by left clicking on it.  At that point the chess board is cleared of all the eye candy clutter and reveals only the information of the selected piece which is highlighted.  What happens is that (green) hexes show where that piece may move because of its given type, that is: Rook horizontally and vertically; or Bishop diagonally remaining on its starting color, etc.  This movement plot emulates what is given in the first game state but in contrast it is the only movement plot shown on the board, i.e Ceteris Paribus.  The movement plot is terminated when it reaches a chess board boarder, an ally piece, or a foe piece.  At the point of meeting an ally, if certain conditions are met according to that type it may be considered protected, at which point a (cyan) hex surrounds the piece that had terminated the movement plot of the selected piece.  A coincident action also occurs if the termination piece is of the other team, or a foe piece.  At that point that piece is surrounded by a (red) hexagon showing that that piece may be taken.  After viewing the options of the selected piece the player may right click in a tile on the board moving the piece to that tile.  If the piece is occupied by an ally piece the selected piece is unable to move to that tile, if there is no piece on that tile the selected piece is simply moved to that tile, and if that tile is occupied by a piece of the other team, a foe piece, that piece is automatically taken from the board and the selected piece is moved to that tile.  That player then clicks on the title name of the opposing player and the first game state is repeated followed by the second game state until checkmate, stalemate or victory is assumed, thus ending that game of chess.  But as stated, the need is to speed up the down time in-between player turns, i.e. the full chess board piece scan.

Done.  The inter-turn scan is down to less than a second.  All 32 chess pieces are scanned through their respective algorithms with dramatically greater speed and still with equal accuracy.  Also the highlight around the piece as when it is selected to move has been removed while the scan progresses.

What was done here is that that portion of code needed to be turned almost inside out and two more void functions were built taking four arguments each.  Giving the for/loop increments as the arguments of those functions allowed the exchange of the previously hard coded variables in the switch/case structure more freedom to access the necessary routines.  First building the entire structure in long-hand, so to speak, made the code consolidation much easier, although now it is more complex.  But the scan speed has gone from 30 seconds to 6 seconds to 1 second, with each new implementation, for all 32 pieces.

BackUp_02.  The next thing to clean up is the problem of the shifting pieces.  When a piece is taken, it is moved off the board and out of play.  The way the full scan is set up, all of the pieces, those in play and those out of play, are registered.  But while doing so a check to see if a pawn could be traded in for another piece was also flagged, and during that scan a pawn might shift a space downward in the out of play dungeon area when it was checked against itself.  It didn’t do anything to affect the game but the effect was that something on the board would move that actually had no reason to.  It just looked sloppy when it happened and could also allow for misinterpretation when actually nothing was going on.  Done.

There seems to  be something quite wrong with the movement plot of the King in the first game state, the state where all of the moves are drawn to the screen.  The plot of the King is shown radiating out like the plot of the Queen, while the Kings movement is only to be one tile horizontally, vertically or diagonally.  Hmm.  The two void functions TestKing(…) and PlotKing() are used in the first game state and the second game state respectfully.  I’ve checked the last game build, “Confection de Logic”, and that didn’t occur there.  So this must have come about because of the newly introduced algorithms that have sped up the scan.  And yes, while rebuilding the void functions and their call structures, the King and Queen positions got switched, so like in Dr. Seuss’ Fox and Socks, the Moose was drinking Goose Juice and the Goose was drinking Moose Juice.  Just switched there positions and all is well and back to normal.  That was some long searching and work to find this simple fix.

BackUp_03 thru BackUp_15.  Yikes!  The game has a name, “X ~ Change”.  And with that, numeration and valuation will assimilate all of the pieces movement plots along with the terminus functions of those plots that show protection and or peril for each piece each turn of the game.  The first thing to do is to tally up the movement plots.  A movement plot is found by taking each piece on the board and from their capacity of directional movement that turn, count each tile that can be moved to, for each piece.  At the games start only the Pawns and the Knights are able to move.  The Pawn, on the first move, is able to move two tiles forward which, for 8 pieces becomes a total of 16 tiles.  Also on the first move, the 2 Knights are able to move to 2 tiles each, for a total of 4 tiles.  When added together the total comes out to be 20 tiles total that can be moved to from the starting positions of the chess pieces.  The next valuation also comes from the movement plot of the pieces which pertains to how many pieces are protected by other pieces of the same team.  Initially, because of the tight placement of all of the teams pieces on either side of the chess board, the total comes out to be 14 tiles.  This is because the 2 Rooks have no protection from any of the other allied pieces on the board in the games starting positions.  Finally, the last valuation is that of the opposing forces pieces to be in peril because of a pieces terminus in concern to their movement plot whereby it would be, or have the capacity to be, taken by a piece on the allied side.  At the start of the game there is no allied piece that has the capacity to take an opponents piece off the board, and so, the count begins with 0, no piece is in peril on either side of the chess board at the start of the game.

*  A “Movement Plot” can be counted more than once per tile, but per turn, it is counted once for each and every piece that can move to that tile.  “Protected” pieces are only counted once as are also pieces in “Peril” no matter how many pieces protect or are able to take an opposing piece.

Now that those numerations have values it is possible to begin the fun that comes from the theme of the month, CHANGE.  The first thing to do is to change the given numbers, that being: movement plot 20, protected 14 and peril 0.  I tried to come up with something that would show the correct rundown of what was going on under the hood using each instance of a turn in either of the teams side bars, and this is what I came up with.  These three numbers are all multiplied together.  The problem of showing what goes on in code and what is seen in the side bar became a little more tricky and I ended up kinda getting it drawn somewhat respectfully.  This is how it goes.  If at some point in time one or more of the numbers is Zero (0), and seeing that they are being multiplied and didn’t want the result to be zero, I used a set of if() statements that would first check to find a zero in any of those positions and if so use a different function found in the next switch/case derived from the value given to set the following switch/case.  The result was, although the read out on the side bar always says, multiplied by (X), the code behind it never multiplies by zero.  Instead of leaving on the screen a zero followed by a multiplies sign after it 0 x, the number zero is just kept from being written to the screen.  This seems to be the simplest way to express what is going on under the hood and still provide to the players just how the numbers are being attained.  Something else could be put in place of the empty space but the game speed, in switching back and forth between the two players, should make what is seen from the chess board in comparison to the side bar apparent with little to no problem.

Those are the first three lines in the side bar.  The next line, the fourth line, takes the total given from the first three lines and divides that number by the number of pieces from that team still on the chess board.  That total is seen in green.  But if you look at the result it is given as a decimal.  What happens behind the seen is the total on the screen is actually the reciprocal (1/x) of the result which is given on the fifth line.  These first five lines come directly from the pieces on the board, where these pieces can move, which pieces are safe because they are protected and can not be taken without retribution and which of the opponents pieces could possibly be taken from play on the chess board.  All of these numbers change with each move of a piece for every turn.

The values on the sixth line has two values.  Although there are two values, they both equate to the same value.  The first value is attained from the time it takes for that player to make a move and switch to the next player.  On the time line above the top of the chess board two more objects have been added.  They look like stick people without arms or legs, just a long body and a head where the body is the color of the team, white or black, and the head comes from the sub color, being purple or orange.  When a players turn begins, so does that timer on the time line.  To give an idea about the utility of the time line, it has six different functions that can be read from it.  The top most number in light gray gives the overall time since the start of the game.  The number directly below is another timer that shows the distance in time from either side of the red central tick mark to the current players end time.  This number changes color starting the game as gray in its centered position of time 00:00.  Then, for example when the white team is active it ticks towards the white teams side, which is to the right.  Conversely, when the black team is active the timer moves to the left.  There are 7 thirty second blocks for a total of 210 seconds or 3 minutes and 30 seconds of time on either side or a total of 7 minutes on the full time line.  The next two time keepers are positioned on the far ends of this time line.  These times keep track of the total time each player has used to come up with their winning game plan, move the pieces and click the button to select the other players team to become active.  Now, we get back to the little stick figures and the side bar values.  When a players turn commences the stick figure always begins at zero and counts off one per second.  At the end of the turn the stick figure is placed at the end point on the timeline using the length of time as the measure of the distance moved.  That time is shown as the first number in line 6.  That number is then equated to another number by again taking its reciprocal (1/x), so the two numbers are the same but second number is the reciprocal of the first.  The seventh line is where the number of pieces and the attributes of the players remaining pieces and the time taken to move one piece where it changes the strategy on the chess board are combined to form a numeric value.  This value is given to a log() function where that value always starts out large, decreasing at an increasing rate, and become smaller until it meets the zero crossing where it decreases at a decreasing rate. This is drawn out for every second the player takes to make a decision to move a piece on the board.  But, both teams start with equal pieces and placement of those pieces, and with each move the dynamics change, and provide a range of opportunities to …

Hmm.  As all of this has been going on, I’ve also been working on a chart, placed underneath the chess board.  This graph is shown in a rectangle and is updated to show the current players ability to grow, or lose, their GDP, Gross Domestic Product, or possibly GNP (I don’t really know, it’s a game “For Pete’s Sake!“) for each turn of the game.  This is shown as an oddball type of a Production–possibility frontier, kinda, sort a, or something like that in nature.  So anyway, what it does is for the given instance, of a turn, the values taken from the metrics of all the pieces on the chess board, which are boiled down to one value, and turns that into a function that can be drawn as a graph and read simply and easily during the players turn.  At the start of a turn, the graph takes the metrics and draws out the full curve in gray.  Then, as the players turn ticks by while figuring out the best move, the graph updates with the actual value that will be awarded once the player has moved and has relinquished the turn back to the other player.  Instead of looking at the numbers change, the graph provides the most consolidated venue to show the most pertinent information at a glance.  One other feature within the graph are two red lines, one horizontal and one vertical.  Both do the same thing, that is, showing where positive gains turn into negative losses.

BackUp_16 thru BackUp_19.  So what comes next is, from what I have noticed, while moving the pieces about the board is that the update calls to the In Protection and In Peril functions are not reflected accurately when a piece is moved, then when it is put back, to then have a different piece moved before the end of the turn.  Although in a proper game of chess, once a piece is moved and then the hand is taken from that piece it is said to have been set in stone and is not to be moved any further that turn.  But, to reflect a more proper adaptation that would allow such behavior, and for the sake of utilizing the remunerations that could be achieved by glancing at the graph at the bottom of the chess board, I am now looking into the affordance that will allow such behavior, i.e. moving a piece, looking at the bar graph to see if it is a viable option, then moving it back to try a different piece, and so on.  In doing so, I’ve gone through the code and have added many different flags and function calls to get an understanding of the logical flow of the game.  With every change, the previous code has the possibility to influence another aspect of the game that was not initially intended.  That’s the nature of computer programming.  But in having done this with many trial and error attempts, I think I am getting closer to a solution that will update the statistics of the pieces on the chess board with each piece move within that players turn.  Thus far, the only full update was given as the players switched turns.  This was good enough when a simple number was totaled and a given value was accumulated, but in hindsight it may have not been the most correct value that accurately reflected the positioning of those pieces for that turn, and therefore the correct rate of accrual for that turn.  With that in mind and because of the capacity to scan the chess pieces on the board more quickly than previously, the possibility to get the true metrics from the board for that turn to be expressed on the graph seems to be a succinct possibility.

Looking at what has been added and where it begins as a flag, SetCPP, which stands for the incorporation of the function ClearProtectedPerilous(); placed, where that flag is set to true to be able to call that function once.  That flag in void mouseReleased() opens the gate to that function any time that the mouseReleased function is called.  Also as a stipulation to the ClearProtectedPerilous function being called in mouseReleased an && (AND) qualifier is added to an if() statement to combine the validity of the mouse pointer to be in the area of the chess board itself along with the action of the mouse coming from a right mouse click.  These two conditions must be met to trigger the action of another full scan of the chess board pieces.  Per usual, this came about by first just having the function called no matter what, which happened to happen at any mouse click anywhere in the playing field from any of the mouse buttons used.  It was interesting, but very messy and, as for being functional to game play, became annoying very quickly, thus the “fix”.  Ham-fisted numbskullery is the mother of invention, but “Luck is the Residue of Design.”

To continue in game play, test runs begin to show that although this now assumes promise, it is still running into stumbling blocks that, from what I would guess will become a myriad of subsequent “fixes”.  Nothing can be done with one flail swoop that will complete this directive without test upon test.  And so, I must see where this will lead from the game play itself and from all the tweaks that are involved as the objective of finding the chess piece moves are illuminated substantively whereby they are seen upon the graph for each piece whenever dislocated by movement.

The capacity for “dislocated by movement” is an important factor here because a right click can happen anywhere on the chess board which will set off the scan.  Seemingly this does nothing detrimental to the game itself.  But it is nonessential here because the normalcy of game play within the actions needed to go from a piece relocation, which is further observed through its rewritten graphic statistical representation, where the newly formulated calculi expresses the recompense and remuneration of that move, stays the same and is therefore redundant and is again nonessential.  Finding how this all may be alleviated is what comes next.  First off I will need to know which is the selected piece, get the position of that piece and then store that position so it can be checked against when/if the right click will set off that scan.  If it is different from the original position, then the full piece scan should run once to repopulate the values used to draw the graph within the chart.  Easier said than done.

Denial of illusivety is what has become at task.  Capture of the position, validation of relocation and probably something else or more will be needed to get this to happen.  Let’s start with the capture part.  It’s a players turn, the timer is ticking, the graph is drawn and the values of “positive returns” are diminishing.  A player selects a piece to move, ding, ding, ding.  This is where the capture commences, but where in the code is it?  I need to make my game screen sloppy with extraneous coordinate pairs of indices and labels once again.  OK, I think I have something with CaptureI and CaptureJ that are set in the left mouse down set of reestablishment variables block.  But once the right click occurs the scan initiates and those variables are reassigned and become useless for the intended purpose.  I need to give them over to other dedicated variables byValue to keep them resident and be able to use them for validation later on.  But this needs to be done once in a different block of code so they are not rewritten as the games code flow progresses with its many passes per second.  Hmm.  Oh yeah, this is a frightful mess.  Yup, nothing.  Still working on it, but, the graph is now color coded where when the total GDP for that turn is above zero the chart lines are green and when below zero the lines are red.  Also in the side bars the values that are used to derive these colors have the same color scheme.  Well, that’s just beautiful.  I give up, but not surrender.  It’s time to run back a few Back Ups and start where things were working better than they are right now.  The biggest problem is that although I can get it to scan the board after a piece move I can’t get the player switch buttons at the top of the game to do what they were intended to do, that is switch to the other players team pieces.  It’s a mono on nobody.  It’s an only one person can play one team and can’t do anything else game.  Wee, oh what fun.  Now which Back Up was the one that is the last best Back Up to start with.  Back in a moment.  But first to save this mess.

BackUp_20 thru BackUp_??  It looks like BackUp_16 is where the Research and Development started all these test progressions.  So now to open another sketch and load some of the other back ups out of archive to dig out some of that R&D.  Not all is lost, some of that worked, I think, kinda sort a, a little bit.  Things are movin’ slow right now, like, real slow.  I had better play this version through a couple of times to make sure this one isn’t just hanging in there by a thread.  The graph color upgrade and other value coloring is getting dropped into place and saved in BackUp_20, more to follow.

Hmm, good morning.  And I have lost my stream of thought and think I’ll need to start again from BackUp_20, maybe.  Yep, I’m still learning how to build it forward and to still have a system that will step back to a point of consolidated stability while being able to collect the few trinkets that would have otherwise been lost as R&D while building and testing obscures the consistency of the program as it moves further into complexity.

Well, it’s kinda fun figuring out how it doesn’t work.  But, what I’ve got here, again, is a game that has two major modes.  The first mode is where all of the possibilities of movement and their consequences are shown.  The second mode shows the repercussions that occur for a single piece as that one piece is shown in isolation.  The situation that is of concern is when, within a players turn, a piece is moved to another tile to see how it affects the statistics given in the side bar of that player.  Until the player switches the turn over to the opposition, any piece can be moved multiple times about the chess board but only one piece can be moved to a valid position per that turn.  The only exceptions are when a Pawn is traded for another piece or when the King and the Rook use the “Castle” maneuver.  So when one piece moves, the “Evolution” or the “Castle” moves are performed which is considered one valid move and the turn may pass to the next player.  Then when the player is satisfied with the strategy found within the given time frame, the player selects the turn advance button at the top of the playing field.  This runs through the function that relinquishes the turn to the next player where it resets some values and clears the way for the next player.  OK, simple enough, sure.

Now to define just what problems become apparent as this process is set into play.  Where to start.  The game begins with the splash screen where the only options are to select either the Black or the White team buttons to acknowledge who goes first.  From there, that screen is exited and the chess board is shown with the pieces in their starting positions.  The pieces are scanned to reveal their contribution to the battle plan.  Those contributions are tallied and totaled in the side bar and finally these statistics are shown in a bar graph below the chess board.  As the first player sees this screen being drawn out for the first turn of the game, a set of timers begin to count out various aspects that afford to the player delineations of time used.  These timers mark out, total game time, total cumulative turn time for either player, a count up count down per turn time and accompanying bar on the time line, a single turn time which is reset at each start of a players turn and is seen in the side bar where, this time is also drawn from that single turn time as it is combined with the chess board statistics to be revealed in a chart given as a dynamic bar graph.

There seems to be a multitude of complexity within this basic set of actions.  What I need to do is to separate when calls to the screen are instantiated per logic cycle in comparison to the logic that updates the actions of the player.  A call to draw the screen when the logic that performs these other functions have not yet been completed at best just cause the screen to flicker and at worst revaluates the variables which give false readings or change the logic flow to the point of inoperability.  All of these problematic instances have happened within the building of this game as it has continued to grow in intricacy.  As if you couldn’t tell.

Enough of this administrative banter, but it has actually let me see where I’m not.  To get where I’m going how do I slice and dice this code.  More R&D, more scrolling up and down, more side notes and searches, more cut and paste, more comment/uncomment, more logical in/exclusions, more building and documentation, lest I forget.  So where am I?

That last excursion in speeding up the piece scan, from 30 seconds to 1 second, involved separating the logic from the draw code.  And with that, I think I’ll be needing to do the same again and continue to separate the last parts of value update code from the remaining perpetually scanned draw code.  With each cycle, from what I can gather, the code page is read from top to bottom.  The game starts by initializing the global variables, then jumps into the setup() function to instantiate the variables with their initial values.  After that the code is read again and again from within the draw() function.  I would guess that it has come to the point in building this game that I do that again because I’m sure that I have no idea of what is actually going on in there as of late.  With that, the first order of business is to start at the top and cut out all of the commented out trial and error code, then save that as BackUp_21, done.  This will be my next waypoint if I should ever need to retreat from my continuing expansion, which I probably will.

The code page is clean of extraneous detritus.  Next on the list is to give a visual “hand check” to get a grasp of what is called from where.  And in doing so, of course, I have added a couple of more visual cues.  While play testing this game, and looking at the bar graph, the time given to have a positive collection of GDP was given by looking at the left side of a vertical red line that marked where the zero crossing occurred.  The left side bars on the graph are shown in green while those to the right of the zero line are shown in red.  But where is zero placed on this graph?  It moves from turn to turn and also from any update from a piece movement during that turn.  How long do I have before there are negative returns?  Is there a value I could see on the chart that would let me know just when that would happen?  Of course there is.  And so there is now a numeric value set in the top middle of the chart that counts down to zero.  When that number reaches zero the value disappears, because it isn’t needed any longer.  But if a piece is moved so that its positioning moves that zero crossing reappears and continues to count down to zero again.  In that way, not necessarily will the best or most strategic move be made but, it will give a better idea as to when a positive return could be made.  Also there have been added two markers placed on the top and bottom of the outline of the chart.  It was the best place to put them because of the scarcity of the limited space left to be populated in the game screen that could possibly make some sense from the statistics drawn from the game values.  These markers start on the left side of the graph and as the final totals from either teams side bars accrue, these markers make there way across the charts outlines on the top and bottom from the right as a small reminder of who is ahead in respects to that GDP part of the game.  Nothing much, a little bit of indiscernible clutter, if you don’t really know what it is for or what it means.

So anyway, back to the logic flow.  Or, I could save BackUp_22, because I have added a scenario where when one of those little stick figures gets pushed back to the end of the timeline, the opposing team achieves Victory.  This comes about from the up/down count timer that uses the white and black bars at the top of the game screen.  There are three minutes and thirty seconds on either side of the zero mark on the top timeline.  So, for instance, when it is the Black teams turn, that team uses time to get the strategy together, move the piece and then switch to the other player.  While all that is happening the bar lengthens, to the Black teams detriment, and moves closer to the left side of the timeline end point, being three minutes and thirty seconds.  If that bar moves all the way to the end, time is up and the opponent is victorious, the game timer stops and the game is over, but also visa versa.  Yes, I’m still looking for a way to update the statistics with each piece move, sure, I’m gettin’ there, eventually.

Maybe getting the chess board to not draw any of the movement plots, InPeril nor InProtection icons to the screen would be another way to find out how to get the value update logic separated from the draw calls, just so I can get another idea of how this might be done.  To figure this out I’ll start another mini project within this game to see when pieces are called to move.  As it stands, a chess piece is left clicked to be selected as the piece to move.  When that one piece is selected only that piece has its move statistics shown on the chess board.  When the mouse is right clicked on a tile that has an ally piece nothing happens.  If that tile has an enemy piece on it that piece is taken from the board and the ally piece replaces that piece on the tile.  When no piece is present that piece is simply moved to that tile.  Simple enough, on the outside.  On the inside there are some boolean flags that need to be switched so that the other statistics are not drawn to the screen.  At this point I will need to start some R&D searches so I can have a start tile and an end tile with their positions accessible for that one piece.  The problem so far is that the function used to get that information to the draw method is volatile, meaning that it changes frequently and rapidly, it is not stable.  If I capture a value from that function, which is the starting position of that selected piece and then right click to move it, the function that initially gave that value is the same function that revalues that value to have it move to its new position.  Hmm.

Save BackUp_24, this save changed the middle count timer under the total game timer.  With this change that timer now reflects the bars start position and length as it counts down to zero as it gets closer to either end of the timeline.  3 : 30 is the middle of the timer and 0 : 0 is at either end of the timeline making it easier to understand just what the white and black bars are representing.  When that timer reaches zero, (0 : 0), the other team achieves Victory, but not necessarily CheckMate nor StaleMate.  Another change is to move the Accrual Markers to the middle of the bar graph chart, top and bottom, from being on the far left.  The starting position allows for a positive and negative movement of these markers seeing that both + and – values are used when coming up with a total accrual of the given statistics.

Save BackUp_25, this save moves the turn counters, those that are incremented each time a player finishes a turn and gives it over to the other player, from the inside of the top of the far ends of the timeline, to the outside middle of the ‘current piece’/’taken piece’ rectangle in the upper left and right corners of the game screen.  The next update/improvement is found in the chart portion of the bar graph in the center bottom just below the chess board.  The scenario goes like this, a players turn starts and a bar graph from the current statistics are drawn in the chart.  The width of the chart is 200 pixels, so there is only enough room for two hundred ticks of the timer, seeing that the count ticks off once per second.  Three minutes and thirty seconds comes out to be 210 seconds, but that is from the middle of the top timeline, which would leave 10 seconds that would move out of the charts rectangle as an over-run.  Also the total time from one side to the other would be 420 seconds, and that would run past the game screen completely.  So this save adds the logic for what is needed to keep the graph inside the chart.  As the timer ticks away, at some point there is the possibility of the count to reach the middle of the graph. At that point the graph begins to move to the left along with the zero crossing so that the full range of the graph can be viewed.  With that upgrade it can continue to be referenced quickly as the player looks for the best move for that turn.  Now back to finding how to update turn statistics with each move within the turn.

Or I could do a little more work with the bar graph.  What has come to mind is, as a players time is used and as the timeline bar above the chess board moves closer to the current players last seconds of move time, the bar graph on the bottom of the chess board draws out the values across the entire chart.  This looks nice but it doesn’t reveal to the player what is actually coming their way, that is, the other players victory because too much time has been used for strategy and movement.  As it stands, the bar graph moves to the left to keep a good portion of the graph visible, but there are only so many seconds that need to be shown from the bar graph that are pertinent to the actual amount of time left to be played in the game.  At some point in time there are only so many seconds left, and so, only so many increments need to be shown by drawing that many bars on the graph.  If the whole graph is filled, the cut off point, that is, when the game ends, is not given to the player or represented in actual bars remaining in the bottom chart, therefore the coming end is not clear.  This is what the next puzzle will be that I’ll be working on next.  To cut the length of the bar graph short will take some interesting mechanics within the for/loop that draws the bar graph to the screen.

Save BackUp_26, and this is what I’m getting this little game to do.  But I have need to expedite this process, not in the actual building of the game but in the testing of this game.  Each time I make a change to see just what will happen with each little tweak, I need to run the game to the point on the timeline and the corresponding bar graph to see just what has happened.  As noted, it’s a seven minute timeline from end to end, and so three minutes and thirty seconds on either side of the center.  Now guess what happens when I need to figure out what happens at the ends of the timeline or at the finish of the bar graph, that’s right, tick, tick, tick … and tick, tick, tick … and tick, tick, tick until it gets to where I need to see how things turn out from the change in the game.  Well, what I have added to this save are two things that speed up this process, and they are… uhm, well, …  The first thing is to add a pause to the timer of the game to stop the game in its tracks.  All I need to do now is click the middle mouse button and the game will pause until I click the center mouse button again.  I can see just how the variables change with each increment of a second, in the game screen, at least, but not within the code page it self, C’est La Vie, C’est La Guerre : such is life, such is war.  The second adaptation that has become enormously helpful is adding the capacity to speed up the time from a one second increment to where it can run as fast as the CPU can run the games logic cycle.  I can now zip through three minutes and thirty seconds of one second increments in about five seconds, yippy zippy.  This should speed up the testing for each change I make to the code as I try to get the bar graph to match up with the timeline with all of their interconnecting markers.  All I need to do now is add some visual cues to the game screen so I will know what mode I have the game running in.  OK, now for the Easter Eggs, to get the timer to speed up, left click in the upper left or right text boxes, the ones that are either white or black that say Pawn takes King or something like that.  A double << or >> will appear on the top of the screen in green while in zippy mode.  Also the pause button comes from the center mouse click and will stop the game timer.  An icon seen as ||, will also appear on the top of the screen, denoting that the game is paused.  Clicking again will set the game back into normal play mode.  Now back to figuring everything else out.

Save BackUp_27 and BackUp_28, was a lot of hackin’ through the forest, but the graph is working rather well.  That little bit of extra work figuring out how to pause and speed up the game, hmm, and also how to have the side bar statistics be removed from the game screen so I could get a whole slew of other pertinent variable values and their labels out, and, and, and…  But at any rate the bar graph at the bottom of the game screen is done.  It works, and it is synchronized with the timeline at the top of the game screen.  Right now it is saved with all the messy trial and error code that was a bunch of, how about this, but what happens when this player runs it to the other side of zero and then the positive counter is now negative but minus a negative is not actually subtracted but added as a larger negative value, but not, and so on and so forth.  I guess I’ll need to tidy up the code and straighten out all of the curly braces, that’s the fun part, anyway.  But back to it and more testing, perpetual incremental testing.

Save BackUp_29 thru BackUp_33, YES, I have finally got that pesky in-turn update to work for each move of a piece.  With each piece, of the current player, as it is moved about the chess board, the side bar statistics are changed to reflect the updated values.  That was a ton of everything that it takes to get it done.  I am way happy now, I only thought I could get it to do the things that it does so well, but now it does.  Yippy!  Also the bar graph draws out those statistics for each move.  And the best part is that it takes about a second of down time to get it to show the updated data from the complete chess board scan.  Ah that my Laurels are Hardy, “Well, here’s another nice mess you’ve gotten me into!“, but thankfully out of.  And like so much of joy, not that it is so short lived, but to take it onward into the last of the tweaks to come.  And with that …

Save BackUp_34 thru BackUp_38, hmm, if the fast forward mode is selected and there is a right click of the mouse while in fast forward, the bar graph is zeroed out as it is drawn to the chart below the chess board.  Again, this does nothing to change the game but it does look sloppy.  So what I’ll be looking to accomplish next is to match up the thirty second intervals in the top timeline with the tick marks that appear at every thirtieth bar in the bar graph.  And I think that will be just about it for this game build, maybe.   Or, instead of that I’ll add a small help file on the intro screen.  Keyboard keys 1, 2, 3 and 4 are set to be show/hide switches that are for the Statistics Side Bars, Full Board Movement Plots, In Protection and In Peril visual cues.  These can now be toggled on and off individually, starting the game in the off position.  Also, when a Pawn reaches the opposing teams back line and can Evolve into a new chess piece the Statistics Side Bars are hidden to allow access to the redeemable pieces that have previously been taken.

Just added some fade in stuff so the screen is more conducive to game flow and the timing used during board updates as the players move their pieces and switch off between turns. The keyboard keys 0 thru 9 all have new functionality switching different parts of the game screen icons on and off.  I have further enhanced the fade in and out so that with the in-turn statistics updates the player shouldn’t be able to click on something that isn’t ready to be clicked on and will mark that it is ready for play by fully fading back into view.

Almost done, but naught to be as yet, and so, one more time to this proverbial well.  To top this game off I will try to get a starting position and a finishing position placed on the chess board for the selected piece that moves that turn, plus an icon representation of that piece.  Much more easily said than done.  As mentioned, the volatility of the variable values is a major sticking point.  With every click of the mouse, a scan ensues that looks to find that piece and set some flags.  Then from that to draw a different aspect of the game board for when that piece moves to a new position while also taking into account other ancillary actions that may occur because of that move.  The first thing I’ll need are two variables, a coordinate pair (X, Y), that are set once and are not overwritten after the piece is left clicked.  Once registered that set of variables will be the positional representation of that piece until it is moved or deselected for another piece.  If that piece remains selected the game does not let the player switch turns, so that variable should be safe to use for this purpose.

Save BackUp_39 thru BackUp_46, and that is that.  A little bit more of code clean up and a couple of other things.  Another one done.

The Game is Complete.

Play the Game Here.

X ~ Change.

Until then, G’day.

November 30, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0047] ~ Confection de Logic:

Updates – . . .

Java Version 7 Update 45, Uninstalled Java 6 Update 20.  And the theme this month is CANDY.

What is Candy.

Candy, looking at it from a “normative” point of view, should be a sweet treat given and taken as a gift that makes someone happy.  It is truly a superfluous gesture of content, but carries a capacity to generate good will and denote a special time to extend a special moment, like dessert or an after diner mint.  And this is how I will be looking at this months theme in concern to this months game.

Building a Concept.

My mom asked me a question recently, “How can you see in the dark?”  And seeing that I’ve been doing a lot of computer coding lately I took the question away from the small talk we were having and later on thought about it with a little facetious spin.  Inside the computer it is dark, there might be some electricity to power it but in general it is dark.  The same goes for my brain, apart from my electrochemical neurons sparking greater pathways, however that all works, it is dark.  So how do I see in the dark?  Comparative memory of memories of what I have found or at least what I have been lead to believe and by having those memories become consistent from other past experiences.  This is how I see in the dark.  And with that thought, it started me off in another direction when it came to building this months game using the theme Candy.  And of course, I’ll continue to version my way through this month keeping the overall theme the game of chess.

Ceteris Paribus

This game, during game play, has two main states.  Clicking on either button titled White or Black to start the game the first game state is initiated.  This first major game state is seen through a mode where all of the chess pieces are scanned individually.  Each piece is highlighted for a fraction of a second as an algorithm collects data for each chess piece.  In that scan the viable path of that piece, if it protects another piece or if it has the possibility of taking an opponents piece are stored to be revealed in the second mode of the first state.  The second mode in this first game state is where there is a change on the screen that becomes updated to show this new information in a manner that looks like it came from a confectionary, thus following the Candy theme of the month.  The second game state can be selected from any of the chess pieces still in play.  Clicking on a piece of the team whose turn it is to move, shows the options of that piece alone, i.e. ceteris paribus.  The movement plot, any piece that that selected piece protects and any piece that that selected piece may be able to take are shown.  After a piece is moved, that player clicks on the opposing players button on the top of the screen advancing the move to the next player.  If at some point the King is put in Check, the screen changes showing the word Check and flashes the King piece in red.  The process continues back and forth until a checkmate or stalemate status is assumed from the players.

I’ll be doing the documentation differently for this game.  On previous game builds I would build, document and save, build, document and save, build, document and save.  This time around I decided to just build and save, build and save, build and save to finish the game and then work on the documentation.  What I’ll be doing now is reopening the save files, loading and running them to see just what got accomplished at each save.  At times the saves may have been redundant or possibly a panic save just in case but for the most part each save had some substantial change of code yielding new implementation of the added functions and logic.

The Builds, the Saves.


The base code comes from the last game Chess Sequester.  The initial change was to move the title from the center to the bottom of the screen placing it underneath the chess board and to add some flash to the opening screen.  I used some random RGB colors that changed the colors of the hexes so the screen would flash different colors randomly.  The intent here was to give the splash screen a happy candy look.  There doesn’t seem to be much else from the original game that had been changed other than that.


This next phase changed the candy coloring to shades of black and white that keep the general structure of the chess board using shades of gray that flash on the screen.  The title was also changed to Mind-Candy.  When the game is started the chess board is fully visible, unlike the previous game that started with no tiles showing on the chess board.


The splash screen has changed again and has (X, Y) coordinates of the pieces in black and white on either side of the chess board.  There are also black solid square symbols that originate at the position of the pawns with a black line that ends in a solid black circle following the movement plot of a black pawn.  The same is found from the position of the white pawns.  Starting the game and having all of the chess pieces placed on the board, the same movement plots using the described icons follow the pawns as they move on the board.


On the splash screen the pawns movement plots have been removed.  The time line has been changed.  The letters on the time line are gone and three numbers, one on either end and one in the middle.  Starting the game the timer ticks off the seconds and move the red line closer to the current player side.  When the next player start their turn the timer move in the other direction and the counter begins to accrue more time on that players clock while the opposing players clock stops.  The middle timer count up and down as the players trade turns.  The (X, Y) coordinates are also missing.


The clock time is now given in minutes and seconds, ” 0 : 0 “, instead of a single number given in seconds only.  The (X, Y) coordinates are back and when a piece is clicked on, selecting it for movement, the numbers change in how many are shown for either side, why I don’t really know.  But there are now magenta colored hexagons on the chess board that follow the square-line-dot icons described above.  The hexes also follow the movement plot of pawn as it moves.  There are also highlight squares around the chess pieces.  There is a yellow square around the white pieces and purple around the black pieces.


On the non-selected piece screen the all the pieces on the chess board show their movement plot in the hex color of the highlight square that surrounds that piece.  The hexes line widths are also larger.  The board is very cluttered and indiscernible.  There is also another clock timer on the center top of the play field that shows the total elapsed time of both players.  The hexes don’t follow any rule that places them on top of the highlight squares of the pieces.


None of the movement plots on the non-selected piece screen are shown.  The Rook is the piece that was being worked on.  The Rooks movement plot now shows a half-hex on the board in the non-selected piece screen.  The movement plot has been changed for the Rook so that when it comes up to an ally or opponent piece the movement plot stops.  In previous versions the movement plot continued through and past the blocking piece.  Also only one Rook from either side has this new feature, none of the other pieces has this feature implemented as yet.


Hmm, the black and white (X, Y) coordinates are back on the side lines of the chess board.  Maybe something else significant happened, maybe, but nothing noticeable.


Only one Rook, black, has the half-hex movement plot working.  The movement plot only works for the white side.


All four Rooks, two white two black, have their respective highlighting and all four have the movement plots blocked when they run up against another piece be it ally or foe.


Hmm, more extraneous numbers on the screen.


Working on the Bishops now.  The colors of the movement plot are of the same side for both the ally and foe.


Still working on the Bishops but I can’t notice any real change on the screen.


Working on the Knights.  Each have their own color for their movement plots.


More Knight stuff.


All of the chess pieces are highlighted except for the pawns.  All of the pieces have their movement plot shown in their respective color, except for the pawns and the King.


All the pawns show their highlights and the selected screen shows a change of the movement plot that is more constricted than previous builds.


The letters of C-H-E-S-S are printed to the splash screen in random positions.


The name of the game has been changed to “Confection de Logic”, and the King has its movement plot shown in the non-selected piece screen.


The pieces in the back row no longer have their highlights in the non-selected piece screen, only the pawns.  The black and white (X, Y) coordinates numbers are back, along with a couple of other numbers showing about the screen.


Hmm, panic save?


Starting to work on the movement plot of the pawns in the piece selected screen.  The pawn no longer shows all four spaces that a pawn can move, leaving only two forward tiles before a pawn moves and then one there after.  The two diagonal movement plots are only shown when a piece is in that tile.  The two modes are, if an ally is in the diagonal space it is highlighted with a cyan hexagon showing that it is protected by another piece and if a foe is in the diagonal space it is highlighted with a red hexagon showing that it is in peril of being taken.


Hmm, panic save?


All of the chess pieces are highlighted again.  There are two numbers in the bottom left and right sides of the screen that show the coverage of the chess board that a piece can move to.


The first glimmers of a logic scan are started.  The side that goes has each piece highlighted and scanned one at a time, pawns first then the crown pieces, to show the movement plot for the turn to come.  That scan also shows which pieces are protected, cyan hex, and which are in peril of being taken, red hex.


The switch is to the back row being scanned first.  The scan moves at one piece per second, or 16 seconds per side each turn.


Hmm, panic save?  Minimal back ground tweaking?


The one piece per second scan, at the end of the scan, updates the movement plot of all the pieces and also shows which pieces are under protection by another by another ally piece with a cyan hex and which foe pieces are under perilous threat with a red hex.  The hexes have a smaller line width than the movement plot half-hexes each with the given sides color, yellow or purple.


There are only a couple of numbers on the screen testing something or other.


Changed each time a player is switched to scan all of the chess pieces for movement plot, ally protection and foe peril.  This scan takes about 30 seconds each time a player switches to the other player.


I can’t see too much of what might have been changed.


Knocked the whole scan time down to 6 seconds, that’s 3 seconds per side.


Hmm, panic save?  More minimal back ground tweaking?


Changed the foe is in peril, red hex, to a half-hex.  This lets the ally is protected whole hex underneath show.  A chess piece can now be seen as protected and in peril from the non-selected piece screen state.  The single selected piece screen mode still shows whole hexes for the movement plot (green), ally protection (cyan) and foe peril (red).


Cut out all the commented code and cleaned up the white space in-between the code lines.


Cleaned up the screen so no test numbers are printed to the screen.


Enlarged the numbers that show how many tiles are available to be moved to for the remaining chess pieces on the chess board.  Also those same numbers are shown in the respective sides colors either yellow or purple.  During the scan, if the King is in peril from an opponents piece in the same place where the title of the game “Confection de Logic” is shown, Check pops up written in red.  After the scan the King slowly flashes in red to leave no doubt that the King is in check.  Checkmate is still up to those involved.

The Game is Complete.

Play the Game Here.

Confection de Logic.

Until then,


October 30, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0046] ~ For the Sequester:

Updates – . . .

Adobe Reader X (10.1.8).


This months theme is HEXAGONS.  But, per usual, I’ll be versioning my way through this game because I still have some ideas left over from last months game, ChessPionage.  There were things that I thought might be interesting to incorporate into yet another version of a chess like game such as masking.  Masking is taking one image and using it to make a portion of another image invisible, see through, masked.  With that thought, and with the other images of chess pieces that I had already built, I came up with another way that a chess game could vary in its game play nature.  And so I have set off getting the mechanics for those features ready for use in this months game, Ghost Chess.  As I’ll be using what I have already built for last months game, I’ll need to reference the backups of that game while I move through this months game, mostly for formatting positions of screen objects but also to be able to take into account the logic flow from what it was then to how I would like it to behave now.  In this current game I’ll, OR . . .

Eternity is Fleeting.

I’ll need a timer, of sorts, in this game.  So, of course I’ll start a new project called CountDown.  First off I’ll get a starter project named second() from the Processing.js web site and begin to manipulate that.  Seeing that only the seconds are needed, I’ll comment out the minutes and hours keeping only the seconds.  The seconds come from the system clock and as such provide what the current seconds are that are on the clock of the computer.  This gives me a value between 0 and 59.  But this project is focused on giving me a count down of seconds and to keep it within a mental reach so I can build, test and evaluate the results in real time.  I’ll have it count down or up from 0 to 5 and then restart to do it again.  Simple, but not.  Zero is not always zero unless it is set to zero at the start of the count.  Zero could start at any number from 0 to 59.  When the game/project is initialized it gets the current system clock second() value and it is given to a variable to remain constant, for the time being.  This starting value needs to be converted to zero so a count up increment may ensue.  But, this does become a puzzle because when the count reaches 5, in this case, the starting value which was constant in concern to the count up operation now needs to be updated.  The reasoning behind this is that along with the operational constant, another value of type second() needs to be evaluated against it.  Picking any random number in-between 0 and 59, and then having another number subtracted from it, being of type int second(), does not always yield the intended result.  This thusly produces the second by second fleeting eternity in-between the observable test of each value while the seconds are manipulated by the functions meant to evaluate the processes and return the proper results.  As time moves along, the calculation, because of the difference of the start time and the increment cut off time produce inaccuracies that are not conducive to a testing process that is instantaneously apparent or calculable in real time.  One would think that it would be as simple as subtracting start time from finish time but one would be deluded to believe in such a hope.  If the first value were to be 56 and after counting out 5 increments of type second() the end value would be, I think, 1, if 56 were to be 0, in this case.  And this is where the observable value testing, while this short program is running.  It has proven to be, hmm, somewhat entertaining, I could say, maybe not, but maybe.  More hammer and tongs, printing the values to the screen as they change and capturing what I can, in real time, to get this count up timer to work, properly.

And Yet More Shredding.

I pealed the guts out of that last function I was working on, in its entirety.  It was a bunch of if(sometime > OR < sometime) and + OR – some other time then == to the value of the counter and stuff like that, just a bunch of, this? maybe not, or how about, but if I … and so forth.  Now to start it all over again.  Ok, that was a tidy bit of work and suffering but I’ve got it to count an increment once a second with one boolean, two ints of type second and one int as the counter, simple.  And to top it off I added some graphics to show a line that moves with each increment, kinda like what the original sample had except that for any second the counter will increment one second so any interval can be captured.  Now, the question is, “What is it good for and how will it lend itself to game play?”

The Timer.

Back in Ghost Chess I built a timer that fits on the top edge of the chess board.  It is set so about three minutes and twenty-five seconds from the midpoint to either side will tick off in either direction.  An approximate total of six minutes and fifty seconds is what the full length of the timer allows.  When a piece is selected, the current player will find a small red line moving towards the direction where the captured pieces for that player are located.  I still don’t know what repercussions might occur when an interval of or the edge of the timer is reached.  But its up and running and for now, when the edge of the timer is reached it simply resets itself back to the middle position and continues to tick away.  This game is starting to get thick with code and will soon need to borrow from past builds to get the game play to work correctly and quickly.  As it stands anything goes, the rules are breakable, if you’re looking to follow the rules, that is if you even have the slightest inkling of what the rules might be.  Hmm, once again, stealing from Peter to pay Paul, what can ya’ say.

Moving along.

Grabbing some old code from Trail Blazer, I’ll add DrawSwitchPlayer = false; to the mouse move function so a box will be drawn around the text Black or White at the top of the screen so the player will know that that portion of screen is to be clicked on to move the game along.  Currently I have the code to draw the rectangle in void mouseMoved() but the rectangle flickers because it only calls that function when the mouse is moved, not when it’s stationary in that portion of the screen, ergo the boolean flag which will hold open a draw call and alleviate that problematic flickering.  In simplicity it does the trick.  But life should be so simple.  That takes care of when the mouse is moved over the text Black rectangle portion, so the player knows that clicking there will start the timer for the Black House.  And now for the White House.  Fool that I am.  I thought that if(HouseColor == 0), which is a flag to denote that the Black pieces are to now be in play could be of use, but using that flag does no good because, . . . or . . . nope, I was right.  Its not quite a circular reference but something more like setting a flag inside a flagged block that needs to be set to set itself.  But because the flag is in its own boolean if() block it can’t be referenced, ha, something else will need to be done, stupid logic.  Maybe adding WhiteGoes = true; and BlackGoes = true; might work.  I love this large stack of global variables, no classes with pure linear logic.  It’s not modular, nor built to be reworked easily, just built to work.  All right, I’ve got that to work properly with those booleans and have the rectangles appear and disappear when the area inside those rectangles are hovered over with the mouse pointer.  The next piece will be to activate the player and the accompanying timer mode when that area is highlighted and left clicked in.  HouseColor == 0 OR 1 does work now but it works even when the player hasn’t moved a piece yet.  It works exactly the same as if a player clicked on a piece in the previous game.  That also was the procedure to switch the other players timer and would start the movement of the red line in the other direction.  It has produced some change, but it still has no lockout.  So how or what will need to be set to acknowledge that that player has moved and is now ready to relinquish the turn to the other player whereby the selection buttons for the next players turn will reappear.  HouseColor = 3; might lend itself to do something of this sort, but how and where?  I need the position of the selected piece so that when the board is right clicked on, the previous position can be checked against the position of the piece prior to that which is current.  If they are the same no action is taken, if they are different then HouseColor = 3? and the next players text will come up along with the rectangles and accompanying code to be processed.  Oh yea, Fox in Socks and clocks and blocks.  Looking at all this code makes me want to just start a different game, but this is doable, I think.

Your Turn.

But first a backup save #02, and now back to it.  I’ve dimmed the timer a bit and reworked the interface so it isn’t as obtrusive.  The next bit will have to do with how the timer relates to the current player and how that player switches the turn back to the other player.  As it stands the game starts with an empty board with no tiles showing.  The white and black chess pieces, made from the masked images, are set in place with the black pieces on top and the white on the bottom.  The timer is just above the top of the chess board and above that the text Black <== Start With ==> White is displayed so that either the White House or the Black House can start the game.  I added some flag logic so that at the beginning of the game, when the mouse is moved over either the text Black or White, a rectangle appears around the text denoting a left click will select that House as the starting player.  Clicking on one of either of the buttons will start the red line of the timer moving in the direction of the selected players, for lack of a better word, dungeon.  I’ll call it a dungeon because when a pawn gets to the end row on the other side of the board that piece can be traded in for one of the pieces that had previously been taken, if the Queen has not been taken you can’t get another Queen.  So they’re not dead, they’re in the dungeon.  Once the side is selected another rectangle appears above the dungeon.  This box has the color of the current player and in that box, when a piece is selected to move, the name of that piece is shown therein.  If a piece from the other players side is taken to the dungeon that piece is also shown in the box along with having that piece visible in the dungeon.  I have also added some flags so that only the House whose turn it is is able to select the pieces of that House.  And that is how far this games build has progressed.

Nitpicky, for Good Cause.

I’ve just been running with it for a short time.  There has been a lot of trial and error tests with logic and object formatting on the screen.  And the name of the game has also changed.  What used to be Ghost Chess is now ChesSequester, two words mashed into one title.  With that, I might as well explain just what the desired result will become because of the mechanisms being formulated in the game.  To start, chess is chess, it uses the base template of the named game, the pieces, the board, the movement, the tactics.  Sequester is the additive operation to make the game different it its essence.  But as for the formatting, void mouseMoved() and void mousePressed() take care of the logic that to aligns the rectangles that are being drawn to the mouse hover and click operations that the system reveals to the program.  Those rectangles are designed and drawn from calls at the top of the code page, and yes you guessed it more scrolling to get there and back again.  I miss GOTO function/variable name.  Those are nice speedy jumps from the API dropdown menu item.  So anyway, sequester means Sequester, when found in a Wiktionary link.

More Crash, Boom, Bam.

I’ve been just coding for a bit and I’m up to save #09.  A couple things I have found is that when an argument is passed in a function call where that function data type is an integer and the its source is from a random() function generator it needs to be passed to that variable as an explicitly boxed integer type.  It seems that the random generator, even though given two integers as arguments for the low and high limits, still does not make that returned value an integer.  And so, int RND = (int)random(-1, 8); to get the a random value of [0, 1, 2, 3, 4, 5, 6, 7] is needed or the void function will not pass that value as an argument from the calling function into the function that receives it to be used within that function.  This came to be because an array ARY[RND][0] would hang the program and leave me no idea as to what might be causing the error.  The problem here was that RND, a randomly generated integer, when not explicitly declared and converted became an unacceptable value to denote the position of an element within the array.  But all is well and it works now.  This came to be because of the timeline in Chess Sequester.  As the red tick mark circle combo moves away from the zero mark in the middle of the timeline, either away from zero into the white or black timeline, the perilous nature of sequestration in concern to the chess game is found.

Messy Writing.

The save is up to #14.  I have also read through the above paragraphs and from my point of view can almost barely understand it.  But seeing that I had written it, it kind of makes sense as it presents itself as a huge block comment.  It is more of a convoluted mental pathway of bread crumbs so I’m not completely clueless went I need to reference some reasoning of change within the game.  It’s definitely not Hamlet,  more like Green Eggs and Ham, a tome from me to me in the future as forgetfulness begins to reign supreme.

Almost Done with the Testing.

The last thing to get done is set a red hexagon where the last chess piece was taken.  The tile will have a red hexagon until the next piece is taken because of the sequester timeline.  And that wraps it up.  Now to get it into a web page and then on to One Game A Month.  Psst, next months theme is “CANDY!”


Play the Game Here.

Chess Sequester.

Until then, G’day.

September 30, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0045] ~ For the Espionage:

Grace Period: 48 hours.


But first, off to sleep, off to dream.  I awake happy, but in something of a quandary.  I found my Dad last night or maybe he found me.  He said something unintelligible, I replied “What?”  Again something was said but this time I could kind of hear words not just vocal noise.  Then he said something where he would let someone know and mentioned what I thought was a name and we grasped hands in a Greco-Roman Knuckle Lock, a hand clasp.  He laughed and said he understood.  My Father had passed away a few years back, so to see him again, well, made me glad.  When I awoke I felt rested in the knowledge of remembering such a fine gentleman albeit again in a dream.  Only God knows how that all comes to be.  More hmm, so be it.  Now back to the game.


Pursuing the Transcendence.


I have this chess game up and running and there are a couple things that need to be addressed.  Like, what happens when a pawn reaches the other side of the board where it is transformed into another piece.  Then there is en passant, where a pawn can take another piece on its first move of the game unlike any of its further moves beyond that of its first move.  But that and other puzzles will find their spotlight in due time.  And with that duely noted, the theme, philosophy, which is to be incorporated into this game, has finally been built to the point where it is close enough to be ready to and start expressing the philosophy of espionage.  In its simplest terms, espionage is the act of spying.  But in this game the espionage will be overt.  The pieces move about the board within their own capacity.  Each has an algorithm that it follows and that is where, within that movement plot, the overt traces of espionage will be seen.  I had gone through this in part previously while testing the graphics that will be shown on the chess board.  When a piece is selected it makes a call to the draw method where the prospective moves are given and are drawn to the screen as the result of that call.  There are six different pieces, but for as simple as it may seem to have its movement shown, there are many external factors that may inhibit its movement, possibly to the point of that piece not being able to move at all, check mate.


Climbing Through the Ranks.


I have built the void stub functions for the six piece types.  So seeing that the pawn is one of the first pieces to move, I’ll try to work through the pawn and the drawing of its overt movement plot.  I left click on a pawn and it becomes highlighted.  If it is its first move, en passant will also be one of its actions.  A boolean flag set in an array is the best way that I can think of to have this denotation become apparent.  Back to the code page.  Two arrays, one for either house, black or white, may make the searches needed easier to work with. And the name of the array?  EnPassantWhite and Black should suffice.  The variable array is declared in the header and then given their assignment to false in a for/loop for each of the eight pawns in the setup function.  For all practical purposes the pawns are initialized so they are now known to have not moved since the beginning of the game.  Something that has come to mind is, what if a player moves the piece but then decides that that was not the move they wanted for that turn.  I will be leaving that up to the players, but from what I can recall the rules are, “What is laid is played.”  And with that I won’t be adding any undo for a piece that will reset the boolean flag if that situation were to be a result.  I can’t build an all inclusive application, not now, not here.  But to get on with it, where does this flag get set and where will it be used.  I’ll need to put the training wheels back on in my program to find which variable I can use to set which pawn is being moved.  These are just draws to the screen to print out the values of different variables in the different states of game play.  I’ve got’m, so I might as well use’m.  Ok, once again it is somewhat complex but still doable.  The code is dropped into MouseIsDownRight and set so if a SetPiece is 1, that being a pawn, the boolean in that array coinciding with that piece is set to true, it has moved this game.  Now off to the pawns draw function.  Using those flags makes those square highlights easy to draw.  One thing I can now see is the coverage that the pawns can give all the way up to mid field at the start of the game, very staunch, stalwart.  But there is one last thing that I’ll need to do.  When a pawn is on the boarder of the chess field either to the far left or right, there are no tiles there and therefore no need for the highlight.  another thing is that when a pawn is taken, the highlight remains and is shown, if it is selected in the out-of-play sideline.  Also at the far side, when the pawn has reached the line where the Crown pieces are initially set on the opposing side of the field, the pawn can no longer move forward and there the highlight is again no longer needed.  So I have these three variations that need to be taken into account.  One more thing is that a pawn can move out of position, being a side step to either side of its starting point.  This can bring it closer to either of the side boarders of the chess board and again will give it no need for those nonexistent tiles to be highlighted.  With all that said . . .  back to the draw function of the pawn.  Hmm, AND how to keep a piece from landing on a piece of the same team.  But this question will be relevant later on when drawing out the prospective movement plots for the other pieces and so will some portion of these many other puzzles, ok, I’m good, let’s go.  I’ll take on the same team situation next.  Two variables AllyX and AllyY are two good names.  And what values do they need to be useful.  Another exhaustive search to flip a flag called SameTeam.  That adds more code to MouseIsDownRight but an allied piece can no longer move onto a tile from the same team.  Another problem that needed clearing up is that when a piece is selected and then the mouse pointer is positioned outside of the chess board and clicked, that piece moves to a spot that is most closely matched to the values of the board in concern to the tile grid values.  This has been fixed so that when any point outside of the chess board is clicked it no longer registers as a valid position and does nothing.  When a pawn gets to the other end of the chess board so (PawnPromotion == true) the player may pick one of the taken pieces to replace it.  Time for a save #10.  That was time intensive.  All the draw stubs have the general draw algorithm needed to show how that piece will move on the chess board.  The Pawns have their first move to include en passant, the Rook moves horizontally and vertically, the Knight has eight possible tiles to move to each turn the Bishops move diagonally, the Queen moves both horizontally and vertically and also diagonally, and the King can move in any of the adjacent tiles.  All that and the draw got an upgrade so it can be seen more clearly on the light and dark checkered tile layout.  And so with all that done, save #11.  Wow, it looks like the rules for en passant are different than the rules elsewhere, oh well.


Grace Period: 24 hours.


Eat and do dishes, eat and do dishes, eat and do dishes sleep, that and a whole lot of coding.  Save #12.  Now that the moves of the piece can draw to the screen they will need to be refined.  At this time the highlights that radiate from the piece that is set to move can spill over the edges of the chess board.  Getting these to stay within these boarders are what comes next.  I started out with the King.  This is somewhat labor intensive because of the calculations involved.  Each move that is possible, while keeping the next move on the chess board, needs a succinct bounds check.  The King can move horizontally, vertically and diagonally but can only move one tile per turn.  That makes eight tiles, and in the PlotKing() function means eight bounds checks.  But there are two kings in the game, one white and one black.  And as what may have been guessed, yes that means when the other piece is to be selected to move, that piece also need to be bounds checked as will be for all of the pieces, of either side.  The code page is starting to expand because of the code that drives this bounds checking.  The next piece will be the Queen.  But first a save #13.


Time for Introspection.


The queen has a similar movement plot as the king except for the fact that the queen can move in a strait line across the board as far as possible.  This might be the time to use a while/loop seeing that I really don’t know what all of the formats are that will come into play as the queen moves across the board.  Seemingly, starting with the king was a good idea because the queen was relatively easy to implement, only a change to the for loop with no need to use a the while/loop.  The Rook and the Bishop were equally as easy to place into the plot functions of those pieces because those are a subset of movements of the queen.  Now back to the Knight and the Pawn.  These two pieces move differently than the other four pieces mentioned above.  I’ll start with the pawn because it resembles the movement of the king but in a limited capacity.  En Passant, is not the move that I had believed it to be.  So I’ll be reformulating the structure of the function call that had previously represented it.  I kinda like my version of it and I’ll keep it in mind and see what others think, just for fun.  But again another save #14.  I’ve simplified the pawn movement and it is aligned with the currently upgraded pieces.  The Knight is next  Using the existing algorithm and applying the constraint has made the testing process easy to do, there are none.  Save #15.


Things In Things.


Clicking on any of the pieces will show the full potential of the piece while keeping their movement plot on the chess board.  What does become apparent is that that potential is not necessarily what can be obtained because the selected piece may be blocked.  It is currently blocked by the boarders of chess board itself, but the constraints in concern to the other pieces that remain on the board have no bearing while that plot is draw to the screen.  And so, things in things, the constraints in constraints.  I have done something to this effect when I kept a selected piece from moving on top of a piece of the same team.  I’ll check out this portion of the code and see if it is reusable in some fashion or capacity.  I found the Self and Ally check structure and the best place to start would be where I had started before, with the King.  With another function void PlotAllyExclusion() I might have some success.  I’ve also built a function stub called void PlotFoeInclusion() where a further set of constraints will be found.  Well then, it seems to work for one of the tiles occupied by the same teams piece, now to see if the same addition to the next call yields the same results.  Ok, let’s press a little further into that calling function.  Yes!  Now that is starting to look pretty cool, programmatically drawn movement plots, oh yeah.  But parenthesis are in high demand.  And with that, time for another save #16.  Now to test all the possible positions of the King on the chess board.  It works as intended so off to the other King.  Hmm, nothing.  Got it.  Now for the Queen.  Oh that silly queen.  The algorithm works, but, the line of movement for the queen, because of being blocked at some point along the way by an allied piece, does not stop.  The line continues again past that allied piece that is blocking the way.  Back to the drawing board, so to speak.  The question is how to preclude the advancement of that directed line of movement when it gets to the point where it is blocked?  I’m kinda getting it to work with another flag and a third argument in the function but now if an allied piece is in the way it blocks the entire line of movement.  It looks like I’ll need another array to hold the point in the for/loop where the cut off occurred so when that point is reached during the next draw call there will be a flag that denies access to the draw call.  So if instead of having a boolean flag I changed that to an array of integers and have that then set from the next for/loop run through it will be larger than the value set previously and therefore the call will be disabled.  Let’s give it a go.  But only if I add yet another argument to the function so it looks like this, void PlotAllyExclusion(int X, int Y, int Z, int valJ).  Yikes!  But it seems to work, and now for the other parts in the queens function.  That’s looks good.  I also dimmed the chess board when a piece is selected to move.  I did this because there was too much screen clutter and the intended espionage was clouded under the “fog of war”.  Save #17.  Things seem to be going well enough so I’ll add all those trappings to the other pieces functions.  Done, 2564 lines of code to get this game up and running.  Save #18.




Grace is good, and so is this chess game.  Thick with code and philosophy of espionage.  Each move gives the other player just what they need to know what they will get in return.


Until then,


September 4, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0044] ~ The Movement Plot:

The Grace Period: 96 hours.

I think it’s ninety-six hours of grace period, that’s what my clock says, including sleep.  Enough said.

Back to PlotPawn().

To keep the pieces from moving outside of the movement plot design, I’ll need an array that will hold the positions that that piece can move to.  At times, a piece may not be able to move because it is blocked by an allied piece.  It may also be blocked by the opposition, or possibly the chess board boarders themselves.  In any case, when a piece is selected an array of viable tile positions needs to be filled so that when moved it may be checked against it.  This could make the draw calls in concern to the highlighted tiles more easily accessible because they would be decoupled from the draw function.  The furthest a piece can move from its current position is seven spaces because the board is an eight by eight matrix of tiles and the piece itself occupies one.  So the array would need to be at least eight units in length, 0 thru 7.  But it looks like its time for some more underpinning by building an 8×8 array that will hold who is where on the board.  The question now is how do I do this using only numeric values.  What would make the most sense and what type of parser do I want to build so the code can decode it in a usable manner.  0 has been set as black and 1 has been set as the white side.  So the start of the numeric sequence will either be a zero or a one.  The second number in the sequence would be the chess piece type, Pawn, Rook and so forth.  The pawn will be a zero with another zero thru seven following after because there are eight pawns to a side.  So a pawn, in the 64 tile array would be, for the black side, 000 for the first pawn, 001 for the second up to 007 for the last pawn.  A Rook – 1, Knight – 2, Bishop – 3, Queen – 4 and the King – 5 will be the rest of the second numerals in the sequence.  The last numeral, the third numeral, because there are two rooks, knights and bishops will be either a zero or a one, while the queen and king will both be a zero.  With little to no forethought of a pawn making it to the last row and being exchanged for another piece, I’ll just leave it to fate and hope for the best when that time arises.  So where does this get me, and why.

Move a Piece Already.

Yeah, these pieces don’t move at all.  They are stuck.  There is no mechanism that will change their position.  And this gets me back to the array of viable options.  Another run through.  I click on a pawn and it is highlighted in cyan.    MouseIsDownLeft is a replacement for MouseIsDown because I’ll be using a right click of the mouse to move a piece through a different boolean, MouseIsDownRight.  At least that’s the idea.  And again, but how.  Ah that wacky wonderful world of mathematics, pointy-clicky happy land of “This doesn’t work, but how about this”, probably research and development for lack of a better name.  So the pawn moves, not quite correctly but it does stay on the board, cool.  It’s starting to work a little better, more consistent, but still a little loose in concern to the placement on the board.  Another problem here is that the piece doesn’t un-highlight after the right click move to the new position, although the placement in the new position does look good.  One more boolean flag, but what is its name, probably InitiateMove, sure.  And where to put it, directly under UpdateMove = false; and also in if(MouseIsDownLeft == true), just because.  R&D is the sledgehammer, ductape, tweezers, glue and thread place with sparkles, Crêpe paper and crayons.  Weirdness, I need some sleep.

That helps.

Wakey wakey eggs and bakey, that and some coffee, a vitamin and a couple of aspirin and I’m back on top of my game, literally.  I must have been working in my sleep last night, I mean, before I fell into bed.  I have a pawn that, when left clicked is highlighted and when the mouse is moved to another tile and then right clicked the piece is moved to that tile and unhilghlighted.  If the mouse is still on the highlighted piece when the right mouse button is clicked the piece is simply unhighlighted.  Pretty good for not remembering all too well that I had gotten all that done last night.  This is where things start to get tricky so I’ll make another backup copy and start moving this along and testing the permutations to come.   The first thing I should deal with is that when the pawn is left clicked there is a possibility that it will jump the the last tile that was the position of the last right click.  That was a simple fix, all I needed to do was insure that, in the left mouse down function, BoardTileX and Y are also set to the same value of the currently selected chess piece.

More Pawn Plotting.

I have the white pawns movement plot set, all eight pawns can move through the left/right mouse click procedure.  The black pawns are next, done.  All the pawns on the board can move, but that switch/case structure is really long now.  I think its time for save #04.  And to be truthful all the pawns can move anywhere on the board, they don’t follow any rules at all, if it’s a tile on the board they can end up there in one move.  Moving a piece on top of another piece is also possible, but because of the order of the draw function the white piece is always underneath any of the other pieces.  Also it is not removed from the playing field when covered.  So, the first thing to do will be to insure that the pawns have a predefined movement plot.  It’s willy-nilly right now and this is chess, not finger painting.  I’ll need to come up with some, “Stay in between the lines” kind of rules for the pawn pieces.  I had already built the graphics part of the movement plot of a pawn just to see what it would look like on the board.  It is two tiles in front of the piece circumscribed by a square outline in green, because on the pawns first move it is able to move two tiles forward.  And then two diagonal outlines in red off to the sides of the one tile in front, because those are the two attack positions and the tiles that the pawn would land on if that situation were to occur.  It is only a lesson in graphics and has no way, at the present, to influence a restricted movement plot on the pawn.  Also after the first move of the pawn, the same function portrays two tile spaces in front of the piece, it has no variation or way of changing that format.  The red diagonal tile outlines are also always present, even when there is not an opposing piece in that tile.  Is seems like working through all these conundrums with the pawns will lay the foundation for all the other chess pieces.

It’s Only a Model.

What does it take to keep a pawn inside of its predefined movement plot.  It’s time for another dry run to run through what would be seen when a player wants to move the pawn on the chess board.  Take the mouse and hover the pointer above the pawn that is to be moved.  Left click the mouse button, the piece is highlighted in cyan.  This is the signal that the piece has been selected and now has focus.

But First My Focus Is . . .

I’m going to get the rest of the pieces set to move in that long switch/case structure and make it very long.  This way I’ll be able to have a free, yes free, upgrade to the game.  Well, its a long stretch to say game at this point but it will have more functionality than what is there right now.  It’s more than likely my attempt to salvage what PR that the game is giving off right now in its given state.  Time for another save #5 and a web game update, done.

Back to the Focus.

All the pieces move now, the next plan of action will be to get the outlines around their prospective moves. Or, I could start to formulate a way to have captured pieces removed from the board.  In either case there are two puzzles to solve.  In the first, the outlines show where the piece can move because the piece has that type of movement.  In the second the piece can also move to that position, but in doing so will result in the removal of the opponents piece.  I seem to have come to the heart of the matter, into the thick of it.  There are a lot of parts that need to be coordinated and orchestrated.  They will need to move one after another and that is what I’ll need to solve for this puzzle to become a game.

The Grace Period: 72 hours.

I have come upon two types of run throughs.  The first is from the point of view of the player while the second is from the point of view of the developer.  Looking at this chess game from the inside and the outside has given me an opportunity to realize complexities that, in the past, I had taken for granted.  Getting back to the former and the latter, which I had written about previously, the former game rules are observed by the players themselves while the latter requires that the rules are placed within the game code.  With the former, the chess board acts as a guide that aids the players in concern to a decoupled set of rules found through the chess pieces with the guidance of others one would play, or possibly some documentation.  The rules are what make up the game but are not given from the board or the pieces.  In the former, this computer game, as it stands right now the same is true.  With the former or the latter any piece can move anywhere on the board but because of this there comes into account the validity of those moves.  Restricting the pieces movement, and also taking into account the vast and varied possibilities of where a piece could move has lead me to the conclusion that the game, in concern to the constraint of a pieces movement, is complete.  I will leave it up to the players of the game to place the pieces where they deem fit.  Doing so will free me to solve the two last puzzles of this game.  The espionage that will expose the players move and the removal of a piece if it is taken.

Taking an Opponents Piece.

To take an opponents piece, one chess piece needs to land on a tile where another opposing players piece is currently situated.  To do this three things need to be known, where is the initial piece and where will it land with the third bit of information being, is there an opponents piece that occupies that tile so it can be removed from play upon the initial pieces arrival.  From this I’ll need to look at the variables in my code and prepare them for such an event.  But what are these variables?  Are they compatible, or more precisely are they comparable?  Are they in an array that is accessible or do they need to be reformulated?  These questions should be of help as I delve back into my code page to find, from either point of view, if a piece is to be removed when landed on.  As the opposing player the idea is to keep the piece “in safety” by not having it in a tile were the rules of engagement would allow it to be taken.  The next best option would be to have that piece in peril under the guard of another of the same house, i.e team, the white or black set of pieces.  Falling out of safety is what this part of the game build will cover.

Naming the Piece, Building the House.

So far I’ve been dealing with the abstract ideas and concepts that embody the game of chess.  I have the checkered tiled chess board, the two houses being the white and black sets of pieces and the icons of what those pieces have been known to represent.  Those who have some knowledge about the game of chess would corroborate that, by outward appearances, that this computer game resembles a standard setup of a game to be played as chess.  What I haven’t done as yet is to ‘name’ the house or the pieces therein.  I have no intrinsic relation that binds the icons on the board to the code in the program.  What I mostly see now is either what I’ve come up with that is my best representation of the game when it is run on the screen or a bunch of variables inside tiered structures in the project page of the API.  I do have some text clues of what a variables current values are which are printed to the screen and some comments in the code page.  But beyond that its all leaps of faith as I careen back and forth between these two states of this game build.  Ah, but I have incorrectly and blindly forgotten this blog itself, dummy me, as a third pillar.  So back in the code page I’ll need to change some of the variable name that were hastily constructed.  A new variable that contains “House” will represent either the white or black team set.  Also a string array of names for the pieces has also been added.  These will be used to direct the very large and ever growing switch/case and also be placed in that structure to allow the House and the Piece selected when left clicked on and thereby become ready to move.  I’ll also need to have those words placed on the screen so that another visual cue will aid the players as they move through the game.  Done, and now for another save, #6.

Back to Capturing an Opposing Piece.

Ok, that was too convoluted to explain, but I think it works.  What was needed were some variables, FoeFound, FoeX, FoeY, Set Captured and maybe a couple of more.  Then inside the right mouse button click routine there needed to be a for/loop to go through the array of either the black house of pieces or the white, which ever were the opposition of the selected piece.  Then once a piece had the same position of the piece that had just been moved I had a write to the screen that shows that both have the same position through a (X, Y) value with visual validation.  So far it seems to work although nothing further is done.  The next part is to do a little bit more testing and then probably get another array that will set that piece out of action and off to the sidelines.  But first a save, #7, done.  And it does provide the correct signal.  Now to take this a step further I’ll see if I can get it to tell me which piece of the opposing house has been captured by name.  Hmm, as it would seem I have built forward and hadn’t taken into account running the same algorithm backward.  To find the name I’ll need to build another array that will keep the names inside a structure that duplicates the structure of the position array.  Using a class to represent a consolidated unit of all these parts could well have been the way to go, but in this web java world it seems that that is somewhat out of my reach at this time.  So for convenient sake I’ll just use brute force to get this part done.  Or just go the simple route and build an if/else with a switch/case in the MouseIsDownRight if statement, simple enough.  And yet another save, #8, and some more testing.  Good as gold.  I’ll just tidy up the game screen and see if I can get the pieces off the board and over to the side.  Wow, that’s a lot of curly braceses.  When a piece is taken it moves off to the side.  It looks good enough to be the next free upgrade and is enough to make it into what some may call a game, if you know the rules of chess.  I have a few more hours left in my grace period so I’ll leave off here and continue on, after another save #9.

To be continued, . . . again.

Until then, G’day.

September 2, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0043] ~ ChessPionage:

But first new news.

Notepad++ v6.3.2 has been updated to Notepad++ v6.4.5.  That is all.

And now, for something completely different . . .

a game with three aspects: chess, espionage and philosophy.  This months OGAM theme is Philosophy.  Seeing that I have already built a computer chess game using Microsoft Visual Basic 6.0, circa late 1990’s , I already have some of the art assets constructed.  I also have some vague ideas of what to expect while building this months game.  The title ChessPionage is, of course, a combination of chess and espionage.

The trick in building this game is that …

Hmm, I’ve actually forgotten how a for loop is constructed.  OK, got it, back on track.  Start off by opening Processing and creating a new project called Chesspionage.  Then with Trail Blazer also open, cut and paste the framework of commented block delineation structures from the finished game into the Chesspionage project sketch window.  This also entails leaving behind the other parts of the previous program that are game specific and have no use or bearing on this game build.  These empty blocks will provide clear areas or regions, in this new game, where the relevant code for this game is to be placed later on.  It’s a simple way of keeping track of code blocks so that when the scrolling searches begin, i.e. nearly perpetually looking up and down the code page, the general position of the code is found more easily because it will start out as a formal and unified template.

An Ode to Forgetfulness.

It has been a while since I’ve updated my website to reflect my progress as I move along this One Game A Month journey.  It is doable but it is still kinda clunky, for me at least.  Everything in my web site is pretty much hard coded as it goes along.  So it seems like, when I do put in the effort, I keep pulling over at the waysides and scenic outlooks to update the different parts of where I am.  My website is one thing, so the game has a consolidated happy hovel to reside in after all is said and done.  This blog is another, where my thought processes and general hemming and hawing, to keep my mind right, yeah sure, can back track and hopefully move forward as I drop trinkets and baubles along the way.  Then there is the actual game that needs to be built, which takes up the task of building logical constructs that eventually, and again hopefully end up as a playable game.  And finally there are all the odds and ends of assorted remembering that give there best to keep it all connected and moving along.  Tweets happen, but that is usually just a capstone hurrah at the end.  Well at least I can write this.  At the beginning of this year I had absolutely no idea of what it would take to build a completed game, let alone a web game, in an API that I had never worked in or with before.  I guess it’s better to have a grand capacity to forget many things rather than neglecting everything and seeing nothing ventured, nothing lost.  So, how do I build an anchor tag in my web code that will take a hyper-link in this blog post to a specific spot in my sites web page. Hmm, more research, and, OK, got it to work, happy now, so . . .

Back to the Thick of It.

Processing doesn’t take bitmaps (bmp) so I’ll need to convert my chess pieces to jpg files.  Done.  Now to drag them into the sketch so they are recognized in the data folder of the project.  Processing needs to preload these art assets with a, /* @pjs preload=”name.jpg”; */ , directive in the header, so that’s next.  Ah, the intricacies of copy, cut, paste, all from the explorer folder set to details, of course.  And watch out for the naming conventions, I needed a little rework there, but it works now,  Can’t start a variable name with a numeric character.  An eight by eight grid of Pawns are centered in the games screen play area.  There are six pieces, Pawn, Rook, Knight, Bishop, Queen and King, that make up the side.  There are also four hues of those pieces that make four choices for the players team.  So there are twenty-four pieces total that need to be preloaded in the header, then have their variables initialized in the declaration space and then have those variables loaded with the jpg files in the setup function, done-done-done.

Setting the Chess Table.

A standard chess board is made of a square and in that square are sixty-four smaller squares.  The pieces are set in one of the smaller squares and move, centralized in that square, from square to square as they move about the larger board.  It looks like I need a chess board in this game.  Using rect() and its arguments [X,Y,W,H] I have a perimeter around the sixty-four pawns on the screen.  The next part will be a little more tricky, building the checkerboard texture where the chess pieces will rest.  As this will be a standard game of chess, the queen, when the pieces are initially set to begin the game, will rest on her own color.  This means that the top left and the bottom right squares of the board will be the light colored squares.  These alternate back and forth so the diagonals are of the same color.  This will more than likely be a nested for loop, with some tricky if statements to provide the correct shading of the squares.  I’ll see if I can use a % (modulo) function to direct this outcome, having it flip back and forth in the draw loop.  But first I’ll need some hard coded figures to chart this out to get a visually aesthetic model, it is my way of doing things.  Yup, had to change the strokeWeight(#); so the light and dark squares have better highlighting.  Whew! That’s done, and as suspected it was nested for loops with modulo if statements.  I have a chess board.  Now all I need to do is take all that code and drop it into a void function call to tidy up the draw loop and get all those lines out of the way, let’s call it BoardSetUp().

Setting the Chess Pieces.

It’s a nice chess board but it needs the pieces to be placed on the board if a game will ever be played on it.  I’ll need to think this one over.  Or, I could hard code them into place and call that function GameReset(), sure, back to the draw loop I go!  The first thing I’ll need is to find the positions of the pieces so they are all centered on their respective squares, tidy is a good thing.  Another simple for loop of Pawns, white and black, strung across the horizontal rows of the board was simple enough.  Now how to get the other pieces to jump onto the board.  Probably another nested for loop with a switch/case structure to assign the pieces as the loop moves along.  Moving from left to right, yeah left to right but not a nested loop.  The Queen/King and Bishop combination mess up that scheme so it’s easier to give them their own loops.  Or just use the switch/case for all the draws, we’ll have to see if that is a good way to do it or if the game will take a performance hit.  In either case they need to be perpetually drawn to the screen, and so have at you, Ha ha-ha.  Never mind, the Queens line up across from each other on the chess board, so undo that.

Scrubbing Through the First Run.

The chess board has it’s pieces in place, and as it stands, although there are four shades of player pieces, two light two dark, it has become apparent that there will be a main and a secondary player hue for each of the two players.  The reasoning here is that drag and drop or some kind of point and click system seems preferable to any other type of movement mechanism that is conventionally used.  And now for the scrubbing.  Having the pieces drawn to the screen through the current mechanismal function, although it clearly is doing what is intended, there may be some changes to separate the calculations in the functions loop from the actual drawing of the pieces to the screen.  Consolidating all the draws into one function is usually the best way to keep the fastest refresh of the screen commands.  This is where the start of declaration statements for this game, employing arrays, to keep track of the pieces positions will most likely begin.

Save Once, Save Often.

This game, well, project start, has enough work put into it and has gotten to the point where a code page backup should be taken into account.  Done, at least I’ll be able to get back to this point in time if there is ever a need to.

Division of Arguments.

And now to get the draw function arguments separated from the logical loops that programmatically build them.  Draw calls for the pieces need arguments that hold the positions of the pieces on the chess board.  These arguments are currently built within and given to the called draw functions within a looping structure that are dependent on the loops to increment their positions and are immediately drawn to the screen as they are assigned to the arguments, kind of a one-stop-shopping routine.  The calculations are currently inseparable from the calls.  What I need is a series of arrays that will hold the pieces positions in a predefined persistent variable declared in the header space and is initialized in the SetUp function before the program begins the game play.  So what do I need.  Along with the file image, which I already have and have been working with, I’ll need the X and Y position of the image, actually the upper left corner, so that all the images are drawn consistently with in the chess board grid.  And what else will be needed.  If I want any of these chess pieces to move I will need some kind of mechanism that can recognize when the mouse pointer is over that image, i.e. chess piece.  This means I need the area of that pieces jpg file, that being the top left position of the image on the chess board, and the height and width to fill out that square.  Having that information should allow me to do some bounds checking to verify if the tip of the mouse pointer is within the desired area on the screen.  But, to keep the calculations for when this happens down to a sizable roar, I should probably have this happen only when the mousedown function is activated.  A left mouse button click would then allow, because of a boolean flag set to true, the as yet not constructed function to use the chess piece of the secondary hue to be portrayed on the screen.  This will signal to the player that that piece now has focus and the relevant procedures are active and the player may continue to move the set piece, if so desired, to one of the pieces predefined positions.  Voila, the game begins to have pieces that can be moved, but not yet.  I still need to get the arrays of piece positions built, the arrays of boolean flags and the mouse functions that will allow validation of the mouse pointer position in relation to the chess pieces.  This is going to be a long one.  Do I need anything else?

Albeit a Leap of Faith.

Pressing off into the distance may be the best way.  To see what else I’ll need for this game, I will go through an imaginary dry run, playing this game, here, written down, to capture the essence as it supposedly will move along.  This is a game of chess, using a modern standard model of game play.  This computer generated chess game will also incorporate signals that expose the supposed espionage that can come to light while game play ensues.  The resultant philosophy because of the exposition of congruent clues of espionage provide to the players an understanding of causality in relation to each of the pieces the players move.  On a regular chess board, a real chess board, tactile in nature, actually having mass, possibly likened to a piece of furniture along with the curios, the chess pieces, movable through a players adroit manipulations derived of the players physical major appendages because of cognitive implicating desires in concern to the process wherein a winning end game results, the board and pieces are viewed as static in nature and do not vary save for the fact that the pieces are placed on, move about and can be removed from the board.  In comparison, not taking into account all else needed as the hardware, software, connective server hubs, electrical generation and distribution facilities, so on and so forth, etc. etc. etc. unto anon . . . this game, the computer game, has little to no tangibility, no mass except for the photons emitted from the constructed logic portrayed on the computer screen, a conceptional abstraction of the former conveyed as true in the representation of the latter.  In short, in the former chess game the chess board looks the same if a piece moves into a parlous position as when it moves into a safe position.  In the latter, this computer game will add to the chess board a dynamic that, as the players piece is chosen to move, shows the possible paths of that piece and if necessary change the face of the board so tactical placement may be either capitalized on, i.e. moving into, supporting a piece in or averting a dangerous position.

And with that Bout of Gibberish Out of the Way.

This will come about because each piece has its own way of moving.  The Pawn, Rook, Knight, Bishop, Queen and King have predefined movements allocated to them at the start of the game, as yet unimplemented.  The Pawn and the Knight are the only pieces that are not blocked at the start of the game.  All the other pieces cannot move because their movement plots are blocked by other pieces.  Clicking on these pieces will show no alternate paths away from their current position.  The Pawns and Knights, if clicked on, will show their movement plots as . . . hmm, I seem to be getting ahead of myself, in a game programming-atically kind of way.  But, I do want to have a typed game design document to give me an idea to see just what I need, but I really would also like to build while I write so that what I want to do is actually feasible so what I think is the way is possible.  OK, I had to take a little side caveat there to insure that how things are seen on the board can be built programmatically, done and doable.  So, the Pawns and Knights, if clicked on will become blue, cyan actually, and will show their prospective movement plots as a green square outline around a set of tiles where the piece is able to move that turn.  It will be yellow if that tile will put that piece into a position where the opposing players piece will be able to take it the next turn.  If the piece ends its move in a yellow tile the hue of the piece becomes red denoting that it is in danger of being taken by another chess piece.  Thus the espionage.  It looks like I’ll be flipping back and forth between writing this dry run of game play and the capacity to have the game play implementable in code, so be it.  It also looks like I’ll be reverting back into my very old ways of variable naming conventions, back in the days of BASIC, Beginners All-purpose Symbolic Instruction Code, to keep the variable names acronymed, capitalized and very short, i.e. White Pawn 1 == WP1, White Queen == WQ, Black Knight 1 == BK1 and so on.  I’ll try to use the “point(X, Y);” structure to hold the position of the WP1 variable.  Nope, Processing does not recognize the point Data Type as one of its Primitive or Composite data types when it is declared in the header of the code page which means that coordinate pairs are going to be a little long winded and unwieldy in my code.  Hmm, another work around it would seem.  Yes, I’ll be using two sets of arrays, two for each player.  The set consists of an (X, Y) coordinate pair found inside a 2×8 matrix.  The really neeto problem in practicality is how to remember the assignment of the pieces inside the array.  Starting at the top of the board the pieces are lined up R1,K1,B1,Q,K,B2,K2,R2, followed in the second part of the array with, P1, P2, P3, P4, P5, P6, P7, P8.  The arrays start a zero so the columns or files are 0 thru 7 and the rows or ranks move through 0 thru 1.  I want the player, Black Pawns, (P1 – P8), to be in rank 0 along with the White Pawns, just to be consistent while I mentally draw out the chess board with the pieces taken from the array.  The rank 1 array will hold the major pieces, I’ll call them the crown pieces, just to keep it simple, as simple as can be.  The way the board is currently set up the white player is on the bottom with the Queen to the left, and the black player is on top and, while facing the white player, the black Queen is to the right.  Maybe that was what I was trying to figure out a few paragraphs back.  So anyway,  the next thing to do is cut out the entire draw routine used to put the pieces on the board and see if the program still runs, and it does.  And then to assign the arrays of variables, probably using the for/loops with the accompanying switch/case structure, and then switch out the draw() arguments with those array generated variable values.  Syntax, syntax, syntax it’s nice to know a couple of different languages, sort of, sort of confusing.  And watch out so that you don’t switch the number of rows for the number of columns, the screen of death comes up and there isn’t a error checker so you end up flying blind, until you figure it out, wee!  Now back to the nested for/loop with the embedded switch/case in the draw function.  Gad, not a nested loop in the draw function just a single loop with a more intricate switch/case that I think will be getting even more convoluted, only time will tell.

It’s All Back Together.

It draws the chess board with the pieces in place using the arrays that are now built.  So where was I.  The idea I was getting at is clicking on a chess piece and having the possible positions shown by different colored outlines on the respective tiles.  That brings into account the position of the mouse pointer and probably a search algorithm to find the closest match to that point.  Then programmatically assign the match from the search to the list of pieces that remain on the board.  So let’s say that a point on the chess board is clicked.  A mouse down signal is initiated and in the mouse down, for a left mouse button click, activates a function call wherein it reads the list of remaining pieces.  I could shorten that list by using a boolean flag, which would be set to false when a piece is taken.  More arrays, and research.  Nope, no collision detection in the Processing Reference documentation, but there is enough there within the given data types to build something.  I’ll just need the upper left corner and the width and height, which happens to be the same length, to find where on which piece the mouse was clicked.  From the mouse down function, I’ll capture the point on the board, MouseDownPositionX and Y, do some bounds detection and calculate an area that should provide the correct piece selected.  Ok, that’s a nice thing, the mousePressed() function only calls that function once and then exits that function, even when the mouse is held down and moved, very nice.  I thought I might need some extra booleans to remedy that, but not.  So I have a position on the chess board where the mouse pointer had been clicked.  A boolean flag, MouseIsDown, is also needed for further processing and to open the search function to find the pieces position.  Don’t forget to declare the boolean in the header.  So when the mouse is clicked inside a white piece all of the pieces are tinted one color and if clicked in a black piece all are tinted another color.  Now I need to figure out how to get just that one piece to be tinted.  It seems that if I capture the i and j increment of the nested for/loop that might get me closer to my goal here.  From a write to the screen with the text() function, I can see the results which prove true.  The array row zero are the pawns with the row one seen as the crown pieces.  The column numbers are also correctly situated.  In lieu of a boolean I’ll use an int data type that will be set to zero(0) for the black pieces and one(1) for the white pieces.  I’m working towards getting the piece that has been clicked on by . . . Nope, it’s time for another backup to save all this work at this point again.  Ok, I feel better about that, and I’m working towards separating the white pieces from the black pieces with the if() statements inside of two nested for/loops that test the mouse click position against the startup/reset positions given at the initialization of the game.  These positions can and will change as the pieces move, but I haven’t gotten to that point yet.  There, I’ve gotten rid of the menu system from the last game.  I’ll have no use for it in this game and it makes the layout much cleaner.  And that makes it time for another backup save.

The Hunt is On.

The pieces are in the newly revamped structure that separated the position of the piece from the draw method.  It is situated in a switch/case inside a for/loop.  I’ll need to look at that and maybe rework that, OR, just leave it alone by putting it in its own void function to be called at the beginning or reset of the game and then build a game play draw routine from some of those existing pieces.  With all that has been done so far, I’ve broken all the chess pieces into three divisions, that being the white and black pieces, the pawns and the crown pieces.  Finding the one piece that has been clicked on comes from the MouseIsDown flag, the MouseDownPositionX and Y that sets the position of the mouse pointer, and the CaptureI and J variables from a search that captures the piece position on the board along with the PieceColor, either white or black.  From there the player will need to know, or be given acknowledgement that that piece has been selected.  Yes, that switch/case did become a rather large structure but now when the mouse is clicked within a white piece, that piece does change hue to show that it has been selected, very nice.  Now to do the same for the black pieces.  And that works equally as well.  Time for another backup save.

Where Can I Go, What Can I Do?

The board is set, the pieces are placed, the two players can use the mouse to point at a chess piece and select that piece which is then highlighted.  The highlight shows that that piece is ready to move.  The question is how does the selected piece move.  Where does it go.  What is the definition that shows the positions that are possible that turn.  And that is what comes next, the pieces definitions.  Pawns move forward one tile, except for its first move when it can move two tiles.  The Pawn also has the option to move at a diagonal, if attacking an opposing piece.  The other pieces, the crown pieces, being the Rook, Knight, Bishop, Queen and King, have their own movement plots.  I’ll start with the Pawns.  A pawn is selected and what happens.  The pawn is highlighted and then the pawns movement plot is shown in the appropriate tiles.  So I need a definition for a pawn that shows its movement plot.  I’ll also need to know where that definition will be called from, in code, when that piece is selected.  From prior graphics test I have an outline that is used to circumscribe a tile with a green, yellow or red outline.  So far I don’t have a definition that can be attached to a particular piece that will be shown by that outline.  The transposable definition, then, is what will come next.  PlotPawn() will be the void function that is called.  There are sixteen pawns in the game, initially, eight white eight black.  The white pawns will move up the screen and the black down.  I have a division built with the variable PieceColor that can be used to change the direction of the plot inside the function.  The highlights for the Pawn are done, so each of the remaining crown highlights are needed.

And As Time Draws Nigh.

It’s time to bank some of that ever lovin’ grace period.  I’m having too much fun with this game and it has come too far to just pack it away as is.  It’s built for the theme, philosophy, and I’ll be running it to the hilt this time around.  See you on the other side.  To be continued, . . . and finished.

Until then, G’day.

August 31, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0042] ~ August OGAM Game:

New news.

Because of the Seven Day Roguelike Challenge, (twitter) #7DRL, I have my first real critique, by TheUberHunter.  Woo-Hoo!  Thanks.

Also, ZBrush 4R6 is a FREE upgrade. It’s up and running, again, and now . . .

More Lies, more or less.

This months theme is PHILOSOPHY.  Some potential lays within that word to draw out new ideas for this months game.  But as stated, I lied, again.  In a previous months blog I finished off by saying, about Trail Blazer, “No errors have been introduced while advancing these improvements and the game in its entirety has lost no integrity.”  But while playing the game I’ve noticed that when the CONTINUE button is pressed the DEFEATED end splash screen can pop up for some reason or other.  This anomaly doesn’t change the game play but it does nothing except introduce confusion because of its erroneous behavior. Its a lie that needs to be corrected, a fixable lie, more like a mistake donned under the auspices of truth in validity.  Ooops, and so the philosophy begins.

Back to the Theme, eventually.

This game version has run its course.  It works well enough and the game play moves from start to finish.  The game loop is entered, the players avatar advances through the game and when the game is completed, with either a win or lose edict, the game loop is closed.  From there the game can be exited entirely or reset to be played again.  I would venture to say that I have finally built my first complete game.

Layer upon layer.

The ideas for my new game will come from what memories I have left of an old game my sister and I would play a long long time ago, Outdoor Survival.  It was one of my more favored games of my youth.  But as life has gone on I have come across two other games, computer games, that I have found myself enjoying and repeatedly playing.  The first is Age of Empires II: The Age of Kings and the second Caesar III.  The challenge here is to find what I liked best within these three games and put it to myself how to have them blend together in a way that it becomes a new game.  The greatest challenge will be to have it become another complete game because of persistence in my skills with computer programming.

With that said . . .

Seeing that this OGAM ruckus is all for fun and games, I should start to think about how I can take what I am doing now with this web game versioning so, eventually, it will be useful for what I have previously built as HUD ON.  HUD ON isn’t a game, yet.  It is mostly a game template, of sorts, that hold the asset manipulative functions I have formulated and built on the computer, and with XNA and C#, is ported over to be run on my XBox 360.  The game is a map displayed in a 3D world with space ships that fly over the terrain where the game pad controller is used to bump the ships into floating spheres while avoiding the ground below.  That is it, the game so far, HUD ON, no real starting point, no story line, no written rules, not even a glimmer of Ta-Dah at the end, if there is an end to the game.  That then is what is missing and is what I should start thinking about as I try to build my August version for OGAM.

Not directly, but consequentially.

So this months game needs a name, an idea and a direction so that it will aid the game play of HUD ON, or what ever that new XBox 360 mutation or permutation game will become.  I need to start some parallel thought streams to build this game this month and have what I’ve accomplished now become of use later on.  As for OGAM, Trail Blazer is the source stock and this months theme becomes the additive that will give form to this new game and provide a gamified dialectic, more philosophy.  In totality, the desired essences of Outdoor Survival, Age of Empires and Caesar III will form a discourse between these three to start a new direction from the base OGAM submission Trail Blazer.  Having a base game logic template, adding philosophical aspects to and about the game and continuing to build where intertwined story lines form, should then give aid to the, almost, game I have previously built for the Xbox 360, HUD ON.  The provisioning for some interesting wriggling for the future builds because of this months theme offering drives the mental precipitate evoked today and will hopefully linger on, giving way to its own evolution, becoming a playable game for this month and on the Xbox 360.  But . . .

Until then,


August 27, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0041] ~ July OGAM Game The Nuclear Expansion:

Another Rough Month

Aside from my Mom taking a dive, a month long summer cold that hasn’t gone away, having two teeth pulled and another camping trip, I have been able to get one more contribution out to One Game A Month for July 2013.  I’ll keep this entry short.  And as mentioned in the video, if there is any interest in the cards and rules I have formulated as my expansion for the game of RISK, I will gladly expound on them if there are any requests.

Until then,


July 31, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0040] ~ TrailBlazer Optimization:

Tough Month.

This months free time has been eaten up with the 17th Annual Camping Excursion and all its preparation, leaving little to no time for One Game A Month.  Sad but true, actually great and amazing.  The 23 year old van, camping gear acquired over the past 17 years and myself needed a little morale boost and many repairs to do it again this year.  And this trip has given me much food for thought about the game I’m building.  But first . . .

Continuing the game build.

This game continues the previous builds.  But in this version, the objective will be to optimize the games runtime efficiency.  The meaning here is that, while building up to this point the game has had features added to where the avatars direction buttons no longer function with the speed expected.  The button is clicked but the games reaction time is slowed to the point where multiple mouse clicks cannot be registered within the game fast enough to provide a smooth gaming experience.

A slight backtrack.

While reading last months blog to get an idea of what this game has come to be, I’ve noticed some typos that need correcting.  Done.  And now to go about starting the next version of Wanderer 2 to become TrailBlazer.  Open the web page and select “View source” from the dropdown menu.  I have Notepad++ installed and set as my default web page viewer so the code from the page opens in Notepad++.  Then open Processing.  Back in Notepad++ select all the code from inside the canvas script and paste it into Processing.  All that needs to be done now is to open the data folder from the last games version, Wanderer2, select all the art asset files and drag them into the TrailBlazer page.  Processing prints out that 31 files have been added to the sketch.  In Processing, save the file and click “Start server”.  And nothing happens.  Ah yes #213 through #219 need to be switched, from those commented to uncommented and vice versa, because while running the game in Processing in comparison to running this game from the web the names given to access the art assets have different directives that point to where the files are located.  The files are located in the sketches data folder on the computer while constructing the game and in the web directory of the site when running the game through a web browser.  Another thing that I had forgotten was that a precompile directive /* @pjs preload=”. . .”; */ needs to be deleted, not just commented out, and replaced so the splash screen pictures are recognized when run from the web, or the computer file folder.  More intricacies to remember, hmm.

So anyway it’s up and running again.

It still works, as the last build, and now I can start to dig through the code to make this game run more smoothly.  1794 lines of code to get this game to run.  It comes out to be 60 KB as the .pde file with the art assets weighing in at 0.98 MB.  It’s a small game but the logic and accompanying algorithms eat up way too many CPU cycles.  I think the real problem here is that the draw routines are the true culprit.  Each time the screen is redrawn the entire switch/case loop, which calls the draw functions in succession from an array for each terrain feature in the 23×23 grid, 529 terrain grid draw calls per cycle, slows the game to the point where the mouseover() functions for the avatars directed movement grind to, pretty much nearly, a halt.  And this is my inefficiency, the draw loop.  And this is what this months version will address.

The game face, On and Off.

To get an idea if this is the true culprit I’ll need to turn off all the terrain draw calls to the screen for the grid map.  Eeek gad!  I’m lost again, in my own code, and my comments seem to lie to me at times.  This system, Processing using JavaScript for the web, although similar to the C# and XNA programming system for the XBox, is starting to become overly familiar and makes me think, when I jump back into XBox programming, I’ll need to restudy and re-research a lot of protocols and concepts, more hmm.  Now how do I comment out the terrain grid draw calls for this game without breaking the build.  #436 #508  Block commented that switch/case out and the terrain no longer draws to the screen and the avatar direction button clicks are as fast as can be expected.  But does the game run in its entirety and complete as desired.  My questions here and throughout this blog are perpetually invoked rhetorical consternations because of the state of the game build not actual directed questions per se.  So instead of burying this blog with question marks they will all be finished with periods unless an extreme need for questioning is to be exemplified.

Testing the blank grid.

The terrain grid is blank.  The only features on the map are the grid lines and the avatar.  The grid squares are 25×25 pixels.  Moving the avatar is now more reliant on the mini-map because that is where the terrain icons are seen.  The newly introduced problem here is that, although the springs coordinates are seen in the list, the complete route from spring to spring cannot be planned in advance.  Every grid space is and remains blank with each avatar movement.  To simplify the avatars trail blazing capacity I’ll first see if it is possible to place the springs on the map.  #627 to #646 is the randomization of the springs on the already populated terrain grid.  I added an if/else to the for/loop and the springs are visible at the start of the game.  Ok, that works well enough.

Blazing the Trail.

The games avatar direction movement clicks are up to speed, the map shows where the springs are located again and the mini-map has become a more useful feature.  Now to work on what has given this game its name, TrailBlazer.  What is lacking is the trail that has just been blazed by the avatar.  All that I can think of for this would be an array of booleans that will retain truth or falsity in concern to the passage of the avatar as this hero steps into a grid space on the map.  This would keep the draw calls to a minimum because, for all practical purposes, a player wouldn’t step into every grid space on the map while trying to get to each spring.  The most livable trail is the most viable route and therefore would not cover the entirety of the map.  The load on the CPU would be lowered and the game speed would be kept up.  This is the best line of optimization that I can come up with as this months game submission draws near.

Building the Trail.

#116 boolean[][] TrailGrid = new boolean[25][25]; will be my starting array for the avatars path.  Initialize the array in a double for/loop at #283, TrailGrid[i][j] = false;.  And where will I put this variable so that it is updated when the avatar moves into a space on the grid and sets the flag to allow that grids terrain icon to draw on the map?  It seems that I should move backwards from the draw function where all the terrain icons calls are made and set that boolean flag there.  Once I figure that out, how and where to place that variable should become more apparent.  So what happens, #436?  Nope, #447 is where the springs are allowed to pass the flag as if(grid == 9) for the switch/case.  So if that boolean is changed to if(TrailGrid[i][j] == true) then I’ll need to go back and assure that that is initialized to true to show the springs at the beginning of the game.  And of course the answer is where or how or both.  And that also means I can get rid of the else{} part of the if() statement.  Ok.  #309 place it in the Spring Hamlet Visited initialization loop in the setup function at the beginning of the game.  Now the scary part, does it still work?  Oh yea, that’s cool.  But what happens next so the trail that has been blazed remains on the map.  #1593 TerrainGrid[HX][HY] = true; should do it.  Nope, not even close, back to #447.  TerrainGrid isn’t TrailGrid, simple wrong variable name, and now it works correctly, kinda.  Why does the grid on space (0, 0) always draw?  Nothing else draws because of the boolean flagging, hmm.  I don’t get it.  The for/loops are set to zero when initialized and the for/loops that are used to call the draw functions for the switch/case is also set to zero so I don’t understand how or where the upper left hand corner of the grid map is getting the “ok” to get that icon drawn to the screen.  That one is a total mystery to me.  So what you do is hard code TrailGrid[0][0] = false; in both the setup initialization and the reset functions and what do you get.  To get mean about it, how about #1786 text(” ICON  (” + TrailGrid[0][0] + “)”, 600, 165); // label. And the answer is “true”.  But how is it changed to true after the explicit declaration as false?  Why, where and or how is it reinitialized?  Now to get dastardly about this and #1544 put the initialization in a loop that is continuously called.  And the result is, it looks like it is drawn at the start of the game and then undrawn as it gets to that function.  Something is overwriting that and I don’t like it.  Ok, that works.  Both the avatar and that unruly terrain icon are drawn in the upper left hand corner for an instant when the game starts.  But the avatar moves to the center of the playing field and now after moving that TrailGrid[HX][HY] = true; // set the grid that the avatar is in to true. setting to the end of the draw() function #675 it is working properly.  Comment out #1788 and all is well.

The Mini-Map.

#1543 void Hero_Progression()

#1589 void Hero_Surroundings(int grid, int row, int col)

These are the two functions that need some work if they are to have the mini-map viewable at all times during game play.  The idea here is to take the position of the avatar on the map in pixels, convert that value to a grid location in the 23×23 grid map, which in the array is 0 through 22, take those numbers and find it in the array, where that terrain type is then placed in the 3×3 mini-map.  As noted, when the avatar is on a border of the playing field the algorithm tries to access a value that is not available in the array which holds these values.  The result is an access violation which causes the game to crash.  Having some type of validation or error checking is where this is going towards.  The initial problem is that negative numbers are introduced when deriving the result and although it is easy to manipulate this is really not a best practice and produces this very problematic error.  As it stands, for this nested for/loop, the conditional has been placed inside the innermost loop.  It was simple and moved the game to completion.  What is needed now are a series of conditionals where dedicated nested for/loops are placed inside these conditionals.  It may seem a little more clunky but it should provide the desired results, that being the capacity to view the mini-map from all locations of the avatar on the grid map.  There are eight problem positions of the avatar.  The corners where rows and columns are unviewable, the top and bottom sides where rows are unviewable and the left and right sides where the columns are unviewable.  Again, the numbering is from 0 to 22 of this 23×23 square of 25×25 pixel grids.  The top left is coordinate (0, 0) and the bottom right coordinate is (22, 22).  In the mini-map the top left is (0, 0) and the bottom right (3, 3).  Added #1577 to 1712, which are the afore mentioned nested loops inside conditionals to make the mini-map work properly while the avatar is on the playing field boarders.  Added also, so this will work is #1444 void OutDoors_Blank(int X, int Y).

Back to the Upper Left Corner.

TrailGrid[HX][HY] = true; // set the grid that the avatar is in to true.  This is still causing problems but I think I can guess what is happening.  HX and HY are initialized to 0 in the setup function.  The game begins to run and although TrailGrid[0][0] is set to false, never mind, like it always is in programming and mathematics, order takes precedence.  All I needed to do was switch two function calls which were one atop the other so that the Heroes position was set the first time through before the call that requested the use of the variables from that call, duh.  So why are things always in the last place that you look?  Because once you find what your looking for you stop looking for what you’ve found.

And That is That.

The game code for this month is finished.  The game speed has been optimized by clearing the terrain map and then having only the terrain icons appear when the avatar has moved into that grid space affording the game name TrailBlazer to be held true.  The functionality of the mini-map has been enhanced by having all positions of the avatar on the grid capable of reflecting the surrounding terrain from all locations.  The mini-map no longer fails to be visible while the avatar is on the playing field boarders.  No errors have been introduced while advancing these improvements and the game in its entirety has lost no integrity.  This has become another successful versioning expedition in coding practices.  I’m satisfied with this months outcome.

Play the Game.

Trail Blazer


July 1, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0039] ~ Refining Wanderer:

It works, but . . .

Now for the checklist, from the top.  Change the 64×64 .png icon image to show that there have been changes made within this version of the game. Done, it shows the Spring of Life now. Next, after the icon is clicked, the player is taken to the game which presents itself on the webpage in a browser.  The look of the splash screen is the same, OR, nope, what I need to do is copy the last project build over into a new instance of Processing as Wanderer2.  Then, so the project solution will run in the browser in JavaScript mode, I need to copy the art assets into the API so they can be found by this instance within the projects data folder.  This has been made into a simple task by opening the previous game data folder in Explorer, selecting all the contents in that data folder, and dragging it onto the Processing page of the game that data is to be copied to.  Processing makes a new folder in the solution instance folder, names it data and copies all the selected art assets into the new folder.  Very cool.  All that needs to be done is to save the game, stop the last browser instance and click run.  Voila, the new version is up and running for this month.  Now I can change the game entrance button to say “. . . SEEK” which is changed from “. . . HOPE”, and change the color to reflect the change of the Dragon motif, gold, to a bluish color which is to denote the Spring of Life is to be the objective of this version build.  Open MS Paint and use the Color Editor to get the RGB settings into the code page, done. And just to give an idea of what is in this game and to get a little fancy, I might as well put the game icon, the Spring of Life, then the Hamlets and the Castle along with the existing avatar into the splash screen to add a coherency to the direction of the game.  And where might I find the splash screen in the code page?  Hmm, more recollection and searching.  Nope, I hard coded the images into the .jpg itself, so I need to open Photoshop and have at it.  Then open MS Paint and rebuild a Hamlet because it builds a clearer image for what needs to be represented, them place that image into the splash screen.  Now for the castle for the splash screen also.  Just run the game to get to the victory conditions and screen shot the vector art built by the game itself and place that in the splash screen.

Segue break.

Easier said than done, this is a tough game even if you do know the rules.  While running through the game to get to the victory conditions and the castle vector art to be copied, I’ve noticed a couple of things that could prove insightful to the player.  Click on the three by three grid of arrow directions to move the avatar in that direction.  The terrain takes care of the distance the avatar can move per day and the food and water cost.  These are shown by the green and cyan colored survival bars, which reflect the current status of the avatars health and longevity.  But, when the avatar moves into a grid space which is adjacent to the border of the playing field the mini-map disappears.  The reasoning behind this is so that the algorithm that reads the data to build the mini-map doesn’t crash out.  While reading the data to fill the three by three mini-map assets, when the avatar is on the border edge of the full map, only some of the nine grid spaces are allocated within the array.  Accessing, or trying to access the data with the current algorithm causes the program to crash because of a data over or under run error.  It is trying to access data which does not exist within the array.  The simple solution was to drop the mini-map out of the draw loop.  Its capacity to access the nonexistent data to be drawn and therefore the erroneous algorithm call were bypassed.  Simple for me to understand but possibly confusing to the player.

Another feature creep idea that might make the game more playable would be to add something that would be of concern and involve the mouse position when it hovers over one of the nine vector arrows.  The idea here would be to show where, if that button were to be clicked, the next grid position of the avatar.  This would take some of the guess work out of the equation and let the player make more insightful paths while moving towards the next Hamlet.

This game needs a help file.  Having a clearer definition of the terrain icons is needed along with some what an why.  And that is going to be the major change to this months version, an addition to this game, helpful documentation.  What can be clicked on to get this game to do what it does is very obscure at this point.  Actually what would really be nice would be to have a flowchart that I could click on that would show only the logic flow that I’m actually concerned with.  I grow weary of the overload of code I’m assailed with every time I seek to change something.  Having everything, the entire code, available and accessible is great but every time I want to do something at least ninety percent of the code I’m looking at is irrelevant.  Too much scrolling and needing to think, no, that’s not it, nope, not here, hmm this isn’t the place, ok does this have anything to do with what I need to change.  Tedium in excess, futility and grand inefficiency.  It makes me sad, and only adds to the . . . yeah whatever.  Now that would be something to build, but that would be a programming API and not a game.  Or maybe I could gamify an API, but not today, so back to it with my mindless stare and brain numbing searches.

The theme for this month is “Grow”, so I will grow a users manual for the game.  As for the side line quest, seeing that I haven’t played this game for some time, will be to come up with ideas that I can incorporate into next months version.  Forgetting what I have known and then realizing what was thought to be simple then concluding that it was not is where these ideas are going to come from.  Right then, onward to the chase.

Segue break is over.

When I start the game, the only choice is START, not CONTINUE, not RESTART.  Those last two can be dimmed out and made inaccessible, for the time being.  Beautiful, but how does this come about?  Back to MenuSystem and #707, #715 to find some booleans.  GameContinue #887, #737, #707.  Ok, that’s done.  The CONTINUE button is grayed out at the start of the game and has been disabled until the game has been started via the START button click.  Now for the RESTART button.  #930 and it was just about the same as what was needed to rectify the last problem.  Hmm, I’m building this game like how I would build applications and it seems that this game is turning into a hybridized game/app.  Somehow the menu system feels a little off, not quite gamish and not quite appish.  Its not bad, its not wonky, maybe, but it gets the job done, hmm.  Well, that’s done.  I added a boolean GameReset and stuck all the resettables inside the if() statement, and it works now.  All that needs to be done for this version is to add the documentation that will let the player know how to play the game.  Or, do some play testing and find that the little avatar doesn’t move back to center stage after RESTART, more searching to get this cleared up.  Well, the Defeat conditions don’t reset either, and so I find the function call, right click on it and find that there is no GOTO function definition in the dropdown menu.  More manual searching.  That’s silly, the victory conditions and the defeat conditions are nowhere near each other.  Yes they are, but the conditions aren’t directed back to a central boolean value.  They’re just flappin’ in the wind.  Alright, after the avatar has been defeated, the player or in this case the tester, can continue to click on the direction arrows and the avatar keeps moving.  To top it off the Food and Water bars use negative numbers to feed the width of the bars so the bars begin to grow again.  That’s another good one where if the avatar is in a state of Teleportation at the time of expireation, i.e. death, the green avatar figure is not reset to its viewable state and only the red and white dot are seen.  This I found because the movement distance retains the distance of the current movement distance of the terrain grid at which the Teleport Spell is cast.  It needs to be reset to ??? along with a disabling of the use of food and water.  No food and water is to be used during the Teleport Spell movement.  BMR is the Biome Movement Rating which is the distance the avatar will move through the terrain per turn.  #725 BFWR is Biome Food & Water Rating and is used to subtract the given amount from the avatars cache of food and water per turn.  I just noticed that I keep saying turn while a Teleport Spell, although the direction arrow is clicked multiple times, the result is to be that only one turn has passed.  This might become of consequence at some point in time but currently turns are only accounted for the progressive directed distance of the avatar.  The code could be starting to become messy, despite all my good efforts to keep it tidy.  Now I need to add a Boolean to the switch/case so that the BMR and the BFWR are not reset with each click of the direction arrows.  So if(TelePortSpell) . . . Ah ha more messy code.  I put the Food & Water restore to 100% inside the switch/case function because that was the best place to have it reset, but that actually messes up the Teleport implementation because no matter where the avatar is on the grid map the food and water is always set to full when ever the teleport button is pressed.  More changes.  Rules, I need some rules for the game if the mechanics of this code are to be found to be correct.  And the first rule I have found is that when using the TelePort Spell one days supply is consumed for that terrain type in preparation for this feature to work.  #1634  Because that is how it works.  Back to the Defeat conditions.  #555  In either case Victory or Defeat the game is over.  So how do I stop the input and keep the avatar from moving.  #693  It looks like the easiest way is to put the mouse interaction for the direction arrows inside an if statement so while GameOver is false the player will have access to that portion of the game.  Once GameOver is true there will no longer be any input for the avatar.  #532 #562 #649 #696  That should do it.  Or maybe not.  It kinda works.  It locks out the buttons, the directionals and the Teleport button, but the last button that was selected is still active.  Clicking anywhere on the 3×3 square still activates the last button that was selected and moves the avatar in that direction and continues to change the food and water meters.  In fact, clicking anywhere on the canvas object activates that button.  Ahh that was void mouseMoved() not, nope hold on, what I need to do is assure that InVectorSetBounds = false; is set outside of this function, in both the Victory and Defeat conditions.  That works.  Now if BMR or BFWR are less than or equal to zero both will be equal to zero, and where should that go?  Because at the end of the game the food and water meters want to add on a last decrement to the meters.  #563 In the Defeat conditions routines of course.

Feature Creep, kinda.

Working with the food and water meter bars has pressed an issue that will promote a change in the games interface.  Something as simple as adding numeric counters in front of the meters.  Having a value that corresponds to the meter size could be helpful.  Where then is that draw function?  Follow the meter, WaterMeterWidth.  #1188, #1200  Two lines of code, that was too easy, but I’ll take it.  It looks good and it gives a better definition of what is going on, seeing that the values are given in the legend anyway. Having that mini-map fall off the screen is somewhat disconcerting.  But that will have to wait for June.  The help file documentation manual is what the plan was.  All that forgetting over the month just to remember how it all works again and then not being able to look at it without any subjugated preconceptions wasn’t the plan.  Knowing how it works doesn’t help in building a help file when you already know what you need to know while not knowing is what the help file is all about.  Yes, that fateful dichotomy rears up once again, ha ha have at you mon ami (“my friend”), monamine (i.e. Neurotransmitter).

The Manual.

I’ll need to switch around some of the button links to the different pages in the game. #1041, #1094 Nope, I still don’t get this menu system, its too spread out in between the draw method and the mouse routines, it works, but again there is too much scrolling back an forth.  I guess that’s what peek and poke were for back in the day, just after adders, accumulators and such were in vogue, so be it.  Now how do I get back to my game after I get to my players manual. #832 Alright, it’s not the best menu system but that’s as good as it gets this month.  Until next month.

Play the Game.

Wanderer II


May 31, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0038] ~ Focus on the Locus:


But first, a short “what’s its” of the month.  Dun dun da-a-a, Xbox One, eight cores of processing power among other things.  I don’t have one, yet, but as an XNA hobby/Indie programmer I think that might just happen.  And two, the computer version MMORPG Dungeons & Dragons Online is proving to be an incredible game.  If they make a version that runs on the new Xbox One, like the game that was put out before, Dungeons & Dragons: Daggerdale for the Xbox 360, I could see that happening too.  Hopefully as a seamless, transferable, built so that no loss of any of my Avatars, their assets or their Reincarnation upgrades is a part of the deal, sure, I’ll be in.  Now back to One Game A Month and version 2.0 of Wanderer.

The game starts, and I know how to play it, Wanderer.  I’ve written the blog posts so I understand the backstory.  I know the routine for input interactivity between the game interface and the controls used for that interaction.  I have a pretty good idea of the pitfalls of the avatar in the game and what are the best ways to keep the avatar alive during game play.  And, of course, I know fully well just what doesn’t work or just kinda works or might work if certain conditions that aren’t quite obvious are met, or, or, or . . .

Wanderer v2.0

It looks like the game itself is as complete as it needs to be for it to be considered an actual game.  It starts with a splash screen.  It moves right into the storyline build up.  And then, it starts to get a little scant when the next options are given for the player to make the next choice.  There are three directions that the player may choose from, all available to the player to select, at that point, the beginning of the game, that being START, CONTINUE, RESTART.

Start works just fine, it had to, because I wouldn’t have been able to test the games logic and follow the accompanying algorithms had it not.

Continue, was added because during game play, if a player were to right click on the canvas object where the main game action is taking place, (i.e. the terrain map, avatar, springs, hamlets, legend and other assorted game assets), where the player finds direction through a game state change back to where game management options are found and can be chosen from, the Continue option allowed reentry into the game where the player left off from the right click.

Restart, has remained in limbo since the games inception, and has for the longest time, has hadn’t much of any observable, more like nonrecognition of its existence, constructive work directed towards it with its use or within its function.  Reflexively, the work-around or easy-out, for me, while building this game, was to right click on the webpage, not the canvas object, and from the browser menu dropdown list item was to select Refresh.  This would simply reload the game on the webpage in its entirety and bypass the Restart button option completely.  Very quick and dirty, cheap and easy, and from a players point of view, a huge break from the captivation that is constructed to enfold a player while one progresses through a seamless adventure presented by the game.

This is how Wanderer starts up and with what a player is confronted with while entering into a, prospectively, enjoyable game experience.


From all this reflection, Wanderer, although playable, is not as intuitive a game to play through the given seemingly simplistic ideals, icon representations and underlying concepts as seen on the screen in its current state.  The presentation assumes leaps of faith that might not be as clear to one who would stumble upon and find this game through a browser and a search engine.  There are also still too many gaps that allow for presumptions that are not fully and at times more than likely not even partially addressed nor have been given any documentation so as to be found in the games, and at the time of this writing nonexistent, help file.

So, what’s your point?

The theme for May on One Game A Month 2013 is “Grow”, and seeing that I have gamified myself previously, I will incorporate that theme unto myself as I continue my versioning of this game, my game, Wanderer, now at version 2.0.  Having stepped away from this game build for a time and now walking through it again, I can see how I refresh my own rerecognition of the paths I take which furthers the creation and evolution of this game.  It is a strange way of fate that as I draw on recollections to build retention, that tendency presumes I become oblivious to the obvious, wherein, that oversight is then perpetually reinforced.  Yep, and Yikes.  I must still be learning how to learn.  I guess that’s what my gamification take on the “Grow” theme is.  Good for me.

And yet, what is my point?

I have found my OGAM Mission Statement: “To become gainfully imbued.” is gaining truth in its surmisassions.  Thanks again Christer.

To Be Continued . . .


May 30, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0037] ~ The Perceived Direction:


And the direction is seen through versioning.  Dragons Hoard, was an epic adventure of an avatar seeking to consolidate the Hamlets of the land and return them back to the kingdom.  This next game is to take that previous game template and put on it an overlay,(possibly an underlay).  That then will be the next version and will be seen as the game going by the title “Wanderer”.  The theme for this month on One Game A Month is “Spring”, and so, for this games sake it will mean Artesian aquifer.  The last version of this game was built with one bold jump into creation, as a Seven Day Rogue Like challenge entry, with little to no forethought in how it would be of use as a template.  But Dragons Hoard has become the template to base my concept of versioning on and Wanderer is the next step in its progression.

Stepping back.

With this new concept for the April game I will have the hero wandering through the land looking for water.  The “Springs” this avatar will find are where the residents of the kingdom consolidate, and so, will be where the hamlets set their roots.  This little adventure game will be previous in time to Dragons Hoard and is what will set the stage for the already built game Dragons Hoard.  In Wanderer the Hero sets out into the wilderness and must find suitable locations for the Hamlets to be founded within the Kingdom, i.e. the “Springs of Life”.

And so it begins.

To champion this cause the avatar begins charting the Realm in search of the “Springs of Life”.  These springs are where the good guys and the bad guys want to be.  Both need the water and both are in it for keeps.

The over/underlay code restructuring.

Change the for loop to start with the springs placed where the randomly selected hamlets are assigned.  Then once the spring has been won, the hamlet will spring up from the well and onto the map.  OK, that’s special, now I need to go back and get rid of the initial randomization when testing the layout visualization in the Terrains’ select case function.  That was it, the Victory conditions were set, strangely, because of the randomly generated amount of hamlets for each game which made for some messy logic and a lot of time consuming “if(&& || &&)” sifters for HamletVisited booleans. Cleared those up and out.  All right, that is kinda silly.  When I was building the draw routines for the map legend, (i.e. the mountains, trees, prairies, swamps and waters), I used the grid and not a general position in the Cartesian coordinate plane, (Quad I,II,III,IV), as I did for the Castle and Hamlets.  Yeah, consistency would make sense.  What do you want for 168 hours of break neck speed programming?

Construction next fifteen miles, merge right, fines double in orange barrel work zones, detour ahead.

#1459 switch/case show-hide spring or hamlet.

#532 set the “spring” in lieu of the “hamlet”.  And yet it tends to disagree with my arguments (i.e. function parameters).  Keeping a consistent coordinate plotting system is the matter at hand.

JavaScript is not like the precompiled languages that I’ve become accustomed to as far as I can see.  Things are a little too spread out and the consolidated train of thought has too much intangibility.  Having everything on one code page doesn’t help either.  I really don’t feel like melting the program down and starting over, but I just might do exactly that for the May version submission.  And with that thought, it’s time for . . .

Slash and Burn.

What don’t I need from the game Dragons Hoard is to become my first “Block Comment” excursion.  There is no castle and so the dragon will have no interest in this land.  No Castle, no Dragon, done, commented out.  Hamlets will be cropping up where the springs are set so I’ll keep those draw functions.  The placement of the hamlets though will align with the springs and therefore will follow the placement algorithm used for the terrain icons given on the grid map.  That should tidy things up a bit.  But there will only be a limited set of springs and not a “fill the map with assorted terrain features” amount.  I also don’t think there will be any PermaDeath or MagicMana in this game either.

Really, is that how it works.

Aah, I get it.  Along with the disjunction between how the terrain icons are placed and how the hamlets and now defunct castles are placed, there is also the mini-map that also uses an offset different of that used in either of the previous draw routines.  That’s what you get for building on a tear, yippy zippy, crash boom bam and it’s done, hmmm.  Well, I think I can follow the somewhat scant train of thought through this and with a little more slash and burn I should be able to translate the remaining code into a new project.  That new project being the game “Wanderer”,(my avatar should have a magic wand but that will have to wait).

More ideas.

PermaDeath could be changed to food and MagicMana to water (in the next game).  Done, it’s in this game. Now for some rules.  This hero wanders about the yet to be kingdom looking for springs so hamlets can sprout.  But the hero and the hamlets will need food and water but this is the story of an avatar hero seeking to build a kingdom.  And so, only the hero needs to stay alive, with a personal stash of food and water, while searching this new found realm.  These are the rules . . .

Movement is essential and this is how fast about the grid with its differing types of terrain the avatar can cross it, along with the cost of staying alive.

Type      Move    Food  &    Water

Water            : = 9      0      0

Prairie          : = 7      2      2

Forest           : = 5      1      1

Swamp         : = 3      3      3

Desert           : = 2      4      4

Mountain    : = 1      5      5

This is the general metrics of movement vs. sustenance.  And with that information I could probably build a legend for the map.  And now that that legend is done, I can see the biomes set on the map with each biome having a movement rating which also has a Food and Water cost coefficient for the movement through that terrain.

The Clicks.

Now all I need to do is figure out what happens when I click on a vector set button.  Supposedly, with each click, as the hero moves, the effort needed to pass over that terrain has a cost.  The difficulty rating is measured by the capacity of that terrain to supply the necessary food and water to the avatar so the supplies carried by that avatar are not so quickly diminished while passing over that terrain.  The other half of the difficulty rating is how easily the avatar will find the terrain to be traversed.  To keep the game simple, basic integer types will be used.

Alright, I have found the draw function for the hamlet and must now rearrange it so it conforms to the other game draw functions.  More hmmm, but, “Notepad++ is awesome!” and with that I find ‘time’ is what makes things stupid.  And so it is time to get out the ol’ trusty melon ball scooper and switch out the innards of that pesky Hamlet draw function.

Line Numbers: #503, #1127, #257, #955, #506, #484.

That should just about do it for getting the springs and the hamlets on the map.  Now to finish it off with a little collision testing where when the avatar is in the space of a “Spring” that will be seen as a Hamlet on the grid/map.  A counter also needs to tick off one more conversion so when all ten hamlets are built the game is won.  Yes, those are the only Victory conditions.

Whew, boolean traps, if verification, nested for loops and counters all for the sake of having a “Spring of Life” turn into a Hamlet.  And they do, finally.  Next is to clean up the victory conditions. Done.  When all the hamlets have been built a Castle, (yes, it made a reappearance) appears above the mini-map, and the ta-daa “VICTORY” is shown across the grid map.  Oops, I lied, the castles are in the victory conditions “You Won” splash ending screen.

This last bit was a little tricky, but it did turn out well enough.  Getting the avatars movement coordinated with the icon legend.  Just to add some understanding to what is going on as the player clicks on the vector set to move the Hero, I placed an underline in the legend to show which terrain feature is currently deterring the Heros’ movement.

And that just about wraps it up.  All that is left to do is get it into a web page.  Then a couple of test runs just to make sure that it is working properly, and last is to get this into my WordPress Blog.  And so, Happy Spring.  And . . .

Play Wanderer Here.


April 30, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0036] ~ Continuing My Dragons Hoard Game:

For the continuing, of course. 

This hasn’t been a normal month by any stretch of the imagination.  To start off, Notepad++ has an update from v6.2 to v6.3, Thank you.  But what is even more strange is that, for the past month I really got my nerd on.  Stranger than fiction is found in becoming a Dungeons & Dragons Online player.  I never gave much credence to the thought that an MMORPG such as DDO would ever have any overbearing appeal to me, but, “Yah live, yah learn” is how I have to look at it now.  A while back, for the XBox 360, I picked up Dungeons & Dragons: Daggerdale and thought that they should make a sequel or an expansion pack or something to continue the game.  And apparently they did.  Both the computer and console game have the same style, of course, but the computer MMO version of DDO has a much better avatar point of view and capacity to manipulate it.  I am duly impressed by the graphics, the depth of character creation, the breath of the playing field (i.e. the worlds within worlds), the melee and spell systems, the multi player social grouping tools that allow the player to break out of solo mode game play and into the MMO play style, the questing setup, layout and flow and of course the plethora of monsters.  I kinda took the better part of the month off and built two avatars, a multiclass male Dwarven Wizard lvl 11 / Cleric lvl 1 and his cohort in clandestiny, for now, a female Drow Favored Soul lvl 5.  And just to give a little flavor to my characters, I’ve borrowed an idea from a game I played, Pathos, found because of One Game A Month.  The rules of this small game, Pathos, are that two star-crossed lovers are to be kept apart by placing barriers in their path but not so much so they will never meet.  With my two DDO avatars the rules fall into this alignment in that their chances of meeting are thwarted by the game itself which has placed barriers in their way.  This is mostly because the game doesn’t allow me to play both characters at the same time.  Although having the capacity to “hire” one of my own characters to be my sidekick within the game would be an enormous boon and would more than likely be acceptable to any player within the game, this seems and is as of yet naught to be, and therein lay the Pathos, my underlying theme for my DDO idiom.  Not for glory, prestige, platinum, shards or any of the other countless baubles and gifts of weapons, armor or spells will they ever meet.  Only in the “Dragons Dream” do they exist, that, and through the shared bank will they ever trade secrets.  Such is the story line, for these two, my avatars/characters, ^’o’^ Eandor Aufoolm and EanZingTihel Aufoolm ^’o’^, at any rate.  Yep, really got my nerd on this month.

I looked up to find . . . 

But while coming up for air, and shaking off the “in the game” experience, I’ve noticed how or at least on what a larger part of the game model is based.  In economic terms “utility” and “opportunity cost” seem to be the driving factors.  But the game itself is well provisioned for these terms and is masterfully constructed.  With the visual representations for the characters appearance and the commodities that they can behold, wear or use along with the actions the characters can perform allows much room to incorporate interprétions of any story line that a players avatar might cling.  This world where these, my avatars, exist are presented through detailed terrain and changing environments.  Day and night cycle, the clouds, rain, sun and moon come and go and the water has its fluidity.  There are story lines that accompany the quests which take the avatar through the city, its buildings, dungeons, subterranean caverns and further into the unknown.  The mystique of “what’s around the next bend” has a pull on the player and sets the challenge of each level higher with each turn.  Replayability is also built into the game where a players character can start again from the beginning with something called True Reincarnation.  I can only imagine how many hours were resourced to devise and build this game, and I really don’t have any desire to even begin to contemplate how many hours were given to play test and play this game.  That’s entertainment for the sake of entertainment.  DDO with hard taught economic theory given through entertainment, hmm, who would have thought gamification could be so pervasive, oh well.

So anyway. 

Getting back to what I am trying to accomplish through One Game A Month.  I find that with my last game, “Dragons Hoard“, where the game was built in 168 hours for the Seven Day Rogue Like challenge in March, the time given to the product revealed produced many changes.  The game I found myself with wasn’t exactly what I was envisioning when I started that initial thought in my brain.  I just ran with what I could do within the time constraints I was given.  It was close, but definitely fell short of the mark of my expectations.  I can see how feature creep can become appealing to those who don’t understand the interconnectivity involved to add something that wasn’t initially intended to interact with the processes that are to . . . well, to say it gets complex would be an understatement.

Meanwhile, back at the ranch. 

And so, with that in mind I will take my OGAM involvement towards a construction model and thought retention system I, once again only have an inkling of what I can envision, will devise.  To this end I will use the template of Dragons Hoard as the game type that will be built upon, but the end game isn’t the game.  The end game are the systems and mechanisms that are utilized while building the game.  Loosing track of what I have already built seems to be a larger part of the problem here.  I stumble upon an old game I had forgotten about and say, “Did I really build this?”, but once I open it up I find that I can recall the logic flows, for the most part.  Still, it wouldn’t be a shabby way to have some flowchart, template, pseudo code, commentation, blueprint kind of thing that I could go through and say, “Yeah, this worked, that didn’t, this kinda did, that might or almost would, this could, if . . . ” and so on.

The Plan. 

This then is what I’ll be looking to do while I finish out the year and continue to build my games for One Game A Month.  Not to go out of my way to build a ton-o’-games, but to, like Spock put it, “I am trying to build a pneumonic memory device out of crude stones and animal skins” to help me remember what I’ve accomplished thus far, and then find it again, easily.  I’m always so off topic, big deal, it is my way, so be it.

Until then,


April 20, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0035] ~ RogueLike Challenge:


. * * * Dragons Hoard  * * * .

In the depths of my dreaming

I awoke from my slumber

to espy my new incarnation a lumbering hulk

in scaly skin gleaming.

Eyes drawing in

all the world that is mine

of taking for nought if new sleep should arise.


Day 1 : The Play.

This RL will be that of a Dragons Dream, forever reawakening to find that all of everything will run short of its desires.  Time is the drubbing force that will be its demise.  Those who hasten the Dragons repose unto death will claim its possessions.  Surviving each successive Dragon incarnation, The Interim, the Champions free thoughts of love, life and the Dragons Hoard hatches yet another Dragon whose appetite draws its ravenous maw to interpose, and the cycle begins anew.  To find the Dragon and quash its revival, for a time, the Heroes must follow the trail of the entranced minions back to the Dragons Lair.  The fight becomes more difficult as they get closer to the Lair.  The growing Dragons hold on its minions strengthens with the Dragons proximity and longevity.  The furthest from the Dragon with the most weakest of mind are most easily coerced to hinder the Champions.  Those creatures tending to villainous ways have stronger wills but are still corruptible and add to the safety of the Dragons perimeter.  Getting ever closer, nefarious monsters are singled out and are set to do the Dragons bidding in battle.  And at last the Dragon itself will task the party in a duel unto PermaDeath.

That’s a good baseline story.

Its got a plot to match the Protagonist to an Antagonist, a plot device as the Dragons Hoard and Recursion for replayability.


Day 2 : A place to stand and fight.

Ok, I’ll be needing a map of the world for my characters to roam about in and on.  I keep thinking Characters like I’ll have a whole party of adventurers, and so far I have no characters.  So, for as much as a group of players sounds like a wonderful idea, I should start with at least one and see how that plays out, just one Hero and one Dragon.  From there I can cut to the final scene and see how the final battle will turn out and a new game will restart, after the Hero or Dragon has been defeated.  Raise the lights, roll the credits, it’s all over, Dun Dun Dun T-Daaah! The End.  Restart?  I guess the next three options would be, after the START of the game, should be EXIT, CONTINUE and RESTART.  With those options the player can exit the game and leave with a push to the intro splash screen, which is almost the same as pausing the game, continue the game from a Heros player pause or restart the game if the Hero should find PermaDeath as the allotted fate.

Hm, it looks like Processing, with its last update, changed the colors of main methods from the colors of the key words, I think, not exactly sure, seems that way, maybe, anyway it might look different, I’m not sure what they did exactly but I’m good with it, anyway.

I just built the games splash screen and peeled the menu system out of last months game Streamonsters.  I tidied up the code and the comments and shuffled their placement in hopes that the global code page becomes slightly more coherent, for me at least.  It’s up and in my site as a basic game shell/framework and it will have all week to get the assets and logic in place along with the polish it so sorely needs. Now to pop this into my ever growing 7DRL blog post.

Then to finish off  the day I only need to do some stuff like rolling up the chords, getting the tools into the job box, straitening out the lumber and covering it up with a tarp, sweeping up the work areas and picking up any stray nails, talking to the foreman to see what’s going on tomorrow, grabbing my lunch pail and hitting the road for that ride home.  No, wait, that was carpentry, aah I got it, select start button, click shutdown, brush teeth go to sleep.


Day 3 : Screen Real Estate.

It seems that my next piece of work in this Hack & Slash game is to get the playing field in order.  This can only mean that I need to divvy up my 800 by 600 grid of pixels into a map side and a control panel side.  The map will consist of a scrolling grid to hold the environment, player, non-player characters, landmarks, treasures, artifacts, villains, etc. all of the viewable pieces of the game.  The control panel side will be a place to keep the score card as an updated set of statistics and good to know information as an easily accessible and somewhat configurable area.


Day 4 : Game Intro.

I’ve been shifting around the menu system and have found that having a blueprint of the game is a nice thing to have, along with some flowcharts and a consistent set of variables mapped to a table of contents/comments.  But in this challenge, small, fast and done is the modus.  Inline and block comments are the way to go, just don’t forget to change them to remain consistent with the variable, method, function or whatever if cut/copy/paste is how it is build.  That’s how I do it, ccp.  I reread my comments as a quick and dirty way of doing a hand-check of the logic flow as I go.  So comments that don’t read right or say something that seems a little off means I haven’t been through this code block lately.  Moving along . . .

With my great artistic creativeness I also have another slice of art in an Intro Screen.  It’s something like a splash screen with the only purpose of it is to allow for assuring that the player assigns a controller, in an XBox console game, as the host player.  The reality is that that screen isn’t needed at all in this game but, “It is my way”, in doing things.  I’m must be getting an itch to get back to my XBox and GS-XNA 4.0.

I started digging into the main game playing field and have the beginnings of a coordinate grid and an info panel space.  It’s a lot of making the pieces fit and not much for game play as yet.


Day 5 : Hmm, to the “n”th degree.

I need to add a Users Manual to the mix.  I fully understand this game in its entirety, NOT.  And so, I’m sure that anyone who just looks at this game will also be, “on the same page”, NOT.  So, whenever whoever starts up this game to play it, they will get an Instruction Manual going by the simple title of Manual.

OK, that was really special, in the menu system I’ve got goin’ here, do not, yes do not overlap the box that is to be clicked on, on the current screen with another clickable box on the upcoming menu system page.  It takes a while to figure this one out because it isn’t all that obvious.  To begin, everything looks right, but when the boolean switch is given the new value, the game decides that when it updates this value, it doesn’t realize that the sluggish human coding this logic, which it has given to the program, can’t fathom the general leap of faith that goes on along with the idea behind said logic.  Hmm, to the “n”th degree.  So, back to quick and dirty, just move the first box out of the way of the upcoming box in the next menu screen, alleviating the need to track down and build another boolean trap, and all is well, at last.  Next solution, oh yes the manual button and the Manual itself.  Can I have a Dragon and a Hero yet?  How about some tufts of wheat in the field around the castle?

Yeah, this coordinate plane thing is sooo counter intuitive.  Whoa, Microsoft has recognized #1GAM in a good way, Microsoft Loves #1GAM.  Now, back to the grind stone to forge ahead and strike while the iron is hot.  I’m getting closer to finishing off my 7DRL, in its most basic form.  I have a grid and my Hero in the map area.  In the control area I have my VectorSet and two coordinate pairs.  The VectorSet moves the Hero about the map while one coordinate pair is matched with the Heroes’ position and the other pair is matched to the position of the mouse pointer.

Everything is tidy.  The Hero, which looks like a little red dot, can run around the map and there is a BIG RED D for the dragon that is causing mischief in the kingdom.  But not so much that I won’t be going to sleep right now.  My Hero needs some stuff like food and who knows what else.  And my dragon is stuck in one spot, but my Hero can’t dispose of the dragon except by attrition, no weapons.  I go nighty nite right now.  bye.


Day 6 : Who gets what where.

The game has a Hamlet and a Castle.  The problem is that the map, as it stands, is quite small.  Each step for the Hero is a full grid space, twenty-five pixels.  It’s simple, but moving quickly about the map is paramount right now.  Along with the Castle and the Hamlet, our Hero and the Dragon occupy some space in the opening map.  This is something like what I was thinking initially.  What I would like is that the map should have some translation properties so the Hero will stay in the same position on the screen and the world will move underneath.  Having the map stay stationary and the Hero to move on the map is another way that would prove useful.  I have a couple of ideas that fill out the environment like Mountains, Deserts, Swamps, Waters, Forests and Prairies.  That should be more than enough for this 7DRL.  I also came up with a list of general adventurers gear that every Avatar should have at hand.  Seeing that these haven’t made it onto the game screen yet, I will set to manipulating the coordinated grid of the map.  The first thing I need to do is to tie something onto the map, like a Hamlet, so when our Hero begins this journey the happy hovel fades into a distant memory, and off the screen.  Ah-hah and sigh, auto completion is a very nice thing to have, my scrolling finger is taking a beating, but a wheel mouse does help out well enough, that and the scroll bar.

Eeek-gad, I will need another rethink because shifting the map is going to take a very critical look see at the code and probably some cross referencing with my old app FxMap.  There is no time to do this map translation process and so I will have a static map, more sigh.  What  would I like this game to do now?  What do I have already to make this game into an Outdoor Survival like RogueLike game?  I have a Castle and a Hamlet a Hero and a Dragon in a Map that has a grid and a control panel that has a VectorSet to move my Hero about the map and two coordinate sets, one for the Heroes’ position and one for the mouse pointer position and lastly a PermaDeath gauge.  Sadly I will need to grid lock my Hero to this map but, “C’est la vie”, “C’est la guerre”.  I’ll need to randomize the positions of my Castles and Hamlets on the map.  Ok, they both can be drawn as many times in a loop as need be anywhere on the map.  My Hero can be a Feudal Lord, when not slaying dragons.  And more proof in action, KISS makes my day.


Day 7 : The Last Day To-do.

Most of the parts of this game are in place.  I should start with the setup and mechanics, that being the map randomization.  It looks like I’ll need an array of 23×23 so I’ll splurge and make it 25×25.  Each grid box will have a terrain type assigned to it which will change the speed that the Hero can walk through that grid space.  The grid is populated with the dominant terrain features, that being, they have a colored boarder around the grid which represents the type of biome that is dominant in each map grid.  Also, the Prairies, Forests and Waters graphics are done and load in to each representative grid.  The Hero has one spell, the only spell in the game and lets the Hero Tele-Port to another place on the map.  This will use Magic Manna, which can be replenished at either the Castle or a Hamlet.  I believe I have won.  My game does not give me and out of memory error, but hints to me, more like something to show that my fat ham-fisted numbskull logic creation produces a game g-u-i sloooow, like a snail.  The real problem here is that I don’t have my monsters, other than my Dragon in the game.  Well, it looks like I have found the fabled Sword in the Stone and in the same Sword in the Stone, where the sword is my code and the stone is my computer.  My code is stuck in my computer and it won’t come out.  What I need is a super computer and a dedicated time slot.  Or, I could just optimize what I have, it’s only a game, you know, not a simulation.  Not nice, bad timing, happy and sad, my buddy is in town and only nine hours left to finish off this 7DRL, but I can now teleport, probably teleparty myself over there, in spirit anyway.  So, like my ol’ Master Carpenter would say when you’ve gota’ set to doin’, “It doesn’t get done by just lookin’ at it.”

I think its the arc algorithm.  I just block commented out the void function call and its back up to speed, too many screen write calculations.  I need a different draw type.   The Triangle Strip seems to work well, but the whole map is pretty much filled up with terrain features, so maybe I could half that in the setup generation part.  I better see how it runs as a web game in my browser.  OK, not bad for a turn based game.  Now to work on moving the Hero through the terrain type grid.  Hoh-boy, supra-flash back, my sister and I played the game OutDoor Survival a long time ago, mid 1970’s, and thought back then that that was a really cool, fun and entertaining game.  This game seems to have something in common with that one, and I like it.

Yes I do, and it looks similar, in part, except for the stick figure guy that slowly becomes hunched over to the point where he is crawling on all fours, to where he lay prone and splayed.  That, in this game would be the Heros bane and demise.  But alas and alack, I have but 5 hours left to end game.  The Hero can, after alot of crash and burn, move about the map with less than a 25 pixel step, in fact at any incremental step.  Glad that’s done.  The next thing is to build a pretty map in the control panel, kind of like a mini-map, to see how much food and water it takes to get to, then through, the monster hoard.  Hmm, the mini-map works but now there is the issue of bounds checking and array over/under runs.  This shouldn’t be too hard, famous last words.  It’s done, it seems fail safe, it’s in a canvas and won’t break anything accept my coders pride, so all is well.  Not much time for play testing, oh well.  4 hours to go.  What’s next?  Another incremental save with a play test to the March FarNiche OGAM web site game.  It still works on the web, so off we go.

The story line has changed again.  The way I see it, the Hero must run around the Kingdom and go to each Hamlet to get a piece of the Dragon Slaying Sword, an Artifact that will be the bane unto the Dragons demise.  So I need some Castles and Hamlets dispersed about the Kingdom.  Off like a flash.  Got the randomly positioned Castle, and now … random Hamlets good.  3 hours.  Select All in Processing should have something else underneath paste.  Yep I’m in overdrive mode now, Visual Basic is kickin’ in “for(int i = 0 to NumHam)”, hmm.  Collision needs a print to the screen.  A nice thing about Processing is that you can change the code while the host is running and update the code en-process without the “ding” from the debug runtime compiler thing.  Wow, there doesn’t seem to be any collision detection in Processing, more sluggish graphics, tick, tick, tick.  I’ve got Relational Operators to mutate.  Aaaagh AxisOrigin[] not HeroCOG[] and so it works now.  2 Hours to done did.  I think our Hero should find a better way to win in this beautiful land of Puff, the Magic Dragon.

One more time to the well.  And 1 more hour to Victory Conditions.  Forty minutes to THE END.  Pointy, clicky, test, run, test, run.  Twenty minutes to go.  One last gaze through the eye of change and into the eyes of the Dragons Hoard.  Five minutes.  Farewell.  To the web with you.  That’s all she wrote, yup, and that is what they say is that.  A week, a RogueLike, and I have a game, kinda.


To Be Continued.

Next year.

Play the Dragons Hoard Here.

Good week, G’day.

March 9, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0034] ~ One Game A Month email-blog:

Hello One Game A Month: in care of Christer, et al.

I’ve been assailed by my many permutations and combinations of late and have a couple of questions.  After that last Twitter conversation about sort pointer over-runs (start/end at zero or one), and my shot at topping your silliness with behoovement, which was pretty much a blank space with no better word that would fit, I thought it would be best to hit the reset button and get to you a long winded real stream of thought.

Muahaha ha ha . . .

I have already submitted my March game, and would think I just used up my get out of jail free card by the very nature of the entry, maybe, maybe not.  I posted a Vlog about a game recently invented called VennisPong.  It’s a mash up of Volleyball, Tennis and Ping-Pong.  There is another game that follows within the same vlog from about a year or so back called Forest Bowling.  I didn’t want anyone who might watch my entry think that that first game was just a fluke so I topped it off with that second game, two games for the price of one.  To prove that point, I also used my Gravatar as my game icon seeing that I am part and parcel of the gamification portrayed.  Yep, I’m in my game too.  I might as well follow in the footsteps of greatness.  My vlog games also have a dedicated instruction manual blog post on page 0033 at my FarNiche WordPress presence pertaining to both VennisPong and Forest Bowling.

To my questions.

I noticed that when entering my March submission there is a drop-down list-box where a month can be selected as the month for the particular submission.  What I was wondering, although of course I am not to be inclined as to wonder about others who have submitted laterally across those months, and of those months, those months that have not had as yet any realism in actual occurrence, i.e. futures See: No Rules clause, if more than one game per month could be appended to the current months submission.

To cut to the chase, is there a submission system that allows for multiple submissions vertically within the same month, using that same drop-down month selector.  I wonder in this thought because I may bank my RogueLike of this month for another month, in case of an emergency.  But then again, if I am feeling bold and reckless, I might submit it under this same month (March) if there were to be any capacity to facilitate such an action and if there were to be any advantageous reasoning  behind this type of action.  A seeming fear would be that of one in which it would erase or supplant my previous submission.  But then again this is “One” Game A Month and not “Some” Games A Month or “Games To Come In The Upcoming Months”.  Provision of the months drop-down list to facilitate this utility may or may not have been the intention initially perceived  of nor have any bearing to this site as it moves along through its evolution.  And as noted games needn’t be offered in consecutive months any way.  To move on, it seems to me that pre-submitting laterally across the forthcoming months assures the “bowling a 300 game” aspect where “strikes” add the next two alley bowling ball rolls into the “frame”.  But in doing so, the months “Theme” is in part neglected.  The potential to eschew the collective buzz about that months “Theme” becomes imminent along with the assimilation through hivemind.  The question is, are there any advantages if one were to add games vertically, if it is possible at this time to add games vertically to the same month, if it is a possible work in progress or is it that it would just mess up whatever type of system that was initially intended and of that in mind at its inception.  For all intents and purposes the quick links switchboard panel in the profile page provided, grants access to any of the other games conceived during that month by the respective developer.  Those games, in excess of the hopefully polished and favorite “One” game offering for that month, could find direction by other means facilitated by that games particular creator.  From my best recollection, initially you were thinking that a handful of your buddies would be getting together on this site to do something of this nature, collectively building games monthly, but it just went . . . uhm . . . became the happenin’ place.

As for my wonderin’, I didn’t feel I should put any fake place holder games in just to see what would happen.  So I guess the question is, is it possible to add games vertically?  If that were to be true, is it possible to sort those games where they pertain to the variety of “Game Jam” themes presented over the month.  And finally, is there any reason that that would make those vertical additions and/or singular submitions into a particular “Theme” more advantageous, seeing that lateral pre-submissions to upcoming months already assure the concurrent/successive month upon month bonus?  Once again, that being said, tossing out the entirety of this summation of concern while leaving it to only add a drop-down list-box selector, which would consolidate the “Jam” under that months game offering to which it pertains, thus alleviating any presumption of more than one game entry per month, has also come to mind and is nothing but a mere contemplation.

Agreeably, this is a rather oat meal-esque kind of email/blog but these first two months haven’t been dull at all.  And like I had mentioned above, time, for at least me, to hit the reset button.  The questions herein are by no means of any pressing matter.  It is more of a way just to say hey I’m still hangin’ in there, I have found your creation, i.e. site, very intriguing and that I like the way you’re tending to this site with the apparent Über babysitting of the servers in need of coolant and/or radiator juice and general TLC.  Also, I felt a need to quell with quill my “Happy Bunny” brain, as it were, and come to grips with the thoughts I have been entertaining.  Just to add a touch of realism, this whole adventure on One Game A Month seems a little bit, to me, like going to an “Outfitter” when getting ready to hit the boundary waters, when going in on a fly-out fishing trip or the many other excursions I have participated in, in the past.

In closing:

This conjunction you have formulated, if put to a Turing Test would find a computer is a great aid in facilitation but unfathomably difficult beyond reasoning to re-simulate in its convoluted dynamic.  Just an observation.  But really, this is a very cool hub site.  Excellent effort of you, for your time and patients, that of Team SpreadTheLove and of course thanks to the many others in this cavalcade of OGAM adventurers.

Best of Spartan RogueLike and like adventures.

Sleep well, pleasant dreams, wake rested.

Gratefully yours,


March 8, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0033] ~ VennisPong:

A Real Time, Face Time Strategy Game.

VennisPong is a combination of three games in one.  Volleyball, Tennis and Ping-Pong, that being Table Tennis.  Each of these games have their own playing field, equipment, participant and rule prerequisites.  VennisPong is a collage of these three, where the adaptation is adherent to provide the longest volley possible by giving a “good-faith” effort to allow the other teams members a reasonable chance to return the volley.

The Playing Field.

As in Table Tennis, the playing field is a ping pong table sized plane, with an accompanying net that splits the field width wise into two equal halves.  Preferably, and as in some Volleyball and Tennis courts, the floor provides a deadening effect.  In this case a carpeted floor deadens the balls bounce and keeps the out-of-play balls nearer to the playing field.

The Equipment.

The equipment needed to play this game consists of a ping pong ball, two padded table tennis rackets (paddles) and two strung tennis court rackets (rackets).

The Participant.

This game is designed to be a four player game, other adaptations are sure to be available through ingenuity, cunning, skill, and agreeable corroboration.

The Rules.

This game adheres somewhat to the scoring used in conventional table tennis, i.e. ping pong, that being Service is found after a volley where the ball crosses the net successfully three times in succession.  The winning side of the volley is then given the initial service and the game begins.  Service starts in the right hand service area.  The ball, when served for a volley must be at least one foot above the surface of the releasing hand.  Either racket may be used to serve the ball.

Once the ball is in motion, the main objective is to keep the ball alive, which means, to keep the ball from rolling.  Keeping the ball bouncing by a constant succession of both teams members racket hits, in any order and in any chain of succession and as many times by any of either player on any side is allowable.  If the ball rolls the play is dead and which ever side the ball begins its roll is the loosing side.  And so, either team/side can score a point on any serve because the other team/side had the ball die on their side.  The sides are marked using the line of the net from one side to the other as it is connected to the table and follows along in parallel to infinity in either direction.  Walls and other collideable objects will most assuredly prevent the infinity predicament from becoming an issue, if I am found to be wrong, please advise, or reinvent.  Therefore the ball must continue to some capacity in respect to vertical velocity.  Comparatively a purely horizontal velocity equates to a roll.  At times a horizontal velocity may be negated, i.e. when rolling across a couch seat cushion where it continues to roll to the edge and then drops to the floor.  This vertical velocity sustains the play and the ball is allowed to be hit and brought back into play.

The team side, consisting of two players, may hit the ball as many times as they would like to continue the play as long as the ball does not roll or no longer has the capacity to naturally regain any vertical velocity from that roll.  Once the ball rolls, that service is considered dead and the side on which the roll has begun is the side and team that gives the other team a point, something like Volleyball.

Play advances and the service is switched to the other team after five points have been scored.  The game is played up to twenty one.  In case of a tie where both teams have a score of twenty, the first team to advance two points above the other team is the winning team.  Twenty-two to twenty will win, something akin to Tennis “advantage”, but there is no “break point” because service is not imperative in concern to the capacity to score a point.

If you have the energy to play another set, the teams switch sides and the next game ensues.

Beyond that, read up on those three games and come to an agreement on some house rules and have fun.

Game Two, Forest Bowling.

The second game, the bonus game, Forest Bowling has its roots in Bowling, but in particular indoor Ten-pin bowling.

The Playing Field.

Seeing that this is Forest Bowling, the intention is that it is to be played in the forest.  A lane is any mostly flat terrain approximately twenty to thirty, possibly forty feet long, six to ten feet wide and the surface can be any of a variety of materials; dirt, sand, grass, bog.  But the preferred medium is crushed red gravel.

The Equipment.

Their are some equipment specifications.  The first and second go hand in hand, that being a paper and pencil, which can be very difficult to find in the forest.  Next is the all important Bowling Ball.  A ball from a mother, sister or brother-in-law who no longer bowls are perfect candidates from whom a ball may be offered.  Any pound (lb.) weight of ball may be used, but make sure the finger holes do not snag or twist your fingers on release because that would really hurt.  Also, please advise said acquire-ee that the acquirer will be using this ball on a surface that will mar the finish of the bowling ball and that forever after, having been used to play Forest Bowling, will never be suitable to be played with again on an indoor bowling lane.  It will become a dedicated Forest Bowling Ball, never to see the fluorescent light on the polished bowling alley lanes, automated pin setters nor ball returns again.  The next set of equipment is that of the bowling pins.  These pins can be of any wood but white birch is preferable, dead and down is the general rule.  These pins, being approximately six to eight inches in diameter and also approximately twenty-four inches that being two feet, in height should be vertically straight and have the ends cut at a ninety degree angle to the vertical to ensure they are capable of standing on their own.  As for bowling shoes, any shoes will do, even no shoes.  If you feel the need to wear steel tip, epoxy resin or carbon something or other composite boots then do so.

The Participant.

Their may be as many bowlers playing in one game as you see fit.  The only limitation is in keeping all of the players motivated and at the ready when it is their turn to bowl and then subsequently becomes their turn afterwards to be the pin setter for the next bowler.

The Rules.

Forest Bowling moves along as such.  Their are three pins, each eight inches in diameter by two foot high.  They are set up in a triangle with each pin about a foot and a half apart, maybe a little bit more.  The lead pin in the front faces the bowler down the lane with the other two pins behind making it look something like an equilateral triangle.  The midpoint on the line between the back two pins is perpendicular to the line which follows through the lead pin down the bowling alley to the bowler.  The bowler takes the ball, and after there has been an agreed upon release line, makes the ball move towards the pins at the end of the lane.  The ball moves down the lane and hopefully strikes the pin set.  If all three pins are knocked down it is considered a strike.  If one or two pins are knocked over, a second ball may be cast down the lane in hopes of knocking down the one or two remaining standing pins.  If the remaining pins are knocked down with the second ball it is called a spare.  But, if there are one or two pins in the lane after the first ball has been cast, those pins remain until the second ball is cast and until the bowlers turn is over.  In Forest Bowling the pin resetters are best advised to take little risk, and it makes game play more interesting by leaving those downed pins there.

There are various rules as to what that bowler is to do next.  One variation is that that bowler becomes the pin setter for the next bowler, another variation is that that bowler becomes the scorer and then the pin setter.  Having some consistency assures an equal load sharing across the entire team of bowlers and a smooth transition across the entire game.

This game, seeing that there are so few pins, makes it possible to use roman numerals in the “frame” when scoring.  The person with the highest score wins the game.

Again, be smart, stay safe and have fun.

To conclude, as with any physical activity care should be taken before, during and afterward to ensure freedom of injury.  Warm up, stretch, eat right, drink plenty of fluids, play nice and be sure to say to yourself “careful”, allot, if not for your own sake, for the sake of others around you.

With that, thank you, happy gaming, and of course watch VennisPong on my YouTube Channel, the video complement to this blog.


March 4, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0032] ~ I Me Me Yours:

I Me Me Yours.

I have had the wonderful opportunity to gamify myself as of late.  To this point our illustrious headmaster has put to us, a side quest.  There may be others out there that might find intrigue as to how still others welcome the extrospection of yet others One Game A Month games through introspection.  Snazzy idea beat master.  In fact a beautiful idea.  And to not let this be completely altruistic, I will also benefit in being reminded of what I have learned through others.  That being said, …

A Couple of Games.

Site: john deboer.

Game: After Party.

When I first played this game there were no levels that I can recall.  I couldn’t move and there were no drunks. I wasn’t able to do too much, but after a twitter, and a little time, this game has become an all out duke-em-out.  With a lamp shade on my head, or tea cosy, I attempt to make it back home.  There are drunks out in mass.  All seem bent on taking me down for the count.  My only recourse is to use the up, down, left and right keyboard keys to move to the right, the finish line.  Also the z-key lets me, offensively, defend myself from the ever growing pickled perishers, knocking them out in the street.  I haven’t won, yet.

At the games sight, there is a picture of some books which has given me an idea of which I may do the same.  Thanks.

Site: Will develop games for food.

Game: New project.

This game was fun to watch grow.  It reminded me of the old Zelda/Link games, an open field outdoor adventure.  I start out standing in a field and as I roam about freely there are things out there, rocks, mushrooms, snakes, chickens and huts.  The huts have villagers that I can converse with.  They each have a story and mostly would like some help.  That’s to be expected of a Hero, and so off I go picking up rocks, and throwing them, z-key, at snakes, along with movements from the up, down, left and right arrow keys.  Some villager quests are snake skin jacket and mushroom soup, the chickens also lay golden eggs.

Site: 5ifty2wo.

Game: Wizard Adventures.

This game was an experiment for myself as well as the developer.  I am the Ghost of a Wizard and the Reapers are out to make sure I never rise to the moon, my nemesis.  I start out in front of an old castle and must fly upward to defeat the moon in sorcerous combat.  On my way up I must evade and cast spells at the Reapers who stand, actually float and fly, in my way.  Navigation is with the up, down, left and right arrows and I cast spells with the space bar.  For me, this was the interesting part.  I decided to try to use my XBox controller attached to my computer to play this game, and the D-Pad on the game controller worked.  Somewhat astonished at the fact, and after a tweet to let the developer know, I fired up my XBox with Internet Explorer 9, found the game and played it on my XBox using the game pad controller.  There was one hitch, I couldn’t cast any spells because the space bar had no mapping to a controller input.  But all the same it was fun to experiment with that and I was able to dispatch the moon, on the PC, with a keyboard.  A game I won.

Site: Storm Alligator.

Game: A Team For The Job.

This game was pretty well complete by the time I got to it.  It’s kind of like a card game, and kinda not.  But, there is a quest by the King to find a team of adventurers.  Each player is dealt some cards and the cards are played in turn reciprocally.  The objective is to build a team that has one of each class type.  The side who has all the slots filled first wins the Kings approval and becomes the chosen team for the quest.  At first the writing on the screen scrolled a little too fast but there were enough pauses to read the cards which explained the what and why of the cycle that brought about the seemingly quick scrolling in between player exchanges.  It took me a little bit to understand the mechanics of the game, but once I had a grasp of where it was going, the game moved along nicely.  This is also another game that I was able to win.

Site: Liza Shulyayeva.

Game: AlienTree.

This game I couldn’t get to work on my PC using Internet Explorer 9.  It is a game about a tree on an alien world.  The tree is still a tree but its environment behaves differently than what I would consider normal.  The seasons cycles change like day and night.  Spring, summer, winter and fall change in the blink of an eye.  The game is to grow this tree in an alien environment using a glass of water, a beaker of fertilizer, a lopper and a candle.  At first, my tree would grow and then would become a hangman’s tree, literally, my screen would freeze.  So I tried to play this game in Firefox, Chrome and Safari, and from there I could use all of the tools to get my tree to grow and bear fruit through the alien seasons.  But sadly, I am inept with my alien gardening skills and would see my tree bruckel into pieces.  My trees die, dratted environment.

Site: Tapdancing Goats.

Game: Fretwork.

This game I was able to watch grow from an implementation that the developer understood to a game that I, someone who didn’t understand the underpinning of the game logic, could find playable.  To start off, there is a table or a wall, and thereon are pegs spaced evenly across the board.  And on those pegs are spools which are attached to what seems one peg with four spools radiating out from each peg.  But, this is where it gets tricky, when a spool is clicked on to move it radially about the peg, the peg is no longer attached to the adjacent peg and is therefore rotated around the axis of the … well all I can say is that the mechanics have improved immensely and that there are many twists and turns.  The idea of the game is to line up the same colored spools.  Each rotation might grab a previously placed spool and change the initially thought or desired outcome.  The visual cues, by means of tinting the peg/spool unit, give a better understanding of which items are about to be moved.  Another aspect is that of the rotation, initially it seemed to spin rather abruptly, and as of my last playing the rotation is more like a weighted door where a slight nudge will show that it moves while a slightly stronger tug will begin its swing but more like a self closing door it smoothly sets itself into place.  At first I couldn’t figure out how to get any points, but now I am able to get a couple as I guide the colored spools into consecutive strings.

Three come from:

Site: Colin Maxwell’s Blog.

Game: Castle Invaders.

This is a castle siege game where I protect my castle from the invading forces.  I stand atop the bulwark and drop rocks to crush those who would take the home of my King.  To and fro I run as they assail the wall with those who ascend while mounted knights run around the castle.  The arrows fly over head, but sometimes dead on the mark.  Swiftness is my only friend, well, maybe also the rocks.  Defend for your life!

Game: WarWolf.

This is a castle siege game where I am the proud owner of a siege weapon, a trebuchet, which look suspiciously like a catapult.  But in either case, I am charged to put down this castle and force surrender of the inhabitants.  I have limited ammunition, rocks, to pound the castle.  With each hit the castle crumbles and as the walls are lowered the white flags of surrender are raised.

Game: Joust.

I am a Page.  And with a little practice I have become a Knight.  Here, I am at a jousting match, a knight in armor on horseback with my lance.  I am not in mortal combat, this is time for festivities and revelry.  My horse takes off and I raise and lower my lance to spear the balloons as they cross my path.

Each of the three afore mentioned games keep, graphically, within the same motif.  The instructions are simple and informative and a couple have a historical backstory.

And I will finish off with these two.

Site: McFunkypants.

Game: Pathos.

This is a game of the love between Princess Pea and Sir Mushroom.  Looking down at a map of the world in which they reside, it is my duty, nay, mission to keep the two apart.  Luckily I have rocks that I can place in their paths to insure their longing is preserved.  It is also up to me to make sure their path is not wholly barred where their love is forever and anon lost to eternity.

Game: Gate of Rath.

This is a Pac-Man-Like game.  Hm, The End.  But really, the little adventurer is in a dank underground castle cellar, a dungeon.  To sneak through the maze and not be caught by the cellar dwellers is the only hope.  Locking doors can save you for a bit but don’t lock yourself into a dead-end.  I win, no, I lied, I lost.

I must say I have really found Pathos to be of most benefit.  I had need to find a way to build smaller games for One Game A Month.  My XBox-XBLIG game structure was too unwieldy.  Now I am using this model or I should say the tools that build this model to create my own games.  Thanks Mcfunkypants and thanks all for your help and support.  Off and into March.  This month is RogueLike for me unless told other wise.  Until then.


March 1, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0031] ~ Can I Really:

 I think I can, I think I can.

It doesn’t seem that I can build a class and then have an ArrayList of those classes be accessed in this game, in this JavaScript immediate compilation mode.  Currently I am stupefied.  But I did get a bunch of crud muckin’ up the works.  Starting from an array of type class as class[] it will not let me build new of that type, i.e. myclass[maxindex].  I must be thinking in terms of c++.  I’m also getting a little home sick and am finding that C#, for all its nuances, is very entrenched in provisioning game code simplicity.  Days to go, can’t go back, can’t go forward and holding down the fort only ticks the time and lessens the larder. Big big hm.  Well it’s time to sweep up the goop and figure out if a user class can be declared in the namespace and instantiated in setup to be accessed in the draw method, all without hanging the loop.  This little red blood cell is definitely putting me to the ropes, yeowch.  I might need those smelling salts pretty soon.  As It would seem, building an array of that kind in the draw method is possible but if I’m going to do that I might as well just build another big Harry and let that suffice, more research.  And as I should have guessed, primitive datatypes seem to be the only array value holders that I can get to work as a declared array to use from namespace, that being “canvas-space”, to initialization to declaration to update/draw usage, yep, time for the big Harry Rag.  Or, bang goes that idea and let’s just run with another KISSing session.

Tinker … Tailor … Soldier … Sailor …

It looks like I’ll need to build some simple data strings and just hard-code this part.  But before anything like that gets done I need to fill in some more of the back story, just for fun.  Our adventurous little red blood cell, lets just say “Red”, knows the routine.  The pressure is either on when near the Heart or in the extremities, but in either case the mainstay of the ride is either in the Arteries or in the Veins.  It seems Red is somewhat more of a free-lance scamp than previously thought.  But to keep things simple, Red will be bound to those two confines, for now.  For convenience let’s just say that that’s home sweet home for our little Red.  Actually Red can be notoriously RogueLike, squeeging about semi-permeable membranes, but there is precious little time left to gamify those points.

Finally, a Beginning.

Streamonsters has a splash screen and so my game has a beginning.  All I need to do now is polish up the middle and figure out how it will present its end.  Then voila, presto change-o ala ka-zam and I have Februarys OGAM offering.  Notable note Java update: 7 – 15 just came about for an install, painless.  You know, it would do me well to add even a short label to my test displays when I am trying to see how the variables are updating in the canvas, boolean true or false, integer incre/decre-mentation, float precision and the like.  It would definitely help me to remember where in the code I should look so I can jump back into the game, no pun intended.  I need something for Red to do.  And transport of Oxygen is the mainstay and livelihood of Red.  With that in mind, Red needs a meter to gauge the capacity and transference of the Oxygen.  Bumping into or past the vein/artery system wall will release some and if too much is released Red will be thrown to the Bladder by order of the Holy Kidney, so be it.  This silly little game is actually a lot of fun to build, somewhat taxing, but fun and informative all the same.  Hm, control+z in Processing doesn’t take me back to the position of the undo so I’m unsure of what is undid. It does move the text page up and down, but not to the degree I have been accustomed to.  I guess I’ll need to work smaller.  Also the number of undo’s is unknown to me.  But it does build for the canvas and helps me do so, there is joy.  And more joy, the Big Harry works, in rehearsal.  I had to hard code the integer arrays, so far for the head, which lets my little blood cell move incrementally, and there was much rejoicing. Yaaaeee!  Now off to the two arms and legs, then that’s done.  Alright, what makes the Arteries change to Veins, really I should know this one.  What I need to do is use the BodyPart variable, which is the count of the array entries, and use that to split the journey in half because that is where, for all practical purposes, the arteries turn into veins.  Simple.  Now where is it?  Dividing an array counter isn’t a really good idea, but … yes it works and it isn’t halved as a counter but as an ‘if’ flag to denote when the halfway point of the little red blood cells journey is half way over.  What ever.  Back to figuring out the last of the body parts.  Oh boy is this great, I’d like ten thousand marbles please!  Ok, I just figured out how to use half as many arrays to get the same job done.  It was kinda scary, deleting half of the code to do the … , but it works just as well.  It seems that that halfway trick is only needed for the head.  Nope, I lied.  I am using that terminus trick for all the extremities.  Done, a head, two arms and two legs.  The color red for the arteries switches to blue for veins at the terminus, being where the arteries become veins.  More to come.

The Menu System.

Wow, I didn’t really know how to start building a menu, so like any good gamer I played others games and when they looked like they were understandable they became understood.  Seeing a menu and building a menu are two very different things.  But I’m just about done, I think I like to think that cause that’s what I was thinking earlier this afternoon, go figure.  The thing is its not just building the menu, its getting everything that the menu does, or is suppose to do, to do what it does.  KISS can only take it so far and then its up to … well, I’ve got two days left.  I’m not going to do an exhaustive hand-check on this game but I could try to do a logic flow and follow the booleans around.  Build it first, then worry about it.  OK.  Will do dad.  Do Dad? That’s a thing-a-ma-bob.  Yep, still remember that old chestnut.  And I can also get to understand just what all these variables do from where they are located in the program to be built into this wondrous menu system.  There really aren’t untold numbers of values that need to be zeroed out or reset, but there are more or less enough to think that there are.

Finish, Gloat, Tweet, Sleep.

Order is important.  My February game , Streamonsters, is done and the snow outside is deep.  The snow banks are even deeper. And with that,

Ding! – Thanks for Playin’. – (Charles Petzold).  Hero.


February 27, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0030] ~ Two For the Price of One:

 Tick, tick, tick . . .

Still configuring my web site page so my “games” will have a happy home.  I’ve also resolved a couple of issues with the browsers I am using.  Chrome, in the Settings/Show advanced settings … at the bottom of their page, is a title called Web content which affords the capability to set the Font size: to Large and the Page zoom: to 125%.  Happy now ’cause the settings stick and stay.  But I have yet to find and auto-hide for their search tab, yep, right over the top of my page.  I still can’t find a way to have Safari keep my zoom view settings while running from instance to instance.  Firefox seems to hold its zoom settings more closely, it just updated to 19.0, more joy, and GitHub just had an update too.  Also my CSS issues with the browsers staying in a same visible representation sync across the board with my pages .css Layout/Format calls have been rectified, by me?  Really?  But they do all resolve and give the same look, for the most part, flavor is still subjective, in all four of these browsers.  IE9 deals with some rejection/safety complexes, golden-child/black-sheep, careful about the code, who knows what or why.  But in whole all is well, except for sound, in all.

Tweek, tweek, tweek . . .

A little bit more reading and research and my game page template is nearly … no … it’s never done.  But I may have come up with a new title for my game, Streamonsters.  And It just got a Screen Shot Saturday, yeah!  The game itself is starting to take shape, going from a “what is this canvas capable of”, to “how am I going to keep my tools strait as I build and use them” type of confluence-like scenario.  A virtual tool box is a really nice thought and concept but going from nothing to, “a place for everything and everything in its place” in one flail swoop … ok, it’s not quite “old hat” but I think I can deal with it.  And a nice pile of tools doesn’t make a game, but its nearer to the mark.  I’ll need a start, middle and an end to this game.  I think I have a thought or two as to what is in my game, besides a tool box o’ stuff.  I don’t believe that my canvas web game and my application GitHub game are going to be too similar though.  They may share the essence of the general theme but that’s about it.  It’s not about blood but when you’ve got a heartbeat at the base of the game it’s only natural to have blood about.  But to be specific the game is about one blood cell and the nice little life it leads while being pumped around the vein system.

First Things First, Breaks Over, Back to Code Hunting.

Boolean flags are an excellent way to deal with a perpetual loop system, but keeping track of them all, what they do, where they’re placed, if they are active or not, when they become active when do they become inactive, if they are set inside another flag loop, and if so, won’t be active until the outer loop is active, which will be when(?), and on … and on.  Me, the code hunter.  This might help, I’m building my first class structure in Processing.  I have a little red blood cell that needs to stay inside the vein system inside my body.  Start at the heart, move along to the extremities, hang out for a bit, turn around, get cleaned out in the Kidney, high tail it back to the Heart with what little oxygen I have left, take a quick respite at Club Lung and soak it all back up there, only to get ready to set my boot heals to a wanderin’, again.  And this has what to do with this class that I am attempting to build?  As stated, the cell needs a position inside the body and also needs a mechanism to keep the cell from being wisped away and into other systems tracks.  It seems that a stream of data that will set the cells tracks is in order.  Thus a class, that will hold each cell position and have the capacity to also be used as a Keyword to build an array, which will allow it to transform it into a series of data points that follows the path along through the body to each appendage and then back again, is what I am after.  I guess I could consider this to be my first pseudo-code event for a class in Processing, also.

Another Piece of the Puzzle.

I have already built a VectorSet which is a 3×3 square of mouse clickable buttons with eight arrow directions, up, down, left, right, and then the four diagonals between those four.  This helps me move my little red blood cell around the canvas, which is actually how I helped the cell built the body around itself.  Great fun, pretty smart, eh?  Now what I need to do is use that same structure to allow a data stream to manipulate that structure.  Simplistically, it would follow the heartbeat flag and at each beat the trigger would send one class instance of CellPulse data into the stream to update the draw method, retaining its value until the next update, yes, in simplicity.  CellPulse doesn’t give position data, it holds the indices of the 3×3 VectorSet that another method will interpret.  When combined, the red blood cell will have a path to follow because the data from the array of CellPulses will be read through the VectorSet where the draw method captures that data and assigns the little red blood cell ellipse to the position found by the afore mentioned process.

One Game A Month.

Time is short.  Seeing that these logic streams are headed over for a hook into One Game A Month, and now I actually have two games, and this challenge isn’t called “Two or More Games A Month”, I think I’ll just focus on one game.  My choice for this months challenge is Streamonsters.  Sadly though this game will have no sound.  “minim”, the sound library used in Processing, and thusly is in my initial game ASyncingHeart_II built in JAVA Mode, isn’t readily available in Processing.js, which is currently the game given on my site as Februarys offering.  “minim” is not accessible in JavaScript Mode, and so not through this months game Streamonsters.  “minim” is what was this first halves months efforts direction to figure out and be used in this months game.  So be it, some sadness.  Now for a little healin’ with the hurtin’.  Maybe I can get some background music in there somehow.  I’ve got to get back to my “One Game” so …


FYI: The February game Streamonsters links to my FarNiche site, and though currently accessible, the game may be under revision until the start of March 1st, this coming Friday.

February 24, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0029] ~ Not planning for the future, just February:

One more Sketch.

Seeing that the #1GAM theme for February is sound and the way I’ll be going about building my game is through Processing, I’ll set this blog post up so anyone who feels the need to play my game will be able to run it in Processing.

My game is called ASyncingHeart_II and the meaning will become apparent in a moment.  The reason I use Processing now is that the team I was on for Global Game Jam 2013, was using this for our team game, Patient.  The theme was that of a heartbeat and a sound byte of a heartbeat was given to speed us on our way.  Giving this some thought and steeping myself in that idea, I decided to continue on and see what I could build.  Prior to GGJ13 I had no idea of Processing’s existence , so this little how-to needs to be taken from a standpoint of me as a freshie/newb.  The easiest way is to dive right in with the Getting Started page and let them do their best to explain what needs to happen.  As a follow through, there seems to be two main sites; Processing and Processingjs.  Bouncing back and forth between those two sites also seems to be inevitable so… I’ve found it helpful and that it works best when learning about how it goes, by working it like a sing-along and then to just run with it.  For a Processing type to pick for your machine, there are a couple of OS and system types to choose from, i.e. Win, Mac etc. 32, 64 bit systems, etc.  Then, to get accustomed with what they have to offer, many examples and small games accompany the language Reference documentation to become familiar with it and what its capabilities are.

Ready, set, …

By this point, hopefully, you now have the API/IDE up and running.  The two Modes I have been using in the API are JAVA and JavaScript, these are what my February games languages focus on.  In JAVA Mode, when the play button is pressed, the game plays in a console environment, while the JavaScript mode runs through a web page built in a client side server in a browser.  Once you feel comfortable knocking around in their samples, the next step is to take a short jaunt over to GitHub to get the game resources for this Februarys game, that being the source code, sound and image files.

My Next Canvas.

A couple of troubles I have come across, if you haven’t noticed, within the four browsers I am viewing all this gamification in, is that of cross browser coherence, having built yet another ‘canvas’ web game/exposition, VectorSet.  This ‘game’ is more of a what if or how about this, kind of game to get things in working order for the upcoming game challenges.  All that this game does is, in the upper right-hand corner, shows where the mouse pointer is on the canvas.  The only other thing it does, in the bottom right-hand corner, is show a matrix of vector icons.  When the mouse is over the vector pad, a text is shown above the pad giving the coordinates of the matrix icon that the mouse is currently hovering over.  Also, when the mouse enters the area of the vector pad, the corresponding icon changes from its Neutral position icon to a raised, Up, position icon.  When any of the buttons are clicked, via the mouse, a pressed icon, Down, is shown at that position.  When the mouse pointer leaves the vector pad area, the matrix text disappears.  That is all, wee!

Browser Chores, (wars).

Safari, on my PC, does not keep the text and object zoom settings from between an opened to closed to opened browser state instance.  But I can recreate the text and object zoom settings closely from how I built it as seen in IE9.  Although my VectorSet icons still get a little choppy at different zoom levels, i.e. not crisp, but not terrible, VectorSet still retains its intended simplistic beauty, for the most part.

Chrome ‘incognito’ mode gives me the top of the browser screen back from the extensions tool bar that has crept over the top of my webs page from the browser.  But then, I can’t just unview the extensions tool bar by clicking the faux Enabled check box in the Chrome/Extensions tab.  To reclaim that space I need to go into my computer and uninstall their extensions ‘program’, hm.  There is also, seemingly, only one zoom control, but all in all it works just fine in all settings, i.e. my icons in VectorSet retain their beautification, happy me.

Firefox does something quite strange with my VectorSet icons, they jumble the output when using the zoom object from View/Zoom/(Zoom In, Zoom Out).  And after setting the object zoom size, then clicking on the Zoom Text Only, a global reset of the whole page results, taking all the other previous zoom session zooms out of their previously set proportions, more hm.  I’ll deal with it all, somehow.

Just so I’ll remember, which is a small portion of what wisdom is, I’ll try to capture the recipe that is bringing all this side venturing about.  First off, on my PC the screen resolution is 1600×1200 to maximize the allowable monitor real-estate.  My main browser is IE9 with zoom settings of Text size at Larger and the overall browser zoom at 125%.  That’s the most comfortable setting for my eyes and the settings I use almost nearly perpetually, morning, noon and night.

More Rethink.

Seeing that this is a, “Hey, I’ve built a game, check it out!” and then get some Twitter feed back kind of happening.  I might as well change my own rules a bit and build two versions of this game.  One will be in Processing and get a toss over to GitHub with the other built in my site, ready to play.  But I seem to be torn at this point though.  Because Processing in JAVA Mode has great sound using ‘minim’ and sound is this months side-quest, I feel a need to have a game with sound.  On the other hand using Processingjs my game can be put to the web and is then readily playable, although the sound aspect will suffer greatly if not in totality, because web sound isn’t quite up to speed: see W3C, and The audio element, as a consistant standard across all browsers.  The simple, albeit arduous, solution is to build both.  Nine days left in February, sure, if its doable it looks like I’ll do it.  Yeah dad, “Build it first, then worry about it.”, get it, got it, good.

Best of luck to me, until then,


February 19, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0028] ~ OK just get done what you need to to get some sound:

My Game Design Document, My Repo.

I’m really starting to love those ten things before I do that one thing.  And It’s like I have heard before, “… you will be dragged to that level only to be beaten with experience”.

Let’s dive right into my Feb game with the precepts:

What, is your name?  Sir Erythrocyte of Endocrine.

What, is your quest?  To seek the Holy Kidney.

What, is your favorite color?  Blue, no red aaah…agh!!!

But I’m getting ahead of myself.  And I, hmpf, I find myself heart broken, and a bit mystified, Erytrocyte deoxy to oxy v0.  That’s pretty much if not almost exactly what I was looking to do for my February game, very smart, sigh.

No choice but to pick up the pace, again.

It seems that I have a life expectancy of between one hundred and one hundred and twenty days.  It takes me some twenty seconds in between breaths and my main stompin’ grounds are the vein systems.  And from where do I come?  Why bone marrow of course.  Actually, I did take some college biology but that was long enough ago that my academic advisor says, [if I ever get around to achieving through my potential of degreeabilitivness as a state of my degreeabilitivity that, em-hm], I have also ‘grandfathered’ out of taking a foreign language when I do graduate, lucky me.  But, as any good red blood cell I find, it’s time for me to jump ship and get swept away with the tide.  Seeing that they, at Wikipedia, have already pretty much, if not exactly nailed the idea for the game board I was shooting for, it’s time for my February game plot to get a little rethink.  Garçon, another bottle of Château de la KISS please, if you will.


Long story short, my first and only “canvas” game runs on XBox with Internet Explorer.  How is this done you might ask?  Short story excruciatingly long, once upon a time …

Really, Processing is the API where I build and test a JavaScript game, the Processing.js <script>’s are used to “parse?” the code when it is in the web page and thusly in a <canvas>, CSS <link>’s are used to adjust the screen and HTML binds the whole thing together for navigation.  After reading a whole bunch of allot of books/webpages and digging through the given documentation, my site has its first click and play game.  Happy, happy, joy, joy, \o/.

Victory!  But, yes a caveat.

Running a canvas means a set height and width.  A PC might deal with this with a few simple clicks of the browser, but the XBox version needs some differing forethought, and testing, to present itself on the screen following the format/style and layout I have built to be my site.  Having this newly found “canvas” run on both the PC and the XBox has generated some substantial screen compatibility issues.  The canvas size is set internally within the JavaScript game logic setup code, also within the CSS formatting instructions and in the HTML used to provide acknowledgement to the page itself.  Digging out the sledgehammer and crowbar, I break and pry one of my old site pages into two new pages, one to run the canvas on the PC and one to run through the XBox.  Yes, this means building dedicated CSS’s so each will be formatted to a specific device, not optimal but doable.  But I just want some sound in this game I’m trying to build, apposed to ten more other things.  As a parting thought and a future search I am wondering if there is some sort of #directives in JavaScript.  The short answer is NO to #define preprocessor directives found in a precompiled code base, as JavaScript is an interpreted language.  I guess I’m somewhat doing a dry-run test/pseudo-precompile in Processing anyway.  Bang-Snap that idea, but the page would need to know what device it would be sending itself to and I think the device would be the one that is more concerned about what is being sent to it.  More whatever.  So much for having one HTML page with #include and #if device directive where this page then runs its CSS and script because of one browser type but if it is this other device and/or browser then run this CSS and script all from inside the same HTML page.  Browser wars precompilers and … maybe in Internet Explorer 10.

Work and Write, Preamble.

Let’s see if this works.  For the last couple of days I’ve been trying to get a canvas into my sites web page and have found that Mozilla Firefox v18.0.2 is very helpful when trying to find just how my CSS formatting is behaving in my pages.  In their Tools/Web Developer/Inspect, when the mouse points to an area of interest a dotted box outline surrounds the element in question, pretty cool.  The hints it provides shows how the layout of the page elements interact in concern to each other and brought my guess-work back to a more understandable set of pretenses.  After some fiddling around with the canvas and some other formatting issues I was able to test the “canvas” page in; Internet Explorer 9 v9.0.8112.16421, Firefox v18.0.2, Chrome v24.0.1312.57 m, and Safari v5.1.7 (7534.57.2).

Some formatting issues are, in IE9, which is my creation and base format, everything works as formatted, no issue.  In Chrome, which is the next closest format adherent, follows my CSS formatting but there is their search bar across the top of the browser, which I haven’t figured out how to hide yet, that eats into the top of my web page, effectively obscuring my navigation bar I use when running my pages in my PC browser, hm.  Firefox and Safari, in concern to the canvas object, don’t seem to keep the format when using margins and padding with the CSS I built and formatted for IE9, so be it.  I’ll just chalk that one up to me being a novice programmer with HTML, CSS, JavaScript and Processing/.js, for now.  But also, these last two don’t differentiate enough between the text and objects when using their text and objects zoom page tool features.  As you may have guessed, I don’t sit very close to the monitor and have a need to adjust accordingly.  From all this, I can see why, for my GS-XNA 4.0 XBLIG endeavor, I opted for only game pad interaction and then only having to deal with screen size as the next big obstacle, normal screen, wide screen, 720i, 1080p, 1280p, regular CRT, 1024×768, etc., yeah all that screen size stuff.  I’ll also be sticking with the XBox and not the Windows Phone platform.  That only adds too many variables in differing screen sizes, touch screen phones, pads, etc. and other compatibility issues.  But I will need to get back to my XBox game creation sooner than later, although this One Game A Month challenge and ongoing excursion has added a new twist to the entirety of indie gaming.

To the Point.

My February game, no, my March game should be able to be an on page, meal ready to eat, kind of game with instructions in the same page with scroll bars and probably some other neeto stuff.  But until then it looks like I’ll build Feb’s game in Processing, use “minim” as my sound import processor, get the code over to GitHub, have anyone who really wants to play the game load it into Processing to play it and call it a day.  To scry by these past days searches and researches has made me see March as becoming more “build the game” instead of “figure out everything else” so I can.

As a parting toss, my first “canvas” game is up and in my website.  The XBox version needs a screen setting of 1024×768 to look as intended in IE9 through the XBox 360.  It isn’t much of a game more than an exposition.  All it does is load the canvas object into the page and after it is loaded shows two sentences, one in a white font and one in an aqua font.  A mouse click in the canvas enlarges the aqua colored sentence to the point where it starts back at its initial size and also, every other click shows a large blue dot that follows the mouse pointer.  It’s not much in the line of hours of entertainment but that’s what it does.  The End.

Until the morrow, G’day.

February 15, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0027] ~ Gitting some sound Processing:

Install and config GIT?

I’ve already had the pleasure of flashing in a new BIOS on one of my systems so, with all things considered, this shouldn’t be too difficult, right?  Emacs!  Oh-boy, oh-boy.  Hm.  If you have ever seen the movie “Fight Club” there is a strange part about finding your Power Animal.  Why, I don’t know, but I’ve seen the movie and my power animal is Eeyore, sometimes Woodstock, but for now Eeyore who could chew through thistles.  But to get me through this I really hope they have promoted command-line obfuscation through an Icon Project for the “Git” windows version.  And from the way it looks, I will be digging out my old Unix books, wee, at least I still have them, “Just Enough UNIX”.  Great, I guess that it was fun back then so why not now?  Ok, after reading through their “Bootcamp” and watching their videos it makes a little more sense.  Another video The Basics of Git and GitHub, their black screen editor which he uses reminded me of the way I would need to peek and poke around my directories, back in the day, at the University.  But my editor was Emacs, the background was a very light cream color and the language was C++ code, .h, .o, .c, .cpp, make, tar, etc. files that used to make my head spin.  It also reminds me of when we used Pine for email, again back in the day.  Then there is some talk about Vimdiff which seems like a mutation of WinDiff, a file versioner that would check two files for changes, and again back in the day when Visual SourceSafe  was in vogue.  Another thing in the video is the off line storage which reminded me of the Windows briefcase.  All in all it still looks like I’ll be using command lines, keywords and switches, so be it.

“Time Gash” – Cosmic Encounter.

github:training in two minutes, no, wait that’s Mountain Time, and hour and two minutes.  All done.  I just participated, more like attended, in a webinar with GitHub using GoToMeeting, with a call sign name change to FarNiche, of course.  But all too soon it was over. That was an incredible run-through of Git and GitHub.  For me, seeing that I haven’t even installed GitHub for Windows, it was a somewhat fast paced meeting.  During the meeting it showcased the transparent nature and unobtrusive file versioning used where initial offerings are imported from various OS’s.  Then, how those contributions are forked and cloned by others where those contributions are further aligned by those who participate by project/organization within a progressive timeline.  After that they started to lose me as they began to run about saying how this can happen when that goes on and when you do this sometimes it goes this way but in other cases goes that way.  Another foot race, but I followed the concepts well enough as they touched on the major points with the subjects they encompassed.  Having the capacity to serve many repositories all from differing environments, and further, actively promoting propositions where the suggestions that are least inclined to break the build, become the proposals which are considered and then upheld or rescinded by the main branch contributor.  But in all cases the train of thought is committed as a growth node chain whose additive commitments fall in and out of pertinence as contributions and offerings that have the potential to be built in or are relieved from the build but are, at any rate, seen through a progression.  The ultimate tipping point in this chain is seemingly where the volatility of each composition weighs in through a mix of normative and positive judgment calls and thereby confirmed by recollection of the commentation about the contributions where it is finalized through, what I could liken to the “Boolean prime ideal theorem“, or more commonly “House rules“.  Now, all I need to do is to see how well I am able to load up GitHub for Windows and get on with it.

Hookin’ up Git.

My full system backup was just before the Global Game Jam 2013.  So now, and after doing a full virus and spyware definitions update with a complete disk scan, I’ll tackle this.  From my account select Help, then Set Up Git, then Download Git for Windows, the digital signature on the .exe properties are consistent, so here we go.  Right click on GitHubSetup.exe and Run as administrator, show information about this publishers certificate, This certificate is OK.  Install Name: GitHub, Publisher: GitHub.Inc.  Click Install.  37.9 MB.  From:  And there it is, welcome.

Now what?

Introduction to Git with Scott Chacon of GitHub is long but it further explains what he thinks should be going on and it complements his book “Pro Git“.

Can I have some sound now?

From within Processing?

Uhm, G’day – To be Continued . . .

February 9, 2013 Posted by | 2013 [0019] to [00??], The Process | , | Leave a comment

[page 0026] ~ Sound in my Web Game:

Client/Server side sound.

While utilizing both Processing and Processing.js there seems to have been a paradigm shift in the way the Processing code is brought to the web.  Processing.js, from what I have gathered thus far, is the way that the code is to be presented in, in my case, my gamers web page games.  Which of course means that Processing won’t be building me an “applet” and that it would serve me well to read up on HTML5, CSS3 and JavaScript.  Although this seemingly has little to do with my GS-XNA 4.0 creation of games for XBLIG, I still do need to tend to my own web creation and expansion.  In the long run this way side stop and scenic view is a good thing.  All this will also let me present my tiny games to those on One Game A Month with little to no hassle because it will be more closely aligned with the Princess Pea and Sir Mushroom game: Pathos.

A short bout with Chaos.

It’s snowing out.  I walk inside and find that there is a small tuft of snow on the tip of my shoe.  I stand on the mat at the door and pop off both my shoes.  While slipping off one shoe I lightly tap the tip of the snow on the tip of my shoe onto the kicker of the wooden door.  It moves from my shoe and sticks to the door.  I’m now in my socks.  With my socky toes I flick the snow off the door so the moisture won’t stain the wood.  But, in doing so it lands inside my shoe.  I bend to pick up my shoe to knock out the snow.  Now, when it melts outside my shoe when I go back outside my foot won’t get wet inside.  Stepping backwards to go about my day, in my socks, I step where some snow was left from the bottom of my shoe when I first came in.  Pesky Chaos, you just can’t win.

Out of the frying pan and into the fire.

It looks like this months objective is to build a game in Processing and post the code on GitHub.  I’ll have a game.  Anyone can view the code and run it in Processing.  It’ll meet two directives, a game to play and a link to the code to one game.  And it will make me sad that it isn’t a go-to page and mouse click to start and play the game.  Yes, this game is, like so many other entrants, and will need to have something extra to play the game, the installation of Processing.  Once again, my bad.  Hopefully March will bring about a web page game.  At this rate it might, but it will be a real foot race.  I’ve been going over some of the books that deal with the three afore mentioned technologies and the Processing.js site documentation.  It reminds me of when I initially started out trying to build my website in MS Visual Web Developer 2010 Express instead of using MS FrontPage.  I thought that using “W3C//DTD XHTML 1.0 Strict” would be a good idea because I could low ball the browser wars and fly in under the radar, which worked out pretty well.  But, along came Twitter and the like, (possible pun there), and found that the “Strict” Document Type Definition actually was very strict.  So now it’s time to swing way over to the other maximum of the pendulum and dive into that wonderful HTML5 “canvas” object, JavaScript, CSS3 and Processing.js and hope I don’t get lambasted.

The game plan this month.

Build a game in Processing and post the code in a repository, whatever that is.  At GitHub they said something about SHH keys, but its been a while (2005) since I’ve had anything to do with Bash, where I had to mix it up with Linux/Unix at the University, with some Windows Telnet and FTP using Internet Explorer just to debug the test runs in the School environment from at home, where then, I didn’t need to live in the C++ computer lab at school, “Those were the days …”, ugh!  So, seeing that it is always less fruitful to talk about homework than to actually bury oneself in it by doing it, it’s time to put this blog up and out and find what’s new out there, like reading, research, shoveling, doing some dishes, tea with honey and lemon, some small talk and then getting more game ideas into and out of my head.  Oh yeah, with some sound.


February 8, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0025] ~ Profound Sound all Around:

Moose Juice and Goose Juice – The Sleep Book by Dr. Seuss

Processing is small, but I like it. It will also become my way to gamify myself within One Game A Month.  But, this blog will concern its self with how naked I feel while building the February game in Processing, in comparison to using my usual GS-XNA IDE.  **DISCLAIMER** – these are observations I have come across as I build, and may have solutions that I am not aware of at the time of this writing.  So anyway.

How things get done.

The syntax is familiar between the two programming languages and that adds to my comfort.  The help files given by both are uncluttered and easy to understand. The debugger in either is well defined and in general gives good guidance as to where I should look to find where my exception may be found.

The first thing of difference that I had noticed is in where the logic and render code is placed while constructing my programs.  In Processing and GS-XNA the include/using statements along with the declaration statements are still positioned at the top of the project class.  I have yet to find the implementation use of function prototypes, or where or why they would be used or needed in either.  C++?  My bad?  But in GS-XNA the Update and Draw methods are separated, while in Processing the code logic and draw methods are combined.  In either case some pre-thoughts need to be addressed as to the order in which the precedence of each code line should be placed.  A dual line of thought given for the codes step into and through with GS-XNA divides how variables and function calls are executed by the CPU, while in a separate thought and process, the visuals are consolidated and fed through the graphics pipeline and from there are given to the GPU.  And so the Update feeds the CPU with code logic while the Draw feeds the GPU with graphics.  All of this happens while GS-XNA tries to keep a sixty frame per second call consistency, while the logic is free to update within those draw calls.  In Processing the cycle of code iteration is perpetually captured by the draw method/function alone, and therefore, are both seemingly CPU driven.  These two types of implementation are intrinsic because of the IDE’s construction. Given these characteristics, they both express the ideals for which each of the IDE’s were constructed and for what each type of usage they were intended to convey.  Processing is simple, light weight, portable, easy to install and lends itself well to general coding practices, thereby claiming the title as a coders Sketchbook.  GS-XNA is specialized to speed the processes through which the complex tasks of: implementing a window to draw in, accessing the DirectX and other assorted Direct(?), porting a game from the PC to an XBox, and then, with further programmer desire and a subscription, submission of completed games to eventually reside in the XBox Marketplace.  In short, each has their own flavor and charm.

Things that are missing, and sometimes not.

In both, when a function brace is selected the accompanying brace of the selected function is also highlighted.  But, (this is where my nakididity becomes apparent), when I select a variable name in Processing, all the like named variables are not also highlighted within the classes page as in GS-XNA.  Keeping track, in Processing, of where all these variables are placed within the code page, for me, becomes unwieldy.  But this will only make me a better programmer seeing that, although my programs may be smaller, I will be more concise with the naming of each variable used.  Also giving the variables and functions more clear documentation by means of remarks, should again provide a degree of recollection because of repetition in the thought of their meaning arising from the connections I make in the comment about the variable, good for me.  Another concern is my use of global variables and the building of functions that take arguments, something that I haven’t gotten around to yet in Processing, but has come to mind.  Come to think of it, I’m glad I went back to the University for some formal code creation training in C++, the pressure cooker, broasted not baked, although grilled is definitely preferable, and of course in all cases, seasoned to taste.

Another thing I have noticed is that, in Processing, the code page doesn’t have any regions that collapse long code blocks and shorten the scroll distance like in a GS-XNA class page.  For example, in GS-XNA, when a large switch/case, or code block that is no longer in need of change and therefore has no need for further recognition, would then, because of an XML code page format with collapsible nodes, has the capacity to be hidden from view.  Something likened to that of the Wizard of OZ behind the curtain in that merry ol’ land of OZ, where things work as they should, “so pay no attention to that man behind the curtain!”  Somehow, I would presume, in Processing I would be able to build classes in different tabs to hide them, but so far this would only be a fleeting thought never put into practice.

Another thing that I have become accustomed to, in GS-XNA, is selecting a variable and either going to its definition or having all its references displayed in the “Find Symbol Results” list.  I think Processing will show me a lot about how I am used to making my way around the IDE.

Another thing, is setting a bookmark so I can quickly scroll up to where my variables are at the top of the class and then quickly scroll back down to the visual que of the bookmark on the left edge of the code page.  A break point works just as well when the variable is on another page and I have forgotten exactly where I need to go back to, just run in debug and the program breaks where I need to be, that is, if it compiles.

OK, this is a little weird going back and forth in-between Processing and GS-XNA, but it is kinda fun, something new to do, to do, to do.  That’s right, I need to get some music into this game.

Hm, it seems that if a key is pressed, in Processing, only one key will register, therefore there isn’t any chance of having a shift+(some other key) pressed at the same time.  Needs some research.

Eeeek! – well almost.

New in Processing 2.0.  It had seemed that it has lost its web ready capability but with a little searching, it seems that Processing.js has continued on along side it.  And like that, this blog will continue on.  With some sound, really.


February 4, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0024] ~ Veni, Vidi, Somni:

Now that was cool, Global Game Jam 2013.

I had no idea of what to expect, and I’m glad I had no expectations, because as things turned out, I found myself intrinsically imbued with the entirety of the event.  The game works rather well, or well enough, and all in all, this GGJ13  has put me in a mood that should last me for some time to come.  A lot of good people, a great team, a fun weekend building and playing games, and some really excellent memories are what I have come away with.  And even though pushing through with lack of sleep, I need to say it was worth all the effort involved, and will leave it at that.  Perfect.

Green Eggs and Ham – Dr. Seuss.

During the GGJ13 I learned of a new way to accommodate the K.I.S.S. approach for my One Game A Month challenge.  It is Processing.  The syntax is comfortable and it is a feather weight in comparison to my .NET/XNA flagship that I have been navigating about these gamified waters.  Processing runs itself like a little Sketchbook, keeping track of ideas as they pop up, like a computational notepad.  Keeping code small is the best way, with short incremental builds where the debugging ideas are kept only a few steps away.  And yes I do like Processing and XNA (a.k.a. Green Eggs and Ham), I really like them Sam I am.

A very short blog.

G’day and Good Night.

February 2, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0023] ~ Wheedling through the (K–Pg) boundary:

Through a Bazillion handshakes the game is begun.

Loath to expire in this Phylum of mine I must find a magic talisman, build a space suit, and grow wings, for the old K–T Boundary is the new 50. It seems that HTML5 is here, it is moving along, and the flight looks pretty good too.  How might my flight look is yet to be clearly seen.  But, with the “Packing and Distributing Your Game” a transmutation may become possible and some entry given to One Game A Month as a last ditch attempt, maybe, eventually.  A final stumbling block in this continuing escapade is that any entry of mine, of my game, will have its input from a Game Pad, alone, be it PC or XBOX, possibly up to four pad controllers on a single console, eventually.  But I may just thank them for dinner, stop in from time to time, and continue about with my own familiar design.  There is no sense mucking up the field doing everything with my heavy hooves, everywhere, all the time.  It is strange that in creation things can be seen as that of becoming straightened out, even though the universal foam seems to be, for the most part, eternally perturbed.  Well, that was fun.  Most likely, I should set my sights back on my own game devices once again.  A pleasant jaunt it has been.

Finishing my Notes.

I am going to try to rebuild HUD-On, and for comparison and contrast I think I should Fraps this game as, FarNiche 0005 HUD-On Com, in its current state.  A nice before and after, probably more like before and since, as it will be the best way to state this game in its current point in time.  From there, I can begin a process of consistent replication, for the next twelve months, but can only start if it starts at all.

So then the mini-map . . .

I have found that hard coding a variables constant values within the class flow of logic as that particular literal value is not a good idea.  It is best to make a global const and from there all the variables can be changed without “searching” for them all.


“Help me Global Game Jam, you’re my only hope” – Princess Pe-a.  There is yet hope to have a game, game one, ready for January.  #GGJ13 is just before the end of the month so there does seem to be a great and small window of opportunity to devise some sort of game before the next month begins.  As for time management, “How many seconds are in forty-eight hours?”  “And at which clock cycle might you find yourself in quandary in looking for these ‘seconds’ in your 48 hours?”  Very good, well met, yet there is before me another fork. A choice of two, to select one is my only option.  No, no, no, just build a select case, a counter and let the for-while-loop go about being filled with what needs to be done in the time I’ve been allotted.  Ok, tweet out some things that need to be done, like . . . fweep-fweep-fweep-fweep…FWEEEEP.

Things to do, places to go, people to meet.

Start a new solution.  Grab some stuff from BasicGameSize, like everything, and just call it GlobalGameSize with a new GUID as found in Solution/Game/Properties/Application/Assembly Information/GUID.  Because, if by chance you were to build an .exe with the same GUID, “and namespace?”, there may be the chance that that could over write a previous build and thus update, or downgrade the current project build.  What-ever.

I hope I can build this template in . . .

preparation to this upcoming weekend.  Open VSE 2010 and select New Project, then Windows Game(4.0).  Select a desired file Location: and the Name: of the project solution. After the IDE creates and loads the interface, in the Solution Explorer, right click on the GlobalGameSize project and select Properties.  In the XNA Game Studio tab open the Game thumbnail: and give  it some alterations.  Don’t hawk any ideas from the Global Game Jam 2013 site. Ok, I have something close from my GDD prototype I could put to use.  Done.  In the Application tab change the Icon and fill in some more of the Assembly Information.  Move down to the Security tab and click the link, “Learn more about code access security …”, and of course, read more and more.

It’s time to set my boot heals to a’ wanderin’.

The time to pack it up and hit some door is upon me, the point of no return.  If I don’t have it at least I’ll know where it is.

See ya when I git back, back to where I once belong.

Who is Jo-Jo?  Mo-Jo, Jo-Jo?


January 25, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0022] ~ Strike While the Iron is Hot:

it’s really sticky stuff, oh bother.”; from Winnie-Ze-Pooh.

In finding myself being a member of this One Game A Month community, I feel it is my duty to conduce another diverse aspect of gamification.

A Fish out of Water

I’ve searched and researched the many aspects of the playable game options that I have for #1GAM and the long and short of it is . . .

I do have a few options, it seems, none of which include a simple resolution.  For instance:

1).  I build a game on the PC and therefore have the source code which, when compiled, builds the game and is playable through a window created by the API in debug mode.

2).  I have that game after compilation as an .exe and can then play it on the PC by clicking on its .exe from within the Windows Explorer folder. All is good.

3).  Also, I can start up the XBox 360 and have it connect to my PC through Xbox LIVE Indie Games and “XNA Game Studio Connect”.  With that connection the game is deployed to the game console where it is then playable as it had been on the computer.  Again, all is very good.

4).  One last caviate would be to select it from “my games” from within the consoles menu.  But this would prove fully unfruitful to the OGAM community at-large.

And how it gets sticky.

A few forks in the road seem to have come about which diverge from the following conjuncture:

1).  A supposition involving a simplicity that resolves to an implementation where a game “is” in play.

2).  A formalized standard which allows the games concepts to be perceived as that of the given game as “being” played.

3).  And a conclusion that provides some degree of satisfaction because the game “has” been played.

Diverging from this convergence is where I will assume my recourse, in that, of a game played as found from my link on One Game A Month.

High Hurdles.

Underlying those virtual precepts, the methods that will produce a game, will come about if, and only if:

1).  there is the code to be compiled within the compatible API. – PC.

2).  the given .exe is clicked on within a computer having the necessary “redistributables” installed. – PC.

3).  the deployed game is selected from the consoles game menu. – XBOX.

Sordid details.

This option entails having the code reside either on GitHub or CodePlex, where these assets are used to reproduce the game.  Not the best option seeing that in its current “bloatware” status HUD-On is (349 Files, 68 Folders) with 892 MB (935,886,848 bytes).  And my best guess is that that download wouldn’t provide simplicity, seeing that the player would need to install GS 4.0 on the PC so as to have the game data match the game load serializer.

Another “best” option would be to utilize “ClickOnce Deployment”, which seems to be a self-contained package builder, something in the lines of an XNA focused form of Flexera InstallShield in a WINZIP-esque wrap.  This would facilitate the “redistributables” installation onto the PC, but the loadsome nature of this process may also prove, not necessarily prohibitive but more, inhibitive.

Another option would be to load it into a project slot within my “MyI” namespace at which point it would become an entity to be consumed by the playtest and review peers of the XBLIG Games Catalog community. And like Jackie Gleason might say, slap-snap-crack-zip-zoing-zoom, and off and away it goes.  Which means that it would be accessible, in part, on its way to Indie Game approval.  But of course it would need to be a game in completeness, bug and crash free, to the best of my knowledge, and ready, as such, for the MarketPlace, as my game.  This still would not relinquish simplistic access from a link from my OGAM profile.  Hmm, again.

Then, the dogged truth.

Finally, remuneration, which envolves, yes, you may have guessed it, I think the Beatles summed it up pretty well in their song The Beatles – Revolver, Taxman.  Yeah, that stuff, sticky stuff in its own right.  But, not to be confused with recompense, which is qualified by means of anguish, which is perpetually, in all actuality, offset through elation found because of accomplishment, both large and small.

a Wedged Bear in Great Tightness” – also from; Winnie-the-Pooh.

And I believe I will leave it at that.  And get back to what I do best, hibernation, just kidding.  Seeing that One Game A Month is a personal challenge, I could still Karaoke my way through this year, bonus, from sad to glad.  And so, with most optimality the path was proven too impossible, sorry Princess Pea, just too, not completely, impossible that is.  YES has sung it best, “Yours is no Disgrace”.


January 18, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0021] ~ Game 00 Hud-On :

Between a Rock and a Hard Place. (Ms-PL) vs. (???)

Or, maybe its just some nervous jitters about going from the sandbox to the kiddy pool.  I still have no idea of how to demonstrate a game exhibition anywhere for any of this, with any simplicity.  More research, and hopefully an “e” for effort.

My ship is small, the map is open.

What are some simple clues to give away the game?  I guess Genre trumps Motif.  Genre is a type and Motif is the mood.  A quick rundown of the genre please.  It’s a: 3D world bound space-ship flight race.  And the motif please.  It has: terrestrial biome colonies and bio-spheres.  Anything else you would like to add?  Yes, a help file.  How about sound?  No.  Well, yes but . . . no.  How many spheres will there be?  Ha ha, a sphere you say.  I do not understand that sphere primitive, nor its base class.  Maybe I’ll understand the implementation of the instantiated variable.  “Find All References” is a really nice menu dropdown item.  OK, I’ll have up to one hundred spheres.  And what do the spheres do?  In general?  Yes, and specifically.  Generally – The spheres float around the game field, if they hit the terrain they bounce back up.  If they hit the troposphere they bounce back down.  And if they hit the edge of the world they bounce back in.  Specifically – The spheres have, wait for it /* segue – my ship has shields */ just refound them, ok, a SphereHitCount I could use somewhere, for the counting of course.  Putting a break-point in the SphereHitCount method of its bool {}, and running in debug mode, I scry its utility.  Got it.  With the break-point off, the counter works.  Carry on.  If you run into a sphere it changes to a wire mesh sphere and increments the counter by one.  Does it drop to the ground?  What do you mean.  Like, halfway through the terrain so it looks like a dome?  Yes.  No, not yet.  But the orbit of the SampleArcBall camera could be faster, I can’t get a bead on the spheres until they have passed me by.  Well, what happens if the ship hits any of the walls?  It starts over at some random position on the map.  Nice.

What was the deal with each viewport needing a dedicated . . .

Hold On.  Just look for the rotational speed first.  Ok.  But just a minute, A tale of many haggis.  Yeah, that sounds about right, I just jacked up the sphere count to 10,000 and had a frame rate interval of 1 in about every 3 or 4 seconds, maybe 5.  Back to 100 spheres.  Anyway, the spheres come in a variety of colors and sizes.  I could really use a compass or some vector readings to follow on the mini-map.  Maybe even some extra little dots on the mini-map of the spheres (x,y) positions.  /* Correction, make that (x,z), y is perpendicular to the tangent of the virtual gravity, e.g. Vector3.Up, like towards the troposphere.  But, never mind, just another 2D/3D conversion convention. */  And you.  I changed the orbital rotation and the speed is good now.  Now what?  Mini-Map compass vector gauge?  Or, I could just fly really fast and best guess my position by matching the in view frustum 3D terrain to the 2D mini-map.

“But what does it do?”

Is there even a little back-story?  Well, no.  Hmm, would you like there to be one?  Yes.  Like what?  I think that there is a home world where;

Sentient life has evolved, iconoclasts have defeated reason and reactive imitation is the new faith.  The Old Masters of Belief are inexorably destroyed, Creation is considered a black art and the void of chaotic syncretic manipulation opens.  Every twenty-one years the Edict of the Precursors has sacrificed the human pinnacle of there civilization to the heavens, launching them from the home world to the starry sky above.  With a stalwart yet saddening farewell they are taken out, and off the home world, where they begin the cycle anew.  The society that they left behind is then opened to a perpetual, self-fulfilling need, the need to fill the spaces of those who are gone, the real cost of opportunity.  For those who must go and for those who stay behind, their Dilemma is the same.  Deny the History of the Edict and produce Wars of Annihilation on their home world and severance to one another abroad.  Then, followed with the denial of Sacrifice unto Excommunication to those who had been previously sent, those on the home world also rescind their pledge to observe the Edict.  Leaving only all to disavow their previous ties to their recursive existence on the home world, and nought to revel in their new auspicious disassociations in sustaining their home world nor building new off-world colonies, the scattered survivors begin to; . . .

Uhm, well then, or maybe,

Could you make it just a little more simple?  please.

Sure, I agree, great and strange is this wondrous KISS.  I think I can do this, I hope I can do this.

The simple story:  Four space ships are your last hope.  Choose your ship and stop the evaporation spheres from escaping with your colonies.

The back story:  A rogue civilization has unleashed a new weapon upon your home world.  A sphere that engulfs your cities, towns and villages, and lifts them up, then slowly shrink in size until they pop out of existence, along with your colonies.  You must infiltrate the spheres with your ship before they slip away to the void.  “Ramming Speed!”  Time is not on your side.  Fly fast, but don’t crash, four ships are all you have.  Good luck, fight the good fight and remember our survival depends on you. – That’s better.

Until next time, still hobbling toward a more simple story plot.

And as the sun sinks slowly in the sky, our good Master Yoda expounds, in his gravelly voice:  “Mmmm.  Stupid Simple It Keep, and now, yes, forever rest”.

But wait, there’s more . . . G’day.

January 16, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0020] ~ Game 00 KISS:

Like a vale being drawn from my eyes.

Just to whet the whistle, I dove into HUD-On once more and found that, it is really really cool and very very messy. Giving it a month long kiss wouldn’t even begin to get it ready for the January feed.  One pad, many requests.  I know there isn’t a help file, so I’ll save time by not even looking for it.  In the game the camera has two modes, the ChaseCamera and the SampleArcBall camera.  These two eat up a lot of the players controller interfaces; buttons, joysticks, triggers, . . ., thereby having each mode overlap the other, and therefore they each become a different game state.  Hmmm, game state again.  The mini-map is working well, the scale works and the position of the ship in 3D space and on the 2D mini-map match, and the mini-map fade out, just to get a little more screen real-estate, is only still slightly visible when at full dim, all is good.  I concur, giving variables a “<summary> /* comment */” is a good thing.  A flowchart would be so much better, but C’est la vie.   HUD-On is as good as it gets for now.  Double hmm.  No rules?  This game is done.  OGAM bound.

“But what does it do?”

OK, it isn’t exactly done, yet.  I won’t have as much a head start as a whole month, so what does it need?  What does it have now so I’ll have a game.  Start the game, and, Not that button!  That’s the game exit button.

Alright: The ‘back’ button is exit.  The ‘start’ button is switch ships.  And now, for the two game states; ChaseCamera = CC, and SampleArcBall = SAB.  To switch back and forth between the two modes, press the ‘Y’ button in either mode.  Back in CC, to get the ship to initially move, hold down the right trigger and tap the right joystick forward, kinda like holding in the clutch when you start a manual shift car.  If the ship is ever going a zero speed it has stalled so the same procedure is used to start it going again.  This can only be done in CC, not SAB, true, I can see the overloading in action.  And that’s really funny.  While trying to switch back and forth between the game window and notepad using Alt+Tab, instead of only switching out of the running game, I have a command prompt that has also popped up in HUD-On.  Having an idea of the structure of the parts of this game, my best guess is that it has to do with [page 0004] and the PerformanceMeasuring sample, I think.  And how to exit the command prompt?  Unknown Command – CMD>.  I really don’t know, nothing I type in works.  Going to the IDE – Find and Replace CMD, and the victim is, Find All.  Matching lines: 20    Matching files: 4    Total files searched: 61.  This looks promising, cmd.callback(this, command, args); it might be something to look into, later.  Ah-yes, I commented out the command strings, in effect gutting the performance measuring part of the sample, using only the spheres, their collision aspects and of course their movement routines.  I get it, don’t press Alt+Tab now unless you like to have the command prompt covering the screen for the entirety of the play, unless you would rather it be there until you exit the game, did I say game.  Yes, it’s a game!  My January Game, game 00, my first game.  \o/.  Or maybe it was SpaceWar II, nah, that was a dry run.  But I could throw it in, in a pinch, just in case, later on.  The proverbial ace in the hole.  Or maybe, no ace, no face, no trump – a granny hand, not to be confused with a Granny Hand in Sheepshead but not Schafkopf.

OK, more button stuff.

Or, never mind.  If you press Alt+Tab again the command prompt does go away by itself, but it still makes the window call and switches notepad back to TopMost, my bad, whatever.  Change of plan, its just easier to leave the game and notepad off center over each other and then just mouse click on whichever window, to set its focus back to true.  That works.  Now more button stuff like, nope, more game play stuff like I fly a ship around the playing field and run the ship into the spheres that float around the map.  When I hit a sphere, it becomes a geodesic dome and sinks to the ground to become a colony.  In a two player game this could have some substantial connotations.  But for now, the game is only one player, MyI, me flying the ship, seek out the spheres, collide with them and letting them to sink within a given time limit.  I’ll need a timer.  There’s a timer in SpaceWar II that I know of, like a flash.  Whoa, don’t set Fraps to start a movie capture with the video capture hotkey set to the space bar, “Space”, and then type this blog.  You know how many files you end up with?  Lots, 202 for 39.1 GB.  LOL.  I always wanted to say that, just couldn’t find the right idiom . . .  Back in SpaceWar II, I’ll grab a TimeSpan and follow its “Go To Definition” and “Find All References”, OR maybe GameTime.  GameTime does get me into the Update method.

Like a whale being drawn from the skys, not the “Fail Whale”, nor the “Narwhal”.

It looks like I’m back in the groove so its time for hyper drive, take a deep breath and dive into the coding mantra place that gets things done.  I think I’ve got a game for January.  No rules, now that’s great fun.  And again: \o/


January 7, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment

[page 0019] ~ OGAM Game 01 JAN:

Every Quest needs a Map.

So, what is a map, and more importantly, what do I think a map is?  Initially, I picture a map as something tangible, a piece of parchment with ink scrawled upon it.  Beyond that, it needs to be where I am, because a map really isn’t useful to me if it isn’t with me.  If it doesn’t remind me about something that the maker of that map thought to be important, for all practical purposes, it has stopped being my map.  This map, my map, my useful map, because it is with me, could therefore be seen through its probability to promote an expedition of abrogation.  And if that is the case, what is left is a set of waypoints that will leave in-between those points the path that is to be followed.  And that’s a map.

So, what is my map?

Right now, my map is empty, therefore I have nowhere to go.  Who built this map?  It is broken.  What I need is a “Map of Many Things”.  I think I’ll just stroll over to the wizards place and see just what is on the bill-o-fare.  Hello, Good-bye.  Leaving that neighborhood magic shop, I once again have found that for all the best intentions, the Map of Many Things was hidden by a legendary Bodhisattva, and became a relic lost from all reckoning through the passage of time, but I did come away with a philosopher’s stone.  Going back to my disheveled hovel, I place the stone on my “Parchment of Devoid” and low and behold, a portcullis appears from under that stone.  Lifting the stone, to get a closer look, I find that the portcullis has vanished, and in its place is a dot.  No, it’s an icon.  Moving the stone over the icon and placing it back on the parchment, I hear a click.  Looking up I see …

GeoControl2, its been a while.

Yeah, really. I go to the Project tab and click Load Projectsettings.  Rummage, rummage rummage.  Do you know why things are always in the last place you look?  Because once you find them, generally, you don’t need to look any further.  And speaking of looking for, this might be a good time to begin a folder dedicated to consolidating and backing up all these relics of antiquity.  Looking at the names of the files in that old folder, I can vaguely recall the naming convention I had used, nor the reasoning behind the purpose of the names.  It seems that I had tried to use Mod Tool to build a terrain, but although the map mesh object could be built, the ability to properly scale it, and then provide collision detection on its surface had become overloaded in extraneous logic.  I think my next option was to draw a map in GeoControl2 and then, ah yes, two bitmaps, land and terrain.  Terrain is the gray-scale heightmap and land is the Gaussian colored biome.  I may have found the precursor to this fabled Map of Many Things.

Four Blogs a Month?

Sure. – G’day.

January 6, 2013 Posted by | 2013 [0019] to [00??], The Process | Leave a comment