Thursday, December 19, 2013

Developing a flash game 04

Hi there guys...

Adding tile maps to the game wasn't that hard. In the demo below, the map is stored as a text file. This file is interpreted by the game, and all the tiles are then drawn on an image that is the same size of the game. Next the tile map is placed on top of the background. Right now 4 tiles are defined: empty, grass, rocks, and bricks. The interaction between the character and the tiles has not been implemented yet.

Wednesday, December 18, 2013

Developing a flash game 03

Hi there guys...

I just finished adding acceleration to the character and gravity. To test that use left,right, and up buttons:

Tuesday, December 17, 2013

Developing a flash game 02

Hi there guys...

I just finished writing the class that collects user input. Now you could use left and right arrow keys to move the characters left or right. Check it out down here:

Sunday, December 15, 2013

Developing a flash game 01

Hi there...

Recently I found a free flash development tool called FlashDevelop. So I decided to give it a try and learn a little bit about Flash and ActionScript3. Working with flash is kind of easy, so I decided to rewrite the game for flash. I won't dedicate much time to it, instead I will post small builds on the blog. When the game get finished I will put it on the site. For now all I did was creating the main character moving in front of a background.

Over time I hope I could make something that people enjoy and have fun with.

Thanks for reading and have a nice day.

Wednesday, September 25, 2013

Dear math teacher, I hate you...

Warning: This post has nothing to do with programming, you won't learn any valuable thing from it. 

The other day, something reminded me of my study in primary school. One of the things that I used to hear is something that could be translated as follows: "Whomever taught me a letter, owns me as his slave". The goal of this saying is to emphasize the role of the teacher and how important what he is doing. However although I agree that a teachers should be respected, I would say that respect goes to the ones who deserve it. The story is about my encounters with a teacher who in my opinion does not deserve that respect.

That teacher used to give us two classes, math, and geography. I remember his math class starts as follows:

At the very morning, you must answer three multiplication questions, such as 8 x 7, 9 x 4, ... etc. You get about 3 seconds to answer each question. Now if you can't answer two questions, then you stand in front of the class with other students who did not answer.

The math class was the very first class in the morning, so it used to be kind of cold then. So hitting the hands with a wooden stick while its cold  really hurt. Not to mention, a hit on the fingers hurts more than the palm of the hand, I am not sure though if it was in his intention to hit the fingers and cause more pain.

Sometimes the punishment is different, for example he could hold two students high from the hair near the ear, which is in itself painful, then he would - collide/smash - the heads of the students with one another. I suppose, he was creative in torchering students, don't you think?

In other cases a slap on the face is used. I remember a specific geography class very well. It was the last class in the day. I am not sure what the reason was, but I think something upset him that day. What happened after one minute of him entering is the following:

  • Student stands
  • Teacher asks one question
  • If student answers correctly, he sits down
  • If student answers wrong, the student is awarded a good, nice, firm slap to the face.
  • If student does not give an answer with two seconds, then the student is awarded a good, nice, firm slap to the face.
  • Go to next student until finishing all students
Students used to sit in columns, and our class has 3 columns. I was in the last one, about the forth or fifth seat. All I remember is seeing a continuous stream of slaps happening in front of me, by the time he reached me and asked me his question, I could not even hear the question, or think. The only thing that went through  my mind was "How painful would the slap be?". If I remember correctly, only one or two students answered him.

Now, some might argue that it was for the good of students, and this technique would force students to study. However, when I look at the results I would say:

1- I hated the subject
2- I hated the teacher
3- I did not want to learn so as not to please the teacher, although I read enough to pass the exam or avoid getting hit.

I think a teacher who uses such techniques should be fired from his job.

Let me know about your primary school experiences... was it like this in your school?

Saturday, May 4, 2013

Starting Android Development

Hi there guys...

Recently I started learning android development. So far I wrote two simple applications just to experiment with user interface, and database management.

Compared to .Net framework, android seems difficult. The difficult part about it - or what I am not used to - is managing the interface. In .NET for example, you place a button, double click it and you can use it right a way. In android however, you place a button, link the button to an object manually, and set the handler for clicking that button manually. Switching between interfaces and transfer data isn't as straight forward as in .NET. However after getting used to that, it is becoming easier and easier.

So why I am learning android? Well, since I started working on my game (The Escape), I was hoping I would be able to make multiple players play that game on PCs and mobile devices. I was thinking of developing a central server to store the world, and keep track of every creature in it. Players could connect to that world and interact with all these creatures at any time. Another reason is that I am thinking of having evolving enemies and creatures. The evolution could be applied to their behavior, shapes and properties. The goal is that the game won't always be the same since the difficulty changes all the time, and the creatures evolve and change.

The problem is that ideas alone don't mean anything. Bringing them to life is what matters. So what next? Well I have to learn game programming on android (a little of OpenGL). Next I have to develop simple android game to experiment with that. Next is to create the server, followed by creating PC client, and finally creating the android client. Seems like a lot of work, right? Well, probably but I would love to make a game.

Finally check out the two simple apps i created on my google play page at:

let me know what do you think about them, are them good, acceptable, bad? and how could I improve them.

thank you

Thursday, April 11, 2013

Why saying "No" is not an easy thing to do?

Hi there ...

This is not a post about programming, sorry about that.

Since I was young, it was always very hard for me to say "no" to others. People could ask me for anything and I feel obligated to say yes and do it. For some reason saying no gives me the feeling of guilt even to this day.

The reason I am writing this is that a friend asked me for a favor. It was an easy thing to do, and it involved lying to others. I could have done it and helped him a lot, and no one would have known. However it was very obvious for me that what he was asking was wrong. I called him later and apologized for not doing what I promised earlier. 

What bothers me is: [1] I should have said NO right away when he asked me. That could made things easier, and [2] why do I feel guilt because of it?

I am not sure why I am writing this. Probably I just need a way to express my thoughts since I feel really bad about it.

Now for the website. I am still busy with work and study right now, more than ever, so I can't answer emails or post updates. Work seems never ending and my research requires lots of efforts.

Thanks for reading this. Take care and have a wonderful day everyone.