An API for managing and interacting with the EToH Joke Towers Difficulty Chart. This package provides a structured way to define, organize, and retrieve difficulty levels, complete with metadata such as names, images, colors, and ratings.
Install the package via npm:
npm install @rbxts/ejt
import Difficulty from "@rbxts/ejt";
You can access predefined difficulties directly as static properties of the Difficulty class:
const firstDifficulty = Difficulty.TheFirstDifficulty;
console.log(firstDifficulty.name); // "The First Difficulty"
console.log(firstDifficulty.layoutRating); // -10000010
Use the get
method to retrieve a difficulty by its unique ID:
const difficulty = Difficulty.get("TheLowerGap");
if (difficulty) {
console.log(difficulty.name); // "The Lower Gap"
}
You can create custom difficulties by chaining the provided methods:
const customDifficulty = new Difficulty()
.setName("Custom Difficulty")
.setImage(1234567890)
.setColor(Color3.fromRGB(255, 0, 0))
.setRating(42)
.setClass(1);
const id = "CustomDifficulty";
Difficulty.set(id, customDifficulty);
- Node.js
- npm
- Roblox TypeScript (roblox-ts)
- Clone the repository:
git clone https://github.com/evilbocchi/ejt.git
cd ejt
- Install dependencies
npm install
- Build the project:
npm run build
Contributions are welcome! Please follow these steps:
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Commit your changes and push the branch.
- Open a pull request.
This project is licensed under the MIT License. See the LICENSE file for details.