Argon-Runtime-Setup: Difference between revisions
No edit summary |
No edit summary |
||
| Line 14: | Line 14: | ||
Luckily, this is all set up for you already in the ARGON_DefaultPlayer.prefab. Just find it (under Assets >> Argon >> DefaultPlayer) and add it to your scene. | Luckily, this is all set up for you already in the ARGON_DefaultPlayer.prefab. Just find it (under Assets >> Argon >> DefaultPlayer) and add it to your scene. | ||
The DefaultPlayer prefab has an instance of SceneServices and an object with | The DefaultPlayer prefab has an instance of SceneServices and an object with an IHeadlineDisplay component (named HeadlineFeedback). | ||
In general, the DefaultPlayer prefab has all of the components you need to make all of your Argon components work. | |||
= When do I not need the Runtime? = | = When do I not need the Runtime? = | ||
You do not need the runtime if you are only adding standard Unity components--like Rigidbody, Box Collider, etc--with Argon. | You do not need the runtime if you are only adding standard Unity components--like Rigidbody, Box Collider, etc--with Argon. | ||
= Why do I want customize the Runtime = | = Why do I want customize the Runtime? = | ||
The runtime setup that comes packaged in the DefaultPlayer prefab | The runtime setup that comes packaged in the DefaultPlayer prefab has a player attached to a first person camera rig. | ||
If you are making a first person game and are happy with the default implementations supplied with Argon, then you're all set. | If you are making a first person game and are happy with the default implementations supplied with Argon, then you're all set. | ||
But you'll | But you'll likely want to change at least a few things to suit the needs of your game. | ||
Revision as of 13:07, 7 April 2024
Why is there a Runtime Setup
Argon adds components to your objects.
Some of these components need to run extra machinery in your scene to be useful.
For example, the Headline Display commands needs a mechanism for showing text on a UI document.
To get that mechanism, it asks an instance of SceneServices for an instance of IHeadlineDisplay.
So, you need:
- an instance of SceneServices in your scene
- an IHeadlineDisplay component to supply to SceneServices
Luckily, this is all set up for you already in the ARGON_DefaultPlayer.prefab. Just find it (under Assets >> Argon >> DefaultPlayer) and add it to your scene.
The DefaultPlayer prefab has an instance of SceneServices and an object with an IHeadlineDisplay component (named HeadlineFeedback).
In general, the DefaultPlayer prefab has all of the components you need to make all of your Argon components work.
When do I not need the Runtime?
You do not need the runtime if you are only adding standard Unity components--like Rigidbody, Box Collider, etc--with Argon.
Why do I want customize the Runtime?
The runtime setup that comes packaged in the DefaultPlayer prefab has a player attached to a first person camera rig.
If you are making a first person game and are happy with the default implementations supplied with Argon, then you're all set.
But you'll likely want to change at least a few things to suit the needs of your game.