lykoss / lykos

Werewolf, the popular detective/social party game (a theme of Mafia)
https://werewolf.chat
Other
127 stars 63 forks source link

New event Categorys "Tagesereignisse" #472

Closed svdermant closed 3 years ago

svdermant commented 3 years ago

I would like to include the word "Tagesereignisse:" before the death or death_no_reveal messages appear, as I have it now it doesn't work.see: https://pastebin.com/Yiqterfh . This is how the word would appear whenever someone died. But it should appear as a kind of category. In the picture you can see how it shouldn't be. it should only appear once. Picture: https://ibb.co/sy0qwmw I hope you understand what I want. So it should be somewhere in the wolfgame.py but I'm not exactly sure and how ... The addition in the language file brings this so that Lykos writes the word "Tagesereignisse:" several times if a player was killed at It should be so that it is written and underneath the news of the events. Take a look at here https://pastebin.com/QNFTHPcQ - I think the message has to be entered there somewhere, but I don't know exactly how. That's why I ask you.

I would also like to add a category "Nachtgeschehen" where everything is listed that happens in the night etc.

I hope anybody can help me to modify it. And i hope anybody knows what i want.

skizzerz commented 3 years ago

This will require some custom code on your part to implement. Typically most bot admins will create the code files in gamemodes/ even though it isn't technically a game mode. Check gamemodes/__init__.py.example for instructions (you will need to rename it to __init__.py).

The code itself would register some event listeners at appropriate times. Look for where the messages you're interested in augmenting are being used and which events are nearby those uses for you to add additional messages. Then you can look at existing listeners for that event for ideas of how to do what you're trying to do.

We are not going to write this for you, you're on your own for that.

svdermant commented 3 years ago

I would try to understand it myself somehow, but there is nowhere a documentation of all the events that occur in the game or during your programming.

If your wiki had something like this, the event x that and that does etc then it would be easier for me to understand the whole thing. So I have to guess.