Skip to content

Documentation

Bradlee Barnes edited this page Feb 14, 2024 · 7 revisions

lib.

addNewElement()

Adds a new element with whatever name and emoji you want.

Arguments

  • name - String
    • The name of the element to add
  • emoji - String
    • The emoji to display next to the name
  • firstDiscovery - Boolean (optional - default: false)
    • Should the element be marked as a First Discovery?

Example

lib.addNewElement("Robo-saurus", "🤖🦖")

modMenu.

addNewButton()

Adds a new button to the menu.

Arguments

  • buttonText - String
    • Text displayed on the button
  • onClick - Function
    • Callback/function to be called
    • Called with the button element passed through to it via an argument.

Example

modMenu.addNewButton("Add Element", (self) => {
    lib._reqEl() // btw pls don't call this func, it's private :3
})
Clone this wiki locally