Idle Game Maker Handbook
last updated 09/01/2014
The basics of Idle Game Maker
What is Idle Game Maker?
A word of warning
How do I make a game?
An Idle Game Maker game is simply a text file that our website converts into a browser game.
To make your own game, you will have to write that text file using the commands and syntax described below (you'll see, there's a whole array of cool things you can do). Here's what a finished game file looks like : http://pastebin.com/raw.php?i=YrmTqheS. Pretty readable, huh?
You will then have to find a place online to store your text file (pastebin.com is a good one; your text files are hosted for free and, if you register, you can edit them as much as you want. Here are some other text-hosting sites).
Once you're happy with your new game, all that remains to do is to share it with the world!
How do I play my game?
To play a game, take its source file's URL and append it to http://orteil.dashnet.org/experiments/idlegamemaker/?game=.
A game stored at www.example.com/mygame.txt would be playable at http://orteil.dashnet.org/experiments/idlegamemaker/?game=www.example.com/mygame.txt.
- If your game is hosted on pastebin.com, you only have to refer to its identifier (the letters at the end of its url). For example, http://pastebin.com/YrmTqheS becomes http://orteil.dashnet.org/experiments/idlegamemaker/?game=YrmTqheS.
- Note : when hosting your file on pastebin.com, make sure you're registered - or you won't be able to edit your game later! Also make sure to set the file to never expire, and to make it either public or unlisted.
- If you're not hosted on pastebin.com, make sure your file is a .txt file! Your game won't work with any other file type.
General tips about game-making
- You can make an idle game about practically anything. Just look around you!
- Spend some time examining the games you like. You'll probably learn something from the gameplay or from the source file!
- Test your game. A lot.
- If people seem to like your game, consider making a forum where players can talk about it and discuss new features. Having community feedback is essential when making a good game!
- Keep a separate version for testing only.
- Keep backups of your game's source - you never know!
- Add descriptions and, if possible, pictures! Flavor is everything.
- Don't mindlessly copy other cool games you've seen. Add something of your own, be creative! (And no, replacing every instance of "burger" by "pizza" and calling it Pizza Clicker doesn't count as being creative!)
- Beware of spelling mistakes, they can quickly make a game appear very unprofessional. Use spell-check!
- Keep your game fresh and your players curious by adding new stuff regularly!
And now for some rules
- All work from games made using this engine is copyrighted to their respective owners.
- Content creators are expected to respect copyright laws. No user-created content is hosted on our servers.
- Don't use illegal content in your game!
- Please no games involving overly lewd, nude or violent stuff.
- Try not to use copyrighted images (be careful with google image search)! If you use content that demands proper attribution, make sure to provide it!
- Don't do anything shifty with our engine! Basically, if it feels wrong, don't do it.
- Don't try to mislead the players into visiting websites they don't want to.
- No circumventing our system to include scripts or other disallowed HTML tags in your games!
- Please do not use CSS to change or hide the top bar.
- Finally, please do not attempt to hide or alter the ads through CSS, they're what keeps the site afloat! (Using adblock when playing is okay though.)
Writing source files
Your game is made of elements : each resource, clickable button, building, upgrade and achievement is an element.
You can create new elements under the appropriate sections. The code for this is simply creating a new line with
*IdentifierForTheElement, below which you can add properties to the element through commands.
You can define their name, their picture, and lots of other things such as their price, their passive powers, what they unlock...
An element is either visible or hidden. "Unlocking" refers to making an element visible (and earning it, if it's an achievement).
A simple example element would be :
"A placid, friendly mammal. Generates 1 milk every second."
costs 20 money
gives 1 milk
picture : http://example.com/cow.png
- An identifier needs to be composed only of letters and numbers, with no spaces. For example, "Slay monster" should become something like "SlayMonster".
- You cannot have two elements that share the same identifier.
- Identifiers are case-insensitive ("ABC" is treated the same as "Abc" or "abc").
- Note that you can use the
named Xcommand to give an object a displayed name different from its identifier.
- Only refer to an element's identifier in commands, not to its name!
- Be careful about plurals. If you gave a resource the identifier
cookies, the command
gives 1 cookiewouldn't do anything - it should be
gives 1 cookies!
- Important : do not change an element's identifier once set! This would mess up your players' saves since the parser would treat this element as an entirely new object! Instead, change its displayed name.
HTML-wise, boxes are simply <div>s, with a CSS class corresponding to their name. Elements within a box will still be wrapped in their corresponding block first, such as "achievements" or "buildings" - unless the element was specififcally assigned to a different box, in which case it is wrapped directly by the box.
Boxes are kind of an advanced system - make sure you know what you're doing!
//will be treated as a comment and will be ignored by the parser.
Lines that the parser did not understand will also be ignored, but might throw an error.
Other syntax tips
- Pretty much every command is optional, save for the first two lines (
Let's make a game!and your game's name).
- Tabs and multiple spaces are ignored, as are hyphens (-) when they're the first character on a line; feel free to use those to format your source and make it more easily readable.
- HTML is ignored everywhere except in descriptions, where only <b> (bold), <i> (italics), <u> (underlined) and <q> (quotes) are allowed.
- If you make a mistake in your source (or use commands in ways we didn't expect), you might get an error message, or the game might freeze completely. Try to undo your last changes and see where it went wrong!
- By the way, make sure to pay attention when you edit your game. Our parser is designed to be fairly forgiving, but still - a simple typo or syntax error is all it takes to freeze the game!
- A good way to learn more about our syntax is to simply check out the source for Burger Clicker, a game specifically made to showcase many of Idle Game Maker's functions.
The first section in a game's source is the header, in which you define the essential information for your game.
Let's make a game!
Name of your game
created on day/month/year
last updated on day/month/year
This contains miscellaneous settings for your game, such as price inflation, default visibility, background/text color, and others.
Again, each of these commands is optional.
prices increase by X%
The default value is 110%. (Note that Cookie Clicker uses 115%!)
- Note : can be overridden in a specific building with the command
price increases by X%.
selling gives back X%
The default value is 50%.
resources are hidden|visible by default
clickables are hidden|visible by default
buildings are hidden|visible by default
upgrades are hidden|visible by default
achievements are hidden|visible by default
boxes : X, Y, Z...
Box names follow the same naming rules as identifiers : plain letters and digits only, no spaces.
If you do not specify this, a default template of boxes will be used instead.
resources go in the X box
clickables go in the X box
buildings go in the X box
upgrades go in the X box
achievements go in the X box
title goes in the X box
save goes in the X box
background : X
text color : X
custom stylesheet : X
Your CSS must be a .txt file, not a .css file.
Note : please do not hide the ad with CSS! You can, however, move the "support" block - but make sure it is always sufficiently far away from the rest of the buttons and can't be misconstrued as game content!
fonts : X, Y, Z...
A game like Cookie Clicker has only one resource (cookies), but you could imagine, for example, a game where you can cook the Chocolate resource, which you sell for the Money resource, with which you can buy the Candies resource...
starts at X
show X digits
show 0 digitswould display 3,
show 1 digitwould display 3.1 and
show 2 digitswould display 3.14.
Default is 0.
displayed as Abc
You have %a cookie%swould render as "You have 123 cookies".
Default is %a %r ("123 cookies").
on finding say Abc
In Cookie Clicker, this could be the big cookie. Clickables are very versatile however, so feel free to get creative!
on success says Abc
on failure says Abc
gains X% per Y
converts X to Y
In Cookie Clicker, these would be the cursors, grandmas, farms...
starts at X
price increases by X%
gains X% per Y
represents X Y
occupies X Y
multiplies efficiency of X by Y%
multiplies efficiency of X by Y% per Z
multiplies income of X by Y%
Note : these last 3 commands all stack multiplicatively!
converts X to Y
Unlocking an achievement is the same as earning it.
image : X
classed : X, Y, Z...
goes in the X box
visible at X Y
unlocks with X
unlocks at X Y
requires X Y
costs X Y
A clickable will run these once per click (if it meets its requirements); a building or an upgrade will run these on a per-second basis.
A building will multiply the gains and losses by its amount.
gives X Y
gives X1>X2 Y
gives Xa Ya, Xb Yb, Xc Yc...
Note : the last 2 commands can be mixed like so -
gives X1a>X2a Ya, X1b>X2b Yb...
You can also follow the same syntax with the following commands.
takes X Y
builds X Y
destroys X Y
multiplies X Y%
...N% of the time
Note : you can mix and match this command and the others like so -
gives 10 cookies 50% of the time for 5 dollars
...for Xb Yb
...requiring Xb Yb
Communities such as r/idlegamemaker will be more than happy to play and comment on your game. And who knows, if your game makes enough noise, we might even end up featuring it!
We hope you have as much fun using it as we had making it!
Need to contact us? Please do so through our forums.