Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wip fix reload buggerino #737

Draft
wants to merge 1 commit into
base: dev
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Assets/Animation/Augments/Lazur/Cannon_CannonAction.anim
Original file line number Diff line number Diff line change
Expand Up @@ -2107,7 +2107,7 @@ AnimationClip:
m_AdditiveReferencePoseClip: {fileID: 0}
m_AdditiveReferencePoseTime: 0
m_StartTime: 0
m_StopTime: 1.3166667
m_StopTime: 1.3333334
m_OrientationOffsetY: 0
m_Level: 0
m_CycleOffset: 0
Expand Down Expand Up @@ -11057,3 +11057,10 @@ AnimationClip:
floatParameter: 0
intParameter: 0
messageOptions: 0
- time: 1.3333334
functionName: EndFiring
data:
objectReferenceParameter: {fileID: 0}
floatParameter: 0
intParameter: 0
messageOptions: 0
10 changes: 5 additions & 5 deletions Assets/Animation/Augments/Lazur/Lazur.controller
Original file line number Diff line number Diff line change
Expand Up @@ -167,31 +167,31 @@ AnimatorController:
m_DefaultFloat: 0
m_DefaultInt: 0
m_DefaultBool: 0
m_Controller: {fileID: 0}
m_Controller: {fileID: 9100000}
- m_Name: Outer
m_Type: 1
m_DefaultFloat: 0.2
m_DefaultInt: 0
m_DefaultBool: 0
m_Controller: {fileID: 0}
m_Controller: {fileID: 9100000}
- m_Name: Inner
m_Type: 1
m_DefaultFloat: -0.3
m_DefaultInt: 0
m_DefaultBool: 0
m_Controller: {fileID: 0}
m_Controller: {fileID: 9100000}
- m_Name: Spinner
m_Type: 1
m_DefaultFloat: 3
m_DefaultInt: 0
m_DefaultBool: 0
m_Controller: {fileID: 0}
m_Controller: {fileID: 9100000}
- m_Name: Spiral
m_Type: 1
m_DefaultFloat: -0.25
m_DefaultInt: 0
m_DefaultBool: 0
m_Controller: {fileID: 0}
m_Controller: {fileID: 9100000}
m_AnimatorLayers:
- serializedVersion: 5
m_Name: Base Layer
Expand Down
10 changes: 8 additions & 2 deletions Assets/LazurFiringAnimator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,14 @@ public void PlayChargeUpSound()

public void ShootLazer()
{
this.OnShotFiredAnimation?.Invoke();
this.OnAnimationEnd?.Invoke();
Debug.Log("SHOOP DA WOOP");
OnShotFiredAnimation?.Invoke();
}

public void EndFiring()
{
Debug.Log("SHOOP DONE");
OnAnimationEnd?.Invoke();
}

public override void OnFire(GunStats stats)
Expand Down
6 changes: 3 additions & 3 deletions Assets/Models/GunParts/CoilBarrel.fbx.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion Assets/Scripts/Augment/AugmentImplementations/Revolver.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ protected override void Reload(GunStats stats)
extension.transform.SetParent(attachmentSite, true);

animator.SetTrigger("Reload");
gunController.onReload?.Invoke(stats);
}

public void TriggerSteam()
Expand Down
2 changes: 1 addition & 1 deletion Assets/Scripts/Augment/GunController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ private void RpcFireWithNoAmmo()

private void FireGun()
{
if (stats.Ammo <= 0)
if (stats.Ammo < 1)
{
CmdFireWithNoAmmo();
return;
Expand Down