From b000bb259754854e9091c95100cf5726ad262f38 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 17:53:11 +0100 Subject: [PATCH 01/14] Cleaned up old entities --- resources/Schema/Entities/AmmoHUD | 98 -- resources/Schema/Entities/BlueRifle | 19 - resources/Schema/Entities/BoneMarker | 22 - resources/Schema/Entities/DeadGirl.xlm | 255 --- resources/Schema/Entities/FirstPersonArms | 57 - resources/Schema/Entities/Player.xml | 1235 --------------- .../Entities/PlayerAssaultFallbackBlue.xml | 698 --------- .../Entities/PlayerAssaultFallbackRed.xml | 698 --------- .../Schema/Entities/PlayerAssaultRed.xml | 1375 ----------------- .../Schema/Entities/WeaponAssaultRedView.xml | 109 -- .../Schema/Entities/WeaponAssaultRedWorld.xml | 34 - .../Schema/Entities/aaaatestremoveme.xml | 39 - resources/Schema/Entities/aim_rays.xml | 261 ---- resources/Schema/Entities/awdawd | 23 - resources/Schema/Entities/ble | 145 -- 15 files changed, 5068 deletions(-) delete mode 100644 resources/Schema/Entities/AmmoHUD delete mode 100644 resources/Schema/Entities/BlueRifle delete mode 100644 resources/Schema/Entities/BoneMarker delete mode 100644 resources/Schema/Entities/DeadGirl.xlm delete mode 100644 resources/Schema/Entities/FirstPersonArms delete mode 100644 resources/Schema/Entities/Player.xml delete mode 100644 resources/Schema/Entities/PlayerAssaultFallbackBlue.xml delete mode 100644 resources/Schema/Entities/PlayerAssaultFallbackRed.xml delete mode 100644 resources/Schema/Entities/PlayerAssaultRed.xml delete mode 100644 resources/Schema/Entities/WeaponAssaultRedView.xml delete mode 100644 resources/Schema/Entities/WeaponAssaultRedWorld.xml delete mode 100644 resources/Schema/Entities/aaaatestremoveme.xml delete mode 100644 resources/Schema/Entities/aim_rays.xml delete mode 100644 resources/Schema/Entities/awdawd delete mode 100644 resources/Schema/Entities/ble diff --git a/resources/Schema/Entities/AmmoHUD b/resources/Schema/Entities/AmmoHUD deleted file mode 100644 index 6cdb6568..00000000 --- a/resources/Schema/Entities/AmmoHUD +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - - - - 0 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - 360 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - - - - - 0 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - 360 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - diff --git a/resources/Schema/Entities/BlueRifle b/resources/Schema/Entities/BlueRifle deleted file mode 100644 index 194c7739..00000000 --- a/resources/Schema/Entities/BlueRifle +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - R_Arm_Weapon_Joint - - - Models/Weapons/Blue/AssaultWeaponBlue.mesh - - - - - - - - - - diff --git a/resources/Schema/Entities/BoneMarker b/resources/Schema/Entities/BoneMarker deleted file mode 100644 index eda56d56..00000000 --- a/resources/Schema/Entities/BoneMarker +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - R_Leg_Top - - - - Models/Core/UnitCube.mesh - - - - - - - - - - - - diff --git a/resources/Schema/Entities/DeadGirl.xlm b/resources/Schema/Entities/DeadGirl.xlm deleted file mode 100644 index 90a0411d..00000000 --- a/resources/Schema/Entities/DeadGirl.xlm +++ /dev/null @@ -1,255 +0,0 @@ - - - - - - - - - - 600 - - - - - - - - - 5 - - - - - - - - - - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,100 - - - - - - - - - - - - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - - - - - - - - 1 - - - - - Models/Core/UnitHexagon.mesh - - - - - - - - - - - - - - Textures/Weapons/Crosshair/SmallThickHoleDot.png - false - - - - - - - - - - - - - - Idle - 0.28963486380924053 - 1 - - - Models/Characters/Assault/FirstPerson.mesh - true - - - - - - - - R_Arm_Weapon_Joint - - - Models/Weapons/Blue/AssaultWeaponBlue.mesh - true - - - - - - - - - - - Schema/Entities/RayBlue.xml - - - - - - - - - - - - - Schema/Entities/WeaponReloadEffect.xml - - - - - - - - - - - - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - Idle - 0.42156525436696768 - 1 - - - AimRifle - - - - - Models/Characters/Assault/AssaultAnimations.mesh - - - - - - - - - R_Arm_Weapon_Joint - - - Models/Weapons/Blue/AssaultWeaponBlue.mesh - false - - - - - - - - - - - Schema/Entities/RayBlue.xml - - - - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - diff --git a/resources/Schema/Entities/FirstPersonArms b/resources/Schema/Entities/FirstPersonArms deleted file mode 100644 index bf749a4e..00000000 --- a/resources/Schema/Entities/FirstPersonArms +++ /dev/null @@ -1,57 +0,0 @@ - - - - - - Run - 0.5 - 0.97312056690160276 - 1 - 1 - ReloadSwitch - 0.91310356788604263 - LeftRight - 0 - 0.040207288496060478 - 1 - - - DownUp - - - - Models/Characters/Assault/FirstPerson.mesh - - true - - - - - - - - - - - R_Arm_Weapon_Joint - - - Models/Weapons/Blue/AssaultWeapon.mesh - - - - - - - - - - - - - - - - - - diff --git a/resources/Schema/Entities/Player.xml b/resources/Schema/Entities/Player.xml deleted file mode 100644 index 475acf78..00000000 --- a/resources/Schema/Entities/Player.xml +++ /dev/null @@ -1,1235 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - 5 - - - - - - - - - - - - 0.10000000149011612 - 300 - - - - - - - - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - - - - - - - - Textures/Weapons/Crosshair/SmallThickHoleDot.png - - false - - - - - - - - - - - - Schema/Entities/HitMarker.xml - - - - - - - - - - - - - - 1 - - - - - Textures/HealthHUD3.png - - - - - - - - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - 0.0 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - 1 - - - - 100/100 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - 2 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - 3 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 1 - - - - 4 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - 1 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 1 - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - - - - - Models/Widgets/Arrows/Arrow5.mesh - - - - - - - - - - - - - - - BlendTreeAssaultWeapon - BlendTreeSecondaryWeapon - 0 - true - - - Models/Characters/Defender/FirstPersonDefenderBlue.mesh - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - Schema/Entities/WeaponAssaultBlueView.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - Schema/Entities/SidearmWeaponView.xml - - - - - - - - - - - - Idle - WeaponAction - 0 - true - - - - - - - - Fire - Reload - 1 - - - - - - - - ShootShotgunF - 1 - true - false - - - - - - - - - ReloadSwitchF - - 1 - true - - - - - - - - - - - IdleF - - 1 - true - - - - - - - - - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - BlendTreeAim - BlendTreeAssault - - - - - Models/Characters/Assault/AssaultBlue.mesh - - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - - - - Schema/Entities/WeaponAssaultBlueWorld.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - - - - Schema/Entities/SidearmWeaponWorld.xml - - - - - - - - - - - - AimPrimary - AimSecondary - 0 - true - - - - - - - - AimSecWepA - - false - true - - - - - - - - - AimRifleA - - false - true - - - - - - - - - - - ReloadSwitchBlend - FinalMovementBlend - - - - - - - - StandCrouchBlend - JumpDashBlend - 2.5146881298480398e-63 - true - - - - - - - - StandMovement - CrouchMovement - 0 - true - - - - - - - - MovementBlend - Idle - 1 - - - - - - - - Walk - StrafeLRBlend - 0 - - - - - - - - Left - Right - 0.033793529385008014 - - - - - - - - CrouchStrafeLeftF - - 1 - true - - - - - - - - - CrouchStrafeRightF - - 1 - true - - - - - - - - - - - CrouchWalkF - - 1 - true - - - - - - - - - - - CrouchF - - 1 - - - - - - - - - - - MovementBlend - Idle - 1 - - - - - - - - RunWalkBlend - StrafeLRBlend - 2.4565650245976452e-16 - - - - - - - - Walk - Run - 1.2938206818383024e-24 - - - - - - - - WalkF - - 1 - true - - - - - - - - - RunF - - 1 - true - - - - - - - - - - - Left - Right - 0.033793529385008014 - - - - - - - - StrafeRightF - - 1 - true - - - - - - - - - StrafeLeftF - - 1 - true - - - - - - - - - - - - - IdleF - - 1 - true - - - - - - - - - - - - - Jump - DashBlend - 1 - true - - - - - - - - JumpF - - 1 - false - - - - - - - - - DashFBBlend - DashLRBlend - 0.014621149736541383 - - - - - - - - DashForward - DashBackward - 0.014363533804961248 - - - - - - - - DashForwardF - - 2 - false - - - - - - - - - DashBackwardF - - 2 - false - - - - - - - - - - - DashLeft - DashRight - 4.3244885367500671e-16 - - - - - - - - DashLeftF - - 2 - false - - - - - - - - - DashRightF - - 2 - false - - - - - - - - - - - - - - - - - ReloadSwitch - WeaponActionBlend - 1 - true - - - - - - - - ReloadSwitchU - - 1 - - - - - - - - - IdleBlend - ShootBlend - 0 - - - - - - - - IdlePrimary - IdleSecondary - 0 - - - - - - - - IdleAssaultRifleU - - 1 - true - - - - - - - - - IdleSecWepU - - 1 - true - - - - - - - - - - - ShootPrimary - ShootSecondary - 0 - - - - - - - - ShootFastRifleU - - 1 - - - - - - - - - ShootSecWepFastU - - - - - - - - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - Insert name here - Fonts/DroidSans.ttf,100 - - - - - - - - - - - - - - Textures/Icons/Arrow.png - - false - - - - - 50 - true - - - - - - - - - - - - Schema/Entities/DefenderShield.xml - - - - - - - - - - diff --git a/resources/Schema/Entities/PlayerAssaultFallbackBlue.xml b/resources/Schema/Entities/PlayerAssaultFallbackBlue.xml deleted file mode 100644 index 9650cfe8..00000000 --- a/resources/Schema/Entities/PlayerAssaultFallbackBlue.xml +++ /dev/null @@ -1,698 +0,0 @@ - - - - - - - - - - - - - - - - - - 5 - - - - - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - - - - - - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - - - - - - - - Textures/Weapons/Crosshair/SmallThickHoleDot.png - - false - - - - - - - - - - - - Schema/Entities/HitMarker.xml - - - - - - - - - - - - - - 1 - - - - - Textures/HealthHUD3.png - - - - - - - - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - 0.0 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - 1 - - - - 100/100 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 2 - - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 3 - - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 4 - - - 1 - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 1 - - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - 1 - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - Models/Widgets/Arrows/Arrow5.mesh - - - - - - - - - - - - - - - - - - - - Idle - 1.8348644854054612 - 1 - - - - - Models/Characters/Assault/Test/FirstPerson.mesh - - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - Schema/Entities/WeaponAssaultBlueView.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - Schema/Entities/SidearmWeaponView.xml - - - - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - IdleF - 1 - - - - - AimRifle - - - - - - Models/Characters/Assault/AssaultBlue.mesh - - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - - - - Schema/Entities/WeaponAssaultBlueWorld.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - - - - Schema/Entities/SidearmWeaponWorld.xml - - - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - Insert name here - Fonts/DroidSans.ttf,100 - - - - - - - - - - - - - - Textures/Icons/Arrow.png - - false - - - - - 50 - true - - - - - - - - - - - - Schema/Entities/DefenderShield.xml - - - - - - - - - - diff --git a/resources/Schema/Entities/PlayerAssaultFallbackRed.xml b/resources/Schema/Entities/PlayerAssaultFallbackRed.xml deleted file mode 100644 index a32988c7..00000000 --- a/resources/Schema/Entities/PlayerAssaultFallbackRed.xml +++ /dev/null @@ -1,698 +0,0 @@ - - - - - - - - - - - - - - - - - - 5 - - - - - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - - - - - - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - - - - - - - - Textures/Weapons/Crosshair/SmallThickHoleDot.png - - false - - - - - - - - - - - - Schema/Entities/HitMarker.xml - - - - - - - - - - - - - - 1 - - - - - Textures/HealthHUD3.png - - - - - - - - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - - - - - - - - - Textures/Core/White.png - - false - - - - - - - - - - - 0.0 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - 1 - - - - 100/100 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 2 - - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 3 - - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 4 - - - 1 - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 1 - - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - 1 - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - Models/Widgets/Arrows/Arrow5.mesh - - - - - - - - - - - - - - - - - - - - Idle - 1.8348644854054612 - 1 - - - - - Models/Characters/Assault/Test/FirstPerson.mesh - - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - Schema/Entities/WeaponAssaultRedView.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - Schema/Entities/SidearmWeaponView.xml - - - - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - IdleF - 1 - - - - - AimRifle - - - - - - Models/Characters/Assault/AssaultRed.mesh - - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - - - - Schema/Entities/WeaponAssaultRedWorld.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - - - - Schema/Entities/SidearmWeaponWorld.xml - - - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - Insert name here - Fonts/DroidSans.ttf,100 - - - - - - - - - - - - - - Textures/Icons/Arrow.png - - false - - - - - 50 - true - - - - - - - - - - - - Schema/Entities/DefenderShield.xml - - - - - - - - - - diff --git a/resources/Schema/Entities/PlayerAssaultRed.xml b/resources/Schema/Entities/PlayerAssaultRed.xml deleted file mode 100644 index a198196e..00000000 --- a/resources/Schema/Entities/PlayerAssaultRed.xml +++ /dev/null @@ -1,1375 +0,0 @@ - - - - - - - - - - 0.5 - - - - - - - - - - - - - - - 5 - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - - - - - - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - - - - - - - - Textures/Weapons/Crosshair/SmallThickHoleDot.png - - false - - - - - - - - - - - - Schema/Entities/HitMarker.xml - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - 2 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - 3 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 1 - - - - 4 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - 1 - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - 1 - - - - - Textures/Core/UnitHexagon_Rotated.png - - - - - - - - - - - - - - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - - - - - - - - Models/Widgets/Arrows/Arrow5.mesh - - - - - - - - - - - - - - - - - - - - - 1 - - - - 100/100 - Fonts/DroidSans.ttf,64 - - - - - - - - - - - - - - - 1 - - - - - Textures/HealthHUD3.png - - - - - - - - - - - - - - - - - - - - - - - - Textures/Icons/Boosts/Assault-01.png - - false - - - - - - - - - - - - - - - - - Textures/Icons/Boosts/Defender-01.png - - false - - - - - - - - - - - - - - - - - Textures/Icons/Boosts/Sniper-01.png - - false - - - - - - - - - - - - - - - - - - - - Textures/Icons/Abilities/Superman-01.png - - false - - - - - - - - - - - - - 0.0 - Fonts/DroidSans.ttf,64 - - false - - - - - - - - - - - - - - - - - - - MovementBlend - FinalBlend - - - Models/Characters/Assault/FirstPersonAssaultRed.mesh - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - Schema/Entities/WeaponAssaultRedView.xml - - - - - - - - - - - Models/Weapons/Red/AssaultWeaponRed.mesh - - - - - - - - - - - - - - Schema/Entities/RayRed.xml - - - - - - - - - - - - Schema/Entities/ReloadEffectView.xml - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - - - - - 32 - Fonts/DroidSans.ttf,64 - - - - PlayerAssault - AssaultWeapon - MagazineAmmo - - - - - - - - - - - 320 - Fonts/DroidSans.ttf,64 - - - - PlayerAssault - AssaultWeapon - Ammo - - - - - - - - - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - Schema/Entities/SidearmWeaponView.xml - - - - - - - - - - - - BlendTreeAssaultWeapon - BlendTreeSecondaryWeapon - 0 - true - - - - - - - - Fire - Reload - 0 - true - - - - - - - - ShootRifleF - 1 - false - - - - - - - - - ReloadSwitchF - 1 - false - - - - - - - - - - - - - - - - - - - Idle - Run - 0 - true - - - - - - - - RunF - 1 - true - true - - - - - - - - - IdleF - 1 - true - true - - - - - - - - - - - - - - - 0.10000000149011612 - 300 - - - Models/Widgets/Camera.mesh - false - - - - - - - - - - - - BlendTreeAim - BlendTreeAssault - - - - - Models/Characters/Assault/AssaultRed.mesh - - true - - - - - - - - R_Arm_Weapon_Joint - - - AssaultWeapon - - - - - - Schema/Entities/WeaponAssaultRedWorld.xml - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - - - - Schema/Entities/SidearmWeaponWorld.xml - - - - - - - - - - - - AimPrimary - AimSecondary - 0 - true - - - - - - - - AimSecWepA - - false - true - - - - - - - - - AimRifleA - - false - true - - - - - - - - - - - ReloadSwitchBlend - FinalMovementBlend - - - - - - - - StandCrouchBlend - JumpDashBlend - 2.5146881298480398e-63 - true - - - - - - - - StandMovement - CrouchMovement - 0 - true - - - - - - - - MovementBlend - Idle - 1 - - - - - - - - Walk - StrafeLRBlend - 0 - - - - - - - - Left - Right - 0.033793529385008014 - - - - - - - - CrouchStrafeLeftF - - 1 - true - - - - - - - - - CrouchStrafeRightF - - 1 - true - - - - - - - - - - - CrouchWalkF - - 1 - true - - - - - - - - - - - CrouchF - - 1 - - - - - - - - - - - MovementBlend - Idle - 1 - - - - - - - - RunWalkBlend - StrafeLRBlend - 2.4565650245976452e-16 - - - - - - - - Left - Right - 0.033793529385008014 - - - - - - - - StrafeLeftF - - 1 - true - - - - - - - - - StrafeRightF - - 1 - true - - - - - - - - - - - Walk - Run - 1.2938206818383024e-24 - - - - - - - - WalkF - - 1 - true - - - - - - - - - RunF - - 1 - true - - - - - - - - - - - - - IdleF - - 1 - true - - - - - - - - - - - - - Jump - DashBlend - 1 - true - - - - - - - - JumpF - - 1 - false - - - - - - - - - DashFBBlend - DashLRBlend - 0.014621149736541383 - - - - - - - - DashForward - DashBackward - 0.014363533804961248 - - - - - - - - DashForwardF - - 2 - false - - - - - - - - - DashBackwardF - - 2 - false - - - - - - - - - - - DashLeft - DashRight - 4.3244885367500671e-16 - - - - - - - - DashLeftF - - 2 - false - - - - - - - - - DashRightF - - 2 - false - - - - - - - - - - - - - - - - - ReloadSwitch - WeaponActionBlend - 1 - true - - - - - - - - ReloadSwitchU - - 1 - - - - - - - - - IdleBlend - ShootBlend - 0 - - - - - - - - IdlePrimary - IdleSecondary - 0 - - - - - - - - IdleAssaultRifleU - - 1 - true - - - - - - - - - IdleSecWepU - - 1 - true - - - - - - - - - - - ShootPrimary - ShootSecondary - 0 - - - - - - - - ShootFastRifleU - - 1 - - - - - - - - - ShootSecWepFastU - - - - - - - - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - - Models/Core/UnitCube.mesh - - false - - - - - - - - - - - Insert name here - Fonts/DroidSans.ttf,100 - - - - - - - - - - - - - - Textures/Icons/Arrow.png - - false - - - - - 50 - true - - - - - - - - - - - - Schema/Entities/DefenderShield.xml - - - - - - - - - - diff --git a/resources/Schema/Entities/WeaponAssaultRedView.xml b/resources/Schema/Entities/WeaponAssaultRedView.xml deleted file mode 100644 index 0a9b65b2..00000000 --- a/resources/Schema/Entities/WeaponAssaultRedView.xml +++ /dev/null @@ -1,109 +0,0 @@ - - - - - - Models/Weapons/Red/AssaultWeaponRed.mesh - - - - - - - - - Schema/Entities/RayRed.xml - - - - - - - - - - - - Schema/Entities/ReloadEffectView.xml - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - - - - - 32 - Fonts/DroidSans.ttf,64 - - - - Player - AssaultWeapon - MagazineAmmo - - - - - - - - - - - 320 - Fonts/DroidSans.ttf,64 - - - - Player - AssaultWeapon - Ammo - - - - - - - - - - - - - - - - - - - - - diff --git a/resources/Schema/Entities/WeaponAssaultRedWorld.xml b/resources/Schema/Entities/WeaponAssaultRedWorld.xml deleted file mode 100644 index 68d78d03..00000000 --- a/resources/Schema/Entities/WeaponAssaultRedWorld.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - Models/Weapons/Red/AssaultWeaponRed.mesh - - - - - - - - - Schema/Entities/RayRed.xml - - - - - - - - - - - Schema/Entities/ReloadEffectWorld.xml - - - - - - - - diff --git a/resources/Schema/Entities/aaaatestremoveme.xml b/resources/Schema/Entities/aaaatestremoveme.xml deleted file mode 100644 index 8da40b58..00000000 --- a/resources/Schema/Entities/aaaatestremoveme.xml +++ /dev/null @@ -1,39 +0,0 @@ - - - - - - - - - - - - Models/Core/Unithexagon.mesh - - - - - - - - - - - - - - - - - - - 2.2000000476837158 - - - - - - - - diff --git a/resources/Schema/Entities/aim_rays.xml b/resources/Schema/Entities/aim_rays.xml deleted file mode 100644 index c8dac9a3..00000000 --- a/resources/Schema/Entities/aim_rays.xml +++ /dev/null @@ -1,261 +0,0 @@ - - - - - - - - - - - - - - models/core/unitcube.mesh - - - - - - - - - - - - - - - models/core/unitcube.mesh - - - - - - - - - - - - - - - - - - - - - - - - models/core/unitcube.mesh - - - - - - - - - - - - - - - models/core/unitcube.mesh - - - - - - - - - - - - - - - models/core/unitcube.mesh - - - - - - - - - - - - - - Schema/Entities/Player.xml - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Schema/Entities/Player.xml - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - models/core/unitcube.mesh - - - - - - - - - - - - - - - - - - Models\Core\UnitCube.mesh - - - - - - - - - - - - - - - - - - - - - - - 1 - - - Models\Core\UnitCube.mesh - - - - - - - - - - - - - - - - - - diff --git a/resources/Schema/Entities/awdawd b/resources/Schema/Entities/awdawd deleted file mode 100644 index d8dacb54..00000000 --- a/resources/Schema/Entities/awdawd +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - L_Foot - true - - - Models/Core/UnitCube.mesh - - - - - - - - - - - - diff --git a/resources/Schema/Entities/ble b/resources/Schema/Entities/ble deleted file mode 100644 index 6518ee5b..00000000 --- a/resources/Schema/Entities/ble +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - 0.30000001192092896 - 3 - - - - - - - - - - - - - - - - - 0 - - - Models/Widgets/Lights/DirectionalLightWidget.mesh - - - - - - - - - - - - - 8 - 0.60000002384185791 - - - - - - - - - - - - - - - 5 - Models/Characters/Defender/DefenderBlue.mesh - - - - - - - - R_Arm_Weapon_Joint - - - Models/Weapons/Blue/AssaultWeaponBlue.mesh - - - - - - - - - - - AimPrimary - AimSecondary - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - Models/Core/UnitPlane.mesh - - - - - - - - - - - - 8 - 0.60000002384185791 - - - - - - - - - - - 8 - 0.80000001192092896 - - - - - - - - - - - - From 8bcb15a12821fc137290de291ca7fc31bf31ccc0 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 17:53:32 +0100 Subject: [PATCH 02/14] Disabled InputCommand processing while you fiddle with editor UI elements --- src/Engine/Input/InputProxy.cpp | 14 +++++++++----- src/Game/Game.cpp | 2 +- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/Engine/Input/InputProxy.cpp b/src/Engine/Input/InputProxy.cpp index 6c3591e3..295cf1c4 100644 --- a/src/Engine/Input/InputProxy.cpp +++ b/src/Engine/Input/InputProxy.cpp @@ -45,7 +45,7 @@ void InputProxy::Update(double dt) } } -void InputProxy::Process() +void InputProxy::Process(bool suppressNewEvents /*= false*/) { for (auto& pair : m_CommandHandlers) { const std::string& command = pair.first; @@ -62,8 +62,10 @@ void InputProxy::Process() e.PlayerID = -1; e.Command = command; e.Value = currentValue; - m_EventBroker->Publish(e); - //LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); + if (!suppressNewEvents || e.Value == 0) { + m_EventBroker->Publish(e); + LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); + } m_LastCommandValues[command] = currentValue; } } @@ -78,8 +80,10 @@ void InputProxy::Process() e.Value += value; } //e.Value = std::max(-1.f, std::min(e.Value, 1.f)); - m_EventBroker->Publish(e); - //LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); + if (!suppressNewEvents || e.Value == 0) { + m_EventBroker->Publish(e); + LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); + } } m_CommandQueue.clear(); } diff --git a/src/Game/Game.cpp b/src/Game/Game.cpp index 8f589e34..d58c89e0 100644 --- a/src/Game/Game.cpp +++ b/src/Game/Game.cpp @@ -218,7 +218,7 @@ void Game::Tick() PerformanceTimer::StartTimerAndStopPrevious("InputProxy"); m_InputProxy->Update(dt); m_EventBroker->Swap(); - m_InputProxy->Process(); + m_InputProxy->Process(ImGui::GetIO().WantCaptureKeyboard || ImGui::GetIO().WantCaptureMouse); m_EventBroker->Swap(); PerformanceTimer::StartTimerAndStopPrevious("SoundManager"); From abc447b937c1a364fdf54080e31ab2461ed65dc7 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 17:53:47 +0100 Subject: [PATCH 03/14] Updated snapshot filter to ignore the new animation components --- src/Game/Network/MultiplayerSnapshotFilter.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Game/Network/MultiplayerSnapshotFilter.cpp b/src/Game/Network/MultiplayerSnapshotFilter.cpp index 295cdd7a..1131424b 100644 --- a/src/Game/Network/MultiplayerSnapshotFilter.cpp +++ b/src/Game/Network/MultiplayerSnapshotFilter.cpp @@ -15,7 +15,9 @@ bool MultiplayerSnapshotFilter::FilterComponent(EntityWrapper entity, SharedComp || component.Info.Name == "AssaultWeapon" || component.Info.Name == "DefenderWeapon" || component.Info.Name == "Animation" - || component.Info.Name == "AnimationOffset" + || component.Info.Name == "Blend" + || component.Info.Name == "BlendAdditive" + || component.Info.Name == "BlendOverride" || entity.Name() == "PlayerName" ) { return false; From f923872e514f30d0538897351574a5f354326384 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 17:54:01 +0100 Subject: [PATCH 04/14] fixup! Disabled InputCommand processing while you fiddle with editor UI elements --- include/Engine/Input/InputProxy.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/Engine/Input/InputProxy.h b/include/Engine/Input/InputProxy.h index c9ba5ada..a38b8d24 100644 --- a/include/Engine/Input/InputProxy.h +++ b/include/Engine/Input/InputProxy.h @@ -18,7 +18,7 @@ public: void LoadBindings(std::string file); void Update(double dt); - void Process(); + void Process(bool suppressNewEvents = false); template void AddHandler(); void Publish(const Events::InputCommand& e); From 1a403b9b88f58c9f93e0d2c83464068f11b71612 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 17:55:00 +0100 Subject: [PATCH 05/14] TextFieldReader now loops through parents if the entity field was empty and the current entity didn't have a component of that type. --- src/Game/Systems/TextFieldReader.cpp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/Game/Systems/TextFieldReader.cpp b/src/Game/Systems/TextFieldReader.cpp index c2e5c1e4..71218ef8 100644 --- a/src/Game/Systems/TextFieldReader.cpp +++ b/src/Game/Systems/TextFieldReader.cpp @@ -7,17 +7,21 @@ void TextFieldReader::UpdateComponent(EntityWrapper& entity, ComponentWrapper& c } // Find the entity to read from - const std::string& parentEntityName = cAmmunitionHUD["ParentEntityName"]; + const std::string& entityName = cAmmunitionHUD["ParentEntityName"]; + const std::string& componentType = cAmmunitionHUD["ComponentType"]; EntityWrapper readEntity = entity; - if (!parentEntityName.empty()) { - readEntity = entity.FirstParentByName(parentEntityName); - if (!readEntity.Valid()) { - return; + if (entityName.empty()) { + if (!readEntity.HasComponent(componentType)) { + readEntity = readEntity.FirstParentWithComponent(componentType); } + } else { + readEntity = entity.FirstParentByName(entityName); + } + if (!readEntity.Valid()) { + return; } // Find the component to read from - const std::string& componentType = cAmmunitionHUD["ComponentType"]; if (componentType.empty() || !readEntity.HasComponent(componentType)) { return; } From 67ce6c5ae6881e9fc852621321f4bd0898294632 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 19:38:02 +0100 Subject: [PATCH 06/14] Added Speed and Delay fields to explosion effect. --- resources/Schema/Components/ExplosionEffect.xml | 2 ++ resources/Schema/Components/ExplosionEffect.xsd | 2 ++ src/Game/Systems/ExplosionEffectSystem.cpp | 16 ++++++++++------ 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/resources/Schema/Components/ExplosionEffect.xml b/resources/Schema/Components/ExplosionEffect.xml index 22692729..0b4a44c4 100644 --- a/resources/Schema/Components/ExplosionEffect.xml +++ b/resources/Schema/Components/ExplosionEffect.xml @@ -3,6 +3,8 @@ 0 2 + 1 + 0 diff --git a/resources/Schema/Components/ExplosionEffect.xsd b/resources/Schema/Components/ExplosionEffect.xsd index cdde5e52..bd29b2ed 100644 --- a/resources/Schema/Components/ExplosionEffect.xsd +++ b/resources/Schema/Components/ExplosionEffect.xsd @@ -18,6 +18,8 @@ How many seconds the death animation should be + + diff --git a/src/Game/Systems/ExplosionEffectSystem.cpp b/src/Game/Systems/ExplosionEffectSystem.cpp index 2704d2da..71de192a 100644 --- a/src/Game/Systems/ExplosionEffectSystem.cpp +++ b/src/Game/Systems/ExplosionEffectSystem.cpp @@ -2,13 +2,17 @@ void ExplosionEffectSystem::UpdateComponent(EntityWrapper& entity, ComponentWrapper& component, double dt) { - if ((double)component["TimeSinceDeath"] > (double)component["ExplosionDuration"]) { - (double)component["TimeSinceDeath"] = 0.f; + double& delay = (double)component["Delay"]; + if (delay > 0) { + delay = std::max(0.0, delay - dt); } - (double&)component["TimeSinceDeath"] += dt; - //if ((bool)Component["Gravity"] == true) { - // (bool)Component["ExponentialAccelaration"] = false; - //} + if (delay <= 0) { + double& timeSinceDeath = component["TimeSinceDeath"]; + timeSinceDeath += (double)component["Speed"] * dt; + if (timeSinceDeath < 0 || timeSinceDeath > (double)component["ExplosionDuration"]) { + timeSinceDeath = 0.0; + } + } } From 3fda25b604d3feb1c75787633531cff5157dbac0 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 19:38:49 +0100 Subject: [PATCH 07/14] Working first person animations for AssaultWeapon and DefenderWeapon and reload effect for AssaultWeapon --- assets | 2 +- include/Game/Systems/Weapon/WeaponBehaviour.h | 45 +-- resources/Schema/Components/Animation.xml | 2 +- .../Entities/BlendTreeAssaultWeapon.xml | 207 +++++++++-- .../Entities/BlendTreeDefenderWeapon.xml | 159 +++++++++ resources/Schema/Entities/MovementTest.xml | 4 +- .../Schema/Entities/PlayerAssaultBlue.xml | 331 ++++-------------- .../Schema/Entities/ReloadEffectView.xml | 14 +- .../Schema/Entities/WeaponAssaultBlueView.xml | 175 +++++++-- .../Entities/WeaponAssaultBlueWorld.xml | 2 +- .../WeaponAssaultReloadEffectView.xml | 54 +++ .../Entities/WeaponDefenderBlueView.xml | 252 ++++++++++--- .../Systems/Weapon/AssaultWeaponBehaviour.cpp | 36 +- .../Weapon/DefenderWeaponBehaviour.cpp | 78 +++-- .../Systems/Weapon/SidearmWeaponBehaviour.cpp | 2 +- 15 files changed, 915 insertions(+), 448 deletions(-) create mode 100644 resources/Schema/Entities/BlendTreeDefenderWeapon.xml create mode 100644 resources/Schema/Entities/WeaponAssaultReloadEffectView.xml diff --git a/assets b/assets index 6451a3f5..0f9208a3 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 6451a3f5a5a86944a8457b533a2f4518b2191d2b +Subproject commit 0f9208a305b204cc9a7a9d6accfb084bc40e8095 diff --git a/include/Game/Systems/Weapon/WeaponBehaviour.h b/include/Game/Systems/Weapon/WeaponBehaviour.h index e2d5980b..a21ed6d5 100644 --- a/include/Game/Systems/Weapon/WeaponBehaviour.h +++ b/include/Game/Systems/Weapon/WeaponBehaviour.h @@ -32,20 +32,19 @@ public: virtual void UpdateComponent(EntityWrapper& entity, ComponentWrapper& cWeapon, double dt) override { - EntityWrapper firstPersonWeapon = entity.FirstChildByName("Hands").FirstChildByName("AssaultWeapon"); - EntityWrapper thirdPersonWeapon = entity.FirstChildByName("PlayerModel").FirstChildByName("AssaultWeapon"); - if (IsClient && (firstPersonWeapon.Valid() || thirdPersonWeapon.Valid())) { - if (m_ActiveWeapons.count(entity) == 0) { + /* EntityWrapper firstPersonWeapon = entity.FirstChildByName("Hands").FirstChildByName("AssaultWeapon"); + EntityWrapper thirdPersonWeapon = entity.FirstChildByName("PlayerModel").FirstChildByName("AssaultWeapon"); + if (IsClient && (firstPersonWeapon.Valid() || thirdPersonWeapon.Valid())) { + if (m_ActiveWeapons.count(entity) == 0) { + WeaponInfo& wi = m_ActiveWeapons[entity]; + wi.Player = entity; + wi.WeaponEntity = entity; + wi.FirstPersonEntity = firstPersonWeapon; + wi.ThirdPersonEntity = thirdPersonWeapon; - WeaponInfo& wi = m_ActiveWeapons[entity]; - wi.Player = entity; - wi.WeaponEntity = entity; - wi.FirstPersonEntity = firstPersonWeapon; - wi.ThirdPersonEntity = thirdPersonWeapon; - - OnEquip(cWeapon, wi); - } - } + OnEquip(cWeapon, wi); + } + }*/ auto weapon = getActiveWeapon(entity); if (!weapon) { @@ -89,7 +88,7 @@ protected: // Returns wi.FirstPersonEntity or wi.ThirdPersonEntity depending on // if the player is in first person mode or not. - EntityWrapper getRelevantWeaponModelEntity(WeaponInfo& wi) + EntityWrapper getRelevantWeaponEntity(WeaponInfo& wi) { if (isPlayerInFirstPerson(wi.Player)) { return wi.FirstPersonEntity; @@ -137,7 +136,7 @@ protected: void playAnimationAndReturn(EntityWrapper weaponModelEntity, const std::string& subTreeName, const std::string& animationNodeName) { - EntityWrapper root = weaponModelEntity.FirstParentWithComponent("Model"); + EntityWrapper root = weaponModelEntity; if (!root.Valid()) { return; } @@ -254,9 +253,9 @@ private: void selectWeapon(ComponentWrapper cWeapon, EntityWrapper player) { - if (!IsServer) { - return; - } + //if (!IsServer) { + // return; + //} // Don't reselect weapon if it's already active if (getActiveWeapon(player)) { @@ -287,13 +286,15 @@ private: // Spawn the weapon(s) EntityWrapper firstPersonWeapon; EntityWrapper thirdPersonWeapon; - //if (IsClient) { + if (IsClient) { if (firstPersonAttachment.Valid()) { firstPersonWeapon = SpawnerSystem::Spawn(firstPersonAttachment, firstPersonAttachment); } - //} - if (thirdPersonAttachment.Valid()) { - thirdPersonWeapon = SpawnerSystem::Spawn(thirdPersonAttachment, thirdPersonAttachment); + } + if (IsServer) { + if (thirdPersonAttachment.Valid()) { + thirdPersonWeapon = SpawnerSystem::Spawn(thirdPersonAttachment, thirdPersonAttachment); + } } WeaponInfo& wi = m_ActiveWeapons[player]; diff --git a/resources/Schema/Components/Animation.xml b/resources/Schema/Components/Animation.xml index 05de9f9f..8e7fd69b 100644 --- a/resources/Schema/Components/Animation.xml +++ b/resources/Schema/Components/Animation.xml @@ -4,7 +4,7 @@ false false - 0 + 1 true false \ No newline at end of file diff --git a/resources/Schema/Entities/BlendTreeAssaultWeapon.xml b/resources/Schema/Entities/BlendTreeAssaultWeapon.xml index a68175a2..2bdaa0bb 100644 --- a/resources/Schema/Entities/BlendTreeAssaultWeapon.xml +++ b/resources/Schema/Entities/BlendTreeAssaultWeapon.xml @@ -1,46 +1,102 @@ - + - - Idle - WeaponAction - 0 - true - + + MovementBlend + FinalBlend + + + Models/Characters/Assault/FirstPersonAssaultBlue.mesh + - + - Fire - Reload - 1 + BlendTreeAssaultWeapon + BlendTreeSecondaryWeapon + 0 + true - + + + + Fire + Reload + 0 + true + + + + + + + + ReloadSwitchF + 0.5 + false + + + + + + + + + ShootRifleF + 1 + false + + + + + + + + + + + + + + + + + + + Idle + Run + 0 + true + + + + + - ShootShotgunF + RunF 1 true - false + true - + - ReloadSwitchF - + IdleF 1 true + true @@ -48,17 +104,116 @@ - + - - IdleF - - 1 - true - - + + R_Arm_Weapon_Joint + + + Models/Weapons/Blue/AssaultWeaponBlue.mesh + + + + + - + + + + + Schema/Entities/RayBlue.xml + + + + + + + + + + + + Schema/Entities/WeaponAssaultReloadEffectView.xml + + + + + + + + + + + R_Ammo_Joint + + true + + + + + + + + + + + + Textures/Core/UnitHexagon.png + + + + + + + + + + + + + + + + + + + 32 + Fonts/DroidSans.ttf,64 + + + + PlayerAssault + AssaultWeapon + MagazineAmmo + + + + + + + + + + + 320 + Fonts/DroidSans.ttf,64 + + + + PlayerAssault + AssaultWeapon + Ammo + + + + + + + + + + + diff --git a/resources/Schema/Entities/BlendTreeDefenderWeapon.xml b/resources/Schema/Entities/BlendTreeDefenderWeapon.xml new file mode 100644 index 00000000..3f22d57f --- /dev/null +++ b/resources/Schema/Entities/BlendTreeDefenderWeapon.xml @@ -0,0 +1,159 @@ + + + + + + MovementBlend + FinalBlend + + + Models/Characters/Defender/FirstPersonDefenderBlue.mesh + + + + + + + + + BlendTreeDefenderWeapon + BlendTreeSecondaryWeapon + 0 + true + + + + + + + + ActionBlend + Shield + 0 + true + + + + + + + + ActivateDeactiveShieldF + + 1 + false + + + + + + + + + Idle + ActionBlend2 + 0 + true + + + + + + + + IdleF + + + + + + + + + Fire + Reload + 0 + + + + + + + + ShootShotgunF + + 1 + false + + + + + + + + + ShotgunReloadTwoF + + 1 + false + + + + + + + + + + + + + + + + + + + + + + + Idle + Run + 0 + true + + + + + + + + RunF + + 1 + true + true + + + + + + + + + IdleF + + 1 + true + true + + + + + + + + + + diff --git a/resources/Schema/Entities/MovementTest.xml b/resources/Schema/Entities/MovementTest.xml index 50f77401..47284d51 100644 --- a/resources/Schema/Entities/MovementTest.xml +++ b/resources/Schema/Entities/MovementTest.xml @@ -2,7 +2,9 @@ - + + + diff --git a/resources/Schema/Entities/PlayerAssaultBlue.xml b/resources/Schema/Entities/PlayerAssaultBlue.xml index 7773235b..8bceb701 100644 --- a/resources/Schema/Entities/PlayerAssaultBlue.xml +++ b/resources/Schema/Entities/PlayerAssaultBlue.xml @@ -16,6 +16,11 @@ + + + + + @@ -493,250 +498,34 @@ - + - - MovementBlend - FinalBlend - - - Models/Characters/Assault/FirstPersonAssaultBlue.mesh - - - R_Arm_Weapon_Joint - AssaultWeapon Schema/Entities/WeaponAssaultBlueView.xml - - - - - - - - - - Models/Weapons/Blue/AssaultWeaponBlue.mesh - - - - - - - - - - - - - - Schema/Entities/RayBlue.xml - - - - - - - - - - - - Schema/Entities/ReloadEffectView.xml - - - - - - - - - - - - - - - - - Textures/Core/UnitHexagon.png - - - - - - - - - - - - - - - - - - - 32 - Fonts/DroidSans.ttf,64 - - - - PlayerAssault - AssaultWeapon - MagazineAmmo - - - - - - - - - - - 320 - Fonts/DroidSans.ttf,64 - - - - PlayerAssault - AssaultWeapon - Ammo - - - - - - - - - - - - - - - - - - - - R_Arm_Weapon_Joint - - - SidearmWeapon - - - Schema/Entities/SidearmWeaponView.xml - - - - - + - + - - BlendTreeAssaultWeapon - BlendTreeSecondaryWeapon - 0 - true - + + DefenderWeapon + + + Schema/Entities/WeaponDefenderBlueView.xml + - - - - - Fire - Reload - 0 - true - - - - - - - - ShootRifleF - 1 - false - - - - - - - - - ReloadSwitchF - 1 - false - - - - - - - - - - - - - - - - - - - Idle - Run - 0 - true - - - - - - - - RunF - 1 - true - true - - - - - - - - - IdleF - 1 - true - true - - - - - - + @@ -769,8 +558,6 @@ Models/Characters/Assault/AssaultBlue.mesh - - true @@ -790,8 +577,8 @@ Schema/Entities/WeaponAssaultBlueWorld.xml - - + + @@ -811,8 +598,8 @@ Schema/Entities/SidearmWeaponWorld.xml - - + + @@ -832,7 +619,7 @@ AimSecWepA - + false true @@ -844,7 +631,7 @@ AimRifleA - + false true @@ -988,42 +775,6 @@ - - - - Left - Right - 0.033793529385008014 - - - - - - - - StrafeLeftF - - 1 - true - - - - - - - - - StrafeRightF - - 1 - true - - - - - - - @@ -1060,6 +811,42 @@ + + + + Left + Right + 0.033793529385008014 + + + + + + + + StrafeLeftF + + 1 + true + + + + + + + + + StrafeRightF + + 1 + true + + + + + + + @@ -1327,12 +1114,12 @@ - Insert name here + Fonts/DroidSans.ttf,100 - + diff --git a/resources/Schema/Entities/ReloadEffectView.xml b/resources/Schema/Entities/ReloadEffectView.xml index ca7e6e1a..8aa6b8ec 100644 --- a/resources/Schema/Entities/ReloadEffectView.xml +++ b/resources/Schema/Entities/ReloadEffectView.xml @@ -1,20 +1,20 @@ - + - 2 + 1 - true - - - true - + + + 1 + true Models/Weapons/Blue/AssaultWeaponBlue.mesh + true diff --git a/resources/Schema/Entities/WeaponAssaultBlueView.xml b/resources/Schema/Entities/WeaponAssaultBlueView.xml index 9b10618b..235a9480 100644 --- a/resources/Schema/Entities/WeaponAssaultBlueView.xml +++ b/resources/Schema/Entities/WeaponAssaultBlueView.xml @@ -1,44 +1,161 @@ - + + + MovementBlend + FinalBlend + - Models/Weapons/Blue/AssaultWeaponBlue.mesh + Models/Characters/Assault/FirstPersonAssaultBlue.mesh - + - - Schema/Entities/RayBlue.xml - - - - - - - - - - - - Schema/Entities/ReloadEffectView.xml - + + BlendTreeAssaultWeapon + BlendTreeSecondaryWeapon + 0 + true + - + + + + + Fire + Reload + 0 + true + + + + + + + + ReloadSwitchF + 0.5 + false + + + + + + + + + ShootRifleF + 1 + false + + + + + + + + + + + + + + - + + + Idle + Run + 0 + true + + + + + + + + IdleF + 1 + true + true + + + + + + + + + RunF + 1 + true + true + + + + + + + + + + + R_Arm_Weapon_Joint + + + Models/Weapons/Blue/AssaultWeaponBlue.mesh + - - + + - + + + + Schema/Entities/RayBlue.xml + + + + + + + + + + + + Schema/Entities/WeaponAssaultReloadEffectView.xml + + + + + + + + + + + R_Ammo_Joint + + true + + + + + + + + + Textures/Core/UnitHexagon.png @@ -52,7 +169,7 @@ - + @@ -65,7 +182,7 @@ - Player + AssaultWeapon MagazineAmmo @@ -83,7 +200,7 @@ - Player + AssaultWeapon Ammo @@ -98,12 +215,6 @@ - - - - - - diff --git a/resources/Schema/Entities/WeaponAssaultBlueWorld.xml b/resources/Schema/Entities/WeaponAssaultBlueWorld.xml index 9f33c8f2..cb1acae6 100644 --- a/resources/Schema/Entities/WeaponAssaultBlueWorld.xml +++ b/resources/Schema/Entities/WeaponAssaultBlueWorld.xml @@ -20,7 +20,7 @@ - + Schema/Entities/ReloadEffectWorld.xml diff --git a/resources/Schema/Entities/WeaponAssaultReloadEffectView.xml b/resources/Schema/Entities/WeaponAssaultReloadEffectView.xml new file mode 100644 index 00000000..fe33de28 --- /dev/null +++ b/resources/Schema/Entities/WeaponAssaultReloadEffectView.xml @@ -0,0 +1,54 @@ + + + + + + 2 + + + + + + + + + + + 1 + 1 + -1 + 1 + + true + + + Models/Weapons/Blue/AssaultWeaponBlue.mesh + true + + + + + + + + + 1 + + + + + 1 + + true + + + Models/Weapons/Blue/AssaultWeaponBlue.mesh + true + + + + + + + + diff --git a/resources/Schema/Entities/WeaponDefenderBlueView.xml b/resources/Schema/Entities/WeaponDefenderBlueView.xml index 24b18f68..493c7243 100644 --- a/resources/Schema/Entities/WeaponDefenderBlueView.xml +++ b/resources/Schema/Entities/WeaponDefenderBlueView.xml @@ -1,43 +1,209 @@ - + + + MovementBlend + FinalBlend + - Models/Weapons/Blue/DefenderWeaponBlue.mesh + Models/Characters/Defender/FirstPersonDefenderBlue.mesh - + - - Schema/Entities/RayBlue.xml - - - - - - - - - - - Schema/Entities/ReloadEffectView.xml - + + ActionBlend + Shield + 0 + true + - + + + + + ActivateDeactiveShieldF + + 1 + false + + + + + + + + + Fire + ReloadBlend + 0 + + + + + + + + ShootShotgunF + 1 + false + + + + + + + + + ReloadLoop + ReloadTransitionBlend + 1 + + + + + + + + ShotgunReloadTwoF + 1 + + + + + + + + + ReloadStart + ReloadEnd + 0 + + + + + + + + ShotgunReloadOneF + 1 + false + + + + + + + + + ShotgunReloadThreeF + 1 + false + + + + + + + + + + + + - + + + Idle + Run + 0 + true + + + + + + + + IdleF + 1 + true + true + + + + + + + + + RunF + 1 + true + true + + + + + + + + + + + R_Arm_Weapon_Joint + + + Models/Weapons/Blue/DefenderWeaponBlue.mesh + - - + + - + + + + Schema/Entities/RayBlue.xml + + + + + + + + + + + Schema/Entities/ReloadEffectView.xml + + + + + + + + + + + R_Ammo_Joint + true + + + + + + + + + Textures/Core/UnitHexagon.png @@ -51,38 +217,20 @@ - + - - - - 8 - Fonts/DroidSans.ttf,64 - - - - Player - DefenderWeapon - MagazineAmmo - - - - - - - - 64 + 38 Fonts/DroidSans.ttf,64 - Player + DefenderWeapon Ammo @@ -93,6 +241,24 @@ + + + + 5 + Fonts/DroidSans.ttf,64 + + + + + DefenderWeapon + MagazineAmmo + + + + + + + diff --git a/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp b/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp index fc5334c9..13c3d8a3 100644 --- a/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp +++ b/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp @@ -40,12 +40,16 @@ void AssaultWeaponBehaviour::UpdateWeapon(ComponentWrapper cWeapon, WeaponInfo& magAmmo = glm::min(magSize, ammo); isReloading = false; if (wi.FirstPersonEntity.Valid()) { - wi.FirstPersonEntity["Model"]["Visible"] = true; + wi.FirstPersonEntity.FirstChildByName("ViewModel")["Model"]["Visible"] = true; } if (wi.ThirdPersonEntity.Valid()) { wi.ThirdPersonEntity["Model"]["Visible"] = true; } } + double reloadTime = cWeapon["ReloadTime"]; + if (isReloading && reloadTimer <= reloadTime / 2) { + + } // Restore view angle if (IsClient) { @@ -122,18 +126,26 @@ void AssaultWeaponBehaviour::OnReload(ComponentWrapper cWeapon, WeaponInfo& wi) // Play animation playAnimationAndReturn(wi.FirstPersonEntity, "BlendTreeAssaultWeapon", "Reload"); - if (IsClient) { - // Spawn explosion effect - EntityWrapper reloadEffectSpawner = wi.FirstPersonEntity.FirstChildByName("FirstPersonReloadSpawner"); - if (reloadEffectSpawner.Valid()) { - SpawnerSystem::Spawn(reloadEffectSpawner, reloadEffectSpawner); + // Spawn explosion effect + if (wi.FirstPersonEntity.Valid()) { + if (IsClient) { + EntityWrapper reloadEffectSpawner = wi.FirstPersonEntity.FirstChildByName("ReloadSpawner"); + if (reloadEffectSpawner.Valid()) { + reloadEffectSpawner.DeleteChildren(); + SpawnerSystem::Spawn(reloadEffectSpawner, reloadEffectSpawner); + } } - if (wi.FirstPersonEntity.Valid()) { - wi.FirstPersonEntity["Model"]["Visible"] = false; - } - if (wi.ThirdPersonEntity.Valid()) { - wi.ThirdPersonEntity["Model"]["Visible"] = false; + wi.FirstPersonEntity.FirstChildByName("ViewModel")["Model"]["Visible"] = false; + } + if (wi.ThirdPersonEntity.Valid()) { + if (IsServer) { + EntityWrapper reloadEffectSpawner = wi.ThirdPersonEntity.FirstChildByName("ReloadSpawner"); + if (reloadEffectSpawner.Valid()) { + reloadEffectSpawner.DeleteChildren(); + SpawnerSystem::Spawn(reloadEffectSpawner, reloadEffectSpawner); + } } + wi.ThirdPersonEntity["Model"]["Visible"] = false; } // Sound @@ -190,7 +202,7 @@ void AssaultWeaponBehaviour::fireBullet(ComponentWrapper cWeapon, WeaponInfo& wi } // Get weapon model based on current person - EntityWrapper weaponModelEntity = getRelevantWeaponModelEntity(wi); + EntityWrapper weaponModelEntity = getRelevantWeaponEntity(wi); if (!weaponModelEntity.Valid()) { return; } diff --git a/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp b/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp index 2d6ab74b..c18f9397 100644 --- a/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp +++ b/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp @@ -36,7 +36,7 @@ void DefenderWeaponBehaviour::UpdateWeapon(ComponentWrapper cWeapon, WeaponInfo& m_EventBroker->Publish(e); } else { isReloading = false; - playAnimationAndReturn(wi.FirstPersonEntity, "FinalBlend", "Idle"); + playAnimationAndReturn(wi.FirstPersonEntity, "FinalBlend", "ReloadEnd"); } } @@ -99,7 +99,21 @@ void DefenderWeaponBehaviour::OnReload(ComponentWrapper cWeapon, WeaponInfo& wi) reloadTimer = reloadTime; // Play animation - playAnimationAndReturn(wi.FirstPersonEntity, "FinalBlend", "Reload"); + if (wi.FirstPersonEntity.Valid()) { + Events::AutoAnimationBlend eBlendStart; + eBlendStart.RootNode = wi.FirstPersonEntity; + eBlendStart.NodeName = "ReloadStart"; + eBlendStart.Restart = true; + eBlendStart.Start = true; + m_EventBroker->Publish(eBlendStart); + Events::AutoAnimationBlend eBlendLoop; + eBlendLoop.RootNode = wi.FirstPersonEntity; + eBlendLoop.NodeName = "ReloadLoop"; + eBlendLoop.Restart = true; + eBlendLoop.Start = true; + eBlendLoop.AnimationEntity = wi.FirstPersonEntity.FirstChildByName("ReloadStart"); + m_EventBroker->Publish(eBlendLoop); + } } void DefenderWeaponBehaviour::OnHolster(ComponentWrapper cWeapon, WeaponInfo& wi) @@ -114,42 +128,48 @@ void DefenderWeaponBehaviour::OnHolster(ComponentWrapper cWeapon, WeaponInfo& wi bool DefenderWeaponBehaviour::OnInputCommand(ComponentWrapper cWeapon, WeaponInfo& wi, const Events::InputCommand& e) { - if (e.Command == "SpecialAbility" && IsServer) { + if (e.Command == "SpecialAbility") { EntityWrapper attachment = wi.Player.FirstChildByName("ShieldAttachment"); if (attachment.Valid()) { if (e.Value > 0) { - SpawnerSystem::Spawn(attachment, attachment); + if (IsServer) { + SpawnerSystem::Spawn(attachment, attachment); + } - EntityWrapper root = wi.FirstPersonEntity.FirstParentWithComponent("Model"); - if (root.Valid()) { - EntityWrapper subTree = root.FirstChildByName("FinalBlend"); - if (subTree.Valid()) { - EntityWrapper animationNode = subTree.FirstChildByName("Shield"); - if (animationNode.Valid()) { - Events::AutoAnimationBlend eFireBlend; - eFireBlend.RootNode = root; - eFireBlend.NodeName = "Shield"; - eFireBlend.Restart = true; - eFireBlend.Start = true; - m_EventBroker->Publish(eFireBlend); + if (IsClient) { + EntityWrapper root = wi.FirstPersonEntity; + if (root.Valid()) { + EntityWrapper subTree = root.FirstChildByName("FinalBlend"); + if (subTree.Valid()) { + EntityWrapper animationNode = subTree.FirstChildByName("Shield"); + if (animationNode.Valid()) { + Events::AutoAnimationBlend eFireBlend; + eFireBlend.RootNode = root; + eFireBlend.NodeName = "Shield"; + eFireBlend.Restart = true; + eFireBlend.Start = true; + m_EventBroker->Publish(eFireBlend); + } } } } } else { attachment.DeleteChildren(); - EntityWrapper root = wi.FirstPersonEntity.FirstParentWithComponent("Model"); - if (root.Valid()) { - EntityWrapper subTree = root.FirstChildByName("FinalBlend"); - if (subTree.Valid()) { - EntityWrapper animationNode = subTree.FirstChildByName("ActionBlend"); - if (animationNode.Valid()) { - Events::AutoAnimationBlend eFireBlend; - eFireBlend.RootNode = root; - eFireBlend.NodeName = "ActionBlend"; - eFireBlend.Restart = true; - eFireBlend.Start = true; - m_EventBroker->Publish(eFireBlend); + if (IsClient) { + EntityWrapper root = wi.FirstPersonEntity; + if (root.Valid()) { + EntityWrapper subTree = root.FirstChildByName("FinalBlend"); + if (subTree.Valid()) { + EntityWrapper animationNode = subTree.FirstChildByName("ActionBlend"); + if (animationNode.Valid()) { + Events::AutoAnimationBlend eFireBlend; + eFireBlend.RootNode = root; + eFireBlend.NodeName = "ActionBlend"; + eFireBlend.Restart = true; + eFireBlend.Start = true; + m_EventBroker->Publish(eFireBlend); + } } } } @@ -232,7 +252,7 @@ void DefenderWeaponBehaviour::fireShell(ComponentWrapper cWeapon, WeaponInfo& wi } // Play animation - playAnimationAndReturn(wi.FirstPersonEntity, "BlendTreeDefenderWeapon", "Fire"); + playAnimationAndReturn(wi.FirstPersonEntity, "FinalBlend", "Fire"); // Sound Events::PlaySoundOnEntity e; diff --git a/src/Game/Systems/Weapon/SidearmWeaponBehaviour.cpp b/src/Game/Systems/Weapon/SidearmWeaponBehaviour.cpp index d32b7d7e..cba3d5e8 100644 --- a/src/Game/Systems/Weapon/SidearmWeaponBehaviour.cpp +++ b/src/Game/Systems/Weapon/SidearmWeaponBehaviour.cpp @@ -52,7 +52,7 @@ void SidearmWeaponBehaviour::fireBullet(ComponentWrapper cWeapon, WeaponInfo& wi cWeapon["FireCooldown"] = 60.0 / (double)cWeapon["RPM"]; // Get weapon model based on current person - EntityWrapper weaponModelEntity = getRelevantWeaponModelEntity(wi); + EntityWrapper weaponModelEntity = getRelevantWeaponEntity(wi); if (!weaponModelEntity.Valid()) { return; } From 7b0f8873324e04fdb3c86a631d8d075ec053b563 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 19:59:57 +0100 Subject: [PATCH 08/14] fixup! fixup! Disabled InputCommand processing while you fiddle with editor UI elements --- src/Engine/Input/InputProxy.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Engine/Input/InputProxy.cpp b/src/Engine/Input/InputProxy.cpp index 295cf1c4..662aea52 100644 --- a/src/Engine/Input/InputProxy.cpp +++ b/src/Engine/Input/InputProxy.cpp @@ -64,7 +64,7 @@ void InputProxy::Process(bool suppressNewEvents /*= false*/) e.Value = currentValue; if (!suppressNewEvents || e.Value == 0) { m_EventBroker->Publish(e); - LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); + //LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); } m_LastCommandValues[command] = currentValue; } @@ -82,7 +82,7 @@ void InputProxy::Process(bool suppressNewEvents /*= false*/) //e.Value = std::max(-1.f, std::min(e.Value, 1.f)); if (!suppressNewEvents || e.Value == 0) { m_EventBroker->Publish(e); - LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); + //LOG_DEBUG("Input: Published command %s=%f for player %i", e.Command.c_str(), e.Value, e.PlayerID); } } m_CommandQueue.clear(); From 77b9112f55685872371dde28c18209b2b2d132a2 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Mon, 7 Mar 2016 20:04:22 +0100 Subject: [PATCH 09/14] Since I overwrote the assets I was sent with a now reverted commit, Defender weapon reload animations won't work until it's exported properly --- assets | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets b/assets index 0f9208a3..d7685a31 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit 0f9208a305b204cc9a7a9d6accfb084bc40e8095 +Subproject commit d7685a31afeb4ede0a1a50799ad43c85f3efd104 From e43a7be7dbca8d26dbf43cde5b86cb39126c426f Mon Sep 17 00:00:00 2001 From: verysecrethero Date: Tue, 8 Mar 2016 15:55:51 +0100 Subject: [PATCH 10/14] DamageIndicatorSystem now works for singleplayer again. Friendly fire DamageIndicator is now black color. --- include/Game/Systems/DamageIndicatorSystem.h | 3 +++ src/Game/Systems/DamageIndicatorSystem.cpp | 13 +++++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/include/Game/Systems/DamageIndicatorSystem.h b/include/Game/Systems/DamageIndicatorSystem.h index 9c88ba78..f3a95817 100644 --- a/include/Game/Systems/DamageIndicatorSystem.h +++ b/include/Game/Systems/DamageIndicatorSystem.h @@ -15,6 +15,7 @@ #include "Rendering/Util/CommonFunctions.h" //#define INDICATOR_TEST +#include "Core/ConfigFile.h" class DamageIndicatorSystem : public ImpureSystem { @@ -40,6 +41,8 @@ private: std::vector updateDamageIndicatorVector; float CalculateAngle(EntityWrapper player, glm::vec3 enemyPos); + bool m_NetworkEnabled; + //for tests #ifdef INDICATOR_TEST glm::vec3 DamageIndicatorTest(EntityWrapper player); diff --git a/src/Game/Systems/DamageIndicatorSystem.cpp b/src/Game/Systems/DamageIndicatorSystem.cpp index e68f741d..0cc3e717 100644 --- a/src/Game/Systems/DamageIndicatorSystem.cpp +++ b/src/Game/Systems/DamageIndicatorSystem.cpp @@ -10,10 +10,11 @@ DamageIndicatorSystem::DamageIndicatorSystem(SystemParams params) //load texture to cache auto texture = CommonFunctions::LoadTexture("Textures/DamageIndicator.png", false); auto entityFile = ResourceManager::Load("Schema/Entities/DamageIndicator.xml"); + m_NetworkEnabled = ResourceManager::Load("Config.ini")->Get("Networking.StartNetwork", false); } void DamageIndicatorSystem::Update(double dt) { - if (!IsServer && LocalPlayer.Valid()) { + if ((!IsServer || !m_NetworkEnabled) && LocalPlayer.Valid()) { for (auto& iter = updateDamageIndicatorVector.begin(); iter != updateDamageIndicatorVector.end(); iter++) { if (!iter->spriteEntity.Valid()) { updateDamageIndicatorVector.erase(iter); @@ -43,7 +44,7 @@ bool DamageIndicatorSystem::OnPlayerDamage(Events::PlayerDamage& e) glm::vec3 inflictorPos = e.Inflictor["Transform"]["Position"]; //if testing #ifdef INDICATOR_TEST - inflictorPos = DamageIndicatorTest(e.Victim); + inflictorPos = DamageIndicatorTest(e.Victim); #endif float angleBetweenVectors = CalculateAngle(e.Victim, inflictorPos); @@ -54,8 +55,12 @@ bool DamageIndicatorSystem::OnPlayerDamage(Events::PlayerDamage& e) m_World->SetParent(sprite.ID, m_CurrentCamera); //simply set the rotation z-wise to the angleBetweenVectors sprite["Transform"]["Orientation"] = glm::vec3(0, 0, angleBetweenVectors); + //friendly fire - change color of the marker + if (e.Damage < 0.1f) { + sprite["Sprite"]["Color"] = glm::vec4(0.0, 1.0f, 1.0f, 1.0f); + } - if (!IsServer) { + if (!IsServer || !m_NetworkEnabled) { updateDamageIndicatorVector.emplace_back(sprite, inflictorPos); } @@ -122,7 +127,7 @@ glm::vec3 DamageIndicatorSystem::DamageIndicatorTest(EntityWrapper player) { } m_TestVar++; - auto inflictorPos = glm::vec3(currentPos.x + testVar*6.0f, currentPos.y, currentPos.z + testVar2*6.0f); + auto inflictorPos = glm::vec3(currentPos.x + testVar*6.0f, currentPos.y, currentPos.z + testVar2*6.0f); //load the explosioneffect XML auto deathEffect = ResourceManager::Load("Schema/Entities/PlayerDeathExplosionWithCamera.xml"); From 6456df8ce1440c92e09749216f0e9616112809c0 Mon Sep 17 00:00:00 2001 From: verysecrethero Date: Wed, 9 Mar 2016 10:44:08 +0100 Subject: [PATCH 11/14] DamageIndicator is now disabled for Friendly fire --- src/Game/Systems/DamageIndicatorSystem.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/Game/Systems/DamageIndicatorSystem.cpp b/src/Game/Systems/DamageIndicatorSystem.cpp index 0cc3e717..7e22a0d6 100644 --- a/src/Game/Systems/DamageIndicatorSystem.cpp +++ b/src/Game/Systems/DamageIndicatorSystem.cpp @@ -41,6 +41,11 @@ bool DamageIndicatorSystem::OnPlayerDamage(Events::PlayerDamage& e) return false; } + //friendly fire - return + if (e.Damage < 0.1f) { + return false; + } + glm::vec3 inflictorPos = e.Inflictor["Transform"]["Position"]; //if testing #ifdef INDICATOR_TEST @@ -55,10 +60,6 @@ bool DamageIndicatorSystem::OnPlayerDamage(Events::PlayerDamage& e) m_World->SetParent(sprite.ID, m_CurrentCamera); //simply set the rotation z-wise to the angleBetweenVectors sprite["Transform"]["Orientation"] = glm::vec3(0, 0, angleBetweenVectors); - //friendly fire - change color of the marker - if (e.Damage < 0.1f) { - sprite["Sprite"]["Color"] = glm::vec4(0.0, 1.0f, 1.0f, 1.0f); - } if (!IsServer || !m_NetworkEnabled) { updateDamageIndicatorVector.emplace_back(sprite, inflictorPos); From 555b19c41d6aa11ce81f8b564173f0447443a3ff Mon Sep 17 00:00:00 2001 From: viktorljung Date: Wed, 9 Mar 2016 13:49:28 +0100 Subject: [PATCH 12/14] BoneAttachments now working perfectly --- src/Engine/Rendering/BoneAttachmentSystem.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/Engine/Rendering/BoneAttachmentSystem.cpp b/src/Engine/Rendering/BoneAttachmentSystem.cpp index 43dc8634..14db0466 100644 --- a/src/Engine/Rendering/BoneAttachmentSystem.cpp +++ b/src/Engine/Rendering/BoneAttachmentSystem.cpp @@ -50,13 +50,16 @@ void BoneAttachmentSystem::UpdateComponent(EntityWrapper& entity, ComponentWrapp glm::vec4 perspective; glm::decompose(boneTransform, scale, rotation, translation, skew, perspective); - glm::vec3 angles = glm::vec3(-glm::pitch(rotation), -glm::yaw(rotation), -glm::roll(rotation)); + rotation = glm::quat((glm::vec3)entity["BoneAttachment"]["OrientationOffset"]) * rotation; + + rotation.w = -rotation.w; + glm::vec3 angles = glm::eulerAngles(rotation); if ((bool)entity["BoneAttachment"]["InheritPosition"]) { (glm::vec3&)entity["Transform"]["Position"] = translation + (glm::vec3)entity["BoneAttachment"]["PositionOffset"]; } if ((bool)entity["BoneAttachment"]["InheritOrientation"]) { - (glm::vec3&)entity["Transform"]["Orientation"] = angles + (glm::vec3)entity["BoneAttachment"]["OrientationOffset"]; + (glm::vec3&)entity["Transform"]["Orientation"] = angles; } if ((bool)entity["BoneAttachment"]["InheritScale"]) { (glm::vec3&)entity["Transform"]["Scale"] = scale * (glm::vec3)entity["BoneAttachment"]["ScaleOffset"]; From ddde50b69054436110c219c0d415941458de6dc3 Mon Sep 17 00:00:00 2001 From: viktorljung Date: Wed, 9 Mar 2016 14:27:50 +0100 Subject: [PATCH 13/14] Inverse seems to be the same as -w --- src/Engine/Rendering/BoneAttachmentSystem.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/Engine/Rendering/BoneAttachmentSystem.cpp b/src/Engine/Rendering/BoneAttachmentSystem.cpp index 14db0466..c1cdf0f2 100644 --- a/src/Engine/Rendering/BoneAttachmentSystem.cpp +++ b/src/Engine/Rendering/BoneAttachmentSystem.cpp @@ -51,8 +51,7 @@ void BoneAttachmentSystem::UpdateComponent(EntityWrapper& entity, ComponentWrapp glm::decompose(boneTransform, scale, rotation, translation, skew, perspective); rotation = glm::quat((glm::vec3)entity["BoneAttachment"]["OrientationOffset"]) * rotation; - - rotation.w = -rotation.w; + rotation = glm::inverse(rotation); glm::vec3 angles = glm::eulerAngles(rotation); if ((bool)entity["BoneAttachment"]["InheritPosition"]) { From 9d368348d5ebda42979fc62709e0023951246f63 Mon Sep 17 00:00:00 2001 From: sippeangelo Date: Wed, 9 Mar 2016 15:48:57 +0100 Subject: [PATCH 14/14] Updated 3rd person and 1st person animation trees for assault to allow for third person weapon animations --- assets | 2 +- include/Game/Systems/Weapon/WeaponBehaviour.h | 4 + .../Schema/Entities/PlayerAssaultBlue.xml | 581 ++++++++---------- .../Schema/Entities/WeaponAssaultBlueView.xml | 72 +-- .../Entities/WeaponDefenderBlueView.xml | 20 +- .../Systems/Weapon/AssaultWeaponBehaviour.cpp | 31 +- .../Weapon/DefenderWeaponBehaviour.cpp | 38 +- 7 files changed, 346 insertions(+), 402 deletions(-) diff --git a/assets b/assets index d7685a31..d48c77c8 160000 --- a/assets +++ b/assets @@ -1 +1 @@ -Subproject commit d7685a31afeb4ede0a1a50799ad43c85f3efd104 +Subproject commit d48c77c854317333e38917a2be76069df969426d diff --git a/include/Game/Systems/Weapon/WeaponBehaviour.h b/include/Game/Systems/Weapon/WeaponBehaviour.h index a21ed6d5..3f3b6559 100644 --- a/include/Game/Systems/Weapon/WeaponBehaviour.h +++ b/include/Game/Systems/Weapon/WeaponBehaviour.h @@ -60,7 +60,9 @@ protected: EntityWrapper Player; EntityWrapper WeaponEntity; EntityWrapper FirstPersonEntity; + EntityWrapper FirstPersonPlayerModel; EntityWrapper ThirdPersonEntity; + EntityWrapper ThirdPersonPlayerModel; }; IRenderer* m_Renderer; @@ -301,7 +303,9 @@ private: wi.Player = player; wi.WeaponEntity = player; wi.FirstPersonEntity = firstPersonWeapon; + wi.FirstPersonPlayerModel = firstPersonWeapon; wi.ThirdPersonEntity = thirdPersonWeapon; + wi.ThirdPersonPlayerModel = thirdPersonWeapon.FirstParentWithComponent("Model"); OnEquip(cWeapon, wi); } diff --git a/resources/Schema/Entities/PlayerAssaultBlue.xml b/resources/Schema/Entities/PlayerAssaultBlue.xml index 8bceb701..5f245a53 100644 --- a/resources/Schema/Entities/PlayerAssaultBlue.xml +++ b/resources/Schema/Entities/PlayerAssaultBlue.xml @@ -6,9 +6,7 @@ - - 0.5 - + @@ -550,10 +548,10 @@ - - BlendTreeAim - BlendTreeAssault - + + BlendTreeUpper + BlendTreeLower + @@ -577,8 +575,8 @@ Schema/Entities/WeaponAssaultBlueWorld.xml - - + + @@ -598,142 +596,80 @@ Schema/Entities/SidearmWeaponWorld.xml - - + + - + - AimPrimary - AimSecondary - 0 + StandCrouchBlend + JumpDashBlend + 2.5146881298480398e-63 true - - - - AimSecWepA - - false - true - - - - - - - - - AimRifleA - - false - true - - - - - - - - - - - ReloadSwitchBlend - FinalMovementBlend - - - - - + - StandCrouchBlend - JumpDashBlend - 2.5146881298480398e-63 + StandMovement + CrouchMovement + 0 true - + - StandMovement - CrouchMovement - 0 - true + MovementBlend + Idle + 1 - + - MovementBlend - Idle - 1 + Walk + StrafeLRBlend + 0 - + - Walk - StrafeLRBlend - 0 + Left + Right + 0.033793529385008014 - - - - Left - Right - 0.033793529385008014 - - - - - - - - CrouchStrafeLeftF - - 1 - true - - - - - - - - - CrouchStrafeRightF - - 1 - true - - - - - - - - + - CrouchWalkF - - 1 + CrouchStrafeLeftF + + true + + + + + + + + + CrouchStrafeRightF + true @@ -742,119 +678,11 @@ - + - CrouchF - - 1 - - - - - - - - - - - MovementBlend - Idle - 1 - - - - - - - - RunWalkBlend - StrafeLRBlend - 2.4565650245976452e-16 - - - - - - - - Walk - Run - 1.2938206818383024e-24 - - - - - - - - WalkF - - 1 - true - - - - - - - - - RunF - - 1 - true - - - - - - - - - - - Left - Right - 0.033793529385008014 - - - - - - - - StrafeLeftF - - 1 - true - - - - - - - - - StrafeRightF - - 1 - true - - - - - - - - - - - - - IdleF - - 1 + CrouchWalkF + true @@ -863,70 +691,65 @@ - - - - - - Jump - DashBlend - 1 - true - - - - - + - JumpF - - 1 - false + CrouchF + - + + + + + + MovementBlend + Idle + 1 + + + + + - DashFBBlend - DashLRBlend - 0.014621149736541383 + RunWalkBlend + StrafeLRBlend + 2.4565650245976452e-16 - + - DashForward - DashBackward - 0.014363533804961248 + Walk + Run + 1.2938206818383024e-24 - + - DashForwardF - - 2 - false + WalkF + + true - + - DashBackwardF - - 2 - false + RunF + + true @@ -934,35 +757,33 @@ - + - DashLeft - DashRight - 4.3244885367500671e-16 + Left + Right + 0.033793529385008014 - + - DashLeftF - - 2 - false + StrafeLeftF + + true - + - DashRightF - - 2 - false + StrafeRightF + + true @@ -972,71 +793,186 @@ + + + + IdleF + + true + + + + + + + + + + + + + Jump + DashBlend + 1 + true + + + + + + + + JumpF + + false + + + + + + + + + DashFBBlend + DashLRBlend + 0.014621149736541383 + + + + + + + + DashForward + DashBackward + 0.014363533804961248 + + + + + + + + DashForwardF + + 2 + false + + + + + + + + + DashBackwardF + + 2 + false + + + + + + + + + + + DashLeft + DashRight + 4.3244885367500671e-16 + + + + + + + + DashLeftF + + 2 + false + + + + + + + + + DashRightF + + 2 + false + + + + + + + - + + + + + + AssaultWeaponBlend + SidearmWeapon + 0 + true + + + + + - - ReloadSwitch - WeaponActionBlend - 1 - true - + + Aim + WeaponBlend + - + - - ReloadSwitchU - - 1 - - - - - - - - - IdleBlend - ShootBlend - 0 - + + MovementBlend + ActionBlend + - + - IdlePrimary - IdleSecondary - 0 + Fire + Reload + 1 - + - IdleAssaultRifleU - - 1 - true + ReloadSwitchU + 0.5 + false - + - IdleSecWepU - - 1 - true + ShootFastRifleU + false @@ -1044,31 +980,33 @@ - + - ShootPrimary - ShootSecondary + Idle + Run 0 - + - ShootFastRifleU - - 1 + IdleAssaultRifleU + true + true - + - ShootSecWepFastU + IdleAssaultRifleU + true + true @@ -1078,6 +1016,19 @@ + + + + AimRifleA + + 0.10000000149011612 + false + true + + + + + diff --git a/resources/Schema/Entities/WeaponAssaultBlueView.xml b/resources/Schema/Entities/WeaponAssaultBlueView.xml index 235a9480..05b65bbb 100644 --- a/resources/Schema/Entities/WeaponAssaultBlueView.xml +++ b/resources/Schema/Entities/WeaponAssaultBlueView.xml @@ -4,7 +4,7 @@ MovementBlend - FinalBlend + ActionBlend Models/Characters/Assault/FirstPersonAssaultBlue.mesh @@ -13,54 +13,34 @@ - + - BlendTreeAssaultWeapon - BlendTreeSecondaryWeapon + Fire + Reload 0 true - + - - Fire - Reload - 0 - true - + + ReloadSwitchF + 0.5 + false + - - - - - ReloadSwitchF - 0.5 - false - - - - - - - - - ShootRifleF - 1 - false - - - - - - + - + + + ShootRifleF + false + @@ -78,11 +58,10 @@ - + - IdleF - 1 + RunF true true @@ -90,11 +69,10 @@ - + - RunF - 1 + IdleF true true @@ -113,8 +91,8 @@ Models/Weapons/Blue/AssaultWeaponBlue.mesh - - + + @@ -149,9 +127,9 @@ true - - - + + + diff --git a/resources/Schema/Entities/WeaponDefenderBlueView.xml b/resources/Schema/Entities/WeaponDefenderBlueView.xml index 493c7243..c22e7200 100644 --- a/resources/Schema/Entities/WeaponDefenderBlueView.xml +++ b/resources/Schema/Entities/WeaponDefenderBlueView.xml @@ -27,9 +27,7 @@ - ActivateDeactiveShieldF - - 1 + ActivateDeactivateShieldF false @@ -50,7 +48,6 @@ ShootShotgunF - 1 false @@ -71,7 +68,6 @@ ShotgunReloadTwoF - 1 @@ -91,7 +87,6 @@ ShotgunReloadOneF - 1 false @@ -102,7 +97,6 @@ ShotgunReloadThreeF - 1 false @@ -132,7 +126,6 @@ IdleF - 1 true true @@ -144,7 +137,6 @@ RunF - 1 true true @@ -163,8 +155,8 @@ Models/Weapons/Blue/DefenderWeaponBlue.mesh - - + + @@ -197,9 +189,9 @@ true - - - + + + diff --git a/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp b/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp index 13c3d8a3..dddf5fdd 100644 --- a/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp +++ b/src/Game/Systems/Weapon/AssaultWeaponBehaviour.cpp @@ -72,7 +72,7 @@ void AssaultWeaponBehaviour::UpdateWeapon(ComponentWrapper cWeapon, WeaponInfo& const float& movementSpeed = cPlayer["MovementSpeed"]; float speed = glm::length((const glm::vec3&)cPhysics["Velocity"]); float animationWeight = glm::min(speed, movementSpeed) / movementSpeed; - EntityWrapper rootNode = wi.FirstPersonEntity.FirstParentWithComponent("Model"); + EntityWrapper rootNode = wi.FirstPersonEntity; if (rootNode.Valid()) { EntityWrapper blend = rootNode.FirstChildByName("MovementBlend"); if (blend.Valid()) { @@ -125,7 +125,20 @@ void AssaultWeaponBehaviour::OnReload(ComponentWrapper cWeapon, WeaponInfo& wi) reloadTimer = reloadTime; // Play animation - playAnimationAndReturn(wi.FirstPersonEntity, "BlendTreeAssaultWeapon", "Reload"); + playAnimationAndReturn(wi.FirstPersonEntity, "ActionBlend", "Reload"); + // Third person anim + Events::AutoAnimationBlend b1; + b1.RootNode = wi.ThirdPersonPlayerModel; + b1.NodeName = "Reload"; + b1.Restart = true; + b1.Start = true; + m_EventBroker->Publish(b1); + Events::AutoAnimationBlend b2; + b2.RootNode = wi.ThirdPersonPlayerModel; + b2.NodeName = "MovementBlend"; + b2.AnimationEntity = wi.ThirdPersonPlayerModel.FirstChildByName("AssaultWeaponBlend").FirstChildByName("Reload"); + m_EventBroker->Publish(b2); + // Spawn explosion effect if (wi.FirstPersonEntity.Valid()) { if (IsClient) { @@ -233,7 +246,19 @@ void AssaultWeaponBehaviour::fireBullet(ComponentWrapper cWeapon, WeaponInfo& wi } // Play animation - playAnimationAndReturn(wi.FirstPersonEntity, "BlendTreeAssaultWeapon", "Fire"); + playAnimationAndReturn(wi.FirstPersonEntity, "ActionBlend", "Fire"); + // Third person anim + Events::AutoAnimationBlend b1; + b1.RootNode = wi.ThirdPersonPlayerModel; + b1.NodeName = "Fire"; + b1.Restart = true; + b1.Start = true; + m_EventBroker->Publish(b1); + Events::AutoAnimationBlend b2; + b2.RootNode = wi.ThirdPersonPlayerModel; + b2.NodeName = "MovementBlend"; + b2.AnimationEntity = wi.ThirdPersonPlayerModel.FirstChildByName("AssaultWeaponBlend").FirstChildByName("Fire"); + m_EventBroker->Publish(b2); // Sound Events::PlaySoundOnEntity e; diff --git a/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp b/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp index c18f9397..835b5378 100644 --- a/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp +++ b/src/Game/Systems/Weapon/DefenderWeaponBehaviour.cpp @@ -139,17 +139,14 @@ bool DefenderWeaponBehaviour::OnInputCommand(ComponentWrapper cWeapon, WeaponInf if (IsClient) { EntityWrapper root = wi.FirstPersonEntity; if (root.Valid()) { - EntityWrapper subTree = root.FirstChildByName("FinalBlend"); - if (subTree.Valid()) { - EntityWrapper animationNode = subTree.FirstChildByName("Shield"); - if (animationNode.Valid()) { - Events::AutoAnimationBlend eFireBlend; - eFireBlend.RootNode = root; - eFireBlend.NodeName = "Shield"; - eFireBlend.Restart = true; - eFireBlend.Start = true; - m_EventBroker->Publish(eFireBlend); - } + EntityWrapper animationNode = root.FirstChildByName("Shield"); + if (animationNode.Valid()) { + Events::AutoAnimationBlend eFireBlend; + eFireBlend.RootNode = root; + eFireBlend.NodeName = "Shield"; + eFireBlend.Restart = true; + eFireBlend.Start = true; + m_EventBroker->Publish(eFireBlend); } } } @@ -159,17 +156,14 @@ bool DefenderWeaponBehaviour::OnInputCommand(ComponentWrapper cWeapon, WeaponInf if (IsClient) { EntityWrapper root = wi.FirstPersonEntity; if (root.Valid()) { - EntityWrapper subTree = root.FirstChildByName("FinalBlend"); - if (subTree.Valid()) { - EntityWrapper animationNode = subTree.FirstChildByName("ActionBlend"); - if (animationNode.Valid()) { - Events::AutoAnimationBlend eFireBlend; - eFireBlend.RootNode = root; - eFireBlend.NodeName = "ActionBlend"; - eFireBlend.Restart = true; - eFireBlend.Start = true; - m_EventBroker->Publish(eFireBlend); - } + EntityWrapper animationNode = root.FirstChildByName("ActionBlend"); + if (animationNode.Valid()) { + Events::AutoAnimationBlend eFireBlend; + eFireBlend.RootNode = root; + eFireBlend.NodeName = "ActionBlend"; + eFireBlend.Restart = true; + eFireBlend.Start = true; + m_EventBroker->Publish(eFireBlend); } } }