A while ago i went to a course run by computer man Kevlin Henney. He mentioned a technique for looking at your code, and seeing whether you’ve been good about coding in your domain.
It involves using Wordle to generate a tag cloud of your source. The larger the tag is the more times you have used that word. If you are coding in the domain your domain concepts should be big and bold. If you are being imperative, you’ll have lots of syntax code in there.
The results are not pretty.
Clicky for full size
#1 – Keep your privates private! public is the biggest word on there so that probably isnt good mojo. I think there is some leeway here given that the Unity engine prefers publics – you can mess around with them in the inspector then
#2 – Try to have a look for domain words. I can spot a Wheel in the top, and a checkpoint to the right side. I suppose Vector3 is in the domain for a 3D engine
The total size of the scripted source came in surprisingly low, I guess this shows that you don’t have to do a massive amount of scripting to get a fantastic game wow amazing buy it on the appstore now this is the greatest game ive ever played in my entire life. this game is so amazing i am lost for words. out of unity. According to notepad++
Characters (no spaces):94421
Shortest nonblank line:1
How 2 do it
Its actually pretty simple.
1. First I cat’d together all of the *.cs files together using Cygwin:
find ./ -regex ".*\(cs\)$" | xargs cat > out.txt
2. Opened out.txt, copied it all and pasted into Wordle
3. Pressed Generate