Jul 6, 2012

Diablo3 and Endgame.

I see a lot of posts about Diablo 3 endgame all over. Recently Blizzard itself admitted that they are going wrong. Many such discussions and rants are on the internet, and I am adding my own as I am totally disillusioned with the crap game that is Diabo 3.

My thoughts on this is that Diablo 3 is not a game with end game. It never was. Will never be. It is not a World of Warcraft that there are end game stuff that has to be done as a progression. You kill Diablo and thats it.

However, that is not the reason for disliking D3. There are other problems with the game.

I think that the main one is that the game is too short. Playing the normal mode and you can actually finish off in just a day. And that when you are not even a pro gamer. I finished in 2 days as i had a lot of household chores in between. That is too short for a game you pay $60/SGD$90 for. Granted that you play higher difficulty levels, but the game lenght is just nuts. I dont remember completing D2 or D1 in a weekend. Also, Blizzard somehow has the nutty idea that getting killed more leading to a longer time in the game is fun!

Next, I would say is the randomizations of the maps is pathetic. The maps are just too small and there is really no visible randomizations. You always know where the exit to the map is. So, replayability is shit - and this coming from a game which touts replayability as its biggest unique selling point. A few events here and there are all that is new in each run.

The monster randomizations on the otherhand are overdone. With monster packs being tougher and you add random monds to them, which in some combinations are just unplayable takes away the fun from the game.

My 2 cents. What are your thoughts ?

Installing a custom Android ROM

Android is a phone operating system found on most smartphones now. It is developed by Google, and mostly used by manufacturers like Samsung, Motorola, HTC in their phones. Android is evolving at a very fast rate, and almost every year there is a new version available. However, most manufacturers do not support updating the phone OS. What happens is that you are left with older versions of the OS on the phone, while the world is moving ahead.

e.g. I have a Samsung Galaxy Ace with OS version 2.3 ( Ginger Bread) while the latest version available is 4.0 ( Ice Cream Sandwich ) while 4.1 (Jelly Beans ) has just been announced.Samsung is not supporting anything more than 2.3 citing hardware limitations.

The option is to get a custom ROM for your phone. These are not supported by the manufacturers and according to them, if you use the ROMs - you void your warranty. However, I find that not using these ROMs will significantly lower the usability of the phones.

Custom ROMs are specific to your phone. So first you need to find out whether your phone is supported. The two most popular sites are :
1. Cyanogenmod ( phone list )
2. Miui ( phone list)

If your phone is on the above list, you are quite in luck and the process will be straight forward. However, if your is not, then you will have to search a bit. The best place I have found for searching is Youtube ! You will find a video of how to install the custom ROM as well as links to downloading the custom rom. e.g. I have a Samsung Galaxy Ace, which is not on the main sites, but a derivative was found on http://www.themythace.com/index.html website.


The Install Process


Installation of the ROMs is quite easy and step by step process, though you will keep holding your breath to see if it works or not.

There are 2 pieces of software that you need to download.
1. ClockWork Recovery Mode ( CWM) for your device.
2. The ROM for your device.

Download both of these using the computer and put them on your device's SD card.

Below are generic steps to follow - you should check the instructions for installing from the respective sites for your specific device in case it differs.

Make sure your phone is fully charged!

Step 1: Take a backup of your data. Mostly you would want to backup sms, photos, contact numbers, etc. If the data is on the SD card ( e.g. photos are on SD card) you do not need to worry. But anything on the phone memory will need to be backedup if you want to use it later.
Step 2: Copy the CWM and ROM zip files to your SD card using the computer.
Step 3: Now you need to first install CWM. This is done by going into the recoverymode ( usually home + power buttons), chosing to update from SD Card, and using the CWM zip file . See youtube videos on how this is done.
Step 4: Reboot again into recovery mode. Now the recovery mode is using CWM and you will see more options.
Step 5: Reset the data and the cache. This will wipe your phone totally, and hence the requirement of Step1 to take backup of your data.
Step 6: Once this is done, it is advisable to just reboot again into recoverymode.
Step 7: Now in the menu, go to install zip from SD card and select the custom ROM zip you have. This will start the process and you may have to wait from anything between 2 mins to 10 mins to startup. Usually first boot takes time.

There you go, your new OS is ready to rock and roll !
MIUI running ICS on Galaxy ACE


Leave any questions/comments below.

Jun 12, 2012

Apple WWDC '12

Last night Apple again sent the world buzzing with their list of updates. I just finished watching the Keynote and here are my impressions:

  • Siri on the iPad. 
    • I totally nailed it. I had predicted that siri will come but only on the newer iPads and owners of iPad2 and below would be left cold - I was right. 
    • I also dont think Siri is coming to India anytime soon.
      • However, since there were so many references to India in the presentation ( the video of kids, the pdf he dragged to the folder) that I think Apple has started thinking of India. 
      • I wonder where they will open their first stores in ?
  • The retina display macbooks were mind blowing. 
    • There had been a lot of talk about how retina display could not be done for bigger screens. Even Intel wrongly predicted that retina display on laptops will be available by 2013 - a year too late !
    • It also has SSD ( Flash drives ) which is pure yummy! 
    • Unfortunately, there was another shocker - the price. Today, I just did a quick check on the cost of a fully loaded MacBook Pro, and oh boy - that kind of cost will burn out your pocket. Screenshot below with the cost. This device is going to remain a dream for now. 
 
Cost of a fully loaded Retina display MacBook Pro
  • Dictation as a feature - hmm. lets see how this works. 
    • There are some big flaws with dication or Speech to Text. I will wait and see if these are going to be addressed by Apple.
      • They dont really work well in noisy locations. 
      • In quiet location, they dont pick up the accent unless you speak with a nasally American accent.
  • Facebook integration etc is meh. I don't really like the twitter integration in iOS5 as it is quite limited, and also as I cannot share with any other service. Android does this part really well - and I hope one day iOS will be able to. So, untill iOS6 is rolled out, I will reserve my judgement here. 
  • Game Center is a big Game Changer (forgive me the pun!)
    • When the WWDC was going on, i was chatting with my friend and lamenting about the lack of the gaming scene on macs. This is going to change drastically with the game and GL SDK that apple is now providing. 
      • They probably showed Diablo3 as that is one of the few new high end games that run on the MacOS. 
    • It allows users to play across apple devices - which to me is a big deal. You can play on the mac with your friend who is on an iPhone. Superb ! That is if you are into casual gaming. I am still leery about high end games.
    • I really want to see some good mainstream games being made for the mac and at a lower cost. Hope to see this happening now with Apple's focus on GameCenter.
  • Notification Centre... oh how I want that ! 
    • One of the neatest new feature is the notification center. After being used to notifications on Android and iOS devices, I was always wondering when it will come to mainstream computing. Windows 8 has some concept of it I think , but Apple has totally nailed it. 
      • Ramblings : I wonder when this feature will be coming to Linux or will I have to code it myself ?
  • The apps for blind people and autistic children was amazing. I wish other manufacturers also highlight how they are helping in these spheres. 
  • I feel really sorry for the people who bought the old macs in the last month or so. They will get the new OS , but stuck with the older hardware. :P
  • Maps ! 
    • Now Apple is having their own maps. Does this mean that their deal with Google has run its course ? I see this as another attack at Google. 
    • The 3D mode is spectacular. Google has just got a jab to wake up and make their maps better. Fortunately for Google, the apple maps is so far limited to the apple devices. 
Looks like someone liked SimCity a lot in Apple ! The Flyover mode renders buildings in 3d with textures!
  •  Passbook did not make much sense to me as I do not know how those will work. Are those applications even available in India ?
  • Incoming phone and reminders. 
    • Android OS 4 is coming up with quick replies for common replies when you get a call you cannot take at that moment. However, the killer stuff in iOS is the "Remind me when I leave". This will basically pop a reminder of the missed call when you leave that location - this is an awesome feature to have ! 
    • Additionally for the phone - the "Do Not Disturb" feature is what I have been dreaming about for a long long while. I have been woken up too many times at night due to some email pinging. These small things, the attention to detail is what makes people fans of Apple. 
  • Meh about Safari
    • A lot of screentime was spent on Safari. To me that browser is not that great. Sure a lot of mobile traffic uses it - but that is because it is the default browser on the device. This is the IE of iOS world. Just because it is there does not mean it is great. 

Next year I hope to see a list of 'Great new features for India'... but I doubt it will happen. 

Apr 1, 2012

Developing Django app on both Windows and Linux

I was doing most of my development on Linux so far. My desktop is dual boot, so I can log into linux or Windows at whim. This is a small inconvenience. However the bigger problem is when I am travelling as my laptop is by necessity a Windows one. This problem occupied my mind this weekend and the following is how I am getting it to work.

First I used dropbox (in case you want dropbox, please drop me a line as referrals get me more space :) ) and installed on both Windows and Linux. Next step was to move the folder where I was developing into Dropbox. This helps immensely as I dont have to worry while travelling and my code is always replicated into the 3 locations that I work in.

Next I setup git - this is an optional step for you, but I found that it helps that even on my local projects I have version system to go and look back at what changes I have made.

Now the things were working on Linux ( you can look at my earlier posts about the other problems that I had ), so I logged into windows and tried to work out the problems.

On Windows to use Django I use Bitnami Django Stack. It is quite quick and painless to use. The only problem is that the mysql install does not allow you to have root password to have special characters - which is quite common for me. The work around is to install with normal password and then start the django stack and use the mysqladmin to change the root password. I went through all this because I use root for django settings. Yeah, I know i should change it - and will probably do later when I am ready to deploy.

Next on the Bitnami shell do a syncdb and runserver.

On navigating to the http://127.0.0.1:8000 URL, I got a template not found error for index.html

Looking at the settings.py file I found the culprit immediately. The settings for Dirs was very linux specific


TEMPLATE_DIRS = (
"/home/vibhu/website/templates",
)

Same was for the STATIC_DIRS settings.

The solution to this is not to replace it with windows directory as that will just mean that when I log into linux I will again get the problem and have to change back. Searching through the django site and internet I finally got the right solution ( some books have it wrong and the examples were not working). The following seems to work for me:

Edit the settings.py file with the following somewhere at the top



#hack to accomodate Windows
import os
CURRENT_PATH=os.path.abspath(os.path.dirname(__file__))



And then in the relevant sections change the path lines :


STATICFILES_DIRS = (
os.path.join(CURRENT_PATH,'static'),
)
TEMPLATE_DIRS = (
os.path.join(CURRENT_PATH,'templates'),
)



Make sure that you have the trailing comma else the admin login view gets screwed.

Simple enough when you know it.

Mar 28, 2012

Login URLs in Django

Django is a pain.

I know - its a great framework. Its also supposed to be robust and highly recommended by a few friends when I asked around for what should I use as I wanted to learn how to develop a website.

I have been dilly-dallying with making the website for quite some time, but now I am trying to put in a few hrs every week into it. I enjoy it so far... but then I run into some stupid roadblock.

Today I ran into another one. If I do not document it, I am sure that I will make the same mistakes again.

Today's problem was with the login redirect URL.

I have a function with the decorator as follows :

@login_required
def foo(request, template_name="foo.html"):
    return render_to_response(template_name,locals(),context_instance=RequestContext(request))

I changed the default account redirect to /account so my urls.py has the following:
    (r'^account/', include('account.urls')),

Now, when I tried to click on the link which requires the login ( and I am not logged in) I got the following error :

The current URL, accounts/login/, didn't match any of these.

See the s in accounts. I tried searching everywhere where I had the accounts word. grep did not turn up anything and I was quite frustrated.

Finally, I reasoned that it has to be something with the way django does anything and started reading the settings documentation. Sure enough, @login_required requires a url which defaults to /accounts/login !

Why the Django documentation has to be so vague with login is something I don't understand.

So, I added the following lines in the settings.py :
LOGIN_URL='/account/login/'

Not it works !

Gah !

Mar 23, 2012

Lvl 25 Indian Guild in World of Warcraft

This is good news !



Most of my readers would know that I play World of Warcraft. Well, I used to - till a few months back when work became overwhelming to really put in enough time in the game.

When I had started playing Wow in 2006, I was always looking for people from India. I found people from far away places like Brazil but no Indians. Then I started a google group and got a few people in it.

At the end of 2010 I started a guild with the people there after a particularly bad day in office. I named it 'Vinash'. We got the guild to a good start with Indian people joining in. Unfortunately we had a couple of real bad eggs who wanted to run the guild and I was not really Guild Leader material. Sad to say that guild disintegrated.

Enter Sumantho who rolled a new Guild. Since I was on the google group and the facebook group I got excited about it and joined it. The guild got more and more people. It was originally rolled on the horde side on Skullcrusher, called Astra, and I rolled a Paladin figuring that I would make a Tank, and levelled him to 85. Turned out, I made a lousy tank :D

Sometime in between, people decided to move to servers in Oceania as the ones in US , due to the distance of the continents , were not giving good latency numbers. Another factor was that on SK we were just not enough people and getting random people to PUG with us was not happening. So different servers were being checked out for people availability and AH prices. Also, the main people were kinda wanting to go Alliance ( me too ). We had some late night calls over this and ultimately a decision was taken to move to Frostmourne and do a faction change. The guild was named Yuva. I moved my Shaman over to the server and being a healer was gearing it up till work and life caught up. After a month of hardly playing I had to sadly stop playing.

But I continued trolling the facebook group.

Then yesterday it got posted that the guild had levelled up to 25 (the max level as of now in WoW). Felt good. Kudos to the team - Brats, Purva, Bobby, and all the others. GG.

Mar 15, 2012

Redmine Ubuntu Installation Error

One of the most amazing software tools that I have found which meet almost all my needs in the day to day working is Redmine (hard to convince people in the office though). However I ran into a problem recently which seems to be quite prevalent going by the searches thrown up.

Cannot start Ruby on Rails application
The directory "/usr/share" does not appear to be a valid Ruby on Rails application root.

Mar 5, 2012

Earthquake Delhi

Delhi had a tremor in Sep last week and had another one today. People got something to gossip and tweet about. 

Today's earthquake measured 5.2 on the Richter Scale and lasted a few seconds but was enough to get people to run out of their offices. For my part, I did not even feel it and was oblivious to it until I got asked by someone. Thats when I got to know about the quake and checked out the news channels - including facebook and twitter. 

This was a small quake. 

I am scared if a big quake came. 

For comparison, the Latur Earthquake in 1993 was 6.2 , and the more recent Haiti earthquake was 7. 

Delhi falls in Zone IV. If , Delhi was to ever get a high intensity earthquake which lasted more than a few seconds, the city is going to see massive destruction. Most of the city is made up of shanties with no proper planning going into making of houses. People point at Old Delhi and say it will collapse, I think most of the modern Delhi will also collapse. 

The picture I see in my mind is quite grim.
  • Most of the water piping is old piping. It does not need an earthquake to break those pipes and every few months we see news reports of a broken pipe flooding a road in some part of Delhi. These will all happen on the same day. The basic necessity of life will not be available. 
  • Electricity will be the other big hit. People in many parts of the city steal electricity by hooking the overhead lines. Just raise your head above the streetline in any congested locality and you can see the messy mesh of wires. Sparking will cause massive blackouts and fires in most parts of the city. 
  • Houses constructed dont follow the guidelines laid down for earthquake safety. In Many places you have a large area of slums. These will all collapse.
At all this, there is hardly any disaster plan in place. Delhi had a mock earthquake drill a few weeks back - but that assumes that people in Delhi will help out the people in Delhi. There is no plan for getting aid from other parts of the country into Delhi. 

All in all, if this becomes a reality - we are in Deep Shit. 

Feb 10, 2012

Hindi on an Android Phone

This is just an app I am developing on the side. It uses Devanagari scripts to render the text, rather than displaying images as most of the similar apps in the Android Markets do.

Part 1 of the problem was how to load the hindi font in the code and get the display to render it. If you try this on a phone without Hindi support - which is the vast majority of the phones out there, then all you see is squares instead of the text.



This was pretty simple. If you want to load a custom font, this is what you do :


  1. Get the specific font you want to bundle with your application. Lets call it Hindi.ttf
  2. Put it in your project under the "assets/fonts" folder. You will need to create the folder 'fonts'. Not necessary to have the exact name, but I use it as it denotes what the files int the folder are. 
  3. Now you need to tweak your code a bit as you need to load the font before you render the text. This is quite simple - use something like the following :


//Font work
Typeface tf = Typeface.createFromAsset(getAssets(), "fonts/Hindi.ttf");
// Get the UI element handles
mText = (TextView)findViewById(R.id.body_text);
// Set the title and read the file for the text
mText.setText(readRawTxt(pName));
mText.setMovementMethod(new ScrollingMovementMethod());
mText.setTypeface(tf); // setting font for the text. 
 Now when you run the program, you will get the fonts loaded and rendered, which brings use to Part 2 of the problem.

Part 2 of the problem is that the maatras are not getting aligned properly. For this I have so far not been able to figure out how to fix it. If you know , let me know. If I get to know about it, I will update this post.



Tips on purchasing an Android Phone

Here are some tips which I think you may find useful when you are looking to buy an Android phone.

Unlike the iPhone , the Android mobile space has a huge number of variants, which is good and bad at the same time. Good - cause you get variety ( though the current designs all seem to be very similar) , and Bad as you cant figure out what to buy !

My tips below will be looking beyond the advertized features of the phone. So, you will have to read the specifications of the phone you are trying to get and see if it fits for you!

Tip#0 : Wait for ICS

ICS is the next version of Android ( Version 4.0 ) but it is still not available in the market. So, if you can wait then wait for the phones with the new versions to be available.

Android 4.0


Tip#1 : Check for available custom ROMs

When you buy an Android phone from a manufacturer, you will end up with a system with a lot of customizations from the manufacturer. Its like how you go and buy a laptop and get all the preinstalled software. Now, you may actually want this, in which case you can ignore this tip. But, you may also be thinking that this is a lot of bloatware. Not only does it reduce the amount of space that you have available in the phone, it also causes your battery to drain much faster and slows down the phone.

So, have a look at the mods available in the market. I used the Cyanogenmod for installing onto my phone:

Samsung Galaxy ACE running CyanogenMOD7


Some sites you can refer to :
1. Cyanogenmod
2. MIUI
3. XDA Developers

Please note : by flashing the new OS you will void any guarantee from the manufacturer and also you have a risk of bricking your phone. Take all backups and then take them again. Use recovery mechanisms to take backup of the actual OS.

Tip#2 : Check the battery

Don't go by the claims from the manufacturers about the uptime. Its usually by turning off all the features and on a stock device. It falls flat on the face in actual use - the gap is quite large. The one thing you can do now is to look at the mAh rating on the device. Minimally it should be above 1500mAh for lasting around a day. The more the better it is.

Tip#3 : Check the internal memory

The advertisements will be pointing out that you can get upto 32GB of memory by using a SD Card. Ignore that. It is true, but it is not what you are looking at. You are looking at the internal memory present on the device. Look for things which are atleast 2 GB if not more.

Why ? Because most of the apps to function properly need to use the internal memory. Some can function only if they are installed in that part ( e.g. enterprise software ) and almost all require the memory to store user related data. The external SD card is where you store the pictures/videos/songs etc  ( and can move some apps to that area also)

Tip#4 : Now look at other specs
Now you are free to look at the other specs that are available on the phone which you may like. But if you neglect the above 4 tips, i am pretty sure you will end up wishing you hadn't.


Feb 5, 2012

Hard Re-setting Galaxy Ace

Recently, I had a bit of a problem with my phone - the Samsung Galaxy Ace. Apart from being pretty annoyed with Samsung for giving next to no internal memory (150MB only), the phone was eating up battery quite fast and becoming quite slow. So , I decided to hard reset it. Problem is - the information about android phones is too much in plenty and scattered all over the blogs. So, here are the ways you can do it:

1. Enter Recovery Mode
Press the home key and the power key simultaneously. 
When you see the Samsung logo , let go and you get into recovery mode.

2. From the dial pad
Enter the following key strokes:
*2767*3855#

3. From the phone itself.
Go to settings->Privacy Settings -> Factory data reset