The Hyped Up Ocean of Vaporware

The Consumer Electronics Show, or CES for short, is an exciting time for a gadget or tech geek. There’s an endless display, pun intended, of new technology that companies show off to gauge interest, spur interest, and steal interest. This year started out as awesome as ever showing off 15m wireless charging, futuristic cars, NVIDIA’s vehicle GPU technology story, and a laptop with a full-sized desktop keyboard. Of course there will also be the expected: 4K Televisions, smart watches, toys with lots of tech inside, and of course tablets. Phone hardware has mostly moved into their own announcements due to the shear size and demand of that market, but there are plenty of phone accessories.

There’s so much hype and excitement that will fade away in the next few months, but it’s fun to have a post-Christmas shiny object fest. Most often very few of the concepts not already in production ever see the light of day where the average consumer can buy them. The exceptions are those ready for testing in well-known markets like TVs, tablets, and phone battery cases. I still enjoy reading up on the show and checking in to see if there are any nuggets of gold wrapped up inside crazy.

It’s still on through Friday so go check your favorite search provider for news, but I’ll come back tomorrow and the next to update with a few of my favorites as well as links to various blogs and resources for readers and my future reference.

[ST.2015.016]

Alfred is a better Calculator

Alfred
http://www.alfredapp.com/

Alfred is a tool that allows easily and quickly launching of applications typing only the first letter or two as well as quick access functionality like a calculator, search files, or reveal a folder in the finder. Yosemite was released with similar functionality in its improved Spotlight UI. I tried to use Spotlight for a week (my standard testing duration) and found that there were small aspects that didn’t fit into my workflow and I wasn’t willing to see if there were any workarounds or hacks.

Quick calculation is something I use surprisingly often whether for programming, game development, or figuring out how much I’ll pay in a year for Netflix. I used to open a new tab (a browser is open 99% of the time) and type in the math to use Google’s search calc, but it’s one less step with Alfred.

⌘+SPACE type in “=sqrt(33+44)” and hit [ENTER] and “5” is copied into the clipboard ready to paste wherever I please, even back into Alfred.

Spotlight has improved a lot with the latest upgrade, but Alfred makes many actions I want to make with less hassle, even if just slightly. It thinks more like I do and that’s why I continue to install and use it. I’ve recently bought the power pack and am looking into further expanding the level of automation by combining both the new capabilities it offers along with integrating it with scripts I have written.

There are other similar utilities, and they may be more powerful, but for the main essential functions Alfred is my launcher de jour.

Alternatives I’ve used

[ST.2015.014]

Finder is Better with XtraFinder

XtraFinder
http://www.trankynam.com/xtrafinder/

This is a great utility that enhances OS X finder to support better ordering, cut/paste, and Tabs! Who doesn’t like tabs? Essentially it brings it closer to the excellent Windows Explorer I got very used to in my earlier life. The underlying Unix foundation provides the excellent command line file management where XtraFinder brings a similar power to Finder.

Features I like:

  • Tabs. Obviously.
  • Sort folders at the top
  • Cut and Paste files or folders
  • Sometimes useful side-by-side tab view to easily compare or drag
  • ⌘+⇧+G to go anywhere by typing Unix path
  • New Terminal Here
  • New File Here

It’s been rock solid for me since the latest update 0.25.1 and makes working with the GUI much less painful. Terminal is still close by, but now I need it less often, especially in tandem with a launcher like Alfred, which I’ll talk about tomorrow.

[ST.2015.011]

Data-Driven Game Development

I ran across a twitter post to check out a new game engine called Spark. It sounds like an over lofty idea, but with the right focus and vision. I signed up and will give it a test drive if I get into the Beta.

They are using Haxe as their source language, which is great since it can target many runtime/compiled languages. It’s akin to using CoffeeScript as the source for the javascript a web app uses when run in the browser. It is indeed a better variant of ECMAScript than javascript having derived from ActionScript, but go read up on it yourself if you’re interested. I’ve wanted to try out Haxe during a gamejam or for 1GAM, so hopefully I’ll get invited soon and can do so testing out this new engine.

Data-driven development is something every game developer learns over time when they realize the extra work required to go find and tweak the variable, or create another class for a new enemy. Instead they can move as much as possible into data configuration files or scripts separating it from the game logic and core engine code. This allows changing assets on the fly or pulling them from different sources, adjusting parameters for procedural generation algorithms, or even creating new enemies or modifying their behavior. It can allow simple modding support without requiring full scripting experience.

Now with any new games or prototypes I’ve started to build the data models and configuration first. There’s plenty to be said about this topic, and others have written about it better than I could today, maybe I’ll expand upon this topic in the future once I’ve built up a library of data-driven prototypes as well as continued writing practice.

[ST.2015.005]

Cocos2d-x 3.x Migration – C++11 Subtle Mistakes

I’ll probably repeat myself that c++11 makes developing in c++ much more pleasant. However, there are some interesting issues when migrating from various class structures to the new std:: template containers and algorithms.

std::remove removes all elements of a given type, not just the first one found. Normally I try and use the for (auto& element : arr ), but in these cases I use the full iterator syntax instead. Could also use an index based loop, or no doubt another approach which I haven’t learned.

// v is vector<string> may contain duplicate strings
for ( auto& el : v ) {
    // tried to use remove, but removes all found elements
    v.erase(std::remove(v.begin(), v.end(), el), v.end()); 
}

// instead use iterator pointer
for ( auto it = v.begin(); it != v.end(); it++ )
{
  std::string element = (*it);
  if(element == "string to match")
  {
     // want to remove first string match
     v.erase(it); // iterator is invalid afterward
     break;
   }
}

[I’ll continue to append new issues as they’re encountered]