Fixed a few bugs

dev-main
Hazim Bin Ijaz 1 month ago
parent 9934c7c898
commit 1ba3ad4142

@ -1920,7 +1920,7 @@ PrefabInstance:
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 370034730102636685, guid: 4512c09d24f3fa147afb198fa90d63c6, type: 3} - target: {fileID: 370034730102636685, guid: 4512c09d24f3fa147afb198fa90d63c6, type: 3}
propertyPath: VectorWallAbilityKey propertyPath: VectorWallAbilityKey
value: VectorWall value: VectorFence
objectReference: {fileID: 0} objectReference: {fileID: 0}
- target: {fileID: 370034730102636685, guid: 4512c09d24f3fa147afb198fa90d63c6, type: 3} - target: {fileID: 370034730102636685, guid: 4512c09d24f3fa147afb198fa90d63c6, type: 3}
propertyPath: m_GeneralSwapActionPrototype propertyPath: m_GeneralSwapActionPrototype

@ -49,7 +49,7 @@ public class AbilitySystem : NetworkBehaviour
{ {
{ GameDataSource.Instance.DashNCrashAbilityKey, CursorState.Dash }, { GameDataSource.Instance.DashNCrashAbilityKey, CursorState.Dash },
{ GameDataSource.Instance.FreezeThrowAbilityKey, CursorState.Freeze }, { GameDataSource.Instance.FreezeThrowAbilityKey, CursorState.Freeze },
{ GameDataSource.Instance.VectorWallAbilityKey, CursorState.VectorWall }, { GameDataSource.Instance.VectorFenceAbilityKey, CursorState.VectorFence },
{ GameDataSource.Instance.TheExecutionerKey, CursorState.Executioner }, { GameDataSource.Instance.TheExecutionerKey, CursorState.Executioner },
{ GameDataSource.Instance.CrowsForesightKey, CursorState.Foresight }, { GameDataSource.Instance.CrowsForesightKey, CursorState.Foresight },
}; };
@ -84,7 +84,7 @@ public class AbilitySystem : NetworkBehaviour
{ {
if (isAbilityActive) if (isAbilityActive)
{ {
if (activeAbility.abilityKey == "VectorFence") if (activeAbility.abilityKey == GameDataSource.Instance.VectorFenceAbilityKey)
{ {
// For VectorFence, manage wall indicator and placement // For VectorFence, manage wall indicator and placement
ManageVectorFenceIndicator(); ManageVectorFenceIndicator();

@ -3,7 +3,7 @@ public enum CursorState
Default, Default,
Swap, Swap,
Blocked, Blocked,
VectorWall, VectorFence,
Dash, Dash,
Freeze, Freeze,
Executioner, Executioner,

@ -84,7 +84,7 @@ namespace Unity.BossRoom.Gameplay.GameplayObjects
public string DashNCrashAbilityKey = "DashNCrash"; public string DashNCrashAbilityKey = "DashNCrash";
public string FreezeThrowAbilityKey = "FreezeThrow"; public string FreezeThrowAbilityKey = "FreezeThrow";
public string VectorWallAbilityKey = "VectorWall"; public string VectorFenceAbilityKey = "VectorFence";
public string TheExecutionerKey = "TheExecutioner"; public string TheExecutionerKey = "TheExecutioner";
public string CrowsForesightKey = "CrowsForesight"; public string CrowsForesightKey = "CrowsForesight";
public string SwapButtonKey = "Swap"; public string SwapButtonKey = "Swap";

@ -46,7 +46,7 @@ namespace Unity.Multiplayer.Samples.BossRoom
private IEnumerator DelayedServerSetup() private IEnumerator DelayedServerSetup()
{ {
yield return new WaitForSeconds(0.5f); yield return new WaitForSeconds(1.5f);
PlatformSelection(); PlatformSelection();
} }

@ -267,30 +267,30 @@ namespace Unity.BossRoom.Gameplay.UI
// make sure allies array is ready // make sure allies array is ready
// InitPartyArrays(); // InitPartyArrays();
int openslot = -1; // int openslot = -1;
for (int i = 0; i < m_PartyIds.Length; i++) // for (int i = 0; i < m_PartyIds.Length; i++)
{ // {
// if this ID is in the list, return the slot index // // if this ID is in the list, return the slot index
if (m_PartyIds[i] == id) { return i; } // if (m_PartyIds[i] == id) { return i; }
// otherwise, record the first open slot (not slot 0 thats for the Hero) // // otherwise, record the first open slot (not slot 0 thats for the Hero)
if (openslot == -1 && i > 0 && m_PartyIds[i] == 0) // if (openslot == -1 && i > 0 && m_PartyIds[i] == 0)
{ // {
openslot = i; // openslot = i;
} // }
} // }
//
// if we don't add, we are done nw and didnt fint the ID // // if we don't add, we are done nw and didnt fint the ID
if (dontAdd) { return -1; } // if (dontAdd) { return -1; }
//
// Party slot was not found for this ID - add one in the open slot // // Party slot was not found for this ID - add one in the open slot
if (openslot > 0) // if (openslot > 0)
{ // {
// activeate the correct ally panel // // activeate the correct ally panel
m_AllyPanel[openslot - 1].SetActive(true); // m_AllyPanel[openslot - 1].SetActive(true);
// and save ally ID to party array // // and save ally ID to party array
m_PartyIds[openslot] = id; // m_PartyIds[openslot] = id;
return openslot; // return openslot;
} // }
// this should not happen unless there are too many players - we didn't find the ally or a slot // this should not happen unless there are too many players - we didn't find the ally or a slot
return -1; return -1;

@ -588,7 +588,7 @@ namespace Unity.BossRoom.Gameplay.UserInput
} }
if (Input.GetKeyDown(KeyCode.F)) // Vector Wall if (Input.GetKeyDown(KeyCode.F)) // Vector Wall
{ {
ActivateAbilityIfAllowed(GameDataSource.Instance.VectorWallAbilityKey); ActivateAbilityIfAllowed(GameDataSource.Instance.VectorFenceAbilityKey);
} }
if (Input.GetKeyDown(KeyCode.C)) // The Executioner if (Input.GetKeyDown(KeyCode.C)) // The Executioner
{ {
@ -881,9 +881,9 @@ namespace Unity.BossRoom.Gameplay.UserInput
} }
ActivateAbilityIfAllowed(GameDataSource.Instance.FreezeThrowAbilityKey); ActivateAbilityIfAllowed(GameDataSource.Instance.FreezeThrowAbilityKey);
} }
if (CnInputManager.GetButtonDown("VectorWall")) if (CnInputManager.GetButtonDown(GameDataSource.Instance.VectorFenceAbilityKey))
{ {
ActivateAbilityIfAllowed(GameDataSource.Instance.VectorWallAbilityKey); ActivateAbilityIfAllowed(GameDataSource.Instance.VectorFenceAbilityKey);
} }
if (CnInputManager.GetButtonDown(GameDataSource.Instance.TheExecutionerKey)) if (CnInputManager.GetButtonDown(GameDataSource.Instance.TheExecutionerKey))
{ {

@ -166,7 +166,7 @@ InputManager:
axis: 0 axis: 0
joyNum: 0 joyNum: 0
- serializedVersion: 3 - serializedVersion: 3
m_Name: VectorWall m_Name: VectorFence
descriptiveName: descriptiveName:
descriptiveNegativeName: descriptiveNegativeName:
negativeButton: negativeButton:

Loading…
Cancel
Save