Git Product home page Git Product logo

timmy-mk-3's Introduction

Timmy MK 3

Timmy MK 3 is an homage to the original Timmy the Time Bot programmed by Khunee and Juliend10 in Python. I rewrote the Discord bot in JavaScript as I'm more comfortable with it.

See also:

  • HITMAN Milliseconds Time Calc Website
    • Website version of this bot (since not everyone uses Discord)
    • Also includes a link sharing feature, to easily share calculator results with friends
  • Timmy MK 2 Discord Bot
    • Alternative implementation using AWS Lambda (serverless) for hosting, as well as Discord Slash commands

For a full deep dive into the math behind this, please check Time Calc Website README.

How to Run Your Own Instance

  • Before you start, create a .env file and include the line DISCORD_TOKEN=DISCORD_TOKEN_VALUE, where DISCORD_TOKEN_VALUE can be obtained as explained here
  • Run npm install to install dependencies
    • I am on NodeJS version 18.18.2 if it matters
  • Run node index.js to run locally
  • Code formatting: npm run prettier
  • For server hosting, I used railway.app

Documentation

Check Discord.js v12 documentation, as well as this tutorial I was using

Usage Instructions

  1. Add the bot to your Discord server using this URL, or just DM the bot on Discord at Timmy MK 3#9573. Sending commands to the bot in a server and in DM's are both supported.
  2. The required inputs are to type !time SCORE, where SCORE is the score on the rating screen.
    • You can have commas in your score input.
  3. Most video examples from here or here will work for getting valid scores. Otherwise, any score value of about 50,000 to 210,000 should work.
    • NOTE: Only Hitman level completion times of up to 5 minutes are compatible with the bot.
    • Use the Time Calc Website for times of 5 to 15 minutes.
  4. For this example, let's use this video, which is an 8 second run of the "On Top of the World" Hitman level.
  5. We can see at the end of this video that the score at the end of the video is 83,521. As shown here: Score
  6. Now, let's type !time 83521.

Milliseconds Score

  1. As you can see, the bot returns a few viable solutions. One of them (8.981) is within a second of the 8 seconds value shown on the rating screen, so this is the milliseconds value we are looking for.

  2. In case of rounding errors, you will get a warning, as shown below (example: !time 204667):

debug 1

  1. Use the !debugtime SCORE, where SCORE is the score on the rating screen as shown below (example: !debugtime 204667):

debug 2

If needed, click the individual links on the debug message to see the exact math equations used (cross reference with Longer Math Explanation link at bottom):

googleCalc

  1. You can also use the over5 optional parameter to calculate milliseconds for runs between 5 and 15 minutes. Use the syntax !time SCORE over5 or !debugtime SCORE over5, as shown below:

googleCalc

timmy-mk-3's People

Contributors

solderq35 avatar

Watchers

 avatar

timmy-mk-3's Issues

Detailed Score Note

Detailed score (P) on rating screen shows score or something, remember to update documentation

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.