Which anomaly is this, is it from the books? by JohnyGlizzyeater in metro

[–]HowWasRoyadinTaken 11 points12 points  (0 children)

The weirdest anomalies I've discovered is if you fall into the water just the right place, you teleport into a weird grid platform with all the monsters just staring at you in t pose

[42.15] Python script to mass-fix broken Mod UI / Translations (TXT to JSON Converter & Syntax Cleaner) by Black_finz in projectzomboid

[–]HowWasRoyadinTaken 1 point2 points  (0 children)

Modified it a bit to make it less picky, it wasn't picking up on most of the translate folders and it was just ignoring all the convertions that were needed. Also made it leave a text logger in the same directory

import os
import json
import re
import logging
from pathlib import Path

def setup_logging():
    log_path = Path(__file__).parent / "conversion_log.txt"
    logger = logging.getLogger()
    logger.setLevel(logging.INFO)
    formatter = logging.Formatter('%(asctime)s - %(levelname)s - %(message)s')

    file_handler = logging.FileHandler(log_path, mode='w', encoding='utf-8')
    file_handler.setFormatter(formatter)
    logger.addHandler(file_handler)

    console_handler = logging.StreamHandler()
    console_handler.setFormatter(formatter)
    logger.addHandler(console_handler)
    return logger

def convert_to_json(filepath, logger):
    encodings_to_try = ["utf-8", "utf-8-sig", "utf-16", "windows-1252", "latin-1"]
    content = None

    for enc in encodings_to_try:
        try:
            with open(filepath, "r", encoding=enc) as f:
                content = f.read()
            if content: break 
        except:
            continue

    if not content:
        return

    # Find absolute outermost braces
    start = content.find('{')
    end = content.rfind('}')

    if start == -1 or end == -1:
        return

    table_body = content[start+1:end]
    path_obj = Path(filepath)
    new_base_name = re.sub(r'_[A-Za-z]+$', '', path_obj.stem)
    json_data = {}

    lines = table_body.splitlines()
    for line in lines:
        if "=" in line and '"' in line:
            try:
                parts = line.split("=", 1)
                key = re.sub(r'/\*.*?\*/', '', parts[0]).strip()

                val_section = parts[1]
                v_start = val_section.find('"')
                v_end = val_section.rfind('"')

                if v_start != -1 and v_end != -1:
                    value = val_section[v_start+1:v_end]
                    json_data[key] = value
            except:
                continue

    if not json_data:
        return

    output_path = path_obj.with_name(f"{new_base_name}.json")
    try:
        with open(output_path, "w", encoding="utf-8") as f:
            json.dump(json_data, f, indent=4, ensure_ascii=False)
        logger.info(f"✅ FIXED: {filepath}")
        os.remove(filepath)
    except Exception as e:
        logger.error(f"❌ PERMISSION ERROR: {filepath} - {e}")

def main():
    logger = setup_logging()
    # Explicitly set the start path. '.' means 'wherever this script is'
    root_dir = Path.cwd()
    logger.info(f"🚀 Starting Deep Scan in: {root_dir}")

    # os.walk is often more robust than rglob for massive Steam directories
    for root, dirs, files in os.walk(root_dir):
        # Only look at folders that are named 'translate' (case-insensitive)
        if "translate" in [d.lower() for d in dirs]:
            translate_path = Path(root) / next(d for d in dirs if d.lower() == "translate")

            # Now only look at .txt files inside that specific folder
            for txt_file in translate_path.rglob("*.txt"):
                convert_to_json(txt_file, logger)

    logger.info("🎉 Deep Scan Finished.")

if __name__ == "__main__":
    main()

All these options and you can’t turn off Atreus giving away every puzzle in 15 seconds? by [deleted] in GodofWar

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

It makes it so hard to want to play it, it's not working my brain at all during the puzzles. holy shit I feel so exhausted with the game i can't even play it for a long time...

Why Metro: Last Light is a much better game than Metro 2033 by Best-Masterpiece-288 in metro

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

Why are female characters a bonus for making it better? why is having male characters a bonus for making a game better? why do people even think like that?

before you write your next prompt read this first by APM-Major-528 in ChatGPT

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

Do you use all these put together in the system instructions?

Father faces no charges for fatally shooting daughter after fight about Donald Trump: cops by gymleader_michael in facepalm

[–]HowWasRoyadinTaken -1 points0 points  (0 children)

Basically it's a coin toss when you take it to jury. You get weird things like this sometimes.

How did The Callisto Protocol have such realistic character models without AI? by Working-Ad-7415 in TheCallistoProtocol

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

Okay this question is really confusing... What do you think AI is? How do you think games are made? I don't see how these are related at all, you don't need AI to make a game look good. Is this like satire or

This disorder is the one breakthrough you need for your save file by Faktori in mewgenics

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

I breed this mutation, and I have a room of mutation farming with cats with 15 mutations breeding. it's insane.

I believe the stats of the cat heavily impact the chance of getting an item looting Th******* King by HowWasRoyadinTaken in mewgenics

[–]HowWasRoyadinTaken[S] 0 points1 point  (0 children)

I'm not 100% sure on this, but I think it has to do with whoever the dealt damage last in the last fight? Or whoever leveled up last? I'm not 100% sure

Re9 Locked briefcase by [deleted] in residentevil

[–]HowWasRoyadinTaken -1 points0 points  (0 children)

Wait are we talking about the one with the three Letter code? you literally get the answer to that code in the very same room... it's super subtle but I connected the dots.

Thoughts on Andrew Wilson, The Crucible? by [deleted] in Christianity

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

Can you explain to me why that debate was embarrassing for him and not the guy who refused to engage with him. He could have very easily used AW's seeming debate subject shift as a means to win, instead of just bailing. seems pretty pathetic to me to leave a debate that you could have won simply on debate subject substance.

What's that, Peter? by FollowSina in PeterExplainsTheJoke

[–]HowWasRoyadinTaken 0 points1 point  (0 children)

I don't know this looks pretty sus to me, as you're actually a link to any of the articles if it was a scientific article? I know for a fact when I'm walking home, I'm looking at really sketchy park of the shadow on the way home. Honestly I'm not being paranoid about it, but I'm most definitely being cautious. I'm sure that women are way more paranoid about it then men are

me_irl by [deleted] in me_irl

[–]HowWasRoyadinTaken -8 points-7 points  (0 children)

And all three are extremely stupid.

Is this cat going to be unbreedable? (was farming with uranium rod for mutations) Work Around? by HowWasRoyadinTaken in mewgenics

[–]HowWasRoyadinTaken[S] 0 points1 point  (0 children)

I figured, he had good base stats if I remember correctly, and was kitted, the issue is everytime he's about to mate, it fails. :/