4
4
using DtxCS ;
5
5
using DtxCS . DataTypes ;
6
6
using System . Collections . Generic ;
7
+ using System . Globalization ;
7
8
using System . IO ;
8
9
using System . Linq ;
9
10
using System . Text . Json . Serialization ;
@@ -343,11 +344,11 @@ public MoggSong(DataArray dtx) : base()
343
344
344
345
return tracks ;
345
346
} ) ?? new List < Track > ( ) ;
346
- Pans = dtxDict . GetValueOrDefault ( "/pans" ) ? . GetChild < DataArray > ( 1 ) ? . Children ? . Select ( e => e . ToString ( ) . Transform ( o => double . Parse ( ( string ) o ) , 0 ) ) . ToList ( ) ?? new List < double > ( ) ;
347
- Volumes = dtxDict . GetValueOrDefault ( "/vols" ) ? . GetChild < DataArray > ( 1 ) ? . Children ? . Select ( e => e . ToString ( ) . Transform ( o => double . Parse ( ( string ) o ) , 0 ) ) . ToList ( ) ?? new List < double > ( ) ;
348
- Attenuation = dtxDict . GetValueOrDefault ( "/active_track_db" ) ? . Children . Skip ( 1 ) . Select ( e => e . ToString ( ) . Transform ( o => double . Parse ( ( string ) o ) , 0 ) ) ? . ToList ( ) ?? new List < double > ( ) ;
347
+ Pans = dtxDict . GetValueOrDefault ( "/pans" ) ? . GetChild < DataArray > ( 1 ) ? . Children ? . Select ( e => e . ToString ( ) . Transform ( o => double . Parse ( ( string ) o , provider : CultureInfo . InvariantCulture ) , 0 ) ) . ToList ( ) ?? new List < double > ( ) ;
348
+ Volumes = dtxDict . GetValueOrDefault ( "/vols" ) ? . GetChild < DataArray > ( 1 ) ? . Children ? . Select ( e => e . ToString ( ) . Transform ( o => double . Parse ( ( string ) o , provider : CultureInfo . InvariantCulture ) , 0 ) ) . ToList ( ) ?? new List < double > ( ) ;
349
+ Attenuation = dtxDict . GetValueOrDefault ( "/active_track_db" ) ? . Children . Skip ( 1 ) . Select ( e => e . ToString ( ) . Transform ( o => double . Parse ( ( string ) o , provider : CultureInfo . InvariantCulture ) , 0 ) ) ? . ToList ( ) ?? new List < double > ( ) ;
349
350
ArenaPath = dtxDict . GetValueOrDefault ( "/arena_path" ) ? . GetChild < string > ( 1 ) ;
350
- TunnelScale = dtxDict . GetValueOrDefault ( "/tunnel_scale" ) ? . GetChild < double > ( 1 , e => double . Parse ( e . ToString ( ) ) ) ;
351
+ TunnelScale = dtxDict . GetValueOrDefault ( "/tunnel_scale" ) ? . GetChild < double > ( 1 , e => double . Parse ( e . ToString ( ) , provider : CultureInfo . InvariantCulture ) ) ;
351
352
EnableOrder = dtxDict . GetValueOrDefault ( "/enable_order" ) ? . GetChild < DataArray > ( 1 ) ? . Children . Select ( e => e . ToString ( ) . Transform ( o => int . Parse ( ( string ) o ) , 0 ) ) . ToList ( ) ?? new List < int > ( ) ;
352
353
SectionStartBars = dtxDict . GetValueOrDefault ( "/section_start_bars" ) ? . Children . Skip ( 1 ) ? . Select ( e => e . ToString ( ) . Transform ( o => int . Parse ( ( string ) o ) , 0 ) ) ? . ToList ( ) ?? new List < int > ( ) ;
353
354
Title = dtxDict . GetValueOrDefault ( "/title" ) ? . GetChild < string > ( 1 ) ;
@@ -356,7 +357,7 @@ public MoggSong(DataArray dtx) : base()
356
357
ShortArtist = dtxDict . GetValueOrDefault ( "/artist_short" ) ? . GetChild < string > ( 1 ) ;
357
358
Description = dtxDict . GetValueOrDefault ( "/desc" ) ? . GetChild < string > ( 1 ) ;
358
359
RawUnlockRequirement = dtxDict . GetValueOrDefault ( "/unlock_requirement" ) ? . GetChild < string > ( 1 ) ;
359
- Bpm = dtxDict . GetValueOrDefault ( "/bpm" ) ? . GetChild < double > ( 1 , e => double . Parse ( e . ToString ( ) ) ) ;
360
+ Bpm = dtxDict . GetValueOrDefault ( "/bpm" ) ? . GetChild < double > ( 1 , e => double . Parse ( e . ToString ( ) , provider : CultureInfo . InvariantCulture ) ) ;
360
361
Charter = dtxDict . GetValueOrDefault ( "/charter" ) ? . GetChild < string > ( 1 ) ? . Trim ( ) ;
361
362
DemoVideo = dtxDict . GetValueOrDefault ( "/demo_video" ) ? . GetChild < string > ( 1 ) ? . Trim ( ) ;
362
363
PreviewStart = dtxDict . GetValueOrDefault ( "/preview_start_ms" ) ? . GetChild < int > ( 1 , e => int . Parse ( e . ToString ( ) ) ) ;
0 commit comments