mirror of
https://github.com/muskit/MercuryConverter.git
synced 2026-06-02 12:14:26 -07:00
update core dependencies
This commit is contained in:
+1
-1
Submodule _External/SaturnData updated: 9c25652c01...6eb7ce9c04
+1
-1
Submodule _External/UAssetAPI updated: ec758cff14...8aa90add4d
+1
-1
@@ -1 +1 @@
|
|||||||
1.1
|
1.11
|
||||||
+10
-6
@@ -1,3 +1,4 @@
|
|||||||
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using MercuryConverter.Utility;
|
using MercuryConverter.Utility;
|
||||||
@@ -65,25 +66,29 @@ public class Song
|
|||||||
var chartFilePath = Path.Combine(Settings.I!.DataPath, "MusicData", Id, $"{Id}_{Consts.DIFF_FILENAME_APPEND[diff]}.mer");
|
var chartFilePath = Path.Combine(Settings.I!.DataPath, "MusicData", Id, $"{Id}_{Consts.DIFF_FILENAME_APPEND[diff]}.mer");
|
||||||
var clearThreshold = ((FloatPropertyData)assetData[Consts.DIFF_CLEAR_KEY[diff]]).Value;
|
var clearThreshold = ((FloatPropertyData)assetData[Consts.DIFF_CLEAR_KEY[diff]]).Value;
|
||||||
|
|
||||||
|
var c = NotationSerializer.ToChart(chartFilePath, new NotationReadArgs { }, out var chExcs);
|
||||||
|
// TODO: check exceptions
|
||||||
|
|
||||||
var e = NotationSerializer.ToEntry(chartFilePath, new NotationReadArgs
|
var e = NotationSerializer.ToEntry(chartFilePath, new NotationReadArgs
|
||||||
{
|
{
|
||||||
InferClearThresholdFromDifficulty = false,
|
InferClearThresholdFromDifficulty = false,
|
||||||
});
|
}, out var exportExcs);
|
||||||
|
// TODO: check exceptions
|
||||||
|
|
||||||
|
c.Build(e); // set timings as appropriate
|
||||||
e.Title = Name;
|
e.Title = Name;
|
||||||
e.Reading = Rubi;
|
e.Reading = Rubi;
|
||||||
e.Artist = Artist;
|
e.Artist = Artist;
|
||||||
e.BpmMessage = BpmMessage;
|
e.BpmMessage = BpmMessage;
|
||||||
e.PreviewBegin = PreviewTime * 1000f;
|
|
||||||
e.PreviewLength = PreviewLen * 1000f;
|
|
||||||
e.ClearThreshold = clearThreshold;
|
e.ClearThreshold = clearThreshold;
|
||||||
e.Difficulty = diff;
|
e.Difficulty = diff;
|
||||||
e.Level = l.Value.Item1;
|
e.Level = l.Value.Item1;
|
||||||
e.NotesDesigner = l.Value.Item2;
|
e.NotesDesigner = l.Value.Item2;
|
||||||
e.JacketPath = "jacket.png";
|
e.JacketFile = "jacket.png";
|
||||||
|
|
||||||
// TODO: video
|
// TODO: video
|
||||||
|
|
||||||
e.Guid = $"MERCURY_{Uid}_0{(int)diff}";
|
e.Id = $"MERCURY_{Uid}_0{(int)diff}";
|
||||||
|
|
||||||
if (new List<uint> { 1, 2 }.Contains(Source))
|
if (new List<uint> { 1, 2 }.Contains(Source))
|
||||||
{
|
{
|
||||||
@@ -98,7 +103,6 @@ public class Song
|
|||||||
e.Background = BackgroundOption.Version3;
|
e.Background = BackgroundOption.Version3;
|
||||||
}
|
}
|
||||||
|
|
||||||
var c = NotationSerializer.ToChart(chartFilePath, new NotationReadArgs { });
|
|
||||||
ret.Add((e, c));
|
ret.Add((e, c));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ public class Exporter
|
|||||||
}
|
}
|
||||||
finishedAudio.Add(audioKey);
|
finishedAudio.Add(audioKey);
|
||||||
}
|
}
|
||||||
ec.Item1.AudioPath = audioExportFileName;
|
ec.Item1.AudioFile = audioExportFileName;
|
||||||
|
|
||||||
/// VIDEO ///
|
/// VIDEO ///
|
||||||
// mv_... = set video
|
// mv_... = set video
|
||||||
@@ -97,7 +97,7 @@ public class Exporter
|
|||||||
|
|
||||||
finishedMovies.Add(movie);
|
finishedMovies.Add(movie);
|
||||||
}
|
}
|
||||||
ec.Item1.VideoPath = vidFileName;
|
ec.Item1.VideoFile = vidFileName;
|
||||||
}
|
}
|
||||||
prevMovie = movie;
|
prevMovie = movie;
|
||||||
}
|
}
|
||||||
@@ -115,7 +115,7 @@ public class Exporter
|
|||||||
new NotationWriteArgs { FormatVersion = options.ChartFormat }
|
new NotationWriteArgs { FormatVersion = options.ChartFormat }
|
||||||
);
|
);
|
||||||
// restore audio key in db AFTER exporting metadata
|
// restore audio key in db AFTER exporting metadata
|
||||||
ec.Item1.AudioPath = audioKey;
|
ec.Item1.AudioFile = audioKey;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// JACKET ///
|
/// JACKET ///
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
<DataGridTextColumn Header="ID" Width="90" Binding="{Binding Id}"/>
|
<DataGridTextColumn Header="ID" Width="90" Binding="{Binding Id}"/>
|
||||||
<DataGridTextColumn Header="Title" Width="*" Binding="{Binding Name}"/>
|
<DataGridTextColumn Header="Title" Width="*" Binding="{Binding Name}"/>
|
||||||
<DataGridTextColumn Header="Artist" Width="*" Binding="{Binding Artist}"/>
|
<DataGridTextColumn Header="Artist" Width="*" Binding="{Binding Artist}"/>
|
||||||
<DataGridTextColumn Header="Version Released" Width="150" Binding="{Binding SourceName}" SortMemberPath="Source"/>
|
<DataGridTextColumn Header="Version Released" Width="160" Binding="{Binding SourceName}" SortMemberPath="Source"/>
|
||||||
</DataGrid.Columns>
|
</DataGrid.Columns>
|
||||||
<DataGrid.Styles>
|
<DataGrid.Styles>
|
||||||
<Style Selector="DataGridCell">
|
<Style Selector="DataGridCell">
|
||||||
|
|||||||
@@ -74,6 +74,14 @@ public partial class Selection : Panel
|
|||||||
(Song)e.AddedItems[e.AddedItems.Count - 1]! :
|
(Song)e.AddedItems[e.AddedItems.Count - 1]! :
|
||||||
(Song)ListingTable.SelectedItems[ListingTable.SelectedItems.Count - 1]!;
|
(Song)ListingTable.SelectedItems[ListingTable.SelectedItems.Count - 1]!;
|
||||||
|
|
||||||
|
// Debug: Saturn GUIDs
|
||||||
|
var ecs = song.GetEntryCharts();
|
||||||
|
foreach (var (entry, _) in ecs)
|
||||||
|
{
|
||||||
|
Console.WriteLine(entry.Id);
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: song preview playback
|
||||||
Dispatcher.UIThread.Post(() =>
|
Dispatcher.UIThread.Post(() =>
|
||||||
{
|
{
|
||||||
if (song.Jacket != null)
|
if (song.Jacket != null)
|
||||||
|
|||||||
Reference in New Issue
Block a user