summaryrefslogtreecommitdiff
path: root/ModSlots
diff options
context:
space:
mode:
authorAndrew Opalach <andrew@akon.city> 2026-06-02 22:27:51 -0400
committerAndrew Opalach <andrew@akon.city> 2026-06-02 22:27:51 -0400
commit36871052773638da16a8795c657b03064138f388 (patch)
tree588a4b1b134d4fd24fe7ddfc734395170b8faf39 /ModSlots
parentd40ec05f3e61b51be0b6a7797fc11e0b626d238b (diff)
downloadNewCamera-36871052773638da16a8795c657b03064138f388.tar.gz
NewCamera-36871052773638da16a8795c657b03064138f388.tar.bz2
NewCamera-36871052773638da16a8795c657b03064138f388.zip
ModSlots and Scripts cleanup
Signed-off-by: Andrew Opalach <andrew@akon.city>
Diffstat (limited to 'ModSlots')
-rwxr-xr-xModSlots/ModSlots.py13
-rwxr-xr-x[-rw-r--r--]ModSlots/cmd.sh (renamed from ModSlots/cmd.txt)2
-rw-r--r--ModSlots/slots.example.txt2
3 files changed, 10 insertions, 7 deletions
diff --git a/ModSlots/ModSlots.py b/ModSlots/ModSlots.py
index 6460f4c..48b5ca5 100755
--- a/ModSlots/ModSlots.py
+++ b/ModSlots/ModSlots.py
@@ -79,13 +79,14 @@ def Error(msg):
print(msg + '\n' + '^'*len(msg))
Warning_Index = 1
-def Warn(msg):
+def Warn(msg, inline=True):
global Error_Messages
global Warning_Index
msg = f'W(#{Warning_Index}): {msg}'
Error_Messages.append(msg)
Warning_Index += 1
- print(msg + '\n' + '^'*len(msg))
+ if inline:
+ print(msg + '\n' + '^'*len(msg))
class ArchiveType(Enum):
ZIP = 0
@@ -286,7 +287,7 @@ class Mod():
os.remove(target)
elif os.path.isfile(target) or os.path.isdir(target):
if not copy:
- Warn(f'Not replacing/removing non-symlink file: {target}')
+ Warn(f'Not replacing non-symlink file: {target}', False)
continue
file = os.path.join(output, self.raw_map[key])
if copy:
@@ -303,7 +304,7 @@ class Mod():
if os.path.islink(target):
os.remove(target)
elif os.path.isfile(target) or os.path.isdir(target):
- Warn(f'Not deleting non-symlink file: {target}')
+ Warn(f'Not deleting non-symlink file: {target}', False)
def is_armor_override(line):
sp = line.split('/')
@@ -446,10 +447,12 @@ if Mode == 'write':
l.write(hex(struct.unpack('!Q', struct.pack('!d', Seed))[0])[2:] + '\n')
for mod in Mods:
mod.write(old_list, l)
+ if len(old_list) > 0:
+ print('------------Removed------------')
for old in old_list:
old_target = os.path.join(Game_Directory, old)
if os.path.islink(old_target):
- print(f'Removing old link: {old_target}')
+ print(f'{old_target}')
os.remove(old_target)
if Mode == 'verify':
diff --git a/ModSlots/cmd.txt b/ModSlots/cmd.sh
index b8dce44..494c3e3 100644..100755
--- a/ModSlots/cmd.txt
+++ b/ModSlots/cmd.sh
@@ -1 +1,3 @@
+#! /usr/bin/env sh
+source venv/bin/activate
./ModSlots.py Write slots.example.txt /mnt/hdd/mods/mhw /mnt/ssd/SteamLibrary/steamapps/common/Monster\ Hunter\ World
diff --git a/ModSlots/slots.example.txt b/ModSlots/slots.example.txt
index 06de84d..93ae4b1 100644
--- a/ModSlots/slots.example.txt
+++ b/ModSlots/slots.example.txt
@@ -177,11 +177,9 @@ sBamboo Shoot.zip
+Sailor Swimsuit.zip
+Desert Costume.zip
+2nd Design Contest Swimsuit.zip
-+DOA6 Bunny Girl Costumes.zip
+DOA5LR Kasumi_s Battlesuit.zip
+Rabbit Joker.zip
+Princess Warrior.zip
-+Pub Lass Bunny Girl Costume.zip
+Pistachio.zip
+DOA5LR Momiji Kimono.zip
+Stellar Scorpion.zip