Починка бага физики мехов и подов (#2288)
Co-authored-by: pacable <igor.mamaev1@gmail.com>
This commit is contained in:
parent
39f8293418
commit
5d05e7deb3
4 changed files with 34 additions and 25 deletions
|
|
@ -14,6 +14,7 @@ using Robust.Shared.Physics.Components;
|
|||
using Robust.Shared.Physics.Controllers;
|
||||
using Robust.Shared.Physics.Dynamics;
|
||||
using Robust.Shared.Physics.Systems;
|
||||
using Content.Shared.Mech.Components; //sunrise-edit
|
||||
|
||||
namespace Content.Shared.Friction
|
||||
{
|
||||
|
|
@ -30,6 +31,7 @@ namespace Content.Shared.Friction
|
|||
private EntityQuery<PullerComponent> _pullerQuery;
|
||||
private EntityQuery<PullableComponent> _pullableQuery;
|
||||
private EntityQuery<MapGridComponent> _gridQuery;
|
||||
private EntityQuery<MechComponent> _mechQuery; //sunrise-edit
|
||||
|
||||
private float _frictionModifier;
|
||||
private float _minDamping;
|
||||
|
|
@ -49,6 +51,7 @@ namespace Content.Shared.Friction
|
|||
_pullerQuery = GetEntityQuery<PullerComponent>();
|
||||
_pullableQuery = GetEntityQuery<PullableComponent>();
|
||||
_gridQuery = GetEntityQuery<MapGridComponent>();
|
||||
_mechQuery = GetEntityQuery<MechComponent>(); //sunrise-edit
|
||||
}
|
||||
|
||||
public override void UpdateBeforeSolve(bool prediction, float frameTime)
|
||||
|
|
@ -62,6 +65,9 @@ namespace Content.Shared.Friction
|
|||
|
||||
// Only apply friction when it's not a mob (or the mob doesn't have control)
|
||||
// We may want to instead only apply friction to dynamic entities and not mobs ever.
|
||||
if (_mechQuery.HasComp(uid)) //sunrise-edit
|
||||
continue; //sunrise-edit
|
||||
|
||||
if (prediction && !body.Predict || _mover.UseMobMovement(uid))
|
||||
continue;
|
||||
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@
|
|||
- type: InteractionOutline
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1
|
||||
baseSprintSpeed: 2
|
||||
baseSprintSpeed: 3.9 # sunrise-edit
|
||||
- type: Tag
|
||||
tags:
|
||||
- DoorBumpOpener
|
||||
|
|
@ -129,6 +129,8 @@
|
|||
- type: WiresPanel
|
||||
- type: Physics
|
||||
bodyType: Dynamic
|
||||
angularDamping: 10 # sunrise-edit
|
||||
linearDamping: 10 # sunrise-edit
|
||||
- type: Fixtures
|
||||
fixtures:
|
||||
fix1:
|
||||
|
|
@ -239,7 +241,7 @@
|
|||
Blunt: 14 #intentionally shit so people realize that going into combat with the ripley is usually a bad idea.
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2.5
|
||||
baseSprintSpeed: 3.8
|
||||
baseSprintSpeed: 5.5 # sunrise-edit
|
||||
- type: Reflect
|
||||
reflectProb: 0.15
|
||||
spread: 180
|
||||
|
|
@ -307,7 +309,7 @@
|
|||
Blunt: 20
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1.5
|
||||
baseSprintSpeed: 2.5
|
||||
baseSprintSpeed: 4.3 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: MediumArmorNT
|
||||
- type: Reflect
|
||||
|
|
@ -377,7 +379,7 @@
|
|||
Blunt: 26
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2.5
|
||||
baseSprintSpeed: 4
|
||||
baseSprintSpeed: 5.7 # sunrise-edit
|
||||
- type: CanMoveInAir
|
||||
- type: MovementAlwaysTouching
|
||||
- type: Reflect
|
||||
|
|
@ -467,7 +469,7 @@
|
|||
path: "/Audio/Items/drill_use.ogg"
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2
|
||||
baseSprintSpeed: 2.75
|
||||
baseSprintSpeed: 4.2 # sunrise-edit
|
||||
- type: CanMoveInAir
|
||||
- type: MovementAlwaysTouching
|
||||
- type: Reflect
|
||||
|
|
@ -615,7 +617,7 @@
|
|||
Structural: 2
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2.4
|
||||
baseSprintSpeed: 3.7
|
||||
baseSprintSpeed: 5.2 # sunrise-edit
|
||||
- type: Reflect
|
||||
reflectProb: 0.15
|
||||
spread: 180
|
||||
|
|
@ -694,7 +696,7 @@
|
|||
Structural: 2
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2.25
|
||||
baseSprintSpeed: 3.6
|
||||
baseSprintSpeed: 5.2 # sunrise-edit
|
||||
- type: Access
|
||||
tags:
|
||||
- Maintenance
|
||||
|
|
@ -775,7 +777,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2
|
||||
baseSprintSpeed: 3
|
||||
baseSprintSpeed: 5.2 # sunrise-edit
|
||||
- type: Reflect
|
||||
reflectProb: 0.20
|
||||
spread: 180
|
||||
|
|
@ -847,8 +849,8 @@
|
|||
Structural: 250
|
||||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1.5
|
||||
baseSprintSpeed: 2
|
||||
baseWalkSpeed: 2.7 # sunrise-edit
|
||||
baseSprintSpeed: 3.7 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: MediumArmorNT
|
||||
- type: CanMoveInAir
|
||||
|
|
@ -923,7 +925,7 @@
|
|||
Structural: 80
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 3.2
|
||||
baseSprintSpeed: 4
|
||||
baseSprintSpeed: 6 # sunrise-edit
|
||||
- type: Reflect
|
||||
reflectProb: 0.65
|
||||
spread: 180
|
||||
|
|
@ -1000,7 +1002,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2
|
||||
baseSprintSpeed: 3
|
||||
baseSprintSpeed: 4.7 # sunrise-edit
|
||||
- type: Reflect
|
||||
reflectProb: 0.20
|
||||
spread: 180
|
||||
|
|
@ -1092,7 +1094,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1
|
||||
baseSprintSpeed: 1.5
|
||||
baseSprintSpeed: 2.7 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: HeavyArmorNT
|
||||
- type: CanMoveInAir
|
||||
|
|
@ -1179,7 +1181,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1
|
||||
baseSprintSpeed: 1.5
|
||||
baseSprintSpeed: 3.2 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: HeavyArmorNT
|
||||
- type: CanMoveInAir
|
||||
|
|
@ -1269,7 +1271,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 2
|
||||
baseSprintSpeed: 3
|
||||
baseSprintSpeed: 4.8 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: MediumArmorSyndi
|
||||
- type: CanMoveInAir
|
||||
|
|
@ -1359,7 +1361,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1.5
|
||||
baseSprintSpeed: 2
|
||||
baseSprintSpeed: 3.8 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: MediumArmorSyndi
|
||||
- type: CanMoveInAir
|
||||
|
|
@ -1444,7 +1446,7 @@
|
|||
bluntStaminaDamageFactor: 1.5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1
|
||||
baseSprintSpeed: 1.5
|
||||
baseSprintSpeed: 2.7 # sunrise-edit
|
||||
- type: Damageable
|
||||
damageModifierSet: HeavyArmorSyndi
|
||||
- type: CanMoveInAir
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@
|
|||
Blunt: 5
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1
|
||||
baseSprintSpeed: 1.5
|
||||
baseSprintSpeed: 3.1
|
||||
- type: Reflect
|
||||
reflectProb: 0.15
|
||||
spread: 180
|
||||
|
|
|
|||
|
|
@ -52,18 +52,18 @@
|
|||
- type: InputMover
|
||||
- type: InteractionOutline
|
||||
- type: MovementSpeedModifier
|
||||
baseWalkSpeed: 1
|
||||
baseSprintSpeed: 0.75
|
||||
friction: 5
|
||||
weightlessFriction: 5
|
||||
weightlessAcceleration: 3.5
|
||||
weightlessModifier: 3
|
||||
baseWalkSpeed: 1.7
|
||||
baseSprintSpeed: 1.7
|
||||
baseFriction: 15
|
||||
baseWeightlessModifier: 10
|
||||
- type: MovementAlwaysTouching
|
||||
- type: Pullable
|
||||
- type: Clickable
|
||||
- type: WiresPanel
|
||||
- type: Physics
|
||||
bodyType: Dynamic
|
||||
angularDamping: 2
|
||||
linearDamping: 2
|
||||
- type: MobState
|
||||
allowedStates:
|
||||
- Alive
|
||||
|
|
@ -114,7 +114,8 @@
|
|||
enabled: false
|
||||
mask: /Textures/Effects/LightMasks/cone.png
|
||||
autoRot: true
|
||||
radius: 9
|
||||
radius: 30
|
||||
energy: 3
|
||||
netsync: false
|
||||
|
||||
- type: entity
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue