Game Development Reference
In-Depth Information
Figure 4-1. The complete game, Progressive Break-it
Setting Up the Project Files
Now that a solid understanding has been established for what you want to accomplish, let's move right into setting up
the project. Start by setting up the usual HMTL file, which should include the EaselJS and TweenJS libraries, as well as
a new JavaScript file for the game code. Name this file breakit.js . Finally, add the Canvas element, giving it a width of
800, a height of 700, and a background color of black.
<!DOCTYPE html>
<html>
<head>
<title></title>
<script src="../lib/easeljs-0.7.1.min.js"></script>
<script src="../lib/tweenjs-0.5.1.min.js"></script>
<script src="breakit.js"></script>
<style>
canvas{
background-color:black;
}
</style>
</head>
 
Search WWH ::




Custom Search