ember.js evaluation

I am no expert on JavaScript or Ruby  by far, i have done most of my MVC work inside PHP space with CakePHP and ActionScript with Robotlegs. But it’s time for me to dive into the messy but exciting world of JavaScript frameworks. After reading allot about different frameworks i wanted something that resembles CakePHP in the sence that i could get model relations, helpers, easy of use and setup. Ember gives you all this since it’s very inspired by Rails. I knew from reading that the documentation of ember was really bad, things are moving fast in development with breaking changes but i thought to my self that it can’t be that bad, i can probably figure most of the things out. And i have… sort of.

Node

Everywhere you read today when it comes to JavaScript will most likely end up referring you to nodejs. Node is the next big thing in the JavaScript community and everything now is installed with npm install {package}. Don’t get me wrong, i really like Node but it gets really confusing as to how applications are meant to be used when every other framework comes with it’s own web server built in. I am trying to develop an application that will reside inside a CakePHP platform so there will be the standard Apache web server that i know and can trust for a production ready application. This does not apply as much for ember but the only way i could really make good use of ember without learning rails is to use a project called ember-runner for compiling my files or simply write the whole application in a single file. The single file approach was a non-option for me so i went with ember-runner.

Todo examples

The second confusing obstical in choosing JavaScript framework is the lack of good example applications, most frameworks has a simple todo application example witch is nice to quickly compare different frameworks but really not helpful in deciding what to use when building bigger and more complex applications.

API

Ember is really nice in theory but the API is quite confusing and it’s hard to know if you are following a good standard way of doing things when you write your code.

Rails

When you start looking around for help on how to use ember most of the example is built with ruby on rails in mind. Of course it’s possible to build ember applications for other platforms as well but very annoying to sort out all the rails talk.

Never underestimate JavaScript again

From this small initial phase of learning how to better write good JavaScript software i must admit that i underestimated the things that JavaScript can do. The power that node, html5 api, webgl, svg etc has brought this community is extremely impressive and today mostly anything could theoretically be written as an application for the browser (or the desktop) with all the code being JavaScript. And why the hell not! many other languages lives inside their virtual spaces like python, java, flash etc and why shouldn’t you be able to do the same things with JavaScript. Together with node you could even write an application for the desktop with frameworks like appjs and communicate with desktop hardware like a joystick. Someone even wrote an Nintendo 64 emulator in JavaScript.

Summary

The biggest problem with Ember is the breaking changes for now, this framework simply isn’t ready for production purpose yet. This post is just a bit of ranting on my part and  nothing really constructive or gathered so please ignore everything you have read so far.

After posting this i was given a really good article on ember http://trek.github.com/

I wish i was born a python baby

Python is a very sexy language right now, and with that sexiness there comes CoffeeScript that seems to have gather quite the support among JavaScript frameworks. Just look at this cute things: batman, derby, chaplin, tower etc… The grass is always greener on the other side i guess.

The thing is i really like the syntax without allot of unneeded encapsulation and everything looking quite neat, but my old ActionScript brain keeps writing out ; at the end of everything. Why oh why did i bet on a dying horse…

Reprisal

Recently found out about this awesome little indie game made with flash that is very similar to an old classic; populous. Populous is very close to the heart as it’s one of the first games i played back in the days that we only had an old Atari ST.

Reprisal lets you take control of a tribe, guiding them, building land and making them grow in number. Using special totem powers you can control nature itself unleashing its full fury on anyone that stands in your way.

The design is very minimalistic and with greate attention to detail in color and layout. I wished though that it had some kind of multiplayer capability.

http://www.reprisaluniverse.com/site/

ActionScript development on Mac

I’m planing on starting up some small game projects in Flash using either actionscript or haxe with all open source softwares, just to look at the possibilities of doing interactive flash things using this tools.  It looks to be a bunch of different ways of compiling and making this possible but i have a hard time getting going because i can’t seem to find a good IDE to start development in. I currently use Eclipse with Flex plugin for work but is very unpleased with this solution and since this Flex plugin is a commercial product it’s not really what I’m looking for.

The closest thing Ive come across for mac is using MacVim with plugins, i have been trying all kinds of syntax plugins, omni-completion plugins (no auto-completion plugin available) but nothing seems to work, the syntax plugins Ive tried gets weird results in most of the files Ive loaded, omni-completion is just not working no matter how many times i press CTRL-X or CMD-X. MacVim looks really nice but it also looks like it would be a lot of hard work just getting to know the editor.

I have known about FlexBean for NetBeans witch is my IDE of choice, there is also nbflex and flex-bean but development for all of this projects seem to have halted.

Does anyone out there know of a good IDE for developing actionscript on mac? what are people using?

MilkyTracker

There is just something about me that makes me so happy every time i find something extremely nerdy that i can tinker around with, and today i was looking for an easy way to make music the chiptune way and i came across MilkyTracker, i cant say that its easy to understand everything that is happening on the tiny screen, but it feels like it can be something one could learn in a couple of days with enough time on ones hands.

MilkyTracker.png

Streaming content from Mac to Xbox360

This post is very old but i think the technique still works, but i recommend using MacPorts over DarwinPort.

This weekend i was having trouble finding out a good and easy way to stream video from my mac computer to my xbox360, i needed to do this because xbox360 for some reason wont accept the HFS partition on my external drive because i made the partition inside Mac OS using DiskUtility, so i figured why not try to go back to streaming content the way i used to do in the past.

The trouble then was to find a good software that would alow streaming, i first tried to use XBMC which has a build in UPnP server, but the Xbox360 wont recognize and list that one for some weird reason. Then i remember that i used to have a small software called uShare on my old linux system, and i looked it up and it turns out that there is a port available for this software using DarwinPorts. I decided to give it a try and the installation was pritty much straightforward.

After you have installed DarwinPorts to your system you just run the following command:

sudo port install ushare

and after that you get a sample config in /opt/local/etc/ushare.conf.sample so just make a copy from this to the same directory with the name ushare.conf:

sudo cp /opt/local/etc/ushare.conf.sample /opt/local/etc/ushare.conf

now we need to edit some things inside this config file, i personaly like using nano for editing. for this you need first to install nano..

sudo port install nano
sudo nano /opt/local/etc/ushare.conf

The config is kind of self explanatory, but when it comes to setting up which the network interface you need to write en0 or en1 instead of eth1,eth0 just run the command:

ifconfig

and you can see what interface you are going to run, on my MacBook Pro i use en1 because that is the wireless connection. In the bottom of the config you will find a line that sais ENABLE_XBOX=, this should be set to yes obviously but also this needs to be changed to:

USHARE_ENABLE_XBOX=yes

If you don’t know which path to enter this is how you add your default Movies directory on the mac:

USHARE_DIR=/Users/username/Movies