Chuckleberry-Finn / Skill-Recovery-Journal

Mod for Project Zomboid which allows users to craft journals, record gained skills, and recover lost skill progression.
https://steamcommunity.com/sharedfiles/filedetails/?id=2503622437
GNU Affero General Public License v3.0
29 stars 32 forks source link

Please add [SRJ STOP READING] #77

Closed WorkingClassKid closed 3 months ago

WorkingClassKid commented 4 months ago

Hi Chuckleberry-Finn!

First, thank you for your great mod! I'm using it since many years and I love it!

Your mod add the line [SRJ START READING] to the Perk.log file when a user start reading the SRJ in MP.

Can you also add the line [SRJ STOP READING] when the user stop reading the SRJ so that way I will be able to code some lines in python for my discord bot to skip that part and not send a ton of message to the discord channel when someone read the SRJ and level up...

Sorry for my bad english!

Regards,

Chuckleberry-Finn commented 4 months ago

Sorry this got forgotten about, could you clarify what you mean by 'not send a ton of message'?

WorkingClassKid commented 4 months ago

Hi Chuckleberry-Finn,

thank you for your anwser

The problem of the "send a ton of message" is because when a player read the SRJ, the user level up very quickly and our discord bot read the perks log to send a message in the discord channel when a user level up. So when a user read a SRJ, a tons of message is sent to the discord channel ( like 10 skills x 10 levels max can make up to 100 messages in the discords channels in a matter of seconds/minutes) .

So, I have seen you have already added the line [SRJ START READING] in the perks.log when a user start reading a SRJ... so I can already know when a user start reading a SRJ.... but I want to know if you can also add a [SRJ STOP READING] when the user stop reading the SRJ so I will be able to make my discord bot ignore the perks changes for that user because the bot will know when the user start reading an SRJ and when he stop reading it and resume operation normaly for that user after he has finished reading is SRJ

If it's not possible, i will just add a timer so when someone start reading an SRJ, the bot will ignore the perks change for that user for X minutes...but it will be less reliable....

Again.... sorry for my bad english....

Regards,

Chuckleberry-Finn commented 4 months ago

I can try to add stop messages, but I am not 100% sure it will work all the time - as actions can be canceled or interrupted.

WorkingClassKid commented 3 months ago

Hi Chuckleberry-Finn,

thank you for the update! I will test this branch and update my python code for my bot today!

I will add a timer fallback if the action got canceled or interrupted.

Will you push this branch to Steam eventually? or I need to put this branch in a mod pack for my own usage?

Regards,

Chuckleberry-Finn commented 3 months ago

Beta changes can be used through this page which will be removed shortly after full release: https://steamcommunity.com/sharedfiles/filedetails/?id=3246173652

Thanks for asking. 👍

WorkingClassKid commented 3 months ago

Hi Chuckleberry-Finn,

thank you so much! Everything seems to work as expected and our discord channel as not been flooded since last week :-)

Thank you :-)