Formatting HTML with Sublime Text

It’s almost quitting time, and the only thing standing between you and a relaxing evening is the one task you’ve been avoiding all day: Posting photos from the employee recognition dinner on the company intranet site. A simple enough task, it would seem. But “intranet” is such a lofty term to apply to that rats nest of static HTML pages. It was originally assembled (you won’t deign to use the word “coded”) in Dreamweaver by a long-forgotten secretary when you were still in middleschool and IE3 was the hot new browser. HTML5? CSS layouts? Semantic markup? Ha! This intranet never met a table it couldn’t nest. And the formatting … As if tables within tables within tables weren’t hard enough to work with, the HTML looks like it was indented by a macaque after a couple of stiff shots of Jim Beam. But the updates are due today, and there’s no getting around it. You fire up Sublime Text, and wonder …

What’s the best way to untangle this gnarled mess?

To find out, I put several of the most popular HTML formatting Sublime Text plugins through their paces and compared the results. For the tests, I used a nasty HTML test file courtesy of the creator of the HTML Beautify plugin(thanks, Ross!). This file includes just about every formatting misdeed ever conceived by the human mind, including misaligned code blocks, copious amounts of extra white space, preformatted text and inline comments. I ran two tests on each plugin–one with the test file as is, and a second one with a minified version of the file. Which plugin came out on top? Let’s see how they stacked up. Read more …

Facebook for Unity Android P1: Where is the keyhash?

Someone doesn’t find the keyhash showing in facebook plugin for Unity. Here is some common error to fix the problem.

Note: everything is explore in FacebookAndroidUtil.cs

  1. Missing keytool:
    Find out in the file above, you see the function GetKeyHash and Unity use this command to get the key hash “keytool -storepass {0} -keypass {1} -exportcert -alias {2} -keystore {3} | openssl sha1 -binary | openssl base64″Oh! Too many strange keyword!

    Dont worry, everything is in jdk install. All you need is to install JDK 1.7 and set JAVA_HOME, ENVIRONMENT PATH to JDK (I tried 1.6 but problem not solve)

    Restart Untiy and done :)

  2. Couldn’t find the debug.keystore:
    Still got error, never build android android app in eclipse before make you missing the debug.keystore.Check in your computer path: “c:/users/<name>/.android” in window for the debug.keystore. If missing, you have to build an android project with eclipse to make the path visible.

    It’s still not finish, sometimes you put the Unity project not in the same drive with Unity installed. Check in FacebookAndroidUtil.cs

    private static string DebugKeyStorePath {
    get {
    return (Application.platform == RuntimePlatform.WindowsEditor) ?
    System.Environment.GetEnvironmentVariable ("HOMEPATH") + @"\.android\debug.keystore" :
    System.Environment.GetFolderPath (System.Environment.SpecialFolder.Personal) + @"/.android/debug.keystore";
     }
     }
    

    Unfotunately, the path “System.Environment.GetEnvironmentVariable (“HOMEPATH”)” is not contain the harddrive “C:”, so the link return is point to the same drive where you put the unity project.

    To fix this problem, just put System.Environment.GetEnvironmentVariable (“HOMEDRIVE”) before the HOMEPATH.

Good luck step 1!

Unity2D: Transitions between changing scenes

I’ve written a “small” script that allows you to load a level, but it fades the old level out and fades the new one in. The documentation states that the GL class is only available in Unity pro, but in my Unity version (3.0) it works fine in the free version ;) Read more …

Unity 5 Announced With Better Lighting, Better Audio, And “Early” Support For Plugin-Free Browser Games

Even if you don’t know what Unity is, you’ve probably played a game made with it.

Unity is a game development engine that has skyrocketed in popularity over the last few years. Its main draw: you build a game once, and it works (natively!) on nearly every major platform (Xbox, PS3, Windows, iPhone, Android, and so on — the list at this point is nuts) without much extra work.

This morning at GDC, Unity announced the fifth major release of their engine. This comes about 16 months after the launch of Unity 4.0.

So, what does this mean for you, the gamer?

lighting 3

If you’re a gamer, just know that a fairly popular game creation tool just got a whole lot better — better lighting, better audio capabilities, greater efficiency, etc. It’s sort of like if your favorite artist suddenly gained access to a bunch of fancy new paints, or if your favorite band was brought into a bigger, better recording studio. Read more …

Rumor: Assassin’s Creed 5: Unity Will Show Off Four Player Cooperative At E3

More rumors are coming up for upcoming games for this E3. This time, we are apparently going to see two demos for Assassin’s Creed 5: Unity.

Now, here’s the real clincher; one of the demos is for the single player game. The other demo will apparently feature cooperative four player play. Yes, cooperative player is allegedly on the way for Assassin’s Creed.

Of course, no Assassin’s Creed game has featured cooperative play like this before, so if this rumor turns out to be true it is a literal game changer. We also do not know yet if this is local split screen or online multiplayer. Although prevailing market trends would make it more likely that the latter is in the works, I would not rule out local multiplayer just quite yet.

If true, Ubisoft could also use it as an opportunity to show how far along development has gotten. If the game is going to make the franchise’s usual fall release, the demo needs to look close to completion, or else Ubi may have to delay it.

We will make sure to keep you updated with the latest in E3 and Assassins Creed 5 Unity news. Assassin’s Creed 5 Unity is coming Q4 for Windows, Playstation 4, and Xbox One.

Admob with Andengine

If you have a game developed with Andengine you probably don’t use a XML layout file and your activity simply extends the BaseGameActivity class or the SimpleBaseGameActivity class.
I assume that you know hot to add the Admob jar to your project and to set the required permissions in the AndroidManifest file. If you don’t, then check the tutorials on the Admob web site first.

The first thing you need to do is create a new XML layout file, let’s call it game_layout.xml
The content of this file should be similar to the following: Read more …

Code Like a Chef: Work Clean

There are a dozen opinions on any given cooking technique, but in the Alinea kitchen, when you say “TK says…” that’s the end of the discussion.

Thomas Keller is considered by many to be the best chef in America, and almost certainly the most influential. His NYC restaurant, Per Se, is ranked the sixth best restaurant in the world (edging Alinea out of the spot it held in 2011). In 2003 and 2004, his The French Laundry, was named the best restaurant in the world – the first American restaurant to hold the honor. Grant Achatz, chef of Alinea, spent six years at the French Laundry – and so influential was TK’s friendship and mentorship that Grant named his eldest son “Keller”. Read more …

Apple Requiring All App Submissions To Be Optimized For iOS 7 By Feb 1st

Apple is requiring developers to optimize all app submissions for iOS 7 by February 1st, 2014, according to a new posting on its developer portal. That includes new apps and updates to existing apps. In order to optimize apps for the new operating system, they must be built with the latest version of Xcode 5 which includes 64-bit support and access to new features like backgrounding APIs.

Apple has been on a push over the past couple of years to encourage developers to support the latest editions of its OS faster than ever. To do this, it’s made a habit of pointing out the adoption rates of new versions of iOS, which are extremely high. Nearly every event mentions iOS 7 adoption, which now tops 76% of all iOS users, and Apple now publishes current statistics on a page on its site.

It’s likely that Apple is more anxious than ever for developers to update their apps to fit in visually and mechanically with iOS 7, as it’s the largest change in the history of Apple’s mobile software. iOS 7 introduced a much more complex physical language while stripping out many of the visual cues that developers had relied on to instruct users. For better or worse, this has created a new aesthetic that many un-updated apps did not reflect.

However, from the wording of the notice, it appears that this requirement is more about the underlying construction of apps rather than their appearance. You can ‘optimize’ an app (whatever that means) for iOS 7 and build it against the new Xcode without redesigning it. That being said, many of Apple’s standard UI elements have changed in its new SDK so most apps being built in the new tool will need some re-working in order to look and function correctly.

What I am doing for relax – Leagua of Legends guide

Seven Ways to Get Better at League of Legends

Multiplayer Online Battle Arena games have come a long way since their humble beginnings. Starting as a mod for Warcraft 3 called Defense of the Ancients, games in this genre are now played by millions of gamers worldwide. At the top of the MOBA pile is League of Legends, a game developed by creators of the original DotA mod.

The total amount of information to take in when starting LoL can be unnerving. There’s a few things a player should know if he wants to improve. Here’s seven things you can do to play better and start rising through the ranks. Read more …