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

More art #132

Merged
merged 129 commits into from
Sep 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
129 commits
Select commit Hold shift + click to select a range
2549e0e
Lancer now rotates the clockwise
Greenfoot5 May 7, 2023
d4791a3
Dynamic turrets actually rotate the correct part
Greenfoot5 May 7, 2023
c85d3ea
Lancer now rotates the correct part on button press
Greenfoot5 May 7, 2023
c19768e
Updated Unity version
Greenfoot5 May 7, 2023
c45421f
Added new art for Lancer, Smasher, Gunner & Shooter
Greenfoot5 May 7, 2023
6eeaa6f
Added new Laser art
Greenfoot5 May 7, 2023
7b243f6
Updated bullets and impact effects for Lancer, Gunner & Shooter
Greenfoot5 May 7, 2023
1f932d4
Fixed issues with lancer's rotation
Greenfoot5 May 7, 2023
e90815c
Heavily nerfed giantslayer
Greenfoot5 May 7, 2023
a58ac2d
Buffed gunner's rotation speed from 7.5 to 8.5
Greenfoot5 May 7, 2023
61d42b4
Increased laser's rotation speed from 7 to 8 and reduced range from 4…
Greenfoot5 May 7, 2023
f6b0c3e
Added shop icons for Laser and Lancer
Greenfoot5 May 7, 2023
c6bea10
Fixed Stun not stunning Smasher
Greenfoot5 May 7, 2023
fb4a1e8
Gunner & Shooter bullets no longer complain they have no target
Greenfoot5 May 7, 2023
eda189e
Fixed Unique modules not being unique
Greenfoot5 May 7, 2023
62b82a1
Leaderboards now correctly display in Level Select
Greenfoot5 May 7, 2023
6e5e47f
Added a translation for Reload's tagline
Greenfoot5 May 7, 2023
31051ce
Fixed Tutorials' anchors
Greenfoot5 May 7, 2023
0a1d5b7
Setup the dev builds to build for macos on macos
Greenfoot5 May 7, 2023
17afe94
Too many uses of the license key?
Greenfoot5 May 7, 2023
bdf2d94
Slow module is now unique on Smasher
Greenfoot5 May 7, 2023
052fd3c
Slow module now has stats for smasher levels
Greenfoot5 May 7, 2023
d6e60e8
Attempts to fix issues with licenses
Greenfoot5 May 7, 2023
a56fd98
Updated game version
Greenfoot5 May 7, 2023
46c1ef9
Begin attempts at Android build
Greenfoot5 May 7, 2023
833d4e0
Tutorial controls are now anchored properly
Greenfoot5 May 7, 2023
0434287
Remove semantic versioning mention & error for return license.
Greenfoot5 May 7, 2023
6cc04bc
Attempt to fix Android by providing Github Token
Greenfoot5 May 7, 2023
c2bb3ff
Made more art updates for every turret
Greenfoot5 May 7, 2023
7845656
Updated the smasher smash effect
Greenfoot5 May 7, 2023
b441c8c
Missiles now deals less damage but increases fire rate
Greenfoot5 May 7, 2023
b4ba236
Updated version to nightly-12b
Greenfoot5 May 7, 2023
0cc61fb
Updated art for Enemy, Enemy 1, Tracer & Tracer 1. Higher tier enemie…
Greenfoot5 May 8, 2023
7df5d85
Slow is now unique on all modules
Greenfoot5 May 9, 2023
07afd7c
Changes some sizes for basic Enemy
Greenfoot5 May 9, 2023
d3aadef
Privacy Policy button now says Privacy Policy
Greenfoot5 May 9, 2023
1de51bd
Added art for tough enemies
Greenfoot5 May 9, 2023
6acff34
Some enemies no longer rotate
Greenfoot5 May 9, 2023
de1bdfb
Giantslayer is now unique
Greenfoot5 May 9, 2023
50395f6
Updated some translation stuff
Greenfoot5 May 9, 2023
ee89a15
Updated the unity version
Greenfoot5 May 9, 2023
776d7ce
Shooter deals more damage and has a higher fire rate
Greenfoot5 May 9, 2023
401e81d
Gave Squared some art
Greenfoot5 May 9, 2023
c34e927
Attempt to make builds work for Android
Greenfoot5 May 10, 2023
8cb2514
Attempt to use Ubuntu for OSX builds
Greenfoot5 May 10, 2023
4d5d90b
Removed the cap on how many builds could run parallel
Greenfoot5 May 10, 2023
989de48
Fixed error in build.yml
Greenfoot5 May 10, 2023
42e2fe1
Fixed build.yml issues
Greenfoot5 May 10, 2023
cf6f255
Updated version
Greenfoot5 May 10, 2023
de4af62
Exclude DoNotShip info
Greenfoot5 May 11, 2023
7241060
Removed id from job
Greenfoot5 May 11, 2023
9928032
Fixed build issues
Greenfoot5 May 11, 2023
9e0dad6
Updated some actions to v3
Greenfoot5 May 11, 2023
7d46e5b
Edited to attempt to exclude DoNotShip
Greenfoot5 May 11, 2023
13f1ee2
Added art for the splitter and summoner
Greenfoot5 May 11, 2023
b13da59
Updated some abilities
Greenfoot5 May 11, 2023
9cfa6bd
Bosses are now drawn on top of other enemies
Greenfoot5 May 11, 2023
394775f
Lancer Wall now has execute 2 rather than burn 1
Greenfoot5 May 11, 2023
cf15e59
Gunner mega gets Tracker & Velocity 2 (was 1) and fire rate 3
Greenfoot5 May 11, 2023
f4b15d3
Gunner gains increased damage, increased max fire rate, but lower spi…
Greenfoot5 May 11, 2023
b608f26
Summoner's ability icon for summoning is now the summoned
Greenfoot5 May 11, 2023
a69ca7e
Attempts Windows message in failure message too
Greenfoot5 May 11, 2023
abcee68
Now builds using macOS exclusively
Greenfoot5 May 13, 2023
5481ac4
Setup basic UI (not hooked into anything)
Greenfoot5 May 16, 2023
7933ad8
Started hooking up the UI
Greenfoot5 May 16, 2023
1a49d76
Hooked up the new UI in Prototype
Greenfoot5 May 17, 2023
9c4662a
Cleaned up all the levels and made it clearer when the shop is afford…
Greenfoot5 May 17, 2023
e546c7d
Removed a TODO
Greenfoot5 May 17, 2023
cbae4d1
Sell Percentage is now in the LevelData
Greenfoot5 May 17, 2023
aceee6b
Added a Giantslayer T3 option on Prototype and significantly reduced …
Greenfoot5 May 17, 2023
9704bf0
Fixed more saving and loading bugs
Greenfoot5 May 17, 2023
f68e481
Fixed autoselect
Greenfoot5 May 17, 2023
d58684e
Reimported TMP Essentials
Greenfoot5 May 17, 2023
8abebe3
Updated version
Greenfoot5 May 17, 2023
046496e
Builds are now ubuntu
Greenfoot5 May 17, 2023
9afa7d3
Revert "Reimported TMP Essentials"
Greenfoot5 May 17, 2023
6361b45
Increased version
Greenfoot5 May 17, 2023
e58caef
Update LICENSE
Greenfoot5 Aug 11, 2023
bbc45bc
Merge pull request #131 from Greenfoot5/License-Update
Greenfoot5 Aug 12, 2023
831aff2
Did a bunch of stuff, need a cleaner tree
Greenfoot5 Aug 21, 2023
7fe81b1
Cleaned up Deselect functions in BuildManager
Greenfoot5 Aug 21, 2023
77c63db
Cleaned up access for variables
Greenfoot5 Aug 21, 2023
b56791f
Strings are now localized
Greenfoot5 Aug 21, 2023
8e8360a
Removed an item no longer needed
Greenfoot5 Aug 21, 2023
3bfaf35
Some stuff change with Transition.prefab
Greenfoot5 Aug 21, 2023
bcb72fc
Cleaned up translations for the generic levels
Greenfoot5 Aug 21, 2023
591d2b1
Added options for the TypeCard on Turret & Module cards
Greenfoot5 Aug 21, 2023
790876a
Merge remote-tracking branch 'origin/more-art' into more-art
Greenfoot5 Aug 21, 2023
ed84e52
Updated the version to 2.0
Greenfoot5 Aug 21, 2023
124127c
Added localisation for the enemies & wave counter
Greenfoot5 Aug 21, 2023
a68259a
Added localization for shop selection & pause/game over menus
Greenfoot5 Aug 21, 2023
b47e728
Cleared non-custom values in Pirate to allow for fallbacks
Greenfoot5 Aug 21, 2023
34152fe
Added more localizations
Greenfoot5 Aug 21, 2023
0f65aff
Big enemy death effect now contains energy bits
Greenfoot5 Aug 22, 2023
aa33db8
Sell effect now uses bits & bytes
Greenfoot5 Aug 22, 2023
bac7cbf
When a turret is selected from the shop it opens the turrets inventory
Greenfoot5 Aug 22, 2023
403c26f
Cleaned up some functions no longer in use
Greenfoot5 Aug 22, 2023
a5172eb
Fixed an error in shop from localization
Greenfoot5 Aug 22, 2023
889d92e
Turret Info title now changes based on the tab
Greenfoot5 Aug 22, 2023
5ac3ad0
Added none text for turret inventory card
Greenfoot5 Aug 22, 2023
5dd318d
Cleaned up some temporary translations
Greenfoot5 Aug 22, 2023
55e733e
Clean up of TypeSpriteLookup, and fixing of spacing in the property d…
Greenfoot5 Sep 21, 2023
a646605
Turret Glyphs on ModuleShopCard are now expanded and have scale 1
Greenfoot5 Sep 21, 2023
032df17
Code cleanup
Greenfoot5 Sep 21, 2023
f4f691c
Fixed some translations on GameOver
Greenfoot5 Sep 21, 2023
2b6dde3
Fixed pressed & selected colour for inventory items
Greenfoot5 Sep 21, 2023
f9ed52d
Inventory Turret cards now show which turrets they can be applied to
Greenfoot5 Sep 21, 2023
3e272bb
Code cleanup
Greenfoot5 Sep 21, 2023
fb255e7
Cleanup
Greenfoot5 Sep 24, 2023
3569c1c
Tweaked a module description
Greenfoot5 Sep 24, 2023
489ec7a
Shop now contains the type sprite lookup
Greenfoot5 Sep 24, 2023
f4177db
Updated the turret & module inventory buttons, and allows them to be …
Greenfoot5 Sep 24, 2023
a5cfc30
Cleanup
Greenfoot5 Sep 24, 2023
5a8c198
On TurretInfo now shows info button
Greenfoot5 Sep 24, 2023
44de6e5
Removed the apply button from the modules inventory
Greenfoot5 Sep 24, 2023
2dfcda5
Removed redundant NodeUI
Greenfoot5 Sep 24, 2023
c35b557
Buttons are now removed when a module is applied to a turret
Greenfoot5 Sep 24, 2023
4fac35d
Button in modules pages to add another module
Greenfoot5 Sep 25, 2023
dd6d3f9
Module buttons are now disabled when they cannot be applied
Greenfoot5 Sep 25, 2023
636b646
Updated Unity version
Greenfoot5 Sep 25, 2023
6cc818f
Updated License Details
Greenfoot5 Sep 25, 2023
54fd986
Changed how map turrets are added to nodes
Greenfoot5 Sep 25, 2023
379f427
Bug Fixes
Greenfoot5 Sep 25, 2023
c807006
Disabled Loop Level
Greenfoot5 Sep 25, 2023
965a557
Upgrade now correctly counts down between waves
Greenfoot5 Sep 26, 2023
138d8e3
Moves pause button, fixed spawning and did some cleanup
Greenfoot5 Sep 27, 2023
4551658
Slightly tweaked selection in the level select
Greenfoot5 Sep 27, 2023
ec57f8f
Updated game-ci version
Greenfoot5 Sep 27, 2023
7ce93a7
Update game-ci version... again
Greenfoot5 Sep 27, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
99 changes: 54 additions & 45 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,41 +10,48 @@ on:
jobs:
buildForAllSupportedPlatforms:
name: Build for ${{ matrix.targetPlatform }}
runs-on: ubuntu-latest
runs-on: ${{ matrix.jobOS }}
strategy:
fail-fast: false
max-parallel: 3
max-parallel: 1
matrix:
targetPlatform:
#- StandaloneOSX # Build a macOS standalone (Intel 64-bit).
- StandaloneWindows # Build a Windows standalone.
- StandaloneWindows64 # Build a Windows 64-bit standalone.
- StandaloneLinux64 # Build a Linux 64-bit standalone.
#- iOS # Build an iOS player.
#- Android # Build an Android .apk standalone app.
#- WebGL # WebGL.
include:
- targetPlatform: StandaloneOSX # Build a macOS standalone (Intel 64-bit).
jobOS: macos-latest
- targetPlatform: StandaloneWindows # Build a Windows standalone.
jobOS: ubuntu-latest
- targetPlatform: StandaloneWindows64 # Build a Windows 64-bit standalone.
jobOS: ubuntu-latest
- targetPlatform: StandaloneLinux64 # Build a Linux 64-bit standalone.
jobOS: ubuntu-latest
# - targetPlatform: iOS # Build an iOS player.
# jobOS: ubuntu-latest
# - targetPlatform: Android # Build an Android .apk standalone app.
# jobOS: ubuntu-latest
# - targetPlatform: WebGL # WebGL.
# jobOS: ubuntu-latest

outputs:
#StandaloneOSX: ${{ steps.outputResult.outputs.StandaloneOSX }}
StandaloneOSX: ${{ steps.outputResult.outputs.StandaloneOSX }}
StandaloneWindows: ${{ steps.outputResult.outputs.StandaloneWindows }}
StandaloneWindows64: ${{ steps.outputResult.outputs.StandaloneWindows64 }}
StandaloneLinux64: ${{ steps.outputResult.outputs.StandaloneLinux64 }}
#iOS: ${{ steps.outputResult.outputs.iOS }}
#Android: ${{ steps.outputResult.outputs.Android }}
Android: ${{ steps.outputResult.outputs.Android }}
#WebGL: ${{ steps.outputResult.outputs.WebGL }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0
lfs: true

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: Library
key: Library-${{ matrix.targetPlatform }}
restore-keys: Library-

- uses: game-ci/unity-builder@v2
- uses: game-ci/unity-builder@v3
env:
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
Expand All @@ -57,40 +64,42 @@ jobs:
with:
projectPath: 'Tower Defence'
targetPlatform: ${{ matrix.targetPlatform }}
if: ${{ matrix.targetPlatform != 'Android' }}

- uses: game-ci/unity-builder@v3
env:
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}

# Use for paid version:
UNITY_SERIAL: ${{ secrets.UNITY_SERIAL }}

- uses: actions/upload-artifact@v2
# Use for free version:
#UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
with:
projectPath: 'Tower Defence'
targetPlatform: ${{ matrix.targetPlatform }}
androidKeystoreName: user # This file won't exist, but this property needs to exist.
androidKeystoreBase64: ${{ secrets.ANDROID_KEYSTORE_BASE64 }}
androidKeystorePass: ${{ secrets.ANDROID_KEYSTORE_PASS }}
androidKeyaliasName: ${{ secrets.ANDROID_KEYALIAS_NAME }}
androidKeyaliasPass: ${{ secrets.ANDROID_KEYALIAS_PASS }}
androidTargetSdkVersion: AndroidApiLevel31
if: ${{ matrix.targetPlatform == 'Android' }}

- uses: actions/upload-artifact@v3
with:
name: ${{ matrix.targetPlatform }}
path: 'build'
path: |
build/
!*DoNotShip/

# ERROR - Causes errors for some reason.
# Return License
# - uses: game-ci/unity-return-license@v1
# - uses: game-ci/unity-return-license@v2.0.0
# if: always()

# NOT NEEDED - We don't currently make use of this, instead opting for manual builds for new versions
# - uses: paulhatch/semantic-version@v4.0.2
# with:
# tag_prefix: "v"
# # A string which, if present in a git commit, indicates that a change represents a
# # major (breaking) change, supports regular expressions wrapped with '/'
# major_pattern: "(MAJOR)"
# # Same as above except indicating a minor change, supports regular expressions wrapped with '/'
# minor_pattern: "(MINOR)"
# # A string to determine the format of the version output
# format: "${major}.${minor}.${patch}"
# # Optional path to check for changes. If any changes are detected in the path the
# # 'changed' output will true. Enter multiple paths separated by spaces.
# change_path: "Tower Defence"
# # Named version, will be used as suffix for name version tag
# namespace: Bestagone-Defence
# # Indicate whether short tags like 'v1' should be supported. If false only full
# # tags like 'v1.0.0' will be recognized.
# short_tags: false
# # If this is set to true, *every* commit will be treated as a new version.
# bump_each_commit: false
- id: outputResult
run: echo "${{ matrix.targetPlatform }}=${{ job.status }}" >> $GITHUB_OUTPUT
run: echo "${{ matrix.targetPlatform }}Result=${{ job.status }}" >> $GITHUB_ENV

sendSuccessNotification:
runs-on: ubuntu-latest
Expand All @@ -104,20 +113,20 @@ jobs:
content: "Build Success"
embed-title: "New Nightly Build Available!"
embed-description: "[You can get the new builds here](https://github.com/Greenfoot5/Bestagon-Defence/actions/runs/${{ github.run_id }})
\n\n*You may need to scroll down to the bottom*"
\n${{ env.StandaloneWindowsResult }}\n*You may need to scroll down to the bottom*"
embed-color: 1546855

sendFailureNotification:
runs-on: ubuntu-latest
needs:
- buildForAllSupportedPlatforms
- buildForAllSupportedPlatforms
if: ${{ failure() }}
steps:
- uses: tsickert/discord-webhook@v5.3.0
with:
webhook-url: ${{ secrets.NIGHTLY_WEBHOOK_URL }}
content: "Build Failure"
embed-title: "New Nightly Build Failed!"
embed-description: "[You can find the results here](https://github.com/Greenfoot5/Bestagon-Defence/actions/runs/${{ github.run_id }})"
embed-description: "[You can find the results here](https://github.com/Greenfoot5/Bestagon-Defence/actions/runs/${{ github.run_id }})\n${{ env.StandaloneWindowsResult }}"
embed-color: 10949957

22 changes: 20 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,2 +1,20 @@
This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit
http://creativecommons.org/licenses/by/4.0/.
# Source Code

Copyright 2023 Harvey Ford

Licensed under the Apache License, Version 2.0 (the "License");
you may not use any source code from this project except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

# Everything Else

All other assets are licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit
http://creativecommons.org/licenses/by/4.0/
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
![License: Attribution 4.0 International](https://img.shields.io/badge/license-Attribution%204.0%20International-lightgrey)
![Asset License: Attribution 4.0 International](https://img.shields.io/badge/Asset%20License-CC%20BY%204.0-lightgrey)
![Code License: Apache 2.0](https://img.shields.io/badge/Code%20License-Apache%202.0-lightgrey)
![Support Platforms: Android | MacOS/OS X | Windows](https://img.shields.io/badge/platform-Android_|_MacOS/OSX_|_Windows-lightgrey)
![Unity Version: 2022.2.16f1](https://img.shields.io/static/v1?logo=unity&label=Unity%20Version&message=2022.2.16f1&color=blue)
![Unity Version: 2022.3.10f1](https://img.shields.io/static/v1?logo=unity&label=Unity%20Version&message=2022.3.10f1&color=blue)

![Bestagon Defence](Tower%20Defence/Assets/UI/Branding/Bestagon_Wordmark.png)

Expand All @@ -17,7 +18,7 @@ If it doesn't work, join the support server and ask or open an issue!

## Links

[![Website link](https://img.shields.io/badge/Website-Bestagon.Alchemix.dev-blueviolet)](https://bestagon.alchemix.dev/)
[![Website link](https://img.shields.io/badge/Website-bestagon.alchemix.dev-blueviolet)](https://bestagon.alchemix.dev/)
[![Support on Ko-Fi](https://img.shields.io/static/v1?logo=ko-fi&label=Ko-Fi&message=Support&color=13C3FF&logoColor=13C3FF)](https://ko-fi.com/bestagondefence)
[![Notion.so link for documentation](https://img.shields.io/static/v1?logo=notion&label=Notion.so&message=Documentation&color=blue)](https://chambray-comb-aa7.notion.site/Bestagon-Defence-3af38b2be320481580979110f3c373ef)
[![itch.io link for downloading](https://img.shields.io/static/v1?logo=itchdotio&label=itch.io&message=Download&color=success)](https://greenfoot5.itch.io/bestagon-defence)
Expand Down
12 changes: 11 additions & 1 deletion Tower Defence/Assets/Abstract/Data/ModuleChainHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,21 @@ public bool Upgrade(ModuleChainHandler sibling)
// If the upgrade is of a different type,
if (sibling.GetModule().GetType() != GetModule().GetType()) return false;
// If the upgrade is of a different tier,
if (sibling.tier != tier || !chain.CanUpgrade(tier)) return false;
if (!CanUpgrade(sibling.GetTier())) return false;

tier += 1;
return true;
}

/// <summary>
/// Checks if the module can be upgraded from it's current tier
/// </summary>
/// <param name="otherTier">The tier of the other module this module is trying to upgrade with</param>
/// <returns></returns>
public bool CanUpgrade(int otherTier)
{
return otherTier == tier && chain.CanUpgrade(otherTier);
}

/// <summary>
/// Gets the module in the chain of the current tier
Expand Down
5 changes: 4 additions & 1 deletion Tower Defence/Assets/Abstract/Saving/SaveLevel.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
using System;
using System.Collections.Generic;
using Abstract.Data;
using Turrets;
using UnityEngine;
using Random = UnityEngine.Random;

namespace Abstract.Saving
{
Expand All @@ -10,7 +12,7 @@ namespace Abstract.Saving
/// </summary>
public class SaveLevel
{
[System.Serializable]
[Serializable]
public struct NodeData
{
public string uuid;
Expand All @@ -22,6 +24,7 @@ public struct NodeData


public int money;
public int powercells;
public int lives;
public int waveIndex;
public Random.State random;
Expand Down
19 changes: 7 additions & 12 deletions Tower Defence/Assets/Abstract/Saving/SaveManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public static void SaveLevel(ISaveableLevel saveable, string sceneName)
// Tell our leaderboard API to add the player
string leaderboardData =
Environment.GetEnvironmentVariable(SceneManager.GetActiveScene().name + "Leaderboard");
if (leaderboardData != null)
if (leaderboardData != null && _bridge != null)
{
string[] splitData = leaderboardData.Split(';');
_bridge.SendPlayerValue(PlayerPrefs.GetString("Username"), GameStats.Rounds, splitData[0],
Expand Down Expand Up @@ -120,18 +120,13 @@ public static void LoadLevel(ISaveableLevel saveable, string sceneName)

public static bool SaveExists(string sceneName)
{
if (FileManager.FileExists(sceneName + "Save.dat"))
{
FileManager.LoadFromFile(sceneName + "Save.dat", out string json);
var sd = new SaveLevel();
sd.LoadFromJson(json);
if (!FileManager.FileExists(sceneName + "Save.dat")) return false;

FileManager.LoadFromFile(sceneName + "Save.dat", out string json);
var sd = new SaveLevel();
sd.LoadFromJson(json);

if (sd.version == Application.version)
{
return true;
}
}
return false;
return sd.version == Application.version;
}

public static void ClearSave(string sceneName)
Expand Down
2 changes: 1 addition & 1 deletion Tower Defence/Assets/Abstract/TypeSpriteLookup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ namespace Abstract
[Serializable]
public class TypeSpriteLookup
{
private static readonly List<Type> Types = new List<Type>
private static readonly List<Type> Types = new()
{
null, // Represents no specific turret type
typeof(Shooter),
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,6 @@ MonoBehaviour:
m_SerializedData: []
m_GUID: 2f149c34a50f148c5b968ec55cd20563
m_SerializeEntries:
- m_GUID: 8e2f78ef9583e4be18ba8f1d9427e930
m_Address: Assets/UI/Localization/Tables/Strings/MainMenu Shared Data.asset
m_ReadOnly: 1
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: a4bbea44c52ee4ec1ada344d809c9849
m_Address: Assets/UI/Localization/Tables/Assets/Modules Shared Data.asset
m_ReadOnly: 1
Expand All @@ -32,23 +27,13 @@ MonoBehaviour:
m_ReadOnly: 1
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: d8dba3f1b6d9b49129d3bfaa66176bdb
m_Address: Assets/Levels/Generic/Tutorial/Tutorial Shared Data.asset
m_ReadOnly: 1
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 01db83deda24d4c42a2c290e89405b6a
m_Address: Assets/Levels/Generic/LevelSelect/LevelSelect Shared Data.asset
m_ReadOnly: 1
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 7c2fd8aac1d4a4e3e9098ede69f277bd
m_Address: Assets/Turrets/Turrets Shared Data.asset
m_ReadOnly: 1
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: de5ebaefc712f433e8c91b70ace4b38e
m_Address: Assets/Levels/Generic/Settings/Settings Shared Data.asset
- m_GUID: a6170bad920ce47ac8d85f7255dd7a10
m_Address: Assets/UI/Localization/GUI Shared Data.asset
m_ReadOnly: 1
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,6 @@ MonoBehaviour:
m_SerializedData: []
m_GUID: 3715befcbc1184c71a07a7657095ef2f
m_SerializeEntries:
- m_GUID: a2509145f19cd49e8893d905bdbd3618
m_Address: MainMenu_en-GB
m_ReadOnly: 1
m_SerializedLabels:
- Locale-en-GB
- Preload
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 6dfeb8d5a453b4cd9bd33b00ec262319
m_Address: Modules_en-GB
m_ReadOnly: 1
Expand All @@ -38,32 +31,17 @@ MonoBehaviour:
- Locale-en-GB
- Preload
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: d8c982dee487644f9ab5c3e516287f72
m_Address: Tutorial_en-GB
m_ReadOnly: 1
m_SerializedLabels:
- Locale-en-GB
- Preload
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 69ac90c680dde4db686a529636110b77
m_Address: LevelSelect_en-GB
m_ReadOnly: 1
m_SerializedLabels:
- Locale-en-GB
- Preload
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: e5de750e69e374891b56c01bb6bd3ce4
m_Address: Turrets_en-GB
m_ReadOnly: 1
m_SerializedLabels:
- Locale-en-GB
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 0dfd305ecbb3344ad9bfd240ced7d43b
m_Address: Settings_en-GB
- m_GUID: 906121f49d77b4dc78bd63a4c9e104d7
m_Address: GUI_en-GB
m_ReadOnly: 1
m_SerializedLabels:
- Locale-en-GB
- Preload
FlaggedDuringContentUpdateRestriction: 0
m_ReadOnly: 1
m_Settings: {fileID: 11400000, guid: 6e9e55f6df8a74e608f92b8e3a1f0b77, type: 2}
Expand Down
Loading
Loading