Skip to content

arlofonseca/fivem-attributes

Repository files navigation

fivem-attributes

A free player attributes system for setting and viewing details of a character.

Features

  • Set a age, height, and description of your character for better interactions.
  • Attributes are stored in your database.
  • Utilizes Prisma to interact with your database.
  • Administrators have the ability to manage attributes via command.

preview

Installation

If you download the source code via the green Code button, you'll need to build the resource. Information on how to do this is provided below. If you prefer not to build it, you can download latest release and drag and drop it into your server. However, any changes made to the built resource will need to be re-built to apply the changes.

Dependencies

Building this resource

  1. Download and install the LTS version of Node.js.
  2. Open a command-line terminal (e.g., Terminal, Command Prompt).
  3. Enter node --version to verify the installation.
  4. Run npm install -g pnpm to globally install the package manager pnpm.
  5. Download or clone the repository with git clone https://github.com/arlofonseca/fivem-attributes.
  6. Execute the queries found in attributes.sql in your database.
  7. Install all dependencies with pnpm i.
  8. Create a new file named .env within the root directory.
  9. Copy the contents of .env.example to the newly created .env file and edit accordingly.
  10. Connect your database with pnpm pull to add Prisma models to schema.prisma.
  11. Generate Prisma client using pnpm generate.
  12. Build the resource with pnpm build.

Use pnpm watch to rebuild whenever a file is modified.

Usage

Commands

/attributes [age] [height] [details] (alias: /attr)

  • Set your characters age, height, and details.

/examine [playerId] (alias: /ex)

  • Examine another player's age, height, and description.

[ADMIN] /setattributes [playerId] [age] [height] [details] (alias: /sattr)

  • Update another player's age, height, and description.

[ADMIN] /deleteattributes [playerId] (alias: /dattr)

  • Deletes attributes for the specified player.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published