private void Inject(MainSettingsModelSO mainSettingsModel, ILoggerProvider loggerProvider, IAvatarInput input, SpawnedAvatar spawnedAvatar, VRPlatformHelper vrPlatformHelper, AvatarTailor tailor)
 {
     _mainSettingsModel = mainSettingsModel;
     _logger            = loggerProvider.CreateLogger <AvatarTracking>(spawnedAvatar.avatar.descriptor.name);
     _input             = input;
     _spawnedAvatar     = spawnedAvatar;
     _vrPlatformHelper  = vrPlatformHelper;
     _tailor            = tailor;
 }
Exemple #2
0
 private PlayerAvatarManager(DiContainer container, AvatarTailor avatarTailor, ILoggerProvider loggerProvider, AvatarLoader avatarLoader, Settings settings, AvatarSpawner spawner)
 {
     _container    = container;
     _logger       = loggerProvider.CreateLogger <PlayerAvatarManager>();
     _avatarLoader = avatarLoader;
     _avatarTailor = avatarTailor;
     _settings     = settings;
     _spawner      = spawner;
 }
Exemple #3
0
        private void Inject(MainSettingsModelSO mainSettingsModel, ILoggerProvider loggerProvider, IAvatarInput input, SpawnedAvatar avatar, VRPlatformHelper vrPlatformHelper, AvatarTailor tailor)
        {
            _mainSettingsModel = mainSettingsModel;
            _logger            = loggerProvider.CreateLogger <AvatarTracking>(avatar.avatar.descriptor.name);
            _input             = input;
            _avatar            = avatar;
            _vrPlatformHelper  = vrPlatformHelper;
            _tailor            = tailor;

            if (_avatar.pelvis)
            {
                _initialPelvisPose = new Pose(_avatar.pelvis.position, _avatar.pelvis.rotation);
            }
            if (_avatar.leftLeg)
            {
                _initialLeftFootPose = new Pose(_avatar.leftLeg.position, _avatar.leftLeg.rotation);
            }
            if (_avatar.rightLeg)
            {
                _initialRightFootPose = new Pose(_avatar.rightLeg.position, _avatar.rightLeg.rotation);
            }
        }