Fixed a few bugs

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

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

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

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

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

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

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

@ -588,7 +588,7 @@ namespace Unity.BossRoom.Gameplay.UserInput
}
if (Input.GetKeyDown(KeyCode.F)) // Vector Wall
{
ActivateAbilityIfAllowed(GameDataSource.Instance.VectorWallAbilityKey);
ActivateAbilityIfAllowed(GameDataSource.Instance.VectorFenceAbilityKey);
}
if (Input.GetKeyDown(KeyCode.C)) // The Executioner
{
@ -881,9 +881,9 @@ namespace Unity.BossRoom.Gameplay.UserInput
}
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))
{

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

Loading…
Cancel
Save