From 86230a758f5484af8d0f0bdae56eb9912b2469df Mon Sep 17 00:00:00 2001 From: rudderbucky Date: Thu, 7 Jan 2021 18:35:25 -0800 Subject: [PATCH] Fix core upgrader bug, adjust ship builder --- .../Sectors/MainMenuInfectionSector.asset | 192 ++++++++---------- .../MainMenuInfectionSector.asset.meta | 2 +- Assets/Scenes/MainMenu.unity | 2 +- .../Scripts/HUD Scripts/CoreUpgraderScript.cs | 4 +- .../ShipBuilderCursorScript.cs | 2 + 5 files changed, 93 insertions(+), 109 deletions(-) diff --git a/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset b/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset index 960f2191c..544c8eb62 100644 --- a/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset +++ b/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset @@ -21,15 +21,15 @@ MonoBehaviour: type: 2 backgroundColor: {r: 0.4, g: 0, b: 0, a: 1} entities: - - name: Outpost + - name: Bunker ID: 0 faction: 0 - assetID: outpost_blueprint + assetID: bunker_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: -30, y: 0} + position: {x: 15, y: -2.5} patrolPath: waypoints: [] - name: Outpost @@ -40,132 +40,154 @@ MonoBehaviour: dialogueID: vendingID: pathID: - position: {x: -30, y: -10} + position: {x: 17.5, y: 7.5} patrolPath: waypoints: [] - name: Outpost ID: 2 - faction: 0 + faction: 1 assetID: outpost_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 30, y: -10} + position: {x: -17.5, y: 7.5} patrolPath: waypoints: [] - - name: Outpost + - name: Power Rock ID: 3 faction: 0 - assetID: outpost_blueprint + assetID: energy_rock blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 30, y: 0} + position: {x: 15, y: 5} patrolPath: waypoints: [] - - name: Air Carrier + - name: Power Rock ID: 4 faction: 0 - assetID: carrier_blueprint + assetID: energy_rock blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 40, y: -10} + position: {x: -15, y: 5} patrolPath: waypoints: [] - - name: Air Carrier + - name: Bunker ID: 5 - faction: 0 - assetID: carrier_blueprint + faction: 1 + assetID: bunker_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 40, y: 0} + position: {x: -15, y: -2.5} patrolPath: waypoints: [] - - name: Air Carrier + - name: Outpost ID: 6 - faction: 1 - assetID: carrier_blueprint + faction: 0 + assetID: outpost_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: -40, y: -10} + position: {x: -30, y: 0} patrolPath: waypoints: [] - - name: Air Carrier + - name: Outpost ID: 7 - faction: 1 - assetID: carrier_blueprint + faction: 0 + assetID: outpost_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: -40, y: 0} + position: {x: -30, y: -10} patrolPath: waypoints: [] - - name: Bunker + - name: Outpost ID: 8 faction: 0 - assetID: bunker_blueprint + assetID: outpost_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 5, y: -2.5} + position: {x: 30, y: -10} patrolPath: waypoints: [] - - name: Bunker + - name: Outpost ID: 9 - faction: 1 - assetID: bunker_blueprint + faction: 0 + assetID: outpost_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: -5, y: -2.5} + position: {x: 30, y: 0} patrolPath: waypoints: [] - - name: Map Background 3 + - name: Air Carrier ID: 10 faction: 0 - assetID: mapbg3 + assetID: carrier_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 0, y: 7.5} + position: {x: 40, y: -10} patrolPath: waypoints: [] - - name: Power Rock + - name: Air Carrier ID: 11 faction: 0 - assetID: energy_rock + assetID: carrier_blueprint blueprintJSON: dialogueID: vendingID: pathID: - position: {x: -12.5, y: 2.5} + position: {x: 40, y: 0} patrolPath: waypoints: [] - - name: Power Rock + - name: Air Carrier ID: 12 + faction: 1 + assetID: carrier_blueprint + blueprintJSON: + dialogueID: + vendingID: + pathID: + position: {x: -40, y: -10} + patrolPath: + waypoints: [] + - name: Air Carrier + ID: 13 + faction: 1 + assetID: carrier_blueprint + blueprintJSON: + dialogueID: + vendingID: + pathID: + position: {x: -40, y: 0} + patrolPath: + waypoints: [] + - name: Map Background 3 + ID: 14 faction: 0 - assetID: energy_rock + assetID: mapbg3 blueprintJSON: dialogueID: vendingID: pathID: - position: {x: 12.5, y: 2.5} + position: {x: 0, y: 7.5} patrolPath: waypoints: [] - name: ShellCore - ID: 13 + ID: 15 faction: 1 assetID: shellcore_blueprint blueprintJSON: @@ -176,7 +198,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: ShellCore - ID: 14 + ID: 16 faction: 0 assetID: shellcore_blueprint blueprintJSON: @@ -187,7 +209,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 15 + ID: 17 faction: 1 assetID: missile_station blueprintJSON: @@ -198,7 +220,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 16 + ID: 18 faction: 1 assetID: missile_station blueprintJSON: @@ -209,7 +231,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 17 + ID: 19 faction: 1 assetID: missile_station blueprintJSON: @@ -220,7 +242,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 18 + ID: 20 faction: 1 assetID: missile_station blueprintJSON: @@ -231,7 +253,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 19 + ID: 21 faction: 1 assetID: missile_station blueprintJSON: @@ -242,7 +264,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 20 + ID: 22 faction: 0 assetID: missile_station blueprintJSON: @@ -253,7 +275,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 21 + ID: 23 faction: 0 assetID: missile_station blueprintJSON: @@ -264,7 +286,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 22 + ID: 24 faction: 0 assetID: missile_station blueprintJSON: @@ -275,7 +297,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 23 + ID: 25 faction: 0 assetID: missile_station blueprintJSON: @@ -286,7 +308,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Missile Station - ID: 24 + ID: 26 faction: 0 assetID: missile_station blueprintJSON: @@ -297,7 +319,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Ground Base - ID: 25 + ID: 27 faction: 0 assetID: groundcarrier_blueprint blueprintJSON: @@ -308,7 +330,7 @@ MonoBehaviour: patrolPath: waypoints: [] - name: Ground Base - ID: 26 + ID: 28 faction: 1 assetID: groundcarrier_blueprint blueprintJSON: @@ -318,54 +340,14 @@ MonoBehaviour: position: {x: -35, y: -5} patrolPath: waypoints: [] - - name: Outpost - ID: 27 - faction: 0 - assetID: outpost_blueprint - blueprintJSON: - dialogueID: - vendingID: - pathID: - position: {x: 15, y: 5} - patrolPath: - waypoints: [] - - name: Outpost - ID: 28 - faction: 1 - assetID: outpost_blueprint - blueprintJSON: - dialogueID: - vendingID: - pathID: - position: {x: -15, y: 5} - patrolPath: - waypoints: [] platformData: - 010001040000 - 010101040000 - 010801040000 - 010901040000 - 010002040000 - - 040102080204020200010200030200040200020209000401020203020002020204020003020900040202020402000102020302020402080004030202020202040202010202 - - 040502080204060200050200070200080200060209000405020207020006020208020007020900040602020802000502020702020802080004070202060202080202050202 - - 010902040000 - - 010003040000 - - 010103040000 - - 010803040000 - - 010903040000 - - 010001040000 - - 010101040000 - - 010801040000 - - 010901040000 - - 010002040000 - - 010102080200 - - 010202090000 - - 010302090000 - - 010402080000 - - 010502080200 - - 010602090000 - - 010702090000 - - 010802080000 + - 040102080203020200030200040200020209000301020203020004020003020900030202020402000102020402080003030202020202010202 + - 040502080203060200070200080200060209000305020207020008020007020900030602020802000502020802080003070202060202050202 - 010902040000 - 010003040000 - 010103040000 @@ -373,16 +355,16 @@ MonoBehaviour: - 010903040000 platform: {fileID: 0} targets: - - 4 - - 5 - - 6 - - 7 - - 13 + - 10 + - 11 + - 12 - 13 - - 14 - - 14 - - 25 - - 26 + - 15 + - 15 + - 16 + - 16 + - 27 + - 28 hasMusic: 1 musicID: music_sloppy partDropsDisabled: 0 diff --git a/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset.meta b/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset.meta index c224b8e7b..1f9e91971 100644 --- a/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset.meta +++ b/Assets/Blueprints/Sectors/MainMenuInfectionSector.asset.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2fcbfa18bc8e31440b5611b10cd41bbe +guid: b405373bc16575a4fb0baaae4f74c2ca NativeFormatImporter: externalObjects: {} mainObjectFileID: 0 diff --git a/Assets/Scenes/MainMenu.unity b/Assets/Scenes/MainMenu.unity index 9f9c198a5..e5f460087 100644 --- a/Assets/Scenes/MainMenu.unity +++ b/Assets/Scenes/MainMenu.unity @@ -568,7 +568,7 @@ MonoBehaviour: jsonMode: 0 sectors: - {fileID: 11400000, guid: db5d53667eba5974c927ca88b2a5446e, type: 2} - - {fileID: 11400000, guid: 2fcbfa18bc8e31440b5611b10cd41bbe, type: 2} + - {fileID: 11400000, guid: b405373bc16575a4fb0baaae4f74c2ca, type: 2} player: {fileID: 0} current: {fileID: 0} background: {fileID: 241602156} diff --git a/Assets/Scripts/HUD Scripts/CoreUpgraderScript.cs b/Assets/Scripts/HUD Scripts/CoreUpgraderScript.cs index 7a217630e..bb145f7ef 100644 --- a/Assets/Scripts/HUD Scripts/CoreUpgraderScript.cs +++ b/Assets/Scripts/HUD Scripts/CoreUpgraderScript.cs @@ -29,7 +29,7 @@ public void initialize() { } public override void CloseUI() { - ShardCountScript.StickySlideOut(); + //ShardCountScript.StickySlideOut(); player.SetIsInteracting(false); gameObject.SetActive(false); AudioManager.PlayClipByID("clip_back"); @@ -87,7 +87,7 @@ private void incrementAbilityCap(int type) { if(player.abilityCaps[type] < maxAbilityCap[type]) { player.shards -= GetUpgradeCost(type); player.abilityCaps[type]++; - ShardCountScript.UpdateNumber(player.shards); + //ShardCountScript.UpdateNumber(player.shards); } } diff --git a/Assets/Scripts/HUD Scripts/Ship Builder Scripts/ShipBuilderCursorScript.cs b/Assets/Scripts/HUD Scripts/Ship Builder Scripts/ShipBuilderCursorScript.cs index 020f395b5..2e4d4370a 100644 --- a/Assets/Scripts/HUD Scripts/Ship Builder Scripts/ShipBuilderCursorScript.cs +++ b/Assets/Scripts/HUD Scripts/Ship Builder Scripts/ShipBuilderCursorScript.cs @@ -67,6 +67,7 @@ public void GrabPart(ShipBuilderPart part) { parts.Add(part); part.rectTransform.SetAsLastSibling(); } + // offset = Vector2.zero; offset = part.GetComponent().anchoredPosition - GetComponent().anchoredPosition; currentPart = part; } @@ -197,6 +198,7 @@ void Update() { var origPos = transform.position; transform.position = Input.mousePosition; if(bound.Contains(GetComponent().anchoredPosition)) { + transform.position = origPos; GrabPart(parts[i]); break; }