search
HomeBackend DevelopmentGolangSquash Elo Rating System

I am ecstatic to announce my new project, the Squash Elo Rating System. This project is created for the Carleton Squash Club.

Why?

When attending the club myself and talking to other players I realized there was a need for a system that could help players see their ranking and/or their progress within the game, while having a conversation with a member we concluded that Chess.com Elo rating system would kind of work for our purposes.

So I made this project to solve that very need based on these principles:

  1. The thing made should be readily accessible to players
  2. Players should be able to see their ratings, stats, and any other data easily
  3. The system should be simple and intuitive

What

So what exactly did I make here is the question you might be asking after reading this long.

Squash Elo Rating System

Discord Bot (Writing)

Responsibilities/features:

  • Authentication: The Carleton Squash club is private, is very well maintained and on top of that, is on Discord, which by itself provides so much fine-tuning for the admins that the authentication and thus bad data is handled by the Discord itself.
  • Adding players to the system: Players can only be added through Discord.
  • Adding match to the system: The match can only be added through Discord. Also, all the data is also sanitized by the bot.
  • Stats: Players can see their stats.

The bot is made entirely in Golang, this is first because I love using it and also it had a very easy-to-use package, with great documentation which helped me get started in no time.
https://github.com/bwmarrin/discordgo

The original vision for this system was for it to be only a Discord bot where players can view their rankings through Discord. This vision was then disrupted by the conversation I had with the members of my club about how they would use the bot. From the conversation, I could see that there would be a hindrance in players wanting to see their stats/rankings/matchups, because every time they do, it would be public. This led me to the decision to add a website to the system.

Adding a website was essential because I want my club's players to see all data at all times without having to think about server etiquette.

Website (Reading)

Responsibilities:

  • Getting the rankings
  • Getting the player's current stats
  • Having all player's matchups
  • Having a graphic to view players' recent progression

Like I said I wanted the website to be simple, and I don't like writing auth logic so the website is made to be read not write.

The website is also written in Golang because it is the Best language to write servers in.

In conclusion

I would like to thank the president of my club, Noah, for letting me give this project to the community and for helping me improve it with his input.

I would also like to thank Adam an exec in our club who helped me realize that I should not base my DB on Discord Usernames as people can change them, he helped me change it to Discord IDs that are usually only seen at the API level.

I learned a lot with this project, and I put a lot into it, as of now I am in the process of getting this hosted while waiting on the bureaucracy of it all. In the meantime, I wanted to share this project with you. You can find it on my GitHub.

https://github.com/AaravSibbal/SquashWebsite

The above is the detailed content of Squash Elo Rating System. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
String Manipulation in Go: Mastering the 'strings' PackageString Manipulation in Go: Mastering the 'strings' PackageMay 14, 2025 am 12:19 AM

Mastering the strings package in Go language can improve text processing capabilities and development efficiency. 1) Use the Contains function to check substrings, 2) Use the Index function to find the substring position, 3) Join function efficiently splice string slices, 4) Replace function to replace substrings. Be careful to avoid common errors, such as not checking for empty strings and large string operation performance issues.

Go 'strings' package tips and tricksGo 'strings' package tips and tricksMay 14, 2025 am 12:18 AM

You should care about the strings package in Go because it simplifies string manipulation and makes the code clearer and more efficient. 1) Use strings.Join to efficiently splice strings; 2) Use strings.Fields to divide strings by blank characters; 3) Find substring positions through strings.Index and strings.LastIndex; 4) Use strings.ReplaceAll to replace strings; 5) Use strings.Builder to efficiently splice strings; 6) Always verify input to avoid unexpected results.

'strings' Package in Go: Your Go-To for String Operations'strings' Package in Go: Your Go-To for String OperationsMay 14, 2025 am 12:17 AM

ThestringspackageinGoisessentialforefficientstringmanipulation.1)Itofferssimpleyetpowerfulfunctionsfortaskslikecheckingsubstringsandjoiningstrings.2)IthandlesUnicodewell,withfunctionslikestrings.Fieldsforwhitespace-separatedvalues.3)Forperformance,st

Go bytes package vs strings package: Which should I use?Go bytes package vs strings package: Which should I use?May 14, 2025 am 12:12 AM

WhendecidingbetweenGo'sbytespackageandstringspackage,usebytes.Bufferforbinarydataandstrings.Builderforstringoperations.1)Usebytes.Bufferforworkingwithbyteslices,binarydata,appendingdifferentdatatypes,andwritingtoio.Writer.2)Usestrings.Builderforstrin

How to use the 'strings' package to manipulate strings in Go step by stepHow to use the 'strings' package to manipulate strings in Go step by stepMay 13, 2025 am 12:12 AM

Go's strings package provides a variety of string manipulation functions. 1) Use strings.Contains to check substrings. 2) Use strings.Split to split the string into substring slices. 3) Merge strings through strings.Join. 4) Use strings.TrimSpace or strings.Trim to remove blanks or specified characters at the beginning and end of a string. 5) Replace all specified substrings with strings.ReplaceAll. 6) Use strings.HasPrefix or strings.HasSuffix to check the prefix or suffix of the string.

Go strings package: how to improve my code?Go strings package: how to improve my code?May 13, 2025 am 12:10 AM

Using the Go language strings package can improve code quality. 1) Use strings.Join() to elegantly connect string arrays to avoid performance overhead. 2) Combine strings.Split() and strings.Contains() to process text and pay attention to case sensitivity issues. 3) Avoid abuse of strings.Replace() and consider using regular expressions for a large number of substitutions. 4) Use strings.Builder to improve the performance of frequently splicing strings.

What are the most useful functions in the GO bytes package?What are the most useful functions in the GO bytes package?May 13, 2025 am 12:09 AM

Go's bytes package provides a variety of practical functions to handle byte slicing. 1.bytes.Contains is used to check whether the byte slice contains a specific sequence. 2.bytes.Split is used to split byte slices into smallerpieces. 3.bytes.Join is used to concatenate multiple byte slices into one. 4.bytes.TrimSpace is used to remove the front and back blanks of byte slices. 5.bytes.Equal is used to compare whether two byte slices are equal. 6.bytes.Index is used to find the starting index of sub-slices in largerslices.

Mastering Binary Data Handling with Go's 'encoding/binary' Package: A Comprehensive GuideMastering Binary Data Handling with Go's 'encoding/binary' Package: A Comprehensive GuideMay 13, 2025 am 12:07 AM

Theencoding/binarypackageinGoisessentialbecauseitprovidesastandardizedwaytoreadandwritebinarydata,ensuringcross-platformcompatibilityandhandlingdifferentendianness.ItoffersfunctionslikeRead,Write,ReadUvarint,andWriteUvarintforprecisecontroloverbinary

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

Atom editor mac version download

Atom editor mac version download

The most popular open source editor