@@ -276,6 +276,11 @@ public async Task<XivModStatus> IsModEnabled(string internalPath, bool indexChec
276
276
/// <param name="enable">The status of the mod</param>
277
277
public async Task < bool > ToggleModStatus ( string internalFilePath , bool enable )
278
278
{
279
+ if ( XivCache . GameInfo . UseLumina )
280
+ {
281
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
282
+ }
283
+
279
284
var index = new Index ( _gameDirectory ) ;
280
285
281
286
if ( string . IsNullOrEmpty ( internalFilePath ) )
@@ -307,6 +312,11 @@ public async Task<bool> ToggleModStatus(string internalFilePath, bool enable)
307
312
/// <param name="enable">The status of the mod</param>
308
313
public async Task ToggleModPackStatus ( string modPackName , bool enable )
309
314
{
315
+ if ( XivCache . GameInfo . UseLumina )
316
+ {
317
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
318
+ }
319
+
310
320
var index = new Index ( _gameDirectory ) ;
311
321
312
322
var modList = GetModList ( ) ;
@@ -348,6 +358,11 @@ public async Task ToggleModPackStatus(string modPackName, bool enable)
348
358
/// <returns></returns>
349
359
public async Task < bool > ToggleModUnsafe ( bool enable , Mod mod , bool includeInternal , bool updateCache , IndexFile cachedIndex = null , ModList cachedModlist = null )
350
360
{
361
+ if ( XivCache . GameInfo . UseLumina )
362
+ {
363
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
364
+ }
365
+
351
366
if ( mod == null ) return false ;
352
367
if ( string . IsNullOrEmpty ( mod . name ) ) return false ;
353
368
if ( string . IsNullOrEmpty ( mod . fullPath ) ) return false ;
@@ -446,12 +461,21 @@ public async Task<bool> ToggleModUnsafe(bool enable, Mod mod, bool includeIntern
446
461
/// <param name="enable">The status to switch the mods to True if enable False if disable</param>
447
462
public async Task ToggleAllMods ( bool enable , IProgress < ( int current , int total , string message ) > progress = null )
448
463
{
464
+ if ( XivCache . GameInfo . UseLumina )
465
+ {
466
+ throw new Exception ( "TexTools mods cannot be toggled in Lumina mode." ) ;
467
+ }
449
468
var modList = await GetModListAsync ( ) ;
450
469
await ToggleMods ( enable , modList . Mods . Select ( x => x . fullPath ) , progress ) ;
451
470
}
452
471
453
472
public async Task ToggleMods ( bool enable , IEnumerable < string > filePaths , IProgress < ( int current , int total , string message ) > progress = null )
454
473
{
474
+ if ( XivCache . GameInfo . UseLumina )
475
+ {
476
+ throw new Exception ( "TexTools mods cannot be toggled in Lumina mode." ) ;
477
+ }
478
+
455
479
var _index = new Index ( _gameDirectory ) ;
456
480
457
481
var modList = await GetModListAsync ( ) ;
@@ -625,6 +649,11 @@ public async Task<int> PurgeInvalidEmptyBlocks()
625
649
/// <param name="modItemPath">The mod item path of the mod to delete</param>
626
650
public async Task DeleteMod ( string modItemPath , bool allowInternal = false , IndexFile index = null , ModList modList = null )
627
651
{
652
+ if ( XivCache . GameInfo . UseLumina )
653
+ {
654
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
655
+ }
656
+
628
657
var doSave = false ;
629
658
var _index = new Index ( _gameDirectory ) ;
630
659
if ( modList == null )
@@ -676,6 +705,11 @@ where mod.fullPath.Equals(modItemPath)
676
705
/// <param name="modPackName">The name of the Mod Pack to be deleted</param>
677
706
public async Task DeleteModPack ( string modPackName )
678
707
{
708
+ if ( XivCache . GameInfo . UseLumina )
709
+ {
710
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
711
+ }
712
+
679
713
var modList = GetModList ( ) ;
680
714
681
715
var modPackItem = ( from modPack in modList . ModPacks
@@ -716,6 +750,11 @@ where modPack.name.Equals(modPackName)
716
750
/// <returns></returns>
717
751
public async Task CleanUpModlist ( IProgress < ( int Current , int Total , string Message ) > progressReporter = null )
718
752
{
753
+ if ( XivCache . GameInfo . UseLumina )
754
+ {
755
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
756
+ }
757
+
719
758
progressReporter ? . Report ( ( 0 , 0 , "Loading Modlist file..." ) ) ;
720
759
var modlist = await GetModListAsync ( ) ;
721
760
@@ -902,6 +941,11 @@ public async Task<long> GetTotalModDataSize()
902
941
/// <returns></returns>
903
942
public async Task < long > DefragmentModdedDats ( IProgress < ( int Current , int Total , string Message ) > progressReporter = null )
904
943
{
944
+ if ( XivCache . GameInfo . UseLumina )
945
+ {
946
+ throw new Exception ( "TexTools mods cannot be altered in Lumina mode." ) ;
947
+ }
948
+
905
949
var modlist = await GetModListAsync ( ) ;
906
950
var _dat = new Dat ( XivCache . GameInfo . GameDirectory ) ;
907
951
var _index = new Index ( XivCache . GameInfo . GameDirectory ) ;
0 commit comments