Sorry if my post is jump from day to day (cause I have a lot to talk about).
Ok. On Monday, Tuesday and Wednesday, I was coding the puzzle game. On Thursday, after been stuck on how to check whether user's clicking on which tiles, I asked cs to help. He told me to try using event.currentTarget to check. Wow it works!! And I'm so happy! That's why I slowly loving programming. You can get stuck for days, but nothing beats the joy of getting the solution to the problem.
However, I'm still confused on how to check which tile is empty, and move the available tile into the empty slot..
Here's the code to find which tile the user's clicking on (maybe Auron might be interested).
I'm declaring a array called puzzle.
for (var i in puzzle)
{
if (puzzle[i] == event.currentTarget)
{
// coding here
}
}
ps: I hope this works cause I got the above code from my memory. =D
I got a chance to install some REAL STUFF on 25th November! It was my first time in poly life installing real programs! And not from hard disk and getting cracks for the registration code!
Since it's my first time, I took a picture of the box. (ya being lame here =D)
Tada~~~
Well, royal readers here will know that 26th November is my birthday. I've gotten quite "a few" presents from "friends and foes". First, thanks to the company who celebrated my birthday on last friday and presented me with vouchers. *LOLs* Secondly, thanks to the floor outside my house's lift for giving me a bruise on that day (yes I fell down and gotten a gift). Thirdly, thanks for that ferrari! Although I admit doors will be better (ahahaha).
Ok. Shall stop here. My post's being too messy already *laughs*. Shall blog again next week.
And Happy Hari Raya Haji!!