Giter VIP home page Giter VIP logo

riichi-trainer's Introduction

If you're looking to contribute, translations or otherwise, please see the contributing guidelines for instructions.

This is a collection of tools designed to improve the play of Riichi Mahjong players. It includes an efficiency trainer to help players identify the best tile to discard, a replay analyzer to check the efficiency (and safety, if relevant) of a player's discards, an all-last trainer to assist with comebacks, and a few random utilities.

When referring to efficiency here, we're referring to ukeire, which is the tile acceptance of the hand in the present. There's no look-ahead for future efficiency. Ukeire is an easily measurable thing, and playing towards ukeire is sufficient for many players when combined with adequate defensive play. These tools are primarily aimed at people below Tokujou on Tenhou, and most Mahjong Soul players.

See the itch.io page for more information.

For Programmers:

This project was bootstrapped with Create React App. Make sure to run npm install, everyone's favourite command.

Available Scripts

In the project directory, you can run:

npm start

Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

npm run build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!

See the section about deployment for more information.

riichi-trainer's People

Contributors

dependabot[bot] avatar elitesoba avatar euophrys avatar gmayeul avatar noizms avatar ozball avatar rishubil avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

riichi-trainer's Issues

Kan claims

It would be nice if you could claim a kan. Now, the only way to go on is to discard one of the tiles in the kan.

Add a CONTRIBUTING.md

See: https://help.github.com/en/articles/setting-guidelines-for-repository-contributors

It would be good to add what your expectations are with regards to contributions. Do you expect mostly translation work or are you also open to some code contributions? Or whether you want a new issue created for each PR or not. A lot of the stuff currently in README.md could also be moved there, and maybe link the trello board.

I like the efficiency trainer, it is very helpful ๐Ÿ˜„

generated link to fetch a majsoul log doesn't work

Hey there, I was trying to find out how to download majsoul game logs and found your comment here. However I tried this method on your replay analyzer and the link generated won't connect at all. Is there a new way to fetch the logs?

Also, I see that you're basically just using javascript and regular expressions to interpret the logs in a brute force way. I think it would be easier to compile the protobuf using javascript bindings and read it that way.

My ultimate goal is to cobble together code from various places and create a PR for Equim-chan/akochan-reviewer so that it can review Majsoul logs as well as Tenhou ones. I'll be using the protobuf approach once I figure out a way to download the game log reliably.

thanks!

error ERR_OSSL_EVP_UNSUPPORTED

โฏ bun run build
$ react-scripts build
Creating an optimized production build...
Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:67:19)
    at Object.createHash (node:crypto:133:10)
~~~
  opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
  library: 'digital envelope routines',
  reason: 'unsupported',
  code: 'ERR_OSSL_EVP_UNSUPPORTED'

here is avoidance. This project seems to have stopped, so I will develop it on my own fork!

export NODE_OPTIONS=--openssl-legacy-provider
bun run build

Explorer does not show some tiles that increase ukeire

Take the hand 123m12399p57s1122z .
The site says discarding 9p, 1z, 2z are equal with shanten 1, ukeire 8. and that "tiles that increase ukeire" is 0.
But after any of those discards drawing a 4s and discarding 7s increase ukeire because you can now advance the hand by drawing 3s and 6s instead of just 6s. Indeed if load 123m1239p457s1122z it does tell me that ukeire is now 12.

Furiten indication

Thanks for developing this, it is a very nice tool to practice tile efficiency!

It would be nice if the final hand is indicated to be furiten yes/no.

Bug: Aka not included in ukeire

image

2346678p3455577s -> discard 6p. Should be 3 outs instead of 2 outs.
2346678p4555677s -> discard 6p. Should be 7 outs instead of 6 outs.

Changing the suit from souzu to manzu recreated the error.

Round to first decimal place in efficiency trainer

Discard: three of circles (4 tiles). That was the best choice! Your hand is now ready. Congratulations! Your efficiency was 297/298, or 99%.

99.6% gets rounded down to 99% and 98.8% gets rounded down to 98%. I suggest to keep the first decimal place for more accuracy.

Show most efficient tiles only after reaching tempai

Currently you can only see it while discarding or not at all. It would be nice to be able to chose tiles without being influenced by knowledge of what the best move was, but still be able to see the optimal moves later.

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.