After reading a few articles about how our compatriots make flash games, and even make good money on this, I decided to make my own game. And by all means to earn from its sale at least $ 1000. Success in this matter meant a lot to me. All my life I wanted to make games and now I was ready and confident in the success of 100%. This is the story of the development of my first
King of the Rocks flash game.

The idea for the game.
It's all pretty simple. I chose an idea that I could have implemented myself without help, so that I did not have to stumble at every step and the development did not turn into hard labor and long-term construction. Before that, I had already started making games more than once, and each time I didn’t get things done. Therefore, after analyzing the previous experience, I changed the strategy and decided that it was necessary to create a finished product at all costs. That is, I decided to do the game not for the sake of the process, as is often the case, when engaging in the process you lick the graphics and code, but for the result, which can be submitted exactly as a finished product, and not as a handicraft. Therefore, I didn’t come up with anything complicated and decided to just make an analog of a thread of flash games. One of the games I liked at the time was called
Elite Forces: Clone Wars , which was made famous by many
mrBadim . Looking at the mechanics, I realized that I could fully implement such a gameplay. In addition, such games are extremely small and one more just will not be superfluous.
')
Now it was necessary to think about the appearance. I never liked the view from above, but doing something in isometric is difficult, so without much thought I stopped at the side view. In addition, the side view allows you to more spatially show levels, because you can put a lot of things on the background and thereby create a sense of depth. So with a look too was defined quickly.
It also had to come up with who will fight with whom and where the action of the game will take place. The first sketches were not long in coming. I immediately decided that these would be flying objects, because the troops would move only in a straight line and no curved routes would be allowed. The castles themselves will be located on the tops of the cliffs, which cannot be reached by any other means except by air. Some rocks will hang in the air. Each rock will be a separate object to use them more than once. And it will happen high among the clouds. Clouds are not difficult to draw, an extraordinary background is drawn once and used for all levels, there is space, and some kind of romance appears at once, it's a sin not to use all the advantages.
There will be three parties competing for possession of locks and domination in the territory, differing mainly in colors. Initially, I wanted these sailing ships to be flying, but then I didn’t know how to mirror an object in the opposite direction (
scaleX ) and therefore decided to use balloons, it’s not necessary to deploy them at all.

The general concept in the form of a pencil sketch was before my eyes and now that I imagined the approximate amount of work needed to decide on the time frame. Since I came to the solution of the problem strategically, it was also very important to limit the time for the execution of each task. This restriction played a dual role:
- Self discipline. You can not sit too long over honing the details, carried away by this process, you can completely forget about time. Each object has its own time for drawing and it’s impossible to spend more time on a small simple object than on a more complex one.
- If I sell the game, then it is important that the time spent on development is paid off. Develop a game a month and earn $ 500 from selling it. Interest is not big.
During the analysis of the required amount of work, I estimated the approximate time to draw each object and then summed up the clock. Time, of course, took to the maximum and added on top for any unforeseen situations. I also counted time for sleep, food, rest and it turned out about 10 days. Well, I think with special endeavors you can do it in 7 days and therefore gave yourself a weekly period for everything.
Boil work. I put myself in a rigid framework and I even liked it. I felt a certain satisfaction that I kept myself in tight rein and did not give myself a descent. I had a clear plan of action, all the tasks were in order, each time had its own time. If I did not have time and spent more time than planned, then I would do the next task at double speed to catch up. Of course, everything could not go as originally planned. In the process there were new tasks and difficulties about which I did not suspect when drawing up a general plan.
I wrote down all the appearing tasks also in order by a numbered list on separate sheets, and each such sheet was a sub-plan. Major tasks were also divided into subtasks that were recorded in order on a separate sheet. Upon completion, the task was deleted from the list. Later I noticed that the formation of such lists also plays an important role. Tasks recorded on paper, and not in my head are not forgotten. In addition, deleting or marking a task as completed has a psychological meaning. Looking at the lists of solved problems, progress is visible. Every evening I took in hands sheets with crossed out tasks, looked through them and sometimes was amazed how much I could do in such a short period of time. This is a great feeling. I was very proud of myself.
Balls.

I started with drawing units. At first it should have been sailing ships, but I refused them. The reason I described above. In addition, the sailboat is still more cumbersome and has more details. I would not want it when the ships began to fly across the screen porridge of them created confusion. Balls are still easier to perceive, they are more holistic object. Nevertheless, I still threw a few sketches of sailing ships, so that there was no doubt.
such here, unpretentious ballsIslands and castles
The islands were made in parallel with the castles. Locks needed to be drawn so that they visually sat tight on the rocks. For this, below the base of the castles, I added small trees, they hid flaws. Accordingly, the size and shape of the rocks were adjusted to the base of the locks. All objects are drawn in the vector, so that later there were no problems with scaling.
For a change and expansion of the already known gameplay, I came up with 3 types of locks:

- A colony is the main type of locks that generates the bulk of the troops. The higher the level of the castle, the faster the troops are generated in it. Can be upgraded to level 10.
- Academy - balls sent from this building have a much higher speed of movement. The higher the level of this building, the higher the speed of the balls departing from there. Can be upgraded to level 5.
- Mill - every second brings one $ for each warrior inside. If there are 20 balls inside, it means the mill brings in $ 20 each second. To receive money from the mills, you can improve all your locks. As soon as a sufficient amount appears for an upgrade of a lock, an “UP” arrow appears above it. The mill can be improved to level 5.

10 levels of the colony, and 5 levels per academy and mill
Well, the rocks are even nothing such turned outClouds
Clouds as well as rocks are needed to compile locations from them. Create an atmosphere and give the picture depth. I made more varieties.
made it darker so as not to blend in with the background of the pageInterface and its elements.
thumbnail sketchMy friend and advanced designer
Alexander helped me with the interface. I asked him to somehow arrange the menu and buttons, choose the font, make some thread frame. I did the rest of the interface elements myself. There is nothing ordinary in the interface as you can see.

from sketch to implementationInstructions.
it looked like sketchesYou could probably have been on them and not bother, but I still decided to do everything as planned. They didn’t take much time away from me, all the same the style had already been worked out. More time spent on the correct translation of the contents of the instructions. Friends also helped with the translation. As a result, these are the pictures. Full-size options can be found in the game by clicking "How to play" in the main menu.
I admit I know English badly and my friends are amazed how I manage to communicate with sponsors and agree on something in general. Nevertheless, I do not worry and usually correspond with sponsors on my own. I ask friends to help me only when I want to be understood correctly, or I cannot formulate a phrase.Programming
As I said, the gameplay is not tricky and there are no complicated calculations here. I will describe only how the levels and operation of the computer are arranged.
Each level is one frame in the timeline. In each frame on the lower layer is placed the background, mountains and clouds so that a solid picture is formed. Mountains and clouds are simply graphic objects such as graphics. But the castles are already MovieClips, representatives of the Castle class. Locks are placed in the frame on top of the formed background on top of the rocks and each castle is assigned an instance name. In the same frame, the script adds the addition of each lock named instance to the Castles array. The game has a global Castles array which is cleared before each level is launched and is filled with links to the locks placed in the current frame. After that, level processing starts. Thus all the necessary information about the level is stored right in the frame.
The brain of the computer was pretty simple. There are 2 opponents in the game: yellow and red. At the beginning of each level, the frequency of calculation and decision-making is set separately for the yellow computer and separately for the red computer, for example, once a second. Every time when the time is right the computer calculates the most profitable goal for itself. This goal is determined depending on the distance to the enemy castle, the number of units in it, the level of the castle, etc. All these values ​​are expressed by coefficients and the computer simply multiplies them and writes the resulting net into an array. The number of elements in the array is equal to the number of locks. Each element of the array is a regular number indicating the effectiveness of the attack on the castle. The lower the number, the more advantageous the target for the attack. We are looking for the smallest value in the array and the index of its element will correspond to the index of the weakest or most advantageous castle to attack. After that just send the balls there. That's all the work of the computer.
Music and sounds.
He did not write music himself. With this, I puzzled my friend, the
proxiper composer. For several days he wrote a background theme, and also picked up the necessary sounds. The background theme consists of two parts. First, the intro starts and the listener for the end of playback event is set to it. When this event is triggered, a looped topic is triggered.
Beta test.
Beta test as it should be supposed to search for bugs. There were not many bugs, there was nothing special about bugging, but it was worth working on the level balance. In the end, after several passes of the game with different settings, I selected the optimal, in my opinion, parameters. Of course, it was possible to correct a lot of things, but the time allotted for development was already running out and therefore I simply scored some shortcomings. Moreover, they were very insignificant and had little effect on the gameplay.
Register on FlashGameLicense and search for a sponsor.
Selling the game to a sponsor was the reason why this experiment was ultimately carried out. It was terribly interesting how much they would offer for this work and whether they would offer anything at all. I admit, I did not doubt at all that they would give more than $ 2000 per game, although my friends who followed the engine at the auction with me initially thought that $ 1000 was the ceiling. I asked
mrBadim to make the first bet so that the game moved from meta and other sponsors began to interrupt his bet. Thus, trading began with $ 300. Below is the log of proposals:
> 2010-03-26 09:52:14 jaludo_s
$ 3000.00 primary FGL [reentering bid to correct log in our system] Accepted
2010-03-05 18:14:41 jaludo_s
$ 3000.00 primary Intro
2010-03-04 09:31:38 Gimme5Games
$ 2000.00 primary Require: Sponsor logo, links, hi-score API
2010-03-04 07:56:48 SpilGames_Martine
$ 1900.00 primary Branding + API integration
2010-03-03 10:42:11 Gimme5Games
$ 1800.00 primary Require: Sponsor logo, links, hi-score API
2010-03-03 08:50:33 SpilGames_Martine
$ 1750.00 Branding + API integration
2010-03-01 17:08:51 lorenz
$ 1000.00 other Non exclusive, integration api & highscores (+ translati ...
2010-03-01 13:09:53 Gimme5Games
$ 1600.00 primary Require: Sponsor logo, links, hi-score API
2010-02-28 07:55:36 jaludo_s
$ 1500.00 primary Intro and branding
2010-02-26 11:25:14 Gimme5Games
$ 1100.00 primary Require: Sponsor logo, links, hi-score API
2010-02-25 06:05:57 jaludo_s
$ 1000.00 primary Intro and branding
2010-02-22 03:47:43 elite_games
$ 800.00 preloader logos, more games link. cpmstar
2010-02-19 12:49:22 armorgames
$ 600.00 other Cpmstar ads allowed on the viral version
2010-02-19 08:12:04 elite_games
$ 300.00 preloader logos, more games link. cpmstar
I did not like Jaludo at first. I wanted to place a cpm star advertisement in the game, but this did not suit him. We talked with him for a long time, but he did not agree. In the end, I accepted the Gimme5Games bet. I decided that it would be quite realistic to earn $ 1000 from advertising. To other mochi and cpmstar developers, advertising brings quite large sums, which means it will bring me quite a lot. In any case, it was necessary to try and find out what and how. But Gimme5Games turned out to be one more dynamo. They had some problems with the server and he could not give me the necessary assets and scripts, and asked me to wait a bit. 2 or more weeks he fed me with promises, they say everything will give in a couple of days and as soon as I insert the scripts I will transfer money. But I didn’t like these promises at all and I gave him an ultimatum, either pay the advance 50% of the bet, or I’ll go to FGL and tell them to cancel this bet and I’ll accept the Jaludo bid. Meanwhile, I wrote to Jaludo that if he even allowed me to advertise cpmstar in the game, then I would accept his bet. Jaludo agreed and now without a shadow of a doubt I turned to the FGL administration with a request to change the already accepted rate. FGL said that the interests of the developer for them are more important than the interests of the sponsor and quickly changed the accepted bid to the proposal of Jaludo. There were no problems with Jaludo, for a week he transferred me $ 3,000 by international transfer to a bank.
This is how reward and perseverance are rewarded. Everything turned out exactly the same as those guys who wrote about their success in this business. The focus on results has borne fruit, a great experience was gained not only in development, but also in the organization of work, which is also important.
We get acquainted with the result here