Sunday, April 22, 2012

Roman Numerals Kata revisited

More than a year ago I wrote a post and recorded a video about the Roman Numerals Kata. To be honest I haven't been doing many katas lately but as I've had this weekend for myself, I went back and revisited the Kata, in JavaScript this time. And also recorded a video:



I am not really sure about how my coding has changed in the last year. There's no doubt that JavaScript uses a very different philosophy to Java, and I'm a lot more confident writing JavaScript now, but other than that, not much seems to have changed.

The only common pattern I see is that TDD is really helpful. In both screencasts you can see me doing something wrong (mixing up symbols last year, and forgetting to set the main function for immediate invocation this year, for instance) and only by having tests failing I realised that they were problems. It really saves you time if you don't have to deploy your code and play around with it to see what you've broken. Also, being the first user of your own code allows you to put a bit of thought in your design.

In this version I was not interested about recursion or Maps in Java, and I decided to skip the outer BDD layer (although Jasmine would allow me to do so). What was more interesting was to go through the different Module pattern incarnations in JavaScript, and using jasmine-node from the command line, although the --autotest option keeps crashing on me so I cannot use it! I am not the biggest fan of autotest utilities but for these kind of deliberate practice they are actually quite nice.

Thursday, March 8, 2012

A read-only API for P2PU

I've been part of the P2PU community for a good while now, and have organised a couple of groups within their platform so I thought it was about time to give back. On top of that, they use Python and Django, two pieces of technology that up to a month ago or so were completely unknown to me and I have always wanted to learn. Not that  I know all that much about them right now, but there's nothing better for learning than using the tools in a real context and within a real project, so that is exactly what I've been doing for the last couple of weeks. #opensource_ftw!

After an initial proof of concept using tastypie, as recommended by the chaps in the python.ie mailing list, I have started to work on it a bit more seriously and it will hopefully soon enough be reviewed and merged with the main Lernanta codebase. My fork of Lernanta has an API branch where you can find all the code to date.


And you might be wondering... why am I telling you all this? Because I could do with some help! If you want to learn not only Python and Django but aslo about RESTful architecture and web services do not hesitate in joining me.

Illustration by @alisonjeancole


You can also have a look at the blog post in the main P2PU blog.

Sunday, February 26, 2012

Dublin GameCraft 2012

I spent the day with more than 100 game developers and designers yesterday at Dublin GameCraft. It was a lot of fun and although Donall and I didn't really submit our entry for any prizes, we recorded a short video of what we got up to, and here it is:



The topic of the day was: Dinosaur Angst, and as you can see, our dino was pretty angry! Our half baked game was based on OpenSimulator, using stuff we found in the web and LSL. Certainly not the best platform for good gameplay for a shooter, but it was fun to make, the atmosphere in the place was awesome, and have met some really nice people so that's what I call a great day!

Thursday, January 19, 2012

Open Wonderland - Best View proposed changes

Best View is about the most useful capability ever! It works great with objects with an aspect ratio very similar to your screen, but it's not as good with wider objects such as a cardwall.

You can see what I mean in the following video:



So scratching an itch, I've been working on a patch to add functionality to the capability so that you can focus on certain parts of the object. The key modifiers I'm proposing are:

Mouse wheel = zoom in and out
alt + Mouse wheel = move left and right
alt + crtl + Mouse wheel = move up and down

UPDATE
The keys to be used now are:

Mouse wheel = zoom in and out
ctrl + Mouse wheel = move left and right
ctrl + shift + Mouse wheel = move up and down


The mouse wheel effect also works with trackpads and Mac mouse devices by just sliding a finger as if you had a real wheel.

The patch has not been reviewed yet but if you want to give it a go, I have sent it to the mailing list, and I would appreciate any testing and feedback. Just take into account that it might be rejected.

Wednesday, January 11, 2012

New Year, New Wonderland Project

Another year begins and so does another Wonderland Wednesday Project. This time we have decided to improve the telepointer module that is already part of the wonderland-modules project.

The current telepointer has a bit of a weird shape and it's a 3D object. I personally cannot think of the benefits of a 3D pointer as compared to a 2D one… sounds the same to me!
The user name renders on top of the pointer in billboard mode, and that makes parts of the word disappear depending on the surface that the pointer is held against. So the first 2 tasks we will go for first are to change the appearance to a more regular 2D shape, and more importantly, to make it work when you take control of a 2D app.

This module is a good example of a Wonderland Component or Capability. In this case, instead of being available to attach to any object in world, it is programmatically attached to all avatars through a server plugin. A nice example if you want to see how to do such a thing.

We will be working on this again on Wednesday the 18th of January so feel free to pop along to the community server at 1p.m. EST or 6p.m. here in Dublin.

Saturday, December 31, 2011

bye 2011

it's the end of the year, an absolutely fantastic one, which in my case it's been focused on learning, especially with others.

I started the year attending more local meetups than ever, and it has proved a fantastic source of experience and learnings. I have enjoyed very much the local Irish and Dublin groups, and all the other stuff we have organised such as hacking evenings and code retreats.

Probably the most intense experience of the year were the code retreats. Participating, organising, or facilitating, it's an experience that I wouldn't let pass you given a chance if you have not experienced it yet.
I also have to mention the great time I had attending the TDD courses in Madrid for XPWeek. Carlos is a fantastic coach and the courses were really enjoyable.

It has also been a great year 'online' with all the projects we've done with Open Wonderland, and I'm hoping to have more time for it in the new year.

The most important event of the year, personally, was leaving work a couple of weeks ago. After four fantastic years working for TCD I have decided to take a break, focus on my PhD for a couple of months, and see what life has in store for me after that.

Hope you all have a fantastic 2012!

Sunday, November 20, 2011

Open Wonderland and Google Docs Proof of Concept

I have been very quiet for the last while but as my work load eases out I've had some time to mess about with Open Wonderland again.

This time I've spent a couple of hours putting together a proof of concept (POC) to send information to Google Docs from inworld. In the following video you can see how a word processor document is created from an in world HUD.



The module is very rough and has only been thought of as a proof but if you want to check it out feel free to do so. As usual my code is in github: Proof of Concept for Google Docs and Open Wonderland Integration.

I have to say that the Google Data API has its quirks, although I have only spent a couple of hours using it, but it seems to be solid enough to create powerful client applications.

Any feedback is very welcome as usual!