Wednesday, October 29, 2008

More Photoshop

More Photoshop goodness.


My problem is the finding smarter-people-to-be-around part.

Gmail is an OpenID provider

Ignoring all the nag screen crap, it was actually fairly easy to login.

Plura - Now that's cloud computing

This is incredibly clever: game developers can get paid for the computing power that players provide to Plura clients while playing a game.

The next big thing?

It seems micro-blogging / tweetering (is that the right word?) are gaining momentum lately. With the announcement of the Friendfeed Comet API, I think we're moving closer and closer to Comet-driven content delivery.

But to be honest, I think we've already reached a point of critical communication speed. It easy enough to just hit the refresh button to check if anyone anywhere said anything new.

Also, no advertising system that I know of works well to generate eyeball revenue for sites that don't get page refreshes (and I think the ads-in-videos stuff they're trying on Youtube is pretty lame).

With that in mind, I think it's safe to say that value and agenda payloads will more than ever become tied to content: all hail the mass self-aggrandizing propaganda that looms.

The challenge, hence, is to create connection channels that can maximize selectivity and specificity. Maybe tagging actual content and categorizing/prioritizing based on bayesian filtering?

Skein hash function

A new hash function aiming to replace the SHA family of functions. Designed by Bruce Schneier, Niels Ferguson, Stefan Lucks, Doug Whiting, Mihir Bellare, Tadayoshi Kohno, Jon Callas, and Jesse Walker.

Algorithms, algorithms

A list of algorithms. Might be handy later.

Tuesday, October 28, 2008

Change of scenery

Interesting. Reminds me of fantasy games and the whole idea of escaping from reality.

Saturday, October 25, 2008

Creative unpredictability

Interesting. Ties very well with the concept of game content auto-generation.

Wednesday, October 22, 2008

Thoughts on economy and trends

I read this article about young generation and workplace expectations. I think that the trend of over-self-confidence and loss of loyalty is very risky for youth and a sign that they lacks experience. Older workers like job security for a reason: they have bills to pay, children to feed, retirement to worry about.

Let's step back for a minute and think: what if companies do adapt to the mentality that it's companies that need to adapt to the idea of workers with no loyalty?

What if everyone really decides that being their own boss and starting their own business is the way to go?

Here's what I think would happen: new entrepreneurs will almost always start a digital business because it's simply cheaper to crack Photoshop / DreamWeaver / Maya / whatever, than it is to renovate a rented business place (or do any physical world business-related task, for that matter).

Japan is just like that: there's an over-saturation of entertainment-related products, and a ton of people working freelance with virtually no job security and without the leverage of a brand to make a start-up work in the over-saturated entertainment market.

I do see a key difference though in mentalities: in Japan, an artist is a sensei (a master), whereas here, an artist will starve to death. Instead, here, everyone and their dogs make me-too web 2.0 applications and libraries - "computer science" sounds powerful, doesn't it?

Science? yeah, whatever.

Sciences are things that are proven with time - new fads that could potentially maybe perhaps make you rich (if virality works for you) are not science, nor a viable business plan nor a way to get job security that you *will* want sooner or later.

It's kinda weird that now, all the old-school obvious stuff that grandparents used to mumble (you know, saving money, hard work, etc) are all back in the table now. It's probably weirder that these things weren't being taken seriously by a lot of people up until now.

FriendFeed real-time API

A comet JSONP open API. Really cool stuff.

Tuesday, October 21, 2008

Rescue Time

I wonder if it actually helps.

Alone together

Interesting. It makes sense: just because a game is online doesn't mean people care about interacting with other people.

Maybe they're bored of Bejeweled and can't afford Halo.

Peppy - faster selector engine

Interesting, at least while IE8 doesn't come out.

Photoshop actions

Neat collection, especially if you like vintage effects.

Monday, October 20, 2008

A thought on vote-based systems

Here's something I was thinking about vote-based sites like StackOverflow or Digg: can we consider the aggregate sum of votes an accurate representation of people's opinions?

I think that we can't, for a few reasons:

  • Different people use rating systems differently: As was proposed in the Netflix contest earlier this year, some users may reserve a "5 star" rating only for all-time classics whereas some other may rate any funny movie a "5 star". Likewise, some may upvote anything that doesn't offend them, whereas others may only upvote things with which they strongly connect with (by personal experience, for example).
  • Collective thought bias: most people are more likely to agree with the majority than not. This can extend beyond the scope of a single voting decision: the characteristics of future user-generated content are also usually affected by the outcome of past elections. This shift can cause users with differing opinions to avoid participation or leave a site altogether.
  • The incentives are usually not balanced: there's usually a strong preset bias towards taking action on one of the options (i.e. "upvote if this speaks to you" vs. "if you're not compelled/interested by this, you have to choose between acting (downvoting) or not acting (not voting)").
  • Voting systems are often subject to momentum: this is particularly true of news sites - users are encouraged to vote as soon as possible (often before they are able to grasp the full concept, or before they are able to figure out that a certain source is misleading). Voting after a certain time threshold often has little or no social value.

I'm not saying voting-based systems are useless in websites - they can provide a quick insight into whether something is likable or useful. What I'm pondering is this: what's the point of being a sheep?

Meteor Server Comet

So apparently, we can use forever XHR for doing Comet in Safari. I'm a bit skeptical, as this hasn't worked when I last tried this technique, but hopefully I just did something wrong last time.


Second Life for muslims. Call me crazy, but I want to try it out.

Tips for MySQL architects

Nice slideshow.

Response splitting

Nice to keep in mind (I can't think of any reasons why one would want to add user-generated data on a response header, though).

Deploying new UI is hard

Right, iGoogle?

Studies are most likely wrong

Here's a pretty good reason to doubt everything you think you know.

Sunday, October 19, 2008

Flashing of unstyled content

A clever way of fixing it using JQuery.

If all you need to do is display:none elements of a certain class, adding that one rule in a style tag inside of a <noscript> tag might be easier (though probably not as pretty).

Saturday, October 18, 2008

Instant docs for Java SDK

Here's a neat way of getting instant documentation on core java API:

  • Get SlickRun
  • Add a rule that launches your browser (for example "j" to launches Firefox)
  • Set the "Parameters" field to this:$W$&btnI=I%27m+Feeling+Lucky
  • Call SlickRun via WindowsKey+Q, type "j thread", or "j comparable", or whatever.
  • Works for all the classes I've tried so far :)

Friday, October 17, 2008

Some useful stuff about geolocation

For future reference:


I bet 10 bucks that the sponsored link on the top is spyware-ridden. Come on,

Coding vs reusing

Jeff Atwood just wrote about his never-ending HTML sanitization saga. The post is filled with napalm but brings an interesting point I was actually pondering to myself this morning.

Reinventing the wheel is usually considered a horrible practice, yes, but let's face it, great hackers reinvent the wheel all the time. Except they call it "reverse-engineering". Knowing what makes software tick is a crucial skill if you ever do any sort of meaningful debugging (i.e. troubleshooting that doesn't involve guesswork and praying).

Without having the sort of foundation that only comes from implementing an compiler from scratch, how could one hope to produce things like SquirrelFish? How would one even start to talk about a scalable comet infrastructure without having implemented a web server from scratch?

At the end of the day, code reuse may be a good coding practice, but it's a bad business idea for a developer as a skilled worker. Employers can find good code for free for just about everything nowadays; it's the experience and the knowledge about the caveats of the underlying technology that makes programmers valuable.

Thursday, October 16, 2008

Blog Action Day

Today is Blog Action Day. Theme: Poverty.

I don't know if it makes any sense to ask others to donate (considering we ourselves don't usually like to solicited), or even if donations are useful considering that many charities can take 50% or more of a donation for "administrative costs".

I'm not too familiar with tips on how to get out of poverty, but the "bottom up" approach here seems useful.

As far as what I've been taught, working and saving are, despite their lack of glamour, the surest way to get rich.

Wednesday, October 15, 2008

Yahoo on OpenID

So my opinion that OpenID authentication is completely awkward is now backed by some actual research from Yahoo.

One thing that I didn't know (and I use OpenID somewhat regularly), is that is apparently a valid OpenID. What in the world were the designers thinking?

Git justdoit --all &

I just spent half an hour trying to get a patch of a single character up on origin/next of a project, and by the love of god, look at how much I had to type:

git fetch
git co origin/next
git cob fix/123456
### did my one-character change ###
git cob fixdone/123456
git push origin fixdone/123456

git fetch
git co origin/next
git cob next
git merge origin/fixdone/123456
git push origin/next
git co origin/next

git b -D next
git b -D fix/123456
git b -D fixdone/123456

All of this for a one character patch!

Ok, I didn't really spend half an hour on this one task alone, but you get the point.

I'm not that familiar with git and bash, so I'm sure there must be a better way of doing this. Considering that in open-source software (and probably corporate ones too, for that matter), one-line changes are the most common type of patches, having to type all of this sounds unnecessarily complicated, no?

Crisis of faith

Geez, thanks a lot, Eliezer Yudkowsky, you got me thinking again. :)

I really like the idea of a made-up parallel universe, where we deliberately create a constraint that says our beliefs are wrong. I've had the habit of doing this parallel-universe-self-questioning for the longest time, but I never had a good way of sharing this concept with other people without scaring them off into their shells.

Saturday, October 11, 2008

5 ways to know if your business is any good

Down-to-earth list. The advices are pretty obvious, but you'd be surprised by how many people I know who don't follow these rules and keep failing miserably.

Friday, October 10, 2008

aaaah, the panic! the panic!


I got a investment marketing letter on my mail the other day. It said something along the lines of "make investment deposits monthly so that you get fewer shares when prices are up and more shares when prices are low".

I guess for a long term investment strategy, that makes sense, especially combined with portfolio diversification. The chances that everything in a portfolio is going to go bankrupt are pretty much zero, right?

Thursday, October 9, 2008

Soundest banking system

Nice to read some good news that relates to economy, for a change.

Smoking kills, apparently

Apparently, it increases the chances of heart disease, one of the biggest causes of deaths.

I don't know if they are trying to scare smokers into quitting. If that's what they are trying to do, perhaps just laughing at them for having to pay more taxes might work out better, since a large number of smokers are just kids looking for social acceptance (and we know that being buddy-buddy with the government is not exactly popular among these types of people).

Wednesday, October 8, 2008

We are all adults here, right?

I've been wondering for a while: why don't I see this style of OOP "private" variables too often in Javascript:

var MyClass = function() {}
MyClass.prototype = {
  __hello : "hello",
  __world : "world",
  sayHelloWorld : function() {
    return this.__hello + " " + this.__world;
  sayWorldHello : function() {
    return this.__world + " " + this.__hello;

It strikes me as an easier way to handle inheritance. For example, consider the traditional alternative:

var MyClass = function() {
  var hello = "hello"
  var world = "world"
  this.sayHelloWorld = function() {
    return hello + " " + world;
  this.sayWorldHello = function() {
    return world + " " + hello;

How do we extend this so that the private variable world always has a value of "world!!" (with exclamation marks)? How do I label it protected, instead of private?

Rather than engineering mechanisms to prevent people from editing our variables (which anyone with Notepad and your source file could do), wouldn't we benefit from having more value with less (but more "risky") code?

Hear your own gibberish

This is just plain awesome.

Monday, October 6, 2008

Control and superstitions


It seems that feeling that we're out of control is a bad thing: it tends to make us shift blame away from us, even when it makes no logical sense. And it seems it messes up our bodies too.

Saturday, October 4, 2008

Hello world in Scala and Jetty

I just started looking into Scala, which aside from the somewhat funky syntax, seems very expressive and powerful :)

For starters, this is a very good tutorial to get your feet wet.

Because a console "hello world" is too boring and easily googleable, I decided to try out the "easy Java interoperability" they tout, by trying to run a simple web server with it.

I started by grabbing a copy of Jetty (you'll just need the jetty.jar, jetty-util.jar and the servlet.jar, which are in the lib folder)

Next, I created the following folder structure:


Then, in the MyServer.scala file, I added following code:

import org.mortbay.jetty.Server
import org.mortbay.jetty.handler.DefaultHandler
import org.mortbay.jetty.handler.ResourceHandler
import org.mortbay.jetty.handler.ContextHandler

object MyServer {
 def main(args: Array[String]) {
  var server = new Server(8080)
  var fileHandler = new ResourceHandler()
  var defaultHandler = new DefaultHandler()

My run.bat file looks like this (note: you'll need to either setup the path, or point the second line to the bin folder in your scala copy):

@set file=MyServer
@set path=%PATH%;C:\\bin;
@set bin=../bin/
@set cp=%BIN%;%BIN%jetty.jar;%BIN%jetty-util.jar;%BIN%servlet.jar
@call scalac -d %BIN% -optimise -cp %CP% %FILE%.scala
@call scala -cp %CP% %FILE%

Now just write "Hello world" in your index.html file and point your browser to http://localhost:8080/index.html


Friday, October 3, 2008


Old school.

I was talking to a co-worker about this types of games. It's easy to think that creating a system that can auto-generate content is a MMORPG's pot of gold, but the hard part is to add unexpectedness to the equation: i.e. generate game logic challenges that match one's level of skill.

Intelligence vs God

Some genius decided to do a study on the correlation between IQ and the probability of being an atheist. To me, it sounds like a study on the correlation between elitism and elitism. Oh wait, they are the same thing.

I bet a 100 dollars none of the people who participated in the study put any thought into the fact that there are tons of definitions of God.

Flash games

So true.

Getters/Setters in IE8


Wednesday, October 1, 2008

Easy comet in PHP

Nice little hack. It probably doesn't scale, but it does perform long polling with just over 100 lines of code.


This looks useful: a performance measurement add-on to firebug.

Game programming in Scheme