Fix blade damaging player when initially disabled.

This commit is contained in:
Kubsy 2023-04-28 11:05:50 +01:00
parent 0a7fe24994
commit e220c649e5

View file

@ -32,8 +32,8 @@ namespace TEN::Entities::Traps
SetAnimation(item, WALL_MOUNTED_BLADE_ANIM_IDLE);
// Used for GenericSphereBoxCollision.
item.ItemFlags[0] = WALL_MOUNTED_BLADE_JOINT;
item.ItemFlags[3] = WALL_MOUNTED_BLADE_HARM_DAMAGE;
item.ItemFlags[0] = WALL_MOUNTED_BLADE_JOINT; // Damaging mesh joint.
item.ItemFlags[3] = 0; // Set the Damage initially to 0 to avoid player being damaged when the blade is disabled.
item.ItemFlags[4] = 1; // NOTE: avoid the blade pushing lara in GenericSphereBoxCollision() !
}