Free Sample
+ Collection

jMonkeyEngine 3.0 Cookbook

Rickard Edén

Over 80 practical recipes to expand and enrich your jMonkeyEngine skill set with a close focus on game development.
RRP $23.99
RRP $39.99
Print + eBook

Want this title & more?

$12.99 p/month

Subscribe to PacktLib

Enjoy full and instant access to over 2000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

Book Details

ISBN 139781783286478
Paperback298 pages

About This Book

  • Contains an extensive and valuable set of solutions to real jMonkeyEngine game development challenges
  • Learn how to take your game online using the SpiderMonkey network framework
  • Kick-start your next project by applying game-ready templates

Who This Book Is For

If you are a jMonkey developer or a Java developer who is interested to delve further into the game making process to expand your skillset and create more technical games, then this book is perfect for you.

Table of Contents

Chapter 1: SDK Game Development Hub
Setting up a project
Importing a model
Using Scene Composer
Modifying heightmaps with Terrain Editor
Adding a sky box and lighting
Adding water using a filter
Adding some ambient audio
Creating bitmap fonts with Font Creator
Retrieving an attachment node
Using ParticleEmitter – Soaring Birds
An advanced ParticleEmitter class
Chapter 2: Cameras and Game Controls
Creating a reusable character control
Attaching an input AppState object
Firing in FPS
Firing non-instant bullets
Creating an RTS camera AppState object
Selecting units in RTS
Making the camera follow units
Following a character with ChaseCamera
Adding a game controller or joystick input
Leaning around corners
Detecting cover automatically in a third-person game
Chapter 3: World Building
Using noise to generate a terrain
Lighting your world and providing it with dynamic lights
Deforming a terrain in real time
Automating trees' distribution
Endless worlds and infinite space
Flowing water with cellular automata
The essentials of a cube-based world
Chapter 4: Mastering Character Animations
Previewing animations in SDK
Creating an animation manager control
Extending the animation control
Handling jump animations
Creating a custom animation - leaning
Creating a subanimation
Lip syncing and facial expressions
Eye movement
Location-dependent animation – edge check
Aligning feet with ground – inverse kinematics
Chapter 5: Artificial Intelligence
Creating a reusable AI control class
Sensing – vision
Sensing – hearing
Decision making – Finite State Machine
Creating the AI using cover
Generating NavMesh in SDK
Pathfinding – using NavMesh
Controlling groups of AI
Pathfinding – our own A* pathfinder
Chapter 6: GUI with Nifty GUI
Initializing Nifty and managing an options menu
Loading the screen
Creating an RPG dialog screen
Implementing a game console
Handling a game message queue
Creating an inventory screen
Customizing the input and settings page
Using offscreen rendering for a minimap
Chapter 7: Networking with SpiderMonkey
Setting up a server and client
Handling basic messaging
Making a networked game – Battleships
Implementing a network code for FPS
Loading a level
Interpolating between player positions
Firing over a network
Optimizing the bandwidth and avoiding cheating
Chapter 8: Physics with Bullet
Creating a pushable door
Building a rocket engine
Ballistic projectiles and arrows
Handling multiple gravity sources
Self-balancing using RotationalLimitMotors
The principles of a bridge-building game
Networked physics
Chapter 9: Taking Our Game to the Next Level
Creating a muzzle flash using ParticleEmitter
Creating a trigger system
Creating a timer trigger
Adding an interaction trigger
Controlling AI with triggers
Creating a dynamic skybox with a moving sun
Improving a scene with postprocessing filters
Performing complex movements with MotionPaths
Cutscenes using cinematics
Using a positional audio and environmental effects

What You Will Learn

  • Make an online game with the SpiderMonkey framework
  • Design dynamic and attractive GUIs with NiftyGUI
  • Create cutscenes and smooth camera rides with cinematics
  • Build AI that sees, follows, and finds its way through the game world
  • Use Bullet physics to build a more dynamic game world
  • Explore useful tips on taking your game project to the next level
  • Develop a more maintainable project by using Controls and AppStates

In Detail

This book provides you with engaging hands-on game development tips that will keep the game we'll be developing in focus. Each chapter will provide insight into the how's, what's, and why's of jMonkeyEngine and game development step by step.

The book starts by giving you useful tips on the SDK itself, and how using it will make your life as a developer easier. The book then moves on to cover a variety of patterns which you can use to control cameras, characters, and animations, followed by how to make real-time networked games and dynamic game worlds.

If you are a jMonkeyEngine user or Java developer interested in delving further into game development to expand your skill set, then this book is perfect for you.


Read More