Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying JMonkeyEngine 3.0 Cookbook
  • Table Of Contents Toc
JMonkeyEngine 3.0 Cookbook

JMonkeyEngine 3.0 Cookbook

By : Rickard Eden
4 (7)
close
close
JMonkeyEngine 3.0 Cookbook

JMonkeyEngine 3.0 Cookbook

4 (7)
By: Rickard Eden

Overview of this book

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 (12 chapters)
close
close
11
Index

Creating a reusable character control

To start off the chapter, we will create a class that we can use for various character-controlled purposes. The example describes an FPS character, but the method is the same for any player-controlled character.

The Control class we'll build will be based on BetterCharacterControl. It might be a good idea to have a look at the class or the TestBetterCharacter example from the jMonkeyEngine test package if you want to find out how this works. Another good starting point would be the input examples from the same package.

Getting ready

The BetterCharacterControl class is based on physics and requires a BulletAppState class to be set up in the application. The steps required to do this are described in the The ImageGenerator class section in Appendix, Information Fragments. To find out more about bullet and physics, refer to Chapter 8, Physics with Bullet.

How to do it...

Perform the following set of steps to create a reusable character control:

  1. Start by...
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
JMonkeyEngine 3.0 Cookbook
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon