

def realtime_to_gametime(secs=0, mins=0, hrs=0, days=0, weeks=0, months=0, yrs=0, format=False):
    '\n    This method calculates how much in-game time a real-world time\n    interval would correspond to. This is usually a lot less\n    interesting than the other way around.\n\n    Kwargs:\n        times (int): The various components of the time.\n        format (bool): Formatting the output.\n\n    Returns:\n        time (float or tuple): The gametime difference or the same\n            time split up into time units.\n\n     Example:\n      realtime_to_gametime(days=2) -> number of game-world seconds\n                                      corresponding to 2 real days.\n\n    '
    gametime = (TIMEFACTOR * ((((((secs + (mins * 60)) + (hrs * 3600)) + (days * 86400)) + (weeks * 604800)) + (months * 2628000)) + (yrs * 31536000)))
    if format:
        return _format(gametime, YEAR, MONTH, WEEK, DAY, HOUR, MIN)
    return gametime

dataset/ETHPy150Open evennia/evennia/evennia/utils/gametime.py realtime_to_gametime/original