The Tequila Den

Combines the world of Tequila with Games.

Tag Archives: brainfarts

Breaking…

First I want to rant off about the misuse of the phrase “Breaking”/”Breaking news” sort of deal. Maybe it is starting to be my old age, but a lot that is reported with this alerting headline is terribly misleading and not at all … breaking. It literally drives me up the wall, usually this occurs on twitter with a certain junior hockey team’s twitter account, it leans me towards the un-follow button, ugh.

Anyways, the real topic at hand, breaking, ha ha. It seems I’ve been doing more ill-will to Traders than actually making bounds of progress. I’m currently re-working the bank trade logic to be a lot smarter and to handle multiple demands from the player. I ended up crippling the system a little bit (I’m a bit rusty), then I coupled that with a few new maps, and of course some of those have pre-placed gold mines, I’m just kicking the game while it’s down. Also made an over sight when the map doesn’t have a desert the player can’t select the robber as technically it’s not on the board, so there’s another boo-boo.

Back to the grind… weeeeeee.

Advertisements

Longest Road (EVER)

I think I actually got it. What a bitch.

It was a nightmare. I knew it wasn’t going to be easy, but when I first started planning for it, I was honestly stumped. I pieced together the eventual formula, but it took a lot of brain juice.

I’ll break it down. First off, I copy an array of all the roads the player has. Then from that array, I separate all the roads into single segments. What that means is that it is a list of roads that only have a single path. Of course these road segments could be longer when the roads have multiple branches and directions, but this is the simplest form. The roads are all accounted for in this instance. After this, I cycle back through all the segments matching them with other segments and creating new segments. This creates a list of all possible road paths (through all possible branches). This creates a longest road. Although, there’s a catch. Road length can be intercepted by opposing settlements, thus, there’s another check these completed segments must go through. I kept tabs on the ends of the roads throughout the process, so all I did now was cycle through the completed segments catching to see if an ‘enemy’ settlement was blocking, keeping track of the length. At the end, the longest length recorded and returned. Ta-da.

Clear sailing ahead!

Oh fuck, I forgot about ports again. Son of a …

Bouncing like a Whore…

I flew out of the gate working with Canasta to begin with, but as the finish line showed its beautiful head, I decided to take a quick break to freshen up the noodle a bit. I started up production on MouseTrap. I made up a HUD and some basic controls. After I hit a little bit of a mental block, I re-opened up Catan. I miss playing that game. Damn it. I gotta call the boys up for a sit down game. Or… I guess I could finish this?

I need to re-focus and finish something!

Cloudy Brain…

I think I’m getting older. The longer I work into the night sorting through code and trying to do “brain-teasing-tasks” I end up making minor mistakes. These mistakes are hard to decipher and take a long time to debug because in my head the code is correct and its (always) something wrong with the interpretation. But of course, I’m the one who is incorrect. I guess when it comes down to it I can’t add late at night.

Lesson learned: double check what you copy & paste from old code, usually the old shit is sometimes…. shit.