wle_ppefault_npm v0.3.0
Overview
Template project for the Wonderland Engine.
The project includes the PP library.
A collection of assets that can be useful while working with the Wonderland Engine (like gamepads 3D models) can be found here.
Downloads
You can download this template through the following links:
You can also download this template through npm
:
Template Versions
There are a few versions of this template:
wle_ppefault
- a standard project (not
npm
) - the PP library is included as a bundle file
- a standard project (not
wle_ppefault_npm
- an
npm
version of the same project - the PP library is included as an
npm
package - u need to run
npm install
in the project folder in order to install the dependencies
- an
wle_ppefault_npm_unbundled
- an
npm
version of the same project - the PP library is not included as an
npm
package, but as files in the project - can be useful if u plan to edit the PP library to adjust them to your need
- u need to run
npm install
in the project folder in order to install the dependencies
- an
Scene Structure
In the scene you will find only a few objects that should make it easier and faster to get started with the development, without adding too many things you may have to delete.
The scene is composed by a Scene
object that contains a Player
and two Lights
.
The Scene
object has the following components on it:
pp-get-player-objects
- get all the objects related to the player and put them in a global variable
PP.myPlayerObjects
- get all the objects related to the player and put them in a global variable
pp-get-default-resources
- get some engine resources (meshes, materials) and put them in a global variable
PP.myDefaultResources
to make them easily accessible in the code
- get some engine resources (meshes, materials) and put them in a global variable
pp-input-manager
- creates and updates the input devices like the gamepads, the mouse and the keyboard
- creates some global variables like
PP.myMouse
orPP.myGamepads
to easily access these devices
pp-visual-manager
- creates and updates a global visual manager that can be accessed through the variable
PP.myVisualManager
- creates and updates a global visual manager that can be accessed through the variable
pp-debug-manager
- creates and updates a global debug manager that can be accessed through the variable
PP.myDebugManager
- creates and updates a global debug manager that can be accessed through the variable
The Player
object includes:
Pivot
- can be used to offset the head and the hands, for example to have a specific height
- the pivot includes the
pp-player-height
component disabled, you can enable it to set a specific height from the floor - if
local-floor
is enabled, thepp-player-height
component will automatically stop, so that the height will be the real one of the user
Non VR Camera
- used to render the view when you have not entered the VR session yet
Eyes
- used to render the VR view
Hands
- follow the gamepads/tracked hands positions
- the gamepads are displayed as two Meta Quest gamepads that are animated, that means buttons react when pressed in real life
- the tracked hands are displayed through cubes positioned on the tracked hand joints
- includes
pp-console-vr
and 'pp-easy-tune`, two tools that can be useful while debugging and tuning
Head
- follows the head of the player
- includes a
pp-spatial-audio-listener
component
License
You are free to use this in your projects, just remember to credit me somewhere!