Class UnitySerenityInstaller
Central installer for setting up Serenity foundation services in a Unity environment.
Inheritance
UnitySerenityInstaller
Assembly: Serenity.Installation.dll
Syntax
public class UnitySerenityInstaller : MonoBehaviour, IFoundationSettings, IUnityInstallationContext, IInstalledLogServices
Constructors
UnitySerenityInstaller()
Declaration
public UnitySerenityInstaller()
Fields
AssetLoadingMode
Declaration
public SerenityAssetLoadingMode AssetLoadingMode
Field Value
AssetPrefetcherInstaller
Declaration
public UnityAssetPrefetcherInstaller AssetPrefetcherInstaller
Field Value
AudioPlayerInstaller
Declaration
public UnityAudioPlayerInstaller AudioPlayerInstaller
Field Value
CascadeViewInstaller
Declaration
public UnityCascadeViewInstaller CascadeViewInstaller
Field Value
CompositeViewInstaller
Declaration
public UnityCompositeViewInstaller CompositeViewInstaller
Field Value
ConsoleLogInstaller
Declaration
public UnityConsoleLogInstaller ConsoleLogInstaller
Field Value
ConsoleLogSettings
Declaration
public UnityConsoleLogSettings ConsoleLogSettings
Field Value
CutscenePlayerInstaller
Declaration
public UnityCutscenePlayerInstaller CutscenePlayerInstaller
Field Value
DestroyOnFinish
Declaration
public bool DestroyOnFinish
Field Value
EventDispatcherInstaller
Declaration
public UnityEventDispatcherInstaller EventDispatcherInstaller
Field Value
FeedbackInstaller
Declaration
public UnityFeedbackInstaller FeedbackInstaller
Field Value
FileLogInstaller
Declaration
public UnityFileLogInstaller FileLogInstaller
Field Value
FileLogSettings
Declaration
public UnityFileLogSettings FileLogSettings
Field Value
FilePersistenceInstaller
Declaration
public UnityFilePersistenceInstaller FilePersistenceInstaller
Field Value
GameCameraInstaller
Declaration
public UnityGameCameraInstaller GameCameraInstaller
Field Value
GameGraphicsInstaller
Declaration
public UnityGameGraphicsInstaller GameGraphicsInstaller
Field Value
GameModeInstaller
Declaration
public UnityGameModeInstaller GameModeInstaller
Field Value
GameModeSettingsDefinition
Declaration
public UnityGameModeSettingsDefinition GameModeSettingsDefinition
Field Value
GameProgressInstaller
Declaration
public UnityGameProgressInstaller GameProgressInstaller
Field Value
GameSaveInstaller
Declaration
public UnityGameSaveInstaller GameSaveInstaller
Field Value
GameSettingsInstaller
Declaration
public UnityGameSettingsInstaller GameSettingsInstaller
Field Value
GameUiInstaller
Declaration
public UnityGameUiInstaller GameUiInstaller
Field Value
GameWrapper
Declaration
public GameObject GameWrapper
Field Value
| Type |
Description |
| GameObject |
|
GameplayScene
Declaration
public SceneAsset GameplayScene
Field Value
| Type |
Description |
| SceneAsset |
|
GameplayScenePath
Declaration
public string GameplayScenePath
Field Value
GlobalInstaller
Declaration
public UnityGlobalInstaller GlobalInstaller
Field Value
Guid
Declaration
Field Value
Id
Declaration
Field Value
InitializationPipelineInstaller
Declaration
public UnityInitializationPipelineInstaller InitializationPipelineInstaller
Field Value
InitializationPipelineProfile
Declaration
public UnityInitializationPipelineProfile InitializationPipelineProfile
Field Value
InitializationScene
Declaration
public SceneAsset InitializationScene
Field Value
| Type |
Description |
| SceneAsset |
|
InitializationScenePath
Declaration
public string InitializationScenePath
Field Value
InstallOnStart
Declaration
public bool InstallOnStart
Field Value
LeaderboardInstaller
Declaration
public UnityLeaderboardInstaller LeaderboardInstaller
Field Value
LeaderboardViewInstaller
Declaration
public UnityLeaderboardViewInstaller LeaderboardViewInstaller
Field Value
LocalizationInstaller
Declaration
public UnityLocalizationInstaller LocalizationInstaller
Field Value
LocalizationSettings
Declaration
public UnityLocalizationSettings LocalizationSettings
Field Value
LogProfile
Declaration
public UnityLogProfile LogProfile
Field Value
Declaration
public UnityMenuInstaller MenuInstaller
Field Value
Declaration
public UnityMenuServiceSettingsDefinition MenuServiceSettingsDefinition
Field Value
ModalInstaller
Declaration
public UnityModalInstaller ModalInstaller
Field Value
ModalServiceSettingsDefinition
Declaration
public UnityModalServiceSettingsDefinition ModalServiceSettingsDefinition
Field Value
MusicPlayerInstaller
Declaration
public UnityMusicPlayerInstaller MusicPlayerInstaller
Field Value
PathService
Declaration
public IPathService PathService
Field Value
PersistenceBackendDefinition
Declaration
public UnityPersistenceBackendDefinition PersistenceBackendDefinition
Field Value
PersistenceUseCases
Declaration
public PersistenceUseCases PersistenceUseCases
Field Value
Declaration
public UnityPlayerInputInstaller PlayerInputInstaller
Field Value
Declaration
public UnityPlayerInputSettingsDefinition PlayerInputSettingsDefinition
Field Value
PrefetchPolicyRegistry
Declaration
public PrefetchPolicyRegistry PrefetchPolicyRegistry
Field Value
ScoreInstaller
Declaration
public UnityScoreInstaller ScoreInstaller
Field Value
ServiceLocatorInstaller
Declaration
public ServiceLocatorInstaller ServiceLocatorInstaller
Field Value
SoundMixerInstaller
Declaration
public UnitySoundMixerInstaller SoundMixerInstaller
Field Value
StructuredLogInstallers
Declaration
public List<UnityStructuredLogInstaller> StructuredLogInstallers
Field Value
StructuredLogSettings
Declaration
public List<UnityStructuredLogSettings> StructuredLogSettings
Field Value
SystemConfigurationInstaller
Declaration
public UnitySystemConfigurationInstaller SystemConfigurationInstaller
Field Value
SystemConfigurationSettings
Declaration
public UnitySystemConfigurationSettings SystemConfigurationSettings
Field Value
TaskBuildContext
Declaration
public TaskBuildContext TaskBuildContext
Field Value
TimerInstaller
Declaration
public UnityTimerInstaller TimerInstaller
Field Value
UiInstaller
Declaration
public UnityUiInstaller UiInstaller
Field Value
UiSettings
Declaration
public UnityUiSettings UiSettings
Field Value
ViewBrowserInstaller
Declaration
public ViewBrowserInstaller ViewBrowserInstaller
Field Value
ViewElementFactory
Declaration
public UnityViewElementFactory ViewElementFactory
Field Value
ViewRouter
Declaration
public IViewRouter ViewRouter
Field Value
gameSettingsFile
Declaration
public string gameSettingsFile
Field Value
Methods
Awake()
Declaration
DisableGameWrapper()
Declaration
public void DisableGameWrapper()
EnableAudioServices()
Enables all audio services.
Declaration
public void EnableAudioServices()
EnableGameWrapper()
Declaration
public void EnableGameWrapper()
Enables all input service controllers.
Declaration
public void EnableInputServiceControllers()
EnableMusicService()
Enables the music service.
Declaration
public void EnableMusicService()
FinishInstallation()
Finishes the installation process.
Declaration
public IEnumerator FinishInstallation()
Returns
| Type |
Description |
| IEnumerator |
An IEnumerator for coroutine execution.
|
GetLogServiceFromRoute(Type, UnityLogProfile)
Resolves the log service configured for an installer type, honouring the active log profile.
Declaration
public ILogService GetLogServiceFromRoute(Type targetInstallerType, UnityLogProfile logProfile = null)
Parameters
| Type |
Name |
Description |
| Type |
targetInstallerType |
The installer the log route is configured against.
|
| UnityLogProfile |
logProfile |
The profile to route through, or null to use the wired one.
|
Returns
| Type |
Description |
| ILogService |
The routed log service, or null when none could be resolved.
|
InstallAudioPlayers()
Installs the audio players services.
Declaration
public void InstallAudioPlayers()
InstallBootstrapServices()
Installs the core bootstrap services required for the Serenity foundation.
Declaration
public void InstallBootstrapServices()
InstallCascadeViews()
Declaration
public void InstallCascadeViews()
InstallCompositeViews()
Builds and registers composite custom views. Called by InstallMenu().
Declaration
public void InstallCompositeViews()
InstallConsoleLogService()
Installs the console log service.
Declaration
public void InstallConsoleLogService()
InstallCutscenePlayer()
Installs the cutscene player service.
Declaration
public void InstallCutscenePlayer()
InstallEventDispatcher()
Installs the event dispatcher service.
Declaration
public void InstallEventDispatcher()
InstallFeedback()
Installs the feedback (haptics) service.
Declaration
public void InstallFeedback()
InstallFileLogService()
Installs the file log service.
Declaration
public void InstallFileLogService()
InstallGameCamera()
Installs the game camera (registry, active-camera switching, split-screen) service.
Declaration
public void InstallGameCamera()
InstallGameGraphics()
Installs the game graphics service.
Declaration
public void InstallGameGraphics()
InstallGameMode()
Installs the game mode service for managing Menu/Game/Pause states.
Declaration
public void InstallGameMode()
InstallGameProgress()
Installs the game-progress (global completion count/unlocked extras) service.
Runs as an Initialization Pipeline reflection task (see the InstallGameProgress
task asset), no longer during bootstrap.
Declaration
public void InstallGameProgress()
InstallGameSave()
Installs the game-save (slot-based save/load) service. Runs as an
Initialization Pipeline reflection task (see the InstallGameSave task asset),
no longer during bootstrap.
Declaration
public void InstallGameSave()
InstallGameSettings()
Installs the game settings service.
Declaration
public void InstallGameSettings()
InstallGameUi()
Installs the game-UI (HUD, results and screen presenters) service. Runs as an
Initialization Pipeline reflection task (see the InstallGameUi task asset), like
the leaderboard and game-progress services.
Declaration
public void InstallGameUi()
InstallInitializationPipeline()
Installs the initialization pipeline.
Declaration
public void InstallInitializationPipeline()
InstallLeaderboard()
Installs the leaderboard (score submission/ranking) service. Runs as an
Initialization Pipeline reflection task (see the InstallLeaderboard task asset),
no longer during bootstrap.
Declaration
public void InstallLeaderboard()
InstallLeaderboardViews()
Builds and registers leaderboard views. Called by InstallMenu(), and again by
InstallLeaderboard() when that task runs after the menus — idempotent so the
views are only ever built by whichever of the two runs with both tiers available. The guard
relies on Install(IUnityInstallationContext) returning null when the
leaderboard backend is not installed yet: a skipped attempt must not count as installed.
Declaration
public void InstallLeaderboardViews()
InstallLocalization()
Installs the localization service, or its Resources-only fallback.
Declaration
public void InstallLocalization()
Installs the menu service, then the view subsystems that build on top of it.
Declaration
public void InstallMenu()
InstallModal()
Installs the modal service and its components.
Declaration
public void InstallModal()
InstallMusicPlayers()
Installs the music players services.
Declaration
public void InstallMusicPlayers()
Installs the playerInput service.
Declaration
public void InstallPlayerInput()
InstallScore()
Installs the score (multi-metric scoreboard) service. Runs as an Initialization
Pipeline reflection task (see the InstallScore task asset), closing the boot-race
window during which gameplay content under GameWrapper is inactive.
Declaration
public void InstallScore()
InstallSoundMixer()
Installs the console log service.
Declaration
public void InstallSoundMixer()
InstallStructuredLogService()
Installs the structured log sink services, one per configured settings asset.
Declaration
public void InstallStructuredLogService()
InstallSystemConfiguration()
Installs the system configuration service.
Declaration
public void InstallSystemConfiguration()
InstallTaskBuildContext()
Installs the TaskBuildContext.
Declaration
public void InstallTaskBuildContext()
InstallTimer()
Installs the timer service.
Declaration
public void InstallTimer()
InstallUi()
Installs the UI service and its components.
Declaration
InstallUnityViewElementFactory()
Installs the persistence services.
Declaration
public void InstallUnityViewElementFactory()
InstallViewBrowser()
Installs the view browser service and its use cases.
Declaration
public void InstallViewBrowser()
RegisterService<T>(T)
Declaration
public void RegisterService<T>(T service) where T : class
Parameters
| Type |
Name |
Description |
| T |
service |
|
Type Parameters
Returns from the main menu to the primary input gate.
Declaration
public void ReturnToPrimaryInputGate()
RunInitializationPipeline()
Runs the initialization pipeline asynchronously.
Declaration
public void RunInitializationPipeline()
Shows the initial/root view (menu or custom view) via the top-level view router.
Declaration
Shows the primary input view.
Declaration
public void ShowPrimaryInputView()
Start()
Declaration
WrapServices()
Parents every installed service under a single wrapper object.
Declaration
public void WrapServices()
Implements