Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/victor-0x29a/http-resource-mtasa
NodeJS integrated with a plugin of MTA:SA
https://github.com/victor-0x29a/http-resource-mtasa
http lua mta-dev mtasa mtasa-resource nodejs typescript
Last synced: 30 days ago
JSON representation
NodeJS integrated with a plugin of MTA:SA
- Host: GitHub
- URL: https://github.com/victor-0x29a/http-resource-mtasa
- Owner: victor-0x29a
- Created: 2023-04-07T17:19:00.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-02T18:02:50.000Z (11 months ago)
- Last Synced: 2024-04-15T02:21:31.137Z (8 months ago)
- Topics: http, lua, mta-dev, mtasa, mtasa-resource, nodejs, typescript
- Language: TypeScript
- Homepage:
- Size: 46.9 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# http-resource-mtasa
## Configuration
- Ensure the default TCP port in `mtaserver.conf` is set to `22005`.
- Create a user in the server's admin ACL and add their details to the `.env` file in the `Node API` folder (username in `MTASAUSER` field, password in `MTASAPASS` field).
- In the `.env` file in the `Node API` folder, set the server's IP address in the `MTASAHOST` field and the previously configured TCP port in the `MTASAPORT` field.## Adding Commands
- To add new commands, go to the `resource` folder and navigate to the `config` folder. There, you'll find a table containing functions.
- Add a new function by placing a comma after the last function and adding its name within square brackets. Create a function with the referenced name inside the brackets, using the ellipsis (`...`) as the main argument to indicate it's a table.
- Define the arguments for the new function. For example, to set the time, create a variable taking the hour as the first argument from `args`. Use `setTime(hour, 0)` and return a message.
- After adding the function, include it in the API list by going to the `commands.ts` file in the `src/config` directory. Add a new object inside the `commands` array, specifying ID, NAME, DESCRIPTION, and ARGS.## Join the B.R.R Community
[](https://discord.gg/3XeQBzNMHz)