Thursday, September 8, 2011

YouTube Video and Dropdown menu

Having issues with YouTube video showing over you drop down menu.

Just add the parameter "?wmode=transparent" on the url of you YouTube iframe code and you all set.

Wednesday, October 6, 2010


A user can get badges on different category, once the user gets the badge they can post it on Facebook wall about the badge...

When user gets 15 words they get a pundit badge

When user finishes the category they get guru badge

Saturday, October 2, 2010

Chuya Fuchya-UI and UX

Size= 760x550px

One the game is loaded. The user a message and sees two options:
"See how good is you Nepali vocabulary"

a) Learn How to Play
b) Skip to Game

  1. Shows the first screen, where user needs to choose a category before they start "Begin Game". NEXT
  2. Shows the screen and how the game works. Focos on where word pops up and timer(30 sec timer which begins once the user clicks one of the letter) begins.
  3. Focus of Milk Bottle and tells how the milk increases or decreases based on the right or wrong letter selection.
  4. Focus on help button and show show it can give hint about the word. This will decrease 5 sec in timer..
  5. Shows about the setting where they can change the category and volume
  6. Gives options to post the score on Facebook and Challenge friends to beat the score.
User selects the category and "Begin Game" button activates.

Wednesday, September 1, 2010

Nepali Hangman V 2.0

Nepali Hangman works but it is too boring and too difficult. Hence the new version will be more fun and lot easier to work with.

NAME: Chuchaya Fuchaya
The name Nepali Hangman catchy but not fun. The new game name is ChucyaFuchaya, so far... . The game will work on the basic principle of Hangman.

GAME: How to
  • The game will follow the same principles of the hangman.
  • A random word will be populated and user has to guess the word. Instead of a hanging a man there will be a cute Nepali infant with a milk bottle on his side.
  • For every wrong letter the milk on the bottle will decrease and the infant will say something funny/stupid that will hurt the users intelligence, like "Ghada", "Pagi".. something in that line..
  • When the user get the correct letter the milk will increase but the infant won't appreciate and encourage the user.. instead it he will say something like, "not bad", "any fool can guess that".
  • If the user looses the game they baby will cry and say something really mean(but no swearing )
  • If the user wins the the infant will laugh and say something smart, probably show some appreciation...
The category should be something simple and interesting that is related to Nepali. Like shouldn't be Nepali movies as most of the user who uses Facebook probably don't watch Nepali movie. Cannot be Hindi movies.. as many user might know hindi movies it is not allowed. The game should have only Nepal related stuff..
  • Food: Foods from Himal to Teri
    1) Momo (of course)
    Aloo Tama
    Aloo Dum
    थेवे (मूलाको अचार)
    खल्पी (काँक्राको अचार)
    14) Danaura ( similar to sel but not circular)
    15) Anarsa ( nepalese homemade cookies with sabu dada toppings)
    16) Thekuwa(typical terai snack prepared specially in Chhat festival)
    17) Gojiya (dumpling style sweet snacks)
    18) Topi mathai ( Sahped like nepali cap)
    19) Nimki (diamond shaped salted snacks)
    20) Kasaar ( made of rice powder and gud paste)
    21) Aithe (Newar traditional)
    22) Guthpak
    23) Pustakari
    24) Yamari!!!!!
    25) Lakhamari!!!
    26) jeri swaari..
    27) halwaa puri
    28) eithyaa..
    29) nimki
    30) balbaaraa
    31) lhochaamari (ल्हों-चा मरी)

  • Place: Any district, state and popular village
  • Festival: Any festival that is popular all over nepal.
  • God: Definitely not all the 33 Koti names...
Feel free to add category or names

MEAN WORDS: Word that says you are stupid
1) Paji
2) Ghada
3) owloo

Saturday, July 31, 2010

removing duplicates from an array

I searched online to look for a decent algorithm to remove duplicate values from array but didn't get any thing that was successful. There were couple but none of them worked if you had multiple no of duplicates.

The following algorithm works despite the no of duplicates in an array. This method works for me as I needed a sorted array...

_array.sort(); // shorts the array so that all the similar values are together

var firstWord:String; // variable for the first word
var secondWord:String; //variable for the second word
for(var j:int =0; j<= _array.length-1; j++)
firstWord = _array[j];
secondWord = _array[j+1]; //trace("f: " + firstWord + " S: " + secondWord);

if(firstWord == secondWord) //if the first word and second word is similar
_array.splice(j+1,1); // remove the second word from array
j--; // decrease value of counter to recheck for same word

Thursday, July 15, 2010

Android on iPhone

I upgraded my iPhone to os 4.0 from os 3.1. It seemed pretty cool with multitask(kind of) functionality but later I realized that there is no reception. No, I am not talking about new iPhone 4.0 and its hardware issue. The one I have is iPhone 3G.

After few research I found out that iPhone 3G, jail broken with redSnow has the reception. The phone was pretty much useless as I wasn't able to make any phone calls from it. Then I did a little bit more research and found out that I can install Android on iPhone. So I decide to give it a try I had nothing to lose...

The software needed to install android on iPhone is called iphodroid. After few hours of trial and error I was finally able to install a stable version of Android on iPhone. When I installed it for the first time it wasn't responding to the touch. I uninstalled and reinstalled the Android it fixed the issue. The phone was all set to go.

Since it was the fist installation there wasn't even a single contact in my address book. I loged in to google and synced my contact. Since, my google account was synced with itunes all of my contacts was on my new phone.

It was kind of wired to use the phone for the first time because the buttons responded differently than iPhone but it didn't take long for me to figure out the functionality of the buttons. One the first thing that I noticed is that the touch response is kind of slow specially after using iPhone. The user interface isn't that intuitive specially due to the slow response to touch.

One of the main reason I tried Android on iPhone was because the ability to play Flac files via andless app. But it was no use because there was no way for me to upload the music files to the device. The andless app looks for SD to play the music which obesely is not iPhone. So it was no use at all.

Another thing I noticed that the device was running kind of hot and it was sucking all the juice. After continually using the phone for 1.5 hrs the battery was almost dead..

So, my recommandation is not to install Android on iPhone to replace iPhone os.. at least for now..

Monday, June 21, 2010

Notorious Tween and the Garbage Collector Issues

I love tween and use it a lot while making websites and applications. But whenever I use more than 3 tweens simultaneously it doesn't work properly. It works sometimes and sometimes it just freezes in the middle and any Event Listener that has been called is not triggered. Moreover it works on some computer and in some it doesn't.

Before I tell you how to fix it let me explain why it happens. Flash player runs GC (Garbage Collector) once it executes the script. It does this to free up the memory and enhance the performance. Now they way flash player runs the GC depends on the system resource. So if the users computer has less memory GC is triggered earlier and if the user runs the program on the same computer when more memory is available it triggers the GC little late.

Most of the time tween gets stuck if you have code like below where the tween time is different.

var a:Tween = new Tween(a_mc, "y", Back.easeIn, -75, 0, 1, true);
var bTween = new Tween(b_mc, "y", Back.easeIn, -75, 0, 2, true);
var c:Tween = new Tween(c_mc, "y", Back.easeIn, -75, 0, 3, true);
c.addEventListener(TweenEvent.MOTION_FINISH, loadThis);

function loadThis(e:TweenEvent):void
trace ("It's Loaded");

here the Flash Engine runs all the scripts at same time and when the first tween is finished the GC disables all the tweens. A better way to code is to change the starting "y" axis.

var a = new Tween(a_mc, "y", Back.easeIn, -95, 0, 1, true);
var b = new Tween(b_mc, "y", Back.easeIn, -85, 0, 1, true);
var c = new Tween(c_mc, "y", Back.easeIn, -75, 0, 1, true);

function loadThis(e:TweenEvent):void
trace ("It's Loaded");

this way, the tween finishes at the same time, the movie clips reaches the destination in different time like the previous code and have less change to effected by GC. Now, this is not the foolproof. It still gets stuck once in a while. This is the issue with Flash Player and there is not way out, for at least now. The issue gets even worse when functions are triggered based on the Event Listener.

To make sure that the functions are running even when the tween gets stuck we can create timer function. In this function we can run a conditional statement to check if the tween has completed and the event has triggered. Here is the code for that

var activated:Boolean;
var myTimer:Timer = new Timer(1010,1);

var a = new Tween(a_mc, "y", Back.easeIn, -95, 0, 1, true);
var b = new Tween(b_mc, "y", Back.easeIn, -85, 0, 1, true);
var c = new Tween(c_mc, "y", Back.easeIn, -75, 0, 1, true);

function loadThis(e:TweenEvent):void
activated = true;
trace ("It's Loaded");

myTimer.addEventListener(TimerEvent.TIMER, checkTween);

function checkTween(e:TimerEvent):void
if(activated == false)
trace("It's Loaded");
if(a_mc.y <=-1 || b_mc.y <=-1 || c_mc.y <=-1)
a_mc.y = b_mc.y = c_mc.y = 0;