xNarnia / TCR-TerrariaChatRelay

Self-serving Terraria Chat Relay with extensible chat service support
https://forums.terraria.org/index.php?threads/tcr-terrariachatrelay.78196/
MIT License
32 stars 16 forks source link

!world command to show world seed #10

Closed Metacinnabar closed 2 years ago

Metacinnabar commented 3 years ago

Description

Show world seed (possibly configurable) when the Discord command !world is issued.

xNarnia commented 2 years ago

Showing the seed is mixed with a lot of emotions for everyone. Half want it, half don't. I can implement a disable-able !seed command instead?

Metacinnabar commented 2 years ago

Sure!

xNarnia commented 2 years ago

Do you want to make a commit for this? It's very easy with the new command system. A sample command is below.

https://github.com/xPanini/TCR-TerrariaChatRelay-TShock/blob/master/TCRPlugin-Discord/Commands/CmdAddManager.cs

xNarnia commented 2 years ago

We do need a new World command in the TCR namespace. (I didn't get around to adding it oops) We can make the "World" command change it's output based on a "ShowSeed" config option at the TCR level.

Metacinnabar commented 2 years ago

https://github.com/xPanini/TCR-TerrariaChatRelay-TShock/blob/master/TCRPlugin-Discord/Commands/CmdAddManager.cs

This results in a 404.

Do you want to make a commit for this?

I could try to find some time to spend adding this.

Does the new command system support Discord embeds?

xNarnia commented 2 years ago

Ah, that's because I moved the path. Here you go! https://github.com/xPanini/TCR-TerrariaChatRelay-TShock/blob/master/TCR-TerrariaChatRelay/Command/Commands/CmdPlayersOnline.cs

I have not begun working on the embed builder yet. The command system abstracts itself away from Discord anyways, so it doesn't know what it's talking to. We can program the method now, do embeds later.

All you have to so is return a string in a method. Since this command requires access to Terraria's world, this command should be done at the TCR layer.

I have been using a markup though to help standardize formatting across Discord (and future clients)

< /b> Bold < /box> Box < /I> Italics < /br> Break

Metacinnabar commented 2 years ago

Sounds good! I should be able to fit this in this week.

xNarnia commented 2 years ago

Closed #24