-
Posts
18 -
Joined
-
Last visited
Content Type
Profiles
Forums
Servers
Downloads
Gallery
Files posted by GrimReapaa
-
Discord User Authentication
By GrimReapaa in Eluna
Ember's Discord User Authentication Integration (LUA/PYTHON)
This is a mod for intended for Azerothcore's Eluna module, and should be compatible with Eluna's TrinityCore branch as well.
This mod is intended to be used in junction with Ember's Discord Registration Bot, or if you do not want to satisfy that requirement, users must have their discord ID associated with their email in your accounts database.
This somewhat acts as a whitelist for your World of Warcraft server. On server startup, the server starts "DUA.py" which runs a discord bot (ideally the registration bot in this case). You must configure your Discord API key in the PY file. DUA_DB.DUA is made, which is a file that holds all member IDs and relevant roles, if they have any. You must configure relevant role IDs in both the PY and LUA file. When a player logs in, the LUA script runs DUA.py, but this time DUA.py is only searching for that player's associated Discord role in the DUA_DB.DUA file. If any relevant roles are found, the server does nothing. But if no relevant roles are found, or if the user does not exist, then the server will inform the player and they will be kicked for failing to authenticate via Discord.
The intended purpose of this module is to ensure all players accessing your World of Warcraft server are registered via Discord. Some relevant role comments remain to provide ideas that might identify a use case for your server.
Current Compatibility
- Eluna TrinityCore 3.3.5
- Azerothcore Eluna Module 3.3.5
Requirements
- Python3
- Pip Packages: `mysql.connector`, `discord` via `pip install`
- Easy Linux Command that installs the packages for you: `pip install mysql.connector && pip install discord`
Installation Instructions
Create a Discord Bot
1. Access Discord's [Developer Portal](https://discord.com/developers/applications) and create a `New Application`.
2. Navigate to the `Bot` section of your application settings and click `Add Bot`.
- Set the username and profile icon of the bot.
- Reset and save your bots `Token`.
- No permissions are required, as the bot interacts via direct messages with users.
3. Navigate to `OAuth2` -> `URL Generator`.
- In the `Scopes` section:
- [x] `bot`
- Copy the `Generated URL` and paste it into your browser to invite it to your server.
4. The bot should now be visible (_though offline_) in the server you invited it to.
Edit DUA.py
1. In `DUA.py`, there is a list called "relevant_roles" where placeholder values "123" exist.
2. Replace the contents of this list with the Role ID you desire.
3. Ensure the values you enter are NOT in quotes.
4. Save and exit.
Edit DiscordUserAuthentication.lua
1. In `DiscordUserAuthentication.lua`, find the array "relevant_roles" where placeholder values "123" exist.
2. Replace the contents of this list with the Role ID you desire.
3. Ensure the values you enter are kept in quotes.
4. Replace `PATH_TO_DUA_EVENT = "/home/server/bin/DUA.py"` with the location of your `DUA.py` file.
- Temporary `.DUA` character files are stored in the bin directory and may appear there.
6. Save and exit.
To Do
- Provide a check for staff and validate their RBAC roles.
- Output log information to discord channels.
Disclaimer
This is still in active development and will see updates in the future. There are some things in there like mysql connector when it doesn't use it. I just feel this feature is important to release and will lose opportunity in other areas if I spend too much time here.
Contribute
If you'd like to contribute, please fork and create a pull request. Your code will be reviewed and then merged with the main branch.
19 downloads
Updated
-
[ALL] Registration Discord Bot
By GrimReapaa in Tools
Ember's Discord Registration Bot
This is a Python bot that allows users to register a TrinityCore account by direct messaging a bot with specific commands. Users' Discord identifiers are tied to the game account and both the Discord identifier and the TrinityCore username are checked for duplicates.
Current Compatibility
- TrinityCore 3.3.5
- Azerothcore
- CMangos (untested)
- Ashamane (untested)
ANY core should work, provided they have the following commands AND SOAP in the config -
- account set <account> <password> <password>
- account set gmlevel <rank> <realms>
- account create <account> <password> <password>
Requirements
- Python3
- Packages: `mysql.connector`, `discord`
Installation Instructions
Create a Discord Bot
1. Access Discord's Developer Portal and create a `New Application`.
2. Navigate to the `Bot` section of your application settings and click `Add Bot`.
- Set the username and profile icon of the bot.
- Reset and save your bots `Token`.
- No permissions are required, as the bot interacts via direct messages with users.
3. Navigate to `OAuth2` -> `URL Generator`.
- In the `Scopes` section:
- [x] `bot`
- Copy the `Generated URL` and paste it into your browser to invite it to your server.
4. The bot should now be visible (though offline) in the server you invited it to.
Run the Bot
1. Edit the bot config file, [registration.cfg](/registration.cfg).
- The `[mysql]` settings should match the database settings of the TrinityCore MySQL server.
- There are potential issues with setting `host = localhost`. Use `127.0.0.1` instead.
- A blank password will connect via the unix socket.
- The `[discord]` settings should match the following:
- `apiKey` is the bot `Token` generated above.
- `targetServer` is the [ID of a Discord server](https://www.remote.tools/remote-work/how-to-find-discord-id) the bot is in.
- `logsChannel` is the [ID of a Discord channel](https://www.remote.tools/remote-work/how-to-find-discord-id) in the server the bot is in.
- `staff` is the [ID of a Discord role](https://www.remote.tools/remote-work/how-to-find-discord-id) required for "givemepowers"
- The `[soap]` settings should match the following:
- `host` is the SOAP.IP in worldserver.conf
- `user` is a user capable of using account create, and set password commands in-game.
- `pass` is the password for that user.
- `port` is SOAP.Port in worldserver.conf
- `soapRBAC` is the RBAC role provided when "givemepowers" is called.
2. Edit the worldserver config file, worldserver.conf
- 1. Set SOAP.Enabled = 1
3. Run the bot.
- Ensure [Requirements](#requirements) are met.
- Run `discord_bot.py`
Registering via the Bot
1. Ensure the bot is online.
2. Direct message the bot using the following syntax:
- `register <username> <password>`
3. If any errors occur during registration, the bot will let the user know.
Changing Password via the Bot
1. Ensure the bot is online.
2. Direct message the bot using the following syntax:
- `account set password <newpassword> <newpassword>`
3. If any errors occur, the bot will inform the user.
Distributing Staff Powers via the Bot
1. Direct message the bot using the following syntax:
- `givemepowers`
2. If any errors occur, the bot will inform the user.
To Do
- Give a command to authorize GM accounts under the right circumstances
- Add OS specific instructions
- Provide better instructions to maintain safe user permissions and practices
Disclaimer
Anyone who uses this on their server is capable of logging passwords. Encourage your users to provide throwaway passwords or unique passwords. This is a potential way to steal credentials, so it's ethical that all users should be aware and instructed to create unique passwords for your server.
This bot uses the SOAP API to register accounts. So long as your core can handle the above commands and can support SOAP, this bot will work with it.
Contribute
If you'd like to contribute, please fork and create a pull request via the GitHub. Your code will be reviewed and then merged with the main branch.
Your bot is now running. Congrats! If you have any errors, please post them here.
If you'd like, please join Ember, where this content will be actively used and further developed.
Thank you for reading, and thank you for your time.
OLD INSTRUCTIONS WITH PICTURES AND LINUX SPECIFIC COMMANDS -
124 downloads
Updated
-
[Eluna/LUA] Wisp Of Rain
By GrimReapaa in Eluna
I'm not sure if this content will help anyone, but it's here in an effort to keep the content I create open-source.
This feature is intended for the original gameplay loop of World of Warcraft, rather than roleplay functions that I've made before. The terms are explained below in CONFIG values, but I'll use english here. Basically, a player can walk up to a vendor to buy the item Wisp of Rain. They can learn the spell Wisp of Rain. When killing any creature within XP range, there's a 1% chance a wisp will spawn. The wisp autocasts arcane explosion currently. If the player has the optional Wisp of Rain : Wisp Buff item, the wisp is invulnerable unless stunned or interrupted. When killed, the wisp rewards all party members who have Wisp of Rain with a random buff or debuff such as -1 strength, +1 dodge, -1 expertise, etc, etc. If the player has an optional Wisp of Rain : No Debuffs item, the wisp only distributes buffs to that player.
Thanks for reading. If you find any use for this I hope you enjoy it. Downloading the file will take you to a Github repo where the code for this feature is stored.
elunamod-wispofrain
This is a mod for Eluna for Azerothcore/TrinityCore.
Description:
When a user kills a creature, they have CHANCE_TO_SPAWN_WISP / MAX_CHANCE chance to spawn a wisp, provided they have the RISK_OF_RAIN spell. WISP_ENTRY will autocast from SPELL_ARRAY until killed or WISP_DURATION seconds have passed. If the killer or any party members have RISK_OF_RAIN_MOD_HARDMODE, then SHIELD_SPELL is on WISP_ENTRY until interrupted or stunned. If WISP_ENTRY is killed, then killer and party members will receive a random ID from BUFF_ARRAY / DEBUFF_ARRAY. As the buff is distributed, if RISK_OF_RAIN_MOD_NODEBUFFS is held by the unit, then that unit will only receive buffs. All of the above values can be changed in the LUA file itself.
Select your world database Import the code at the beginning of RiskOfRain.lua, specifically from where it says "SQL STARTS" to "SQL ENDS" If you have a spell_dbc_12340 table from WDBX Editor or Stoneharry's Spell Editor, import the SPELL.DBC SQL from where it specifies start to end. If using AzerothCore, you can instead edit these queries to insert into spell_dbc rather than the above table. You will NOT need to recreate the DBCs for the server or the client. If you do not have a spell_dbc_12340 table, you will need to edit the contents of your spell.dbc to match these SQL values. Good luck! (It will be much easier to do the above) Recreate spell.dbc and import it to your sever and client
47 downloads
Updated
-
[WotLK] All M2s/Textures/Tilesets from all expacs
By GrimReapaa in Models
This is all content that has been successfully ported from all expansions up to Shadowlands to work with WotLK. Technically, it's ALL m2s/wmos and their linked textures exported from retail 9.2.5 using the WoW Export tool. Then all files were TXID fixed, along with being ran in the MultiConverter. Afterwards, a python tool I made was used to remove all files overlapping from vanilla WotLK content. This ensures that ONLY expansion content is in this file. I am absolutely confident this is currently the best patch available for this kind of content.
Enjoy M2s, WMOs, tilesets, textures, flames, and other visuals from Shadowlands, BFA, Legion, WoD, MoP, and Cata.
The files are available in BOTH an MPQ and loose file format. The MPQ version is a 14.8GB download, labelled Patch-N.MPQ. The loose files are in a highly compressed 13.3GB .zip file. When either of these are exported, there should be 178,479 files totaling 27.6GB. If you'd like to use it in noggit or your client regardless of the content, download the MPQ version and place it in your Data folder. If you want to only use the tilesets or specific expansion content, download the loose file version and create your own patches with MPQ Editor.
THANK YOU FOR THE FOLLOWING RESOURCES, WITHOUT THEM BEING AVAILABLE, THIS PATCH WOULD NOT EXIST -
Zarkeven's WMO Patch
Alastor's Expansion patch, commissioned and distributed by Valaryon
TXID Fixer
Adspartan's MultiConverter, adjusted by MaxtorCoder
MPQ Editor (3.2)
WoW Export
Implave's WMO's 8.2-10.1
Known issues -
A lot of Shadowlands WMOs don't work. I ran this in TXID fixer, then Multiconverter, so I couldn't say why they don't. They just don't.
Lava/Slime is broken. You might want to delete them before making your patches.
No DBC files are in the .rar. These can only be spawned in noggit and not in-game.
My meme name for the folder is still in there, dubbed "supergoodportedstuffnotedited". Woops.
Notes -
If I find the time to separate these patches out, I'll return with a patch to update this link. If given the same circumstances, I'll also provide a DBC file to merge with yours along with instructions to spawn them in-game. Keep an eye out for updates here if they happen
If used, credits are appreciated! This took about 3 days to complete along with 200GB of drive real estate to mess with these files and make sure a working product was achieved. That does not include the cooperation of community members who contributed to this resource - those individuals should be thanked and appreciated for their contributions to make this happen!
Also, check out Ember, where this content will be used in a roleplay setting!
Thank you for your time and reading this. This is my first submission to model-changing.net and I hope it's useful to someone.
1,671 downloads
Updated