feat: add shoot and cooldown systems

This commit is contained in:
Bragin Stepan
2026-02-21 23:53:45 +05:00
parent 2affd03993
commit af20400b84
25 changed files with 1174 additions and 233 deletions

View File

@@ -34,6 +34,7 @@ namespace Assets._Project.Develop.Runtime.Utilities.SceneManagement
public static class Entity public static class Entity
{ {
public const string Projectile = "Entities/Projectile";
public const string Hero = "Entities/Hero"; public const string Hero = "Entities/Hero";
public const string Ghost = "Entities/Ghost"; public const string Ghost = "Entities/Ghost";
} }

View File

@@ -1,5 +1,7 @@
using _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems; using _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems;
using _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems.Shoot;
using _Project.Develop.Runtime.Logic.Gameplay.Features.Damage; using _Project.Develop.Runtime.Logic.Gameplay.Features.Damage;
using _Project.Develop.Runtime.Logic.Gameplay.Features.Input;
using _Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.Systems; using _Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.Systems;
using _Project.Develop.Runtime.Logic.Gameplay.Features.Movement; using _Project.Develop.Runtime.Logic.Gameplay.Features.Movement;
using _Project.Develop.Runtime.Logic.Gameplay.Features.Sensors.Systems; using _Project.Develop.Runtime.Logic.Gameplay.Features.Sensors.Systems;
@@ -55,7 +57,12 @@ namespace _Project.Develop.Runtime.Entities
.AddStartAttackEvent() .AddStartAttackEvent()
.AddEndAttackEvent() .AddEndAttackEvent()
.AddAttackDelayTime(new ReactiveVariable<float>(2)) .AddAttackDelayTime(new ReactiveVariable<float>(2))
.AddAttackDelayEndEvent(); .AddAttackDelayEndEvent()
.AddInstantAttackDamage(new ReactiveVariable<float>(50))
.AddAttackCanceledEvent()
.AddAttackCooldownInitialTime()
.AddAttackCooldownCurrentTime()
.AddInAttackCooldown();
ICompositeCondition canMove = new CompositeCondition() ICompositeCondition canMove = new CompositeCondition()
.Add(new FuncCondition(() => entity.IsDead.Value == false)); .Add(new FuncCondition(() => entity.IsDead.Value == false));
@@ -76,7 +83,12 @@ namespace _Project.Develop.Runtime.Entities
ICompositeCondition canStartAttack = new CompositeCondition() ICompositeCondition canStartAttack = new CompositeCondition()
.Add(new FuncCondition(() => entity.IsDead.Value == false)) .Add(new FuncCondition(() => entity.IsDead.Value == false))
.Add(new FuncCondition(() => entity.InAttackProcess.Value == false)) .Add(new FuncCondition(() => entity.InAttackProcess.Value == false))
.Add(new FuncCondition(() => entity.IsMoving.Value == false)); .Add(new FuncCondition(() => entity.IsMoving.Value == false))
.Add(new FuncCondition(() => entity.InAttackCooldown.Value == false));
ICompositeCondition mustCancelAttack = new CompositeCondition(LogicOperationsUtils.Or)
.Add(new FuncCondition(() => entity.IsDead.Value))
.Add(new FuncCondition(() => entity.IsMoving.Value));
entity entity
.AddCanMove(canMove) .AddCanMove(canMove)
@@ -84,18 +96,24 @@ namespace _Project.Develop.Runtime.Entities
.AddCanApplyDamage(canApplyDamage) .AddCanApplyDamage(canApplyDamage)
.AddMustDie(mustDie) .AddMustDie(mustDie)
.AddCanStartAttack(canStartAttack) .AddCanStartAttack(canStartAttack)
.AddMustSelfRelease(mustSelfRelease); .AddMustSelfRelease(mustSelfRelease)
.AddMustCancelAttack(mustCancelAttack);
entity entity
.AddSystem(new AttackByInputSystem(_playerInput))
.AddSystem(new MoveDirectionByInputSystem(_playerInput)) .AddSystem(new MoveDirectionByInputSystem(_playerInput))
.AddSystem(new RotateDirectionByMoveInputSystem(_playerInput)) .AddSystem(new RotateDirectionByMoveInputSystem(_playerInput))
.AddSystem(new RigidbodyMovementSystem()) .AddSystem(new RigidbodyMovementSystem())
.AddSystem(new RigidbodyRotationSystem()) .AddSystem(new RigidbodyRotationSystem())
.AddSystem(new AttackCancelSystem())
.AddSystem(new StartAttackSystem()) .AddSystem(new StartAttackSystem())
.AddSystem(new ProcessAttackTimerSystem()) .AddSystem(new ProcessAttackTimerSystem())
.AddSystem(new AttackDelayEndTriggerSystem()) .AddSystem(new AttackDelayEndTriggerSystem())
.AddSystem(new InstantShootSystem(this))
.AddSystem(new EndAttackSystem()) .AddSystem(new EndAttackSystem())
.AddSystem(new AttackCooldownTimerSystem())
.AddSystem(new ApplyDamageSystem()) .AddSystem(new ApplyDamageSystem())
@@ -178,6 +196,63 @@ namespace _Project.Develop.Runtime.Entities
return entity; return entity;
} }
public Entity CreateProjectile(Vector3 position, Vector3 direction, float damage)
{
Entity entity = CreateEmpty();
_monoEntitiesFactory.Create(entity, position, PathToResources.Entity.Projectile);
entity
.AddContactsDetectingMask(Layers.CharactersMask | Layers.EnvironmentMask)
.AddContactCollidersBuffer(new Buffer<Collider>(64))
.AddContactEntitiesBuffer(new Buffer<Entity>(64))
.AddMoveDirection(new ReactiveVariable<Vector3>(direction))
.AddRotateDirection(new ReactiveVariable<Vector3>(direction))
.AddMoveSpeed(new ReactiveVariable<float>(16))
.AddRotationSpeed(new ReactiveVariable<float>(9999))
.AddBodyContactDamage(new ReactiveVariable<float>(damage))
.AddIsDead()
.AddIsMoving()
.AddDeathMask(Layers.CharactersMask | Layers.EnvironmentMask)
.AddIsTouchDeathMask();
ICompositeCondition canMove = new CompositeCondition()
.Add(new FuncCondition(() => entity.IsDead.Value == false));
ICompositeCondition canRotate = new CompositeCondition()
.Add(new FuncCondition(() => entity.IsDead.Value == false));
ICompositeCondition mustDie = new CompositeCondition()
.Add(new FuncCondition(() => entity.IsTouchDeathMask.Value), 0);
ICompositeCondition mustSelfRelease = new CompositeCondition()
.Add(new FuncCondition(() => entity.IsDead.Value));
entity
.AddCanMove(canMove)
.AddCanRotate(canRotate)
.AddMustDie(mustDie)
.AddMustSelfRelease(mustSelfRelease);
entity
.AddSystem(new RigidbodyMovementSystem())
.AddSystem(new RigidbodyRotationSystem())
.AddSystem(new BodyContactsDetectingSystem())
.AddSystem(new BodyContactsEntitiesFilterSystem(_collidersRegistryService))
.AddSystem(new DealDamageOnContactSystem())
.AddSystem(new DeathMaskTouchDetectorSystem())
.AddSystem(new DeathSwitcherSystem())
.AddSystem(new DisableCollidersOnDeathSystem())
.AddSystem(new SelfReleaseSystem(_entitiesLifeContext));
_entitiesLifeContext.Add(entity);
return entity;
}
private Entity CreateEmpty() => new(); private Entity CreateEmpty() => new();
} }

View File

@@ -221,6 +221,207 @@ namespace _Project.Develop.Runtime.Entities
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Sensors.IsTouchAnotherTeam() {Value = value}); return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Sensors.IsTouchAnotherTeam() {Value = value});
} }
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection MoveDirectionC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> MoveDirection => MoveDirectionC.Value;
public bool TryGetMoveDirection(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddMoveDirection()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>() });
}
public _Project.Develop.Runtime.Entities.Entity AddMoveDirection(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed MoveSpeedC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> MoveSpeed => MoveSpeedC.Value;
public bool TryGetMoveSpeed(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddMoveSpeed()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddMoveSpeed(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving IsMovingC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> IsMoving => IsMovingC.Value;
public bool TryGetIsMoving(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddIsMoving()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean>() });
}
public _Project.Develop.Runtime.Entities.Entity AddIsMoving(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove CanMoveC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanMove => CanMoveC.Value;
public bool TryGetCanMove(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanMove(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection RotateDirectionC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> RotateDirection => RotateDirectionC.Value;
public bool TryGetRotateDirection(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddRotateDirection()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>() });
}
public _Project.Develop.Runtime.Entities.Entity AddRotateDirection(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed RotationSpeedC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> RotationSpeed => RotationSpeedC.Value;
public bool TryGetRotationSpeed(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddRotationSpeed()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddRotationSpeed(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate CanRotateC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanRotate => CanRotateC.Value;
public bool TryGetCanRotate(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanRotate(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce JumpForceC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> JumpForce => JumpForceC.Value;
public bool TryGetJumpForce(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddJumpForce()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddJumpForce(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump CanJumpC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanJump => CanJumpC.Value;
public bool TryGetCanJump(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanJump(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.CurrentHealth CurrentHealthC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.CurrentHealth>(); public _Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.CurrentHealth CurrentHealthC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.CurrentHealth>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> CurrentHealth => CurrentHealthC.Value; public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> CurrentHealth => CurrentHealthC.Value;
@@ -427,207 +628,6 @@ namespace _Project.Develop.Runtime.Entities
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.DisableCollidersOnDeath() {Value = value}); return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Lifetime.DisableCollidersOnDeath() {Value = value});
} }
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection MoveDirectionC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> MoveDirection => MoveDirectionC.Value;
public bool TryGetMoveDirection(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddMoveDirection()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>() });
}
public _Project.Develop.Runtime.Entities.Entity AddMoveDirection(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveDirection() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed MoveSpeedC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> MoveSpeed => MoveSpeedC.Value;
public bool TryGetMoveSpeed(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddMoveSpeed()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddMoveSpeed(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.MoveSpeed() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving IsMovingC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> IsMoving => IsMovingC.Value;
public bool TryGetIsMoving(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddIsMoving()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean>() });
}
public _Project.Develop.Runtime.Entities.Entity AddIsMoving(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.IsMoving() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove CanMoveC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanMove => CanMoveC.Value;
public bool TryGetCanMove(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanMove(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanMove() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection RotateDirectionC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> RotateDirection => RotateDirectionC.Value;
public bool TryGetRotateDirection(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddRotateDirection()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3>() });
}
public _Project.Develop.Runtime.Entities.Entity AddRotateDirection(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<UnityEngine.Vector3> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotateDirection() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed RotationSpeedC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> RotationSpeed => RotationSpeedC.Value;
public bool TryGetRotationSpeed(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddRotationSpeed()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddRotationSpeed(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.RotationSpeed() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate CanRotateC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanRotate => CanRotateC.Value;
public bool TryGetCanRotate(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanRotate(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanRotate() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce JumpForceC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> JumpForce => JumpForceC.Value;
public bool TryGetJumpForce(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddJumpForce()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddJumpForce(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.JumpForce() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump CanJumpC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanJump => CanJumpC.Value;
public bool TryGetCanJump(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanJump(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Movement.CanJump() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Damage.TakeDamageRequest TakeDamageRequestC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Damage.TakeDamageRequest>(); public _Project.Develop.Runtime.Logic.Gameplay.Features.Damage.TakeDamageRequest TakeDamageRequestC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Damage.TakeDamageRequest>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent<System.Single> TakeDamageRequest => TakeDamageRequestC.Value; public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent<System.Single> TakeDamageRequest => TakeDamageRequestC.Value;
@@ -719,6 +719,68 @@ namespace _Project.Develop.Runtime.Entities
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Damage.BodyContactDamage() {Value = value}); return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Damage.BodyContactDamage() {Value = value});
} }
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InstantAttackDamage InstantAttackDamageC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InstantAttackDamage>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> InstantAttackDamage => InstantAttackDamageC.Value;
public bool TryGetInstantAttackDamage(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InstantAttackDamage component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddInstantAttackDamage()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InstantAttackDamage() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddInstantAttackDamage(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InstantAttackDamage() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.ShootPoint ShootPointC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.ShootPoint>();
public UnityEngine.Transform ShootPoint => ShootPointC.Value;
public bool TryGetShootPoint(out UnityEngine.Transform value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.ShootPoint component);
if(result)
value = component.Value;
else
value = default(UnityEngine.Transform);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddShootPoint(UnityEngine.Transform value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.ShootPoint() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack CanStartAttackC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanStartAttack => CanStartAttackC.Value;
public bool TryGetCanStartAttack(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanStartAttack(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.StartAttackRequest StartAttackRequestC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.StartAttackRequest>(); public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.StartAttackRequest StartAttackRequestC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.StartAttackRequest>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent StartAttackRequest => StartAttackRequestC.Value; public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent StartAttackRequest => StartAttackRequestC.Value;
@@ -767,25 +829,6 @@ namespace _Project.Develop.Runtime.Entities
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.StartAttackEvent() {Value = value}); return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.StartAttackEvent() {Value = value});
} }
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack CanStartAttackC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition CanStartAttack => CanStartAttackC.Value;
public bool TryGetCanStartAttack(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddCanStartAttack(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.CanStartAttack() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.EndAttackEvent EndAttackEventC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.EndAttackEvent>(); public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.EndAttackEvent EndAttackEventC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.EndAttackEvent>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent EndAttackEvent => EndAttackEventC.Value; public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent EndAttackEvent => EndAttackEventC.Value;
@@ -930,5 +973,120 @@ namespace _Project.Develop.Runtime.Entities
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackDelayEndEvent() {Value = value}); return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackDelayEndEvent() {Value = value});
} }
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.MustCancelAttack MustCancelAttackC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.MustCancelAttack>();
public _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition MustCancelAttack => MustCancelAttackC.Value;
public bool TryGetMustCancelAttack(out _Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.MustCancelAttack component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddMustCancelAttack(_Project.Develop.Runtime.Utilities.Conditions.ICompositeCondition value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.MustCancelAttack() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCanceledEvent AttackCanceledEventC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCanceledEvent>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent AttackCanceledEvent => AttackCanceledEventC.Value;
public bool TryGetAttackCanceledEvent(out _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCanceledEvent component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddAttackCanceledEvent()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCanceledEvent() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent() });
}
public _Project.Develop.Runtime.Entities.Entity AddAttackCanceledEvent(_Project.Develop.Runtime.Utils.ReactiveManagement.Event.ReactiveEvent value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCanceledEvent() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownInitialTime AttackCooldownInitialTimeC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownInitialTime>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> AttackCooldownInitialTime => AttackCooldownInitialTimeC.Value;
public bool TryGetAttackCooldownInitialTime(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownInitialTime component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddAttackCooldownInitialTime()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownInitialTime() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddAttackCooldownInitialTime(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownInitialTime() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownCurrentTime AttackCooldownCurrentTimeC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownCurrentTime>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> AttackCooldownCurrentTime => AttackCooldownCurrentTimeC.Value;
public bool TryGetAttackCooldownCurrentTime(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownCurrentTime component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddAttackCooldownCurrentTime()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownCurrentTime() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single>() });
}
public _Project.Develop.Runtime.Entities.Entity AddAttackCooldownCurrentTime(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Single> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.AttackCooldownCurrentTime() {Value = value});
}
public _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InAttackCooldown InAttackCooldownC => GetComponent<_Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InAttackCooldown>();
public _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> InAttackCooldown => InAttackCooldownC.Value;
public bool TryGetInAttackCooldown(out _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> value)
{
bool result = TryGetComponent(out _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InAttackCooldown component);
if(result)
value = component.Value;
else
value = default(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean>);
return result;
}
public _Project.Develop.Runtime.Entities.Entity AddInAttackCooldown()
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InAttackCooldown() { Value = new _Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean>() });
}
public _Project.Develop.Runtime.Entities.Entity AddInAttackCooldown(_Project.Develop.Runtime.Utils.ReactiveManagement.ReactiveVariable<System.Boolean> value)
{
return AddComponent(new _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.InAttackCooldown() {Value = value});
}
} }
} }

View File

@@ -2,21 +2,30 @@
using _Project.Develop.Runtime.Utilities.Conditions; using _Project.Develop.Runtime.Utilities.Conditions;
using _Project.Develop.Runtime.Utils.ReactiveManagement; using _Project.Develop.Runtime.Utils.ReactiveManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement.Event; using _Project.Develop.Runtime.Utils.ReactiveManagement.Event;
using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack
{ {
public class StartAttackRequest : IEntityComponent { public ReactiveEvent Value; } public class InstantAttackDamage : IEntityComponent { public ReactiveVariable<float> Value; }
public class StartAttackEvent : IEntityComponent { public ReactiveEvent Value; }
public class ShootPoint : IEntityComponent { public Transform Value; }
public class CanStartAttack : IEntityComponent { public ICompositeCondition Value; } public class CanStartAttack : IEntityComponent { public ICompositeCondition Value; }
public class StartAttackRequest : IEntityComponent { public ReactiveEvent Value; }
public class StartAttackEvent : IEntityComponent { public ReactiveEvent Value; }
public class EndAttackEvent : IEntityComponent { public ReactiveEvent Value; } public class EndAttackEvent : IEntityComponent { public ReactiveEvent Value; }
public class AttackProcessInitialTime : IEntityComponent { public ReactiveVariable<float> Value; } public class AttackProcessInitialTime : IEntityComponent { public ReactiveVariable<float> Value; }
public class AttackProcessCurrentTime : IEntityComponent { public ReactiveVariable<float> Value; } public class AttackProcessCurrentTime : IEntityComponent { public ReactiveVariable<float> Value; }
public class InAttackProcess : IEntityComponent { public ReactiveVariable<bool> Value; } public class InAttackProcess : IEntityComponent { public ReactiveVariable<bool> Value; }
public class AttackDelayTime : IEntityComponent { public ReactiveVariable<float> Value; } public class AttackDelayTime : IEntityComponent { public ReactiveVariable<float> Value; }
public class AttackDelayEndEvent : IEntityComponent { public ReactiveEvent Value; } public class AttackDelayEndEvent : IEntityComponent { public ReactiveEvent Value; }
public class MustCancelAttack : IEntityComponent { public ICompositeCondition Value; }
public class AttackCanceledEvent : IEntityComponent { public ReactiveEvent Value; }
public class AttackCooldownInitialTime : IEntityComponent { public ReactiveVariable<float> Value; }
public class AttackCooldownCurrentTime : IEntityComponent { public ReactiveVariable<float> Value; }
public class InAttackCooldown : IEntityComponent { public ReactiveVariable<bool> Value; }
} }

View File

@@ -0,0 +1,15 @@
using _Project.Develop.Runtime.Entities;
using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack
{
public class ShootPointEntityRegistrator : MonoEntityRegistrator
{
[SerializeField] private Transform _shootPoint;
public override void Register(Entity entity)
{
entity.AddShootPoint(_shootPoint);
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 1675979b03c84ec3b990009a37f3d6d9
timeCreated: 1771692788

View File

@@ -0,0 +1,35 @@
using _Project.Develop.Runtime.Entities;
using _Project.Develop.Runtime.Utilities.Conditions;
using _Project.Develop.Runtime.Utils.ReactiveManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement.Event;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems
{
public class AttackCancelSystem : IInitializableSystem, IUpdatableSystem
{
private ReactiveVariable<bool> _inAttackProcess;
private ReactiveEvent _attackCanceledEvent;
private ICompositeCondition _mustCancelAttack;
public void OnInit(Entity entity)
{
_inAttackProcess = entity.InAttackProcess;
_attackCanceledEvent = entity.AttackCanceledEvent;
_mustCancelAttack = entity.MustCancelAttack;
}
public void OnUpdate(float deltaTime)
{
if (_inAttackProcess.Value == false)
return;
if (_mustCancelAttack.Evaluate())
{
_inAttackProcess.Value = false;
_attackCanceledEvent.Invoke();
}
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: afac0aa4f8e842d08a5326a7c89bcd53
timeCreated: 1771693765

View File

@@ -0,0 +1,53 @@
using System;
using _Project.Develop.Runtime.Entities;
using _Project.Develop.Runtime.Utils.ReactiveManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement.Event;
using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems
{
public class AttackCooldownTimerSystem : IInitializableSystem, IUpdatableSystem, IDisposableSystem
{
private ReactiveVariable<float> _currentTime;
private ReactiveVariable<float> _initialTime;
private ReactiveVariable<bool> _inAttackCooldown;
private ReactiveEvent _endAttackEvent;
private IDisposable _endAttackEventDisposable;
public void OnInit(Entity entity)
{
_currentTime = entity.AttackCooldownCurrentTime;
_initialTime = entity.AttackCooldownInitialTime;
_inAttackCooldown = entity.InAttackCooldown;
_endAttackEvent = entity.EndAttackEvent;
_endAttackEventDisposable = _endAttackEvent.Subscribe(OnEndAttack);
}
private void OnEndAttack()
{
_currentTime.Value = _initialTime.Value;
_inAttackCooldown.Value = true;
}
public void OnUpdate(float deltaTime)
{
if (_inAttackCooldown.Value == false)
return;
_currentTime.Value -= deltaTime;
if (CooldownIsOver())
_inAttackCooldown.Value = false;
}
private bool CooldownIsOver() => _currentTime.Value <= 0;
public void OnDispose()
{
_endAttackEventDisposable.Dispose();
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 781d9ce92c044a06b9279a90539e041b
timeCreated: 1771693960

View File

@@ -32,6 +32,11 @@ namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems
{ {
_inAttackProcess.Value = true; _inAttackProcess.Value = true;
_startAttackEvent.Invoke(); _startAttackEvent.Invoke();
Debug.Log("Старт атаки");
}
else
{
Debug.Log("Не могу атаковать!");
} }
} }

View File

@@ -0,0 +1,50 @@
using System;
using _Project.Develop.Runtime.Entities;
using _Project.Develop.Runtime.Utils.ReactiveManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement.Event;
using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Attack.Systems.Shoot
{
public class InstantShootSystem : IInitializableSystem, IDisposableSystem
{
private readonly EntitiesFactory _entitiesFactory;
private ReactiveEvent _attackDelayEndEvent;
private Entity _entity;
private ReactiveVariable<float> _damage;
private Transform _shootPoint;
private IDisposable _attackDelayEndDisposable;
public InstantShootSystem(EntitiesFactory entitiesFactory)
{
_entitiesFactory = entitiesFactory;
}
public void OnInit(Entity entity)
{
_entity = entity;
_attackDelayEndEvent = entity.AttackDelayEndEvent;
_damage = entity.InstantAttackDamage;
_shootPoint = entity.ShootPoint;
_attackDelayEndDisposable = _attackDelayEndEvent.Subscribe(OnAttackDelayEnd);
}
private void OnAttackDelayEnd()
{
_entitiesFactory.CreateProjectile(_shootPoint.position, _shootPoint.forward, _damage.Value);
}
public void OnDispose()
{
_attackDelayEndDisposable.Dispose();
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 8380bd6de9cc46cdbb48f281c3ce660e
timeCreated: 1771693051

View File

@@ -0,0 +1,36 @@
using _Project.Develop.Runtime.Entities;
using _Project.Develop.Runtime.Utils.InputManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement.Event;
using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Input
{
public class AttackByInputSystem : IInitializableSystem, IDisposableSystem
{
private readonly IPlayerInput _playerInput;
private ReactiveEvent _startAttackRequest;
public AttackByInputSystem(IPlayerInput playerInput)
{
_playerInput = playerInput;
}
public void OnInit(Entity entity)
{
_startAttackRequest = entity.StartAttackRequest;
_playerInput.Interact.Enter += OnAttackRequest;
}
private void OnAttackRequest(float value)
{
_startAttackRequest.Invoke();
}
public void OnDispose()
{
_playerInput.Interact.Enter -= OnAttackRequest;
}
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 3b9a5877786f409aa00af044e4b0ab10
timeCreated: 1771695880

View File

@@ -3,7 +3,7 @@ using _Project.Develop.Runtime.Utils.InputManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement; using _Project.Develop.Runtime.Utils.ReactiveManagement;
using UnityEngine; using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Movement namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Input
{ {
public class MoveDirectionByInputSystem : IInitializableSystem, IUpdatableSystem public class MoveDirectionByInputSystem : IInitializableSystem, IUpdatableSystem
{ {

View File

@@ -3,7 +3,7 @@ using _Project.Develop.Runtime.Utils.InputManagement;
using _Project.Develop.Runtime.Utils.ReactiveManagement; using _Project.Develop.Runtime.Utils.ReactiveManagement;
using UnityEngine; using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Movement namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Input
{ {
public class RotateDirectionByMoveInputSystem : IInitializableSystem, IUpdatableSystem public class RotateDirectionByMoveInputSystem : IInitializableSystem, IUpdatableSystem
{ {

View File

@@ -1,4 +1,5 @@
using _Project.Develop.Runtime.Entities; using _Project.Develop.Runtime.Entities;
using _Project.Develop.Runtime.Utilities.Conditions;
using _Project.Develop.Runtime.Utils.ReactiveManagement; using _Project.Develop.Runtime.Utils.ReactiveManagement;
using UnityEngine; using UnityEngine;
@@ -9,6 +10,7 @@ namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Movement
private ReactiveVariable<Vector3> _direction; private ReactiveVariable<Vector3> _direction;
private ReactiveVariable<float> _speed; private ReactiveVariable<float> _speed;
private Transform _transform; private Transform _transform;
private ICompositeCondition _canRotate;
private const float DeadZone = 0.1f; private const float DeadZone = 0.1f;
@@ -17,10 +19,17 @@ namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Movement
_direction = entity.RotateDirection; _direction = entity.RotateDirection;
_speed = entity.RotationSpeed; _speed = entity.RotationSpeed;
_transform = entity.Transform; _transform = entity.Transform;
_canRotate = entity.CanRotate;
if (_direction.Value != Vector3.zero)
_transform.rotation = Quaternion.LookRotation(_direction.Value.normalized);
} }
public void OnUpdate(float deltaTime) public void OnUpdate(float deltaTime)
{ {
if (_canRotate.Evaluate() == false)
return;
if (_direction.Value.magnitude < DeadZone) if (_direction.Value.magnitude < DeadZone)
return; return;

View File

@@ -0,0 +1,37 @@
using _Project.Develop.Runtime.Entities;
using _Project.Develop.Runtime.Utilities;
using _Project.Develop.Runtime.Utils.ReactiveManagement;
using UnityEngine;
namespace _Project.Develop.Runtime.Logic.Gameplay.Features.Sensors.Systems
{
public class DeathMaskTouchDetectorSystem : IInitializableSystem, IUpdatableSystem
{
private Buffer<Collider> _contacts;
private ReactiveVariable<bool> _isTouchDeathMask;
private LayerMask _deathMask;
public void OnInit(Entity entity)
{
_contacts = entity.ContactCollidersBuffer;
_isTouchDeathMask = entity.IsTouchDeathMask;
_deathMask = entity.DeathMask;
}
public void OnUpdate(float deltaTime)
{
for (int i = 0; i < _contacts.Count; i++)
{
if (MatchWithDeathLayer(_contacts.Items[i]))
{
_isTouchDeathMask.Value = true;
return;
}
}
_isTouchDeathMask.Value = false;
}
private bool MatchWithDeathLayer(Collider collider) => ((1 << collider.gameObject.layer) & _deathMask) != 0;
}
}

View File

@@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 3d117def644741f292aef71042b65c6b
timeCreated: 1771695342

View File

@@ -83,6 +83,37 @@ MeshRenderer:
m_SortingLayer: 0 m_SortingLayer: 0
m_SortingOrder: 0 m_SortingOrder: 0
m_AdditionalVertexStreams: {fileID: 0} m_AdditionalVertexStreams: {fileID: 0}
--- !u!1 &3442931992363786575
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8100612580556652068}
m_Layer: 3
m_Name: ShootPoint
m_TagString: Untagged
m_Icon: {fileID: 7174288486110832750, guid: 0000000000000000d000000000000000, type: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &8100612580556652068
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3442931992363786575}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 1}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 3873158065058763651}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &3463170684557075332 --- !u!1 &3463170684557075332
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@@ -232,6 +263,10 @@ PrefabInstance:
m_RemovedComponents: [] m_RemovedComponents: []
m_RemovedGameObjects: [] m_RemovedGameObjects: []
m_AddedGameObjects: m_AddedGameObjects:
- targetCorrespondingSourceObject: {fileID: 7422541279803945012, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f,
type: 3}
insertIndex: -1
addedObject: {fileID: 8100612580556652068}
- targetCorrespondingSourceObject: {fileID: 5353776208456886876, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f, - targetCorrespondingSourceObject: {fileID: 5353776208456886876, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f,
type: 3} type: 3}
insertIndex: -1 insertIndex: -1
@@ -257,6 +292,10 @@ PrefabInstance:
type: 3} type: 3}
insertIndex: -1 insertIndex: -1
addedObject: {fileID: 4422967739020777235} addedObject: {fileID: 4422967739020777235}
- targetCorrespondingSourceObject: {fileID: 8474685674288101080, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f,
type: 3}
insertIndex: -1
addedObject: {fileID: 458033393650918821}
- targetCorrespondingSourceObject: {fileID: 8474685674288101080, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f, - targetCorrespondingSourceObject: {fileID: 8474685674288101080, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f,
type: 3} type: 3}
insertIndex: -1 insertIndex: -1
@@ -329,6 +368,19 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
_collider: {fileID: 2163109570078651387} _collider: {fileID: 2163109570078651387}
--- !u!114 &458033393650918821
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2836758634261632367}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 1675979b03c84ec3b990009a37f3d6d9, type: 3}
m_Name:
m_EditorClassIdentifier:
_shootPoint: {fileID: 8100612580556652068}
--- !u!54 &6434875925373515566 --- !u!54 &6434875925373515566
Rigidbody: Rigidbody:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@@ -379,3 +431,9 @@ CapsuleCollider:
m_Height: 1.87 m_Height: 1.87
m_Direction: 1 m_Direction: 1
m_Center: {x: 0, y: 0, z: 0} m_Center: {x: 0, y: 0, z: 0}
--- !u!4 &3873158065058763651 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 7422541279803945012, guid: 3ff07ac6b3173eb45a2ebf7f8d2afb2f,
type: 3}
m_PrefabInstance: {fileID: 5963347870339261367}
m_PrefabAsset: {fileID: 0}

View File

@@ -0,0 +1,269 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &4825500070918632087
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 4068327021959854356}
- component: {fileID: 6986875278744086031}
- component: {fileID: 6039384679111288233}
- component: {fileID: 5623129036705138240}
- component: {fileID: 2620582635740165898}
- component: {fileID: 6279225968249412253}
- component: {fileID: 4829205802544652}
- component: {fileID: 7920897212951265246}
m_Layer: 6
m_Name: Projectile
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &4068327021959854356
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 3664062506950950245}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &6986875278744086031
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 0fa38a390e3026e4da73b8535ef0c601, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &6039384679111288233
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b7fdeece4c60497ea61a1006e47bfbc5, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &5623129036705138240
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: b3d77209b50f4ecf9185ae250a76b909, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &2620582635740165898
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 801746c26fe0478e80182979f64c22f2, type: 3}
m_Name:
m_EditorClassIdentifier:
_colliders:
- {fileID: 7920897212951265246}
--- !u!114 &6279225968249412253
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 72015d8dc01449c1b86801cc47ccd4a1, type: 3}
m_Name:
m_EditorClassIdentifier:
_collider: {fileID: 7920897212951265246}
--- !u!54 &4829205802544652
Rigidbody:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
serializedVersion: 4
m_Mass: 1
m_Drag: 0
m_AngularDrag: 0.05
m_CenterOfMass: {x: 0, y: 0, z: 0}
m_InertiaTensor: {x: 1, y: 1, z: 1}
m_InertiaRotation: {x: 0, y: 0, z: 0, w: 1}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_ImplicitCom: 1
m_ImplicitTensor: 1
m_UseGravity: 0
m_IsKinematic: 0
m_Interpolate: 1
m_Constraints: 80
m_CollisionDetection: 0
--- !u!136 &7920897212951265246
CapsuleCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4825500070918632087}
m_Material: {fileID: 0}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 4294967295
m_LayerOverridePriority: 0
m_IsTrigger: 0
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 2
m_Radius: 0.2
m_Height: 1
m_Direction: 1
m_Center: {x: 0, y: 0, z: 0}
--- !u!1 &7029576717413718260
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 3664062506950950245}
m_Layer: 0
m_Name: ViewContainer
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &3664062506950950245
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7029576717413718260}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 6501206515914570390}
m_Father: {fileID: 4068327021959854356}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &8082364550922563573
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6501206515914570390}
- component: {fileID: 153098785271525497}
- component: {fileID: 3055021133403032600}
m_Layer: 0
m_Name: Body
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &6501206515914570390
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8082364550922563573}
serializedVersion: 2
m_LocalRotation: {x: 0.70710576, y: -0, z: -0, w: 0.7071079}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 0.3, y: 0.3, z: 0.3}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 3664062506950950245}
m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0}
--- !u!33 &153098785271525497
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8082364550922563573}
m_Mesh: {fileID: 10208, guid: 0000000000000000e000000000000000, type: 0}
--- !u!23 &3055021133403032600
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8082364550922563573}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_StaticShadowCaster: 0
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RayTraceProcedural: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 1
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_AdditionalVertexStreams: {fileID: 0}

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 005cd8f4991704342a8e1e5bbd09b4cb
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -123,6 +123,111 @@ NavMeshSettings:
debug: debug:
m_Flags: 0 m_Flags: 0
m_NavMeshData: {fileID: 0} m_NavMeshData: {fileID: 0}
--- !u!1 &63063970
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 63063974}
- component: {fileID: 63063973}
- component: {fileID: 63063972}
- component: {fileID: 63063971}
m_Layer: 7
m_Name: r
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!65 &63063971
BoxCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63063970}
m_Material: {fileID: 0}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_LayerOverridePriority: 0
m_IsTrigger: 0
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 3
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!23 &63063972
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63063970}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_StaticShadowCaster: 0
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RayTraceProcedural: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 1
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_AdditionalVertexStreams: {fileID: 0}
--- !u!33 &63063973
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63063970}
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
--- !u!4 &63063974
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63063970}
serializedVersion: 2
m_LocalRotation: {x: -0, y: 0.70710576, z: -0, w: 0.70710784}
m_LocalPosition: {x: -0.31, y: 1.57, z: 17.87}
m_LocalScale: {x: 1, y: 4.3882, z: -9.5648985}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0}
--- !u!1 &92564817 --- !u!1 &92564817
GameObject: GameObject:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@@ -135,7 +240,7 @@ GameObject:
- component: {fileID: 92564820} - component: {fileID: 92564820}
- component: {fileID: 92564819} - component: {fileID: 92564819}
- component: {fileID: 92564818} - component: {fileID: 92564818}
m_Layer: 0 m_Layer: 7
m_Name: Ground m_Name: Ground
m_TagString: Untagged m_TagString: Untagged
m_Icon: {fileID: 0} m_Icon: {fileID: 0}
@@ -677,3 +782,4 @@ SceneRoots:
- {fileID: 993779571} - {fileID: 993779571}
- {fileID: 1616281628} - {fileID: 1616281628}
- {fileID: 92564821} - {fileID: 92564821}
- {fileID: 63063974}

View File

@@ -11,8 +11,8 @@ TagManager:
- Characters - Characters
- Water - Water
- UI - UI
- - Projectiles
- - Environment
- -
- -
- -