This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

CofD Resource Tracker

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
S
Steamwolf
Voice
Posts: 8
Joined: Mon May 08, 2017 5:32 pm

CofD Resource Tracker

Post by Steamwolf »

Hello! :-)

As with my previous post, please bear with my incredible lack of experience. I've tried searching for an answer to this, and I've tried muscling through tutorials on tcl, but I have a long way to go before I even begin to understand what I'm doing.

I've recently started up my very first private irc server to run a game (Chronicles of Darkness) with some friends, which is great fun and a total adventure in learning technical things I've never thought I'd be able to do. That said, I have a few resources (Willpower and Fuel) that I would very much like my Eggdrop bot to track for me in a file I can manipulate manually if need be, but I simply don't have the experience with tcl required to do so.

If anyone could possibly help me out, I'd be most appreciative.

Ultimately, this is what I'm looking to accomplish (I'm sorry if this is a big request, I'm simply not sure where else to turn)

Willpower & Fuel tracking script

For each registered Handle, stored in a file I can manipulate manually:

Store Variables

- Handle.wp
- Handle.wpmax
- Handle.fuel
- Handle.fuelmax

Commands sent to bot in a private message by me, only if I’ve identified to my Handle:

getwp Handle
- Replies with “Handle.wp currently #”

setwp Handle #
- Sets Handle.wp to #
- Replies with “Handle.wp set to #”

getwpmax Handle
- Replies with “Handle.wpmax currently #”

setwpmax Handle #
- Sets Handle.wpmax to #
- Replies with “Handle.wpmax set to #”

getfuel Handle
- Replies with “Handle.fuel currently #”

setfuel Handle #
- Sets Handle.fuel to #
- Replies with “Handle.fuel set to #

getfuelmax Handle
- Replies with “Handle.fuelmax currently #”

setfuelmax Handle #
- Sets Handle.fuelmax to #
- Replies with “Handle.fuelmax set to #”

Commands sent by users in public channel:

!wp # Explanation
- Checks that something is written as an explanation
- - If not, returns “((You must explain your reason for spending Willpower))”
- - - (Regardless if they’re Identified or not)
- - - (In text on the channel)
- Decreases Handle.wp by #
- - Only if an explanation exists
- - Only if user is Identified to Handle
- - - Otherwise, send a Notice to Handle that they must Ident first
- Sends a Notice to Handle telling them the current value of Handle.wp
- - Only if an explanation exists
- - Only if user is Identified to Handle
- - Otherwise, send a Notice to Handle that they must Ident first

!getwp / !getw / !gw / !gwp
- Sends a Notice to Handle telling them the current value of Handle.wp
- - Only if user is Identified to Handle
- - - Otherwise, send a Notice to Handle that they must Ident first

!fuel # Explanation
- Checks that something is written as an explanation
- - If not, returns “((You must explain your reason for spending Fuel))”
- - - In text on the channel
- - - Regardless if they’re Identified or not
Decreases Handle.wp by #
- Only if an explanation exists
- Only if user is Identified to Handle
- - Otherwise, send a Notice to Handle that they must Ident first
Sends a Notice to Handle telling them the current value of Handle.wp
- Only if an explanation exists
- Only if user is Identified to Handle
- - Otherwise, send a Notice to Handle that they must Ident first

!getfuel / !getf / !gf / !gfuel
- Sends a Notice to Handle telling them the current value of Handle.fuel
- - Only if user is Identified to Handle
- - - Otherwise, send a Notice to Handle that they must Ident first

Event triggered automatically at 8:00 AM, Eastern Standard Time
- Increase the value of each Handle.wp by 1
- - Only if Handle.wp is less than Handle.wpmax
S
Steamwolf
Voice
Posts: 8
Joined: Mon May 08, 2017 5:32 pm

Post by Steamwolf »

A script has been made! Thank you willyw.
User avatar
caesar
Mint Rubber
Posts: 3776
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Can you share the code so others have the game? :)
Once the game is over, the king and the pawn go back in the same box.
w
willyw
Revered One
Posts: 1196
Joined: Thu Jan 15, 2009 12:55 am

Post by willyw »

caesar wrote:Can you share the code so others have the game? :)
No... it's a mess. heheeh

We "got it to work" and stopped working on it, so it is more like a first draft.
There's a lot of room to clean it up and improve it.

But I'll pm you here about it.
For a fun (and popular) Trivia game, visit us at: irc.librairc.net #science-fiction . Over 300K Q & A to play in BogusTrivia !
S
Steamwolf
Voice
Posts: 8
Joined: Mon May 08, 2017 5:32 pm

Post by Steamwolf »

Well, it does everything I needed it to do, and it does it well. Thanks again, willyw! :-D
Post Reply