Skip to content

Commit 4641a79

Browse files
committed
v1
1 parent 3266ca4 commit 4641a79

1 file changed

Lines changed: 9 additions & 5 deletions

File tree

UXTU4Linux/Assets/engine/runner.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -647,17 +647,21 @@ def apply_args(args_str: str, family: str) -> tuple[str, bool]:
647647
smu_val = _skin_scale(name, raw)
648648
smu_val = max(0, min(0xFFFFFFFF, smu_val))
649649

650+
results = []
650651
for is_mp1, op in matches:
651652
if is_mp1:
652653
status = smu.send_mp1(family, op, smu_val)
653654
else:
654655
status = smu.send_rsmu(family, op, smu_val)
655656
mb = "MP1" if is_mp1 else "RSMU"
657+
results.append((mb, op, status))
658+
659+
applied = any(status == smu.SMU_OK for _, _, status in results)
660+
if not applied:
661+
any_rejected = True
662+
for mb, op, status in results:
656663
status_str = smu.status_name(status)
657-
if status != smu.SMU_OK:
658-
any_rejected = True
659-
lines.append(f"{name} [{mb} 0x{op:02X}] = {smu_val} -> {status_str} [!]")
660-
else:
661-
lines.append(f"{name} [{mb} 0x{op:02X}] = {smu_val} -> {status_str}")
664+
flag = " [!]" if status != smu.SMU_OK and not applied else ""
665+
lines.append(f"{name} [{mb} 0x{op:02X}] = {smu_val} -> {status_str}{flag}")
662666

663667
return "\n".join(lines) if lines else "(no matching commands for this family)", any_rejected

0 commit comments

Comments
 (0)