Skip to content
Snippets Groups Projects
Commit 5e5b1f34 authored by Saul Sayers's avatar Saul Sayers
Browse files

fix onehitkill reset cheat

parent f62f655a
Branches
Tags
No related merge requests found
......@@ -101,7 +101,7 @@ public class Bow : MonoBehaviour
damagePerShot = 2000;
} else if (hitKillCheat && countHitKill > 0){
countHitKill = 0;
damagePerShot = 80;
damagePerShot = setWeaponDmg();
hitKillCheat = false;
}
......
......@@ -70,7 +70,7 @@ public class PlayerShooting : MonoBehaviour
damagePerShot = 2000;
} else if (hitKillCheat && countHitKill > 0){
countHitKill = 0;
damagePerShot = 20;
damagePerShot = setWeaponDmg();
hitKillCheat = false;
}
......
......@@ -73,7 +73,7 @@ public class PlayerShotgun : MonoBehaviour
damagePerShot = 2000;
} else if (hitKillCheat && countHitKill > 0){
countHitKill = 0;
damagePerShot = 20;
damagePerShot = setWeaponDmg();
hitKillCheat = false;
}
......
......@@ -39,6 +39,15 @@ public class Sword : MonoBehaviour
void Update(){
if (!GameManager.isPause) {
if (hitKillCheat && countHitKill == 0){
countHitKill++;
damagePerShot = 2000;
} else if (hitKillCheat && countHitKill > 0){
countHitKill = 0;
damagePerShot = setWeaponDmg();
hitKillCheat = false;
}
if (Attack){
timer += Time.deltaTime;
if (timer > attackTime){
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment