Skip to content

Commit

Permalink
Fixed LaneObject property
Browse files Browse the repository at this point in the history
  • Loading branch information
LunaAmora committed Nov 27, 2021
1 parent 800cd1d commit d45b5ba
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 35d6a8426744d2b4e85ab12f1132238c, type: 3}
m_Name:
m_EditorClassIdentifier:
GameEvents: {fileID: 11400000, guid: c7be7884495f6ed4b93a14fdeff0d0f1, type: 2}
_gameEvents: {fileID: 11400000, guid: c7be7884495f6ed4b93a14fdeff0d0f1, type: 2}
_lean_type: 4
_rotateTweenAngles: 360
_rotateTweenTime: 2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -293,4 +293,4 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 9ae7966f09b306243ac783416be3b5e8, type: 3}
m_Name:
m_EditorClassIdentifier:
GameEvents: {fileID: 11400000, guid: c7be7884495f6ed4b93a14fdeff0d0f1, type: 2}
_gameEvents: {fileID: 11400000, guid: c7be7884495f6ed4b93a14fdeff0d0f1, type: 2}
Original file line number Diff line number Diff line change
Expand Up @@ -293,4 +293,4 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 9ae7966f09b306243ac783416be3b5e8, type: 3}
m_Name:
m_EditorClassIdentifier:
GameEvents: {fileID: 11400000, guid: c7be7884495f6ed4b93a14fdeff0d0f1, type: 2}
_gameEvents: {fileID: 11400000, guid: c7be7884495f6ed4b93a14fdeff0d0f1, type: 2}
2 changes: 1 addition & 1 deletion Assets/_PerpetualJourney/Scripts/Objects/Collectable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ private void Disable()

protected override void CollidedWithPlayer()
{
GameEvents.CollectableCollision();
GameEvent.CollectableCollision();
Disable();
}
}
Expand Down
4 changes: 3 additions & 1 deletion Assets/_PerpetualJourney/Scripts/Objects/LaneObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ namespace PerpetualJourney
{
public abstract class LaneObject : MonoBehaviour, ICanBePooled
{
[SerializeField] protected GameEvents GameEvents {get; set;}
[SerializeField] private GameEvents _gameEvents;

protected GameEvents GameEvent => _gameEvents;

private float _laneSize;
private int _lane;
Expand Down
2 changes: 1 addition & 1 deletion Assets/_PerpetualJourney/Scripts/Objects/Obstacle.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public class Obstacle : LaneObject
{
protected override void CollidedWithPlayer()
{
GameEvents.ObstacleCollision();
GameEvent.ObstacleCollision();
}
}
}

0 comments on commit d45b5ba

Please sign in to comment.