How to trigger split coins

Post Reply
RodGK
Posts: 2
Joined: Tue Aug 01, 2023 2:25 pm

How to trigger split coins

Post by RodGK »

Hi, I am using Mudlet since this year so I am still learning how to use it after using tintin++ and Zmud years ago to mud. I have a trigger to "get all coins corpse" when a mob dies, but I don't know how to auto split the coins with my group. In tintin++ it was easy ("you get % coins from corpse -> action/trigger "split % coins"), but don't know how to replicate it on Mudlet. Can you help me with that?

Thanks in advance!

Rod

User avatar
demonnic
Posts: 886
Joined: Sat Dec 05, 2009 3:19 pm

Re: How to trigger split coins

Post by demonnic »

You can make a perl regex trigger with the pattern "you get (\d+) coins from corpse" (without the "") and then in the script box at the bottom put in
Code: [show] | [select all] lua
send("split " .. matches[2] .. " coins")

RodGK
Posts: 2
Joined: Tue Aug 01, 2023 2:25 pm

Re: How to trigger split coins

Post by RodGK »

Hi, thanks for your answer!
Last edited by RodGK on Thu Aug 03, 2023 9:34 am, edited 1 time in total.

User avatar
demonnic
Posts: 886
Joined: Sat Dec 05, 2009 3:19 pm

Re: How to trigger split coins

Post by demonnic »

if you click 'show' on the code box in my answer it gives what to put in the script box. Reproduced below without the formatting.

send("split " .. matches[2] .. " coins")

Post Reply