• Complain

Egges - Building JavaScript games : for phones, tablets, and desktop

Here you can read online Egges - Building JavaScript games : for phones, tablets, and desktop full text of the book (entire story) in english for free. Download pdf and epub, get meaning, cover and reviews about this ebook. year: 2014, publisher: Apress, genre: Computer. Description of the work, (preface) as well as reviews are available. Best literature library LitArk.com created for fans of good reading and offers a wide selection of genres:

Romance novel Science fiction Adventure Detective Science History Home and family Prose Art Politics Computer Non-fiction Religion Business Children Humor

Choose a favorite category and find really read worthwhile books. Enjoy immersion in the world of imagination, feel the emotions of the characters or learn something new for yourself, make an fascinating discovery.

Egges Building JavaScript games : for phones, tablets, and desktop
  • Book:
    Building JavaScript games : for phones, tablets, and desktop
  • Author:
  • Publisher:
    Apress
  • Genre:
  • Year:
    2014
  • Rating:
    4 / 5
  • Favourites:
    Add to favourites
  • Your mark:
    • 80
    • 1
    • 2
    • 3
    • 4
    • 5

Building JavaScript games : for phones, tablets, and desktop: summary, description and annotation

We offer to read an annotation, description, summary or preface (depends on what the author of the book "Building JavaScript games : for phones, tablets, and desktop" wrote himself). If you haven't found the necessary information about the book — write in the comments, we will try to find it.

Building JavaScript Games teaches game programming through a series of engaging, arcade-style games that quickly expand your JavaScript and HTML5 skills. JavaScript is in the top ten most-used programming languages world wide, and is the basis for applications that can run in any modern browser, on any device from smart phone to tablet to PC. Especial emphasis is given to touch-based interface, but all games also run using a regular mouse and keyboard setup.

The four games youll develop from reading this book are:

  • Painter
  • Jewel Jam
  • Penguin Pairs
  • Tick Tick

These four games are casual, arcade-style games representing the aim-and-shoot, puzzle, maze, and platform styles of game play.

The approach in Building JavaScript Games follows the basic structure of a game rather than the syntax of a language. From almost the very first chapter you are building games to run on your phone or other device and show to your friends. Successive projects teach about handling player input, manipulating game objects, designing game worlds, managing levels, and realism through physics. All told, youll develop four well-designed games, making Building JavaScript Games one of the most enjoyable ways there is to learn about programming browser-based games.

The final chapters in the book contain a very nice bonus of sorts. In them you will find excerpts from interviews with two prominent people from the game industry: Mark Overmars, who is CTO of Tingly Games and creator of GameMaker, and Peter Vesterbacka, the CMO of Rovio Entertainment - the creators of the Angry Birds franchise. Their insight and perspective round off what is already a fun and valuable book.

Egges: author's other books


Who wrote Building JavaScript games : for phones, tablets, and desktop? Find out the surname, the name of the author of the book and a list of all author's works by series.

Building JavaScript games : for phones, tablets, and desktop — read online for free the complete book (whole text) full work

Below is the text of the book, divided by pages. System saving the place of the last page read, allows you to conveniently read the book "Building JavaScript games : for phones, tablets, and desktop" online for free, without having to search again every time where you left off. Put a bookmark, and you can go to the page where you finished reading at any time.

Light

Font size:

Reset

Interval:

Bookmark:

Make

Chapter

Programming

This chapter talks about how programming languages have evolved over time. Since the rise of the Internet in the 1990s, a lot of languages and tools have been developed to support it. One of the best-known languages is HTML, which is used to create web sites. Together with JavaScript and CSS style sheets, it allows the creation of dynamic web sites that can be displayed by a browser. I discuss HTML and JavaScript in detail in this chapter, and you see how to create a simple web application that uses the HTML5 canvas in combination with JavaScript.

Computers and Programs

Before you start dealing with HTML and JavaScript, this section briefly covers computers and programming in general. After that, you move on to how to create a simple HTML page in combination with JavaScript.

Processor and Memory

Generally speaking, a computer consists of a processor and memory. This is true for all modern computers, including game consoles, smartphones, and tablets. I define memory as something that you can read things from, and/or write things to. Memory comes in different varieties, mainly differing in the speed of data transfer and data access. Some memory can be read and written as many times as you want, some memory can only be read, and other memory can only be written to. The main processor in the computer is called the central processing unit (CPU). The most common other processor on a computer is a graphics processing unit (GPU). Even the CPU itself nowadays is no longer a single processor but often consists of a number of cores.

Input and output equipment, such as a mouse, gamepad, keyboard, monitor, printer, touch screen, and so on, seems to fall outside the processor and memory categories at first glance. However, abstractly speaking, theyre actually memory. A touch screen is read-only memory, and a printer is write-only memory.

The main task of the processor is to execute instructions. The effect of executing these instructions is that the memory is changed. Especially with my very broad definition of memory, every instruction a processor executes changes the memory in some way. You probably dont want the computer to execute only one instruction. Generally, you have a very long list of instructions to be executedMove this part of the memory over there, clear this part of the memory, draw this sprite on the screen, check if the player is pressing a key on the gamepad, and make some coffee while youre at itand (as you probably expect) such a list of instructions that is executed by the computer is called a program.

Programs

In summary, a program is a long list of instructions to change the computers memory. However, the program itself is also stored in memory. Before the instructions in the program are executed, theyre stored on a hard disk, a DVD, or a USB flash disk; or in the cloud; or on any other storage medium. When they need to be executed, the program is moved to the internal memory of the machine.

The instructions that, combined together, form the program need to be expressed in some way. The computer cant grasp instructions typed in plain English, which is why you need programming languages such as JavaScript. In practice, the instructions are coded as text, but you need to follow a very strict way of writing them down, according to a set of rules that defines a programming language. Many programming languages exist, because when somebody thinks of a slightly better way of expressing a certain type of instruction, their approach often becomes a new programming language. Its difficult to say how many programming languages there are, because that depends on whether you count all the versions and dialects of a language; but suffice to say that there are thousands.

Fortunately, its not necessary to learn all these different languages, because they have many similarities. In the early days, the main goal of programming languages was to use the new possibilities of computers. However, more recent languages focus on bringing some order to the chaos that writing programs can cause. Programming languages that share similar properties are said to belong to the same programming paradigm. A paradigm refers to a set of practices that is commonly used.

The Early Days: Imperative Programming

A large group of programming languages belongs to the imperative paradigm. Therefore, these languages are called imperative languages . Imperative languages are based on instructions to change the computers memory. As such, theyre well suited to the processor-memory model described in the previous section. JavaScript is an example of an imperative language.

In the early days, programming computer games was a very difficult task that required great skill. A game console like the popular Atari VCS had only 128 bytes of RAM (Random Access Memory) and could use cartridges with at most 4,096 bytes of ROM (Read-Only Memory) that had to contain both the program and the game data. This limited the possibilities considerably. For example, most games had a symmetric level design because that halved the memory requirements. The machines were also extremely slow.

Programming such games was done in an Assembler language. Assembler languages were the first imperative programming languages. Each type of processor had its own set of Assembler instructions, so these Assembler languages were different for each processor. Because such a limited amount of memory was available, game programmers were experts at squeezing out the last bits of memory and performing extremely clever hacks to increase efficiency. The final programs, though, were unreadable and couldnt be understood by anyone but the original programmer. Fortunately that wasnt a problem, because back then, games were typically developed by a single person.

A bigger issue was that because each processor had its own version of the Assembler language, every time a new processor came around, all the existing programs had to be completely rewritten for that processor. Therefore, a need arose for processor-independent programming languages. This resulted in languages such as Fortran (FORmula TRANslator) and BASIC (Beginners All-purpose Symbolic Instruction Code). BASIC was very popular in the 1970s because it came with early personal computers such as the Apple II in 1978, the IBM-PC in 1979, and their descendants. Unfortunately this language was never standardized, so every computer brand used its own dialect of BASIC.

Note The fact that I made the effort to identify the paradigm of imperative programming languages implies that there are other programming paradigms that arent based on instructions. Is this possible? What does the processor do if it doesnt execute instructions? Well, the processor always executes instructions, but that doesnt mean the programming language contains them. For example, suppose you build a very complicated spreadsheet with many links between different cells in the sheet. You could call this activity programming and call the empty spreadsheet the program, ready to process data. In this case, the program is based not on instructions but on functional links between the cells. In addition to these functional programming languages, there are languages based on propositional logicthe logical programming languagessuch as Prolog. These two types of programming languages together form the declarative paradigm.

Procedural Programming: Imperative + Procedures

As programs became more complex, it was clear that a better way of organizing all these instructions was necessary. In the procedural programming paradigm , related instructions are grouped together in procedures (or functions, or methods, the latter of which is the more common modern name). Because a procedural programming language still contains instructions, all procedural languages are also imperative.

Next page
Light

Font size:

Reset

Interval:

Bookmark:

Make

Similar books «Building JavaScript games : for phones, tablets, and desktop»

Look at similar books to Building JavaScript games : for phones, tablets, and desktop. We have selected literature similar in name and meaning in the hope of providing readers with more options to find new, interesting, not yet read works.


Reviews about «Building JavaScript games : for phones, tablets, and desktop»

Discussion, reviews of the book Building JavaScript games : for phones, tablets, and desktop and just readers' own opinions. Leave your comments, write what you think about the work, its meaning or the main characters. Specify what exactly you liked and what you didn't like, and why you think so.