3D Game Programming

(C. Jardin) #1
<body>
<h1>Hello!</h1>
<p>
You can make<b>bold</b>words,
<i>italic</i>words,
even<u>underlined</u>words.
</p>
<p>
You can link to
<ahref="http://gamingJS.com">other pages</a>.
You can also add images from web servers:
<imgsrc="/images/purple_fruit_monster.png">
</p>
</body>

Ignore ICE Warnings for HTML

Your HTML code may get red X warnings. These can be safely
ignored. ICE is meant to edit JavaScript, not HTML, so it can get
confused.

If you hide the code in the ICE Code Editor, you’ll see something like this:


This is a JavaScript book, not an HTML book, but you already see some of
what’s possible with HTML.

After the <body> tags come two <script> tags. Just like the <body> tags, these
<script> tags are HTML, but these load JavaScript from elsewhere on the Web
so that we can use it on the current page.

<scriptsrc="http://gamingJS.com/Three.js"></script>
<scriptsrc="http://gamingJS.com/ChromeFixes.js"></script>

These two lines tell the browser to load two libraries. In this case, we’re
loading a 3D JavaScript library named Three.js and a small library that fixes
some ICE Code Editor bugs in the Chrome web browser.

A1.9 Code: What’s All That Other Code?


Prepared exclusively for Michael Powell report erratum • discuss

Free download pdf