Skip to content

Commit

Permalink
Fixed exception trying to import downloaded ASA mod as archive
Browse files Browse the repository at this point in the history
  • Loading branch information
thommcgrath committed Jan 30, 2024
1 parent 4d5f52a commit ad03b72
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions Project/Modules/Game Support/Ark/BlueprintImporter.xojo_code
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,11 @@ Protected Class BlueprintImporter

#tag Method, Flags = &h0
Shared Function ImportAsBinary(Contents As String, Progress As ProgressWindow = Nil) As Ark.BlueprintImporter
Var ManifestString As String
Var Archive As Beacon.Archive
Try
Archive = Beacon.Archive.Open(Contents)
ManifestString = Archive.GetFile("Manifest.json")
Catch Err As RuntimeException
End Try
If Archive Is Nil Then
Expand All @@ -112,8 +114,6 @@ Protected Class BlueprintImporter

// Return the importer no matter what, because this is an archive file
Var Importer As New Ark.BlueprintImporter

Var ManifestString As String = Archive.GetFile("Manifest.json")
If ManifestString.IsEmpty Then
Return Importer
End If
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,11 @@ Protected Class BlueprintImporter

#tag Method, Flags = &h0
Shared Function ImportAsBinary(Contents As String, Progress As ProgressWindow = Nil) As ArkSA.BlueprintImporter
Var ManifestString As String
Var Archive As Beacon.Archive
Try
Archive = Beacon.Archive.Open(Contents)
ManifestString = Archive.GetFile("Manifest.json")
Catch Err As RuntimeException
End Try
If Archive Is Nil Then
Expand All @@ -105,8 +107,6 @@ Protected Class BlueprintImporter

// Return the importer no matter what, because this is an archive file
Var Importer As New ArkSA.BlueprintImporter

Var ManifestString As String = Archive.GetFile("Manifest.json")
If ManifestString.IsEmpty Then
Return Importer
End If
Expand Down

0 comments on commit ad03b72

Please sign in to comment.