Платформер враги, инфраструктура, герой
This commit is contained in:
1 parent
28125eb382
commit
93819c1dd3
61 files changed
+1463
-423
No files matched your search
+38
@@ -0,0 +1,38 @@
|
||||
|
||||
|
||||
// retard-generated
|
||||
|
||||
using Code.Infrastructure.EventBus;
|
||||
using Code.Infrastructure.StateMachine;
|
||||
using Code.Infrastructure.UI;
|
||||
|
||||
namespace Code.Example.Race.UI
|
||||
{
|
||||
public partial class PlayerScoreCounter
|
||||
{
|
||||
|
||||
public override void FireCreatedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IPlayerScoreCounterCreatedHandle>(h => h.PlayerScoreCounterCreated(this));
|
||||
}
|
||||
|
||||
public override void FireRemovedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IPlayerScoreCounterRemovedHandle>(h => h.PlayerScoreCounterRemoved());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public interface IPlayerScoreCounterCreatedHandle : IGlobalSubscriber
|
||||
{
|
||||
void PlayerScoreCounterCreated(UIPanel panel);
|
||||
}
|
||||
|
||||
public interface IPlayerScoreCounterRemovedHandle : IGlobalSubscriber
|
||||
{
|
||||
void PlayerScoreCounterRemoved();
|
||||
}
|
||||
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 3e7bcd1ea1d0c9d409ebc2fbfb7bcbda
|
||||
@@ -0,0 +1,38 @@
|
||||
|
||||
|
||||
// retard-generated
|
||||
|
||||
using Code.Infrastructure.EventBus;
|
||||
using Code.Infrastructure.StateMachine;
|
||||
using Code.Infrastructure.UI;
|
||||
|
||||
namespace Code.Example.Race.UI
|
||||
{
|
||||
public partial class PlayerScores
|
||||
{
|
||||
|
||||
public override void FireCreatedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IPlayerScoresCreatedHandle>(h => h.PlayerScoresCreated(this));
|
||||
}
|
||||
|
||||
public override void FireRemovedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IPlayerScoresRemovedHandle>(h => h.PlayerScoresRemoved());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public interface IPlayerScoresCreatedHandle : IGlobalSubscriber
|
||||
{
|
||||
void PlayerScoresCreated(UIPanel panel);
|
||||
}
|
||||
|
||||
public interface IPlayerScoresRemovedHandle : IGlobalSubscriber
|
||||
{
|
||||
void PlayerScoresRemoved();
|
||||
}
|
||||
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ed4ee430bfb443e45888c6b7c8d9737a
|
||||
@@ -0,0 +1,38 @@
|
||||
|
||||
|
||||
// retard-generated
|
||||
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.EventBus;
|
||||
using Code.Infrastructure.StateMachine;
|
||||
|
||||
namespace Code.Example.Race.UI
|
||||
{
|
||||
public partial class WinScreen
|
||||
{
|
||||
|
||||
public override void FireCreatedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IWinScreenCreatedHandle>(h => h.WinScreenCreated(this));
|
||||
}
|
||||
|
||||
public override void FireRemovedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IWinScreenRemovedHandle>(h => h.WinScreenRemoved());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public interface IWinScreenCreatedHandle : IGlobalSubscriber
|
||||
{
|
||||
void WinScreenCreated(UIPanel panel);
|
||||
}
|
||||
|
||||
public interface IWinScreenRemovedHandle : IGlobalSubscriber
|
||||
{
|
||||
void WinScreenRemoved();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 316bf9eb00546714d8ae3e96b0f563f7
|
||||
@@ -5,10 +5,10 @@ using Code.Infrastructure.StateMachine;
|
||||
|
||||
using Code.Infrastructure.App.States;
|
||||
|
||||
using Code.Infrastructure.App.States;
|
||||
|
||||
using Code.Example.Platformer;
|
||||
|
||||
using Code.Infrastructure.App.States;
|
||||
|
||||
using Code.Infrastructure.App.States;
|
||||
|
||||
#pragma warning restore CS0105
|
||||
@@ -21,18 +21,18 @@ public partial class AppStateMachine : AbstractStateMachine<Code.Infrastructure.
|
||||
public AppStateMachine(Code.Infrastructure.App.AppStateMachineContext context, EventBus.EventBus eventBus) : base(context)
|
||||
{
|
||||
|
||||
var stateMainMenuState = new MainMenuState(StateMachineContext,eventBus);
|
||||
States.Add(stateMainMenuState.myState, stateMainMenuState);
|
||||
|
||||
var statePlatformerState = new PlatformerState(StateMachineContext,eventBus);
|
||||
States.Add(statePlatformerState.myState, statePlatformerState);
|
||||
|
||||
var stateGameplayState = new GameplayState(StateMachineContext,eventBus);
|
||||
States.Add(stateGameplayState.myState, stateGameplayState);
|
||||
|
||||
var stateBootstrapState = new BootstrapState(StateMachineContext,eventBus);
|
||||
States.Add(stateBootstrapState.myState, stateBootstrapState);
|
||||
|
||||
var statePlatformerState = new PlatformerState(StateMachineContext,eventBus);
|
||||
States.Add(statePlatformerState.myState, statePlatformerState);
|
||||
|
||||
var stateMainMenuState = new MainMenuState(StateMachineContext,eventBus);
|
||||
States.Add(stateMainMenuState.myState, stateMainMenuState);
|
||||
|
||||
}
|
||||
|
||||
protected override bool CheckTransitionAllowed(Code.Infrastructure.App.AppStates nextState) => AllowedStates.HasFlag(nextState);
|
||||
|
||||
+3
-3
@@ -17,12 +17,12 @@ public partial class CameraStateMachine : AbstractStateMachine<Code.Infrastructu
|
||||
public CameraStateMachine(Code.Infrastructure.Camera.CameraStateMachineContext context, EventBus.EventBus eventBus) : base(context)
|
||||
{
|
||||
|
||||
var stateNoneCameraState = new NoneCameraState(StateMachineContext,eventBus);
|
||||
States.Add(stateNoneCameraState.myState, stateNoneCameraState);
|
||||
|
||||
var stateThirdPersonState = new ThirdPersonState(StateMachineContext,eventBus);
|
||||
States.Add(stateThirdPersonState.myState, stateThirdPersonState);
|
||||
|
||||
var stateNoneCameraState = new NoneCameraState(StateMachineContext,eventBus);
|
||||
States.Add(stateNoneCameraState.myState, stateNoneCameraState);
|
||||
|
||||
}
|
||||
|
||||
protected override bool CheckTransitionAllowed(Code.Infrastructure.Camera.CameraMode nextState) => AllowedStates.HasFlag(nextState);
|
||||
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
|
||||
|
||||
// retard-generated
|
||||
|
||||
using Code.Infrastructure.EventBus;
|
||||
using Code.Infrastructure.StateMachine;
|
||||
|
||||
namespace Code.Infrastructure.UI.Panels
|
||||
{
|
||||
public partial class LoadingPanel
|
||||
{
|
||||
|
||||
public override void FireCreatedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<ILoadingPanelCreatedHandle>(h => h.LoadingPanelCreated(this));
|
||||
}
|
||||
|
||||
public override void FireRemovedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<ILoadingPanelRemovedHandle>(h => h.LoadingPanelRemoved());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public interface ILoadingPanelCreatedHandle : IGlobalSubscriber
|
||||
{
|
||||
void LoadingPanelCreated(UIPanel panel);
|
||||
}
|
||||
|
||||
public interface ILoadingPanelRemovedHandle : IGlobalSubscriber
|
||||
{
|
||||
void LoadingPanelRemoved();
|
||||
}
|
||||
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 366a0dfcffa8af64a9692870e278d0ff
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
|
||||
|
||||
// retard-generated
|
||||
|
||||
using Code.Infrastructure.EventBus;
|
||||
using Code.Infrastructure.StateMachine;
|
||||
|
||||
namespace Code.Infrastructure.UI.Panels
|
||||
{
|
||||
public partial class LogoPanel
|
||||
{
|
||||
|
||||
public override void FireCreatedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<ILogoPanelCreatedHandle>(h => h.LogoPanelCreated(this));
|
||||
}
|
||||
|
||||
public override void FireRemovedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<ILogoPanelRemovedHandle>(h => h.LogoPanelRemoved());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public interface ILogoPanelCreatedHandle : IGlobalSubscriber
|
||||
{
|
||||
void LogoPanelCreated(UIPanel panel);
|
||||
}
|
||||
|
||||
public interface ILogoPanelRemovedHandle : IGlobalSubscriber
|
||||
{
|
||||
void LogoPanelRemoved();
|
||||
}
|
||||
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c5614b342dee1c34cb8a1f79905cdb24
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
|
||||
|
||||
// retard-generated
|
||||
|
||||
using Code.Infrastructure.EventBus;
|
||||
using Code.Infrastructure.StateMachine;
|
||||
|
||||
namespace Code.Infrastructure.UI.Panels
|
||||
{
|
||||
public partial class MenuChoosePanel
|
||||
{
|
||||
|
||||
public override void FireCreatedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IMenuChoosePanelCreatedHandle>(h => h.MenuChoosePanelCreated(this));
|
||||
}
|
||||
|
||||
public override void FireRemovedEvent()
|
||||
{
|
||||
_eventBus.RaiseEvent<IMenuChoosePanelRemovedHandle>(h => h.MenuChoosePanelRemoved());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public interface IMenuChoosePanelCreatedHandle : IGlobalSubscriber
|
||||
{
|
||||
void MenuChoosePanelCreated(UIPanel panel);
|
||||
}
|
||||
|
||||
public interface IMenuChoosePanelRemovedHandle : IGlobalSubscriber
|
||||
{
|
||||
void MenuChoosePanelRemoved();
|
||||
}
|
||||
|
||||
}
|
||||
+2
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a8d4139d7ff2ab94e94b856369f4e30a
|
||||
@@ -1,18 +1,18 @@
|
||||
|
||||
#pragma warning disable CS0105
|
||||
using Code.Example.Race.Racer;
|
||||
using Code.Infrastructure.Camera;
|
||||
using Code.Infrastructure.Configs;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Camera;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.SceneLoader;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Volume;
|
||||
using Code.Example.Platformer.Entity;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Input;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Example.Platformer.Entity;
|
||||
using Code.Infrastructure.Configs;
|
||||
using Code.Example.Race.Racer;
|
||||
using Code.Infrastructure.Camera;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.Camera;
|
||||
|
||||
using UnityEngine;
|
||||
#pragma warning restore CS0105
|
||||
@@ -26,32 +26,32 @@ using Code.Infrastructure.Input;
|
||||
{
|
||||
SystemConfigsReferences systemConfigsReferences = Resources.Load<SystemConfigsReferences>("SystemConfigsReferences");
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Example.Race.Racer.RacerSettingsConfig), systemConfigsReferences.RacerSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Camera.CameraSettingsConfig), systemConfigsReferences.CameraSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Configs.LayerMasksConfigConfig), systemConfigsReferences.LayerMasksConfig);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.Audio.AudioSourcePrefabConfig), systemConfigsReferences.AudioSourcePrefab);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.Camera.GameCameraConfig), systemConfigsReferences.GameCamera);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.UI.CanvasSettingsConfig), systemConfigsReferences.CanvasSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.UI.UIPanelSettingsConfig), systemConfigsReferences.UIPanelSettings);
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Audio.AudioSourceSettingsConfig), systemConfigsReferences.AudioSourceSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.SceneLoader.SceneInfoConfig), systemConfigsReferences.SceneInfo);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Audio.AudioInfoConfig), systemConfigsReferences.AudioInfo);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Volume.VolumeSettingsConfig), systemConfigsReferences.VolumeSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Example.Platformer.Entity.PlatformerEnemySettingsConfig), systemConfigsReferences.PlatformerEnemySettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Audio.AudioSourceSettingsConfig), systemConfigsReferences.AudioSourceSettings);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.Input.InputServiceConfig), systemConfigsReferences.InputService);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.UI.UIPanelSettingsConfig), systemConfigsReferences.UIPanelSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Example.Platformer.Entity.PlatformerEntitySettingsConfig), systemConfigsReferences.PlatformerEnemySettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Configs.LayerMasksConfigConfig), systemConfigsReferences.LayerMasksConfig);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Example.Race.Racer.RacerSettingsConfig), systemConfigsReferences.RacerSettings);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.Camera.GameCameraConfig), systemConfigsReferences.GameCamera);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Audio.AudioInfoConfig), systemConfigsReferences.AudioInfo);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.Audio.AudioSourcePrefabConfig), systemConfigsReferences.AudioSourcePrefab);
|
||||
|
||||
_singleConfigReferences.Add(typeof(Code.Infrastructure.UI.CanvasSettingsConfig), systemConfigsReferences.CanvasSettings);
|
||||
|
||||
_multipleConfigReferences.Add(typeof(Code.Infrastructure.Camera.CameraSettingsConfig), systemConfigsReferences.CameraSettings);
|
||||
|
||||
//_singleConfigReferences.Add(typeof(ScenesAssetReferences), systemConfigsReferences.scenesAssetReferences);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,9 +9,9 @@ using UnityEngine.AddressableAssets;
|
||||
namespace Code.Example.Platformer.Entity{
|
||||
#pragma warning restore CS0105
|
||||
[CreateAssetMenu(fileName = "PlatformerEnemySettingsConfig", menuName = "Configs/Gameplay/Platformer/EnemySettings")]
|
||||
public class PlatformerEnemySettingsConfig : ScriptableObject
|
||||
public class PlatformerEntitySettingsConfig : ScriptableObject
|
||||
{
|
||||
public Code.Example.Platformer.Entity.PlatformerEnemyData racerData;
|
||||
public Code.Example.Platformer.Entity.PlatformerEntityData racerData;
|
||||
public UnityEngine.AddressableAssets.AssetReference prefabReference;
|
||||
|
||||
}
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
|
||||
#pragma warning disable CS0105
|
||||
using Code.Example.Race.Racer;
|
||||
using Code.Infrastructure.Camera;
|
||||
using Code.Infrastructure.Configs;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Camera;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.SceneLoader;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Volume;
|
||||
using Code.Example.Platformer.Entity;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Input;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Example.Platformer.Entity;
|
||||
using Code.Infrastructure.Configs;
|
||||
using Code.Example.Race.Racer;
|
||||
using Code.Infrastructure.Camera;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.Audio;
|
||||
using Code.Infrastructure.UI;
|
||||
using Code.Infrastructure.Camera;
|
||||
|
||||
using UnityEngine.AddressableAssets;
|
||||
#pragma warning restore CS0105
|
||||
@@ -20,19 +20,19 @@ using Code.Infrastructure.Input;
|
||||
namespace Code.Infrastructure.Configs{
|
||||
public partial class SystemConfigsReferences
|
||||
{
|
||||
public string RacerSettings;
|
||||
public string CameraSettings;
|
||||
public string LayerMasksConfig;
|
||||
public AssetReference AudioSourcePrefab;
|
||||
public AssetReference GameCamera;
|
||||
public AssetReference CanvasSettings;
|
||||
public string UIPanelSettings;
|
||||
public string AudioSourceSettings;
|
||||
public string SceneInfo;
|
||||
public string AudioInfo;
|
||||
public string VolumeSettings;
|
||||
public string PlatformerEnemySettings;
|
||||
public string AudioSourceSettings;
|
||||
public AssetReference InputService;
|
||||
public string UIPanelSettings;
|
||||
public string PlatformerEnemySettings;
|
||||
public string LayerMasksConfig;
|
||||
public string RacerSettings;
|
||||
public AssetReference GameCamera;
|
||||
public string AudioInfo;
|
||||
public AssetReference AudioSourcePrefab;
|
||||
public AssetReference CanvasSettings;
|
||||
public string CameraSettings;
|
||||
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,7 @@
|
||||
#pragma warning disable CS0105
|
||||
using UnityEngine.AddressableAssets;
|
||||
using Code.Infrastructure.UI;
|
||||
using System;
|
||||
|
||||
using UnityEngine;
|
||||
using UnityEngine.AddressableAssets;
|
||||
@@ -13,6 +14,7 @@ public class UIPanelSettingsConfig : ScriptableObject
|
||||
{
|
||||
public UnityEngine.AddressableAssets.AssetReference Prefab;
|
||||
public Code.Infrastructure.UI.UIPanelType UIPanelType;
|
||||
public System.Boolean Multiple;
|
||||
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user