Game Development Reference
In-Depth Information
The original Three.js author has created a scene editor that you can try at
http://mrdoob.github.io/three.js/editor/ . It is useful for small projects,
but quickly becomes unwieldy for big ones (especially when multiple people need
to work on a project at the same time). Also, the scene editor can't handle custom
objects such as spawn points, so if you use it, at least part of each level will need to
be defined in custom code.
As a result, if you need to create many levels or you need to do so visually, you will
probably need to build your own scene layout tool. There are a few ways you could
do this. First, the Three.js scene editor is part of the Three.js project (in the editor
folder), so you could start with that and edit it. Second, you could try writing an
exporter for an existing level development tool or a converter for its save files, then
writing a custom Three.js loader. Third, you could try writing your own tool from
scratch. The good news on that front is that once you've written one, you can use it
again in other projects.
Clearly, writing reusable components is helpful if you're going to build
more than one Three.js project. Before writing your own components, you
may want to check out two Three.js helper libraries by Jerome Etienne : an
extension system called tQuery and a series of utilities called THREEx ,
available at http://jeromeetienne.github.io/tquery/ and
http://jeromeetienne.github.io/threex/ , respectively.
Voxel.js ( http://voxeljs.com/ ) is a good example of a game engine with its own
level editor. It also has a bunch of modules (including a multiplayer module) that
you can plug in. It's designed for Minecraft-style games, but you might be able to use
it as a starting point for other large-scale projects.
Summary
In this chapter, we learned about designing and developing high-quality games for
the Web. We covered aspects of game design and development that are unique to the
Web, and how Three.js supports them; important performance considerations; and
basic client-server and lock-step networking.
You are now prepared to embrace the next generation of gaming. Congratulations!
 
Search WWH ::




Custom Search