Veracity's MMG scripts

NoobCapt

New member
I'm having some problems with this script.

1. It was working before, when the closet iteration was 1,000,000. I changed it to 100m, it stopped working. Changed it back to 1m, still doesn't work. Gives me the following error:
"Failed to find bet #78424566
Failed to find bet #78424567
Failed to find bet #78424564
Failed to find bet #78424613
Failed to find bet #78424616
Waiting for MMG event..."
This happens after the first 5 bets are placed. Not necessarily before/after they are taken, though.
Once it happens, the script stops running, regardless of whether I won/lost the 5 bets the script placed.

2. Running mmg-log.ash gives me an empty table.

I'd appreciate help with both of the problems.

Many thanks for your time!
 

Veracity

Developer
Staff member
I haven't actually run mmg.ash for a long time; I long since gave up making bets in the MMG.

I recently have been playing around with taking bets and I have seen the problem with mmg-log.ash. I have uploaded a new version which works again. Download a new copy of that script.
 

bundy81881

New member
This looks really cool. I actually haven't had a chance until recently to give this a shot. I'm having some problems running it on my Mac at home. It lays out the bets but then doesn't recognize when the bets are taken and stops. I'm guessing it's gotta be something with my system. Does anyone know how this can be used on my OS (I currently use Lion).
 
Last edited:

Theraze

Active member
It always helps if you can be as specific as possible. Please try to give us logs of it attempting to run. Thank you.
 

bundy81881

New member
Oddly enough it works now. If I get the error again I'll copy and paste. Gotta love that MMG. Let's see how this rolls!
 

LordRedhawk

New member
I was hoping someone could help me with these scripts. I really like Veracity's MMG script and I've been using it for a while and it works great. I also tried the "anti-martingale.ash" script submitted in this thread by Misteryous Stranger, but I need a little help with this one. I hope someone can help me, because I noticed that Misteryous Stranger has been inactive for about 3 years, and I'm not a scripter. So, here's my problem...

When I run "anti-martingale.ash", there are several prompts:
"Please input value for int amount" (starting bet amount... I put 1000)
"Please input a value for float factor" (the amount to multiply starting bet amount by... I put "2")
"Please input a value for int iterations" (how many times the script restarts the betting sequence... I experimented with different numbers here from "1" to "10")
"Please input a value for int chain_count" (how many of these bets to run at the same time, 1-5... I put "1")
"Please input a value for int win_threshold" (I don't know what this is... I tried "1" and I tried "4000" and didn't see what it does)
"Please input a value for boolean stop_when_win (I don't know what this does, either. Options are "true" or "false"... I left it at the default "true")

What I wanted the script to do was make a starting bet of "1000" and double the bet each time it wins until it wins "4000" on the 3rd bet, then restart the betting again at "1000". (IE: 1000 win, 2000 win, 4000 win, 1000... etc etc etc) The script doesn't do that, no matter what I put in the initial prompts. It keeps doubling the bets if it wins indefinitely until it loses, then it restarts the bet at "1000". It's impossible to ever win this way.

Can someone please explain exactly what these prompts mean and what I'm doing wrong? Thanks!
 

slyz

Developer
From looking at the anti-martingale.ash posted by Theraze in post #67, it looks like "win_threshold" means "the number of wins at which the script should start over".

In your case, you should use win_threshold = 3: 1000, 2000, 4000, stop.

It's impossible to ever win this way.
In this and every other way, yup.
 

LordRedhawk

New member
Thanks for your response, slyz. I tried your suggestion and and set the win_threshold to "3", but it still doesn't do as expected. It continued past 3 winning bets. It should have gone back to a "1000" bet after it won the 3rd bet of "4000", but it went on to bet "8000" and lost. It's interesting that it said "Reached winnings limit for chain 1" right after losing the 4th bet that should never have been made. Maybe that's where the problem in the script is? Any suggestions? See here:

Betting 1,000 meat from inventory
Bet 1/1/1: for 1,000 Meat -> bet #81835496
Waiting for MMG event...
02/01/13 09:11:13 AM - brian_damage took your 1,000 Meat bet, and you won, earning you 1,998 Meat.
Bet 1/1/1 (#81835496) taken by brian_damage: 998 / 998 / 998
Moving 9,995 Meat to closet.
Placing meat into closet...
Betting 2,000 meat from inventory
Bet 1/1/2: for 2,000 Meat -> bet #81835498
Waiting for MMG event...
02/01/13 09:11:33 AM - Penguinator took your 2,000 Meat bet, and you won, earning you 3,996 Meat.
Bet 1/1/2 (#81835498) taken by Penguinator: 1,996 / 996 / 2,994
Moving 1,996 Meat to closet.
Placing meat into closet...
Betting 4,000 meat from inventory
Bet 1/1/3: for 4,000 Meat -> bet #81835500
Waiting for MMG event...
02/01/13 09:11:48 AM - Winestand Flute took your 4,000 Meat bet, and you won, earning you 7,992 Meat.
Bet 1/1/3 (#81835500) taken by Winestand Flute: 3,992 / 992 / 6,986
Moving 3,992 Meat to closet.
Placing meat into closet...
Betting 8,000 meat from inventory
Bet 1/1/4: for 8,000 Meat -> bet #81835505
Waiting for MMG event...
02/01/13 09:11:58 AM - Winestand Flute took your 8,000 Meat bet, and you lost. Better luck next time.
Bet 1/1/4 (#81835505) taken by Winestand Flute: -8,000 / -15,000 / -1,014
Reached winnings limit for chain 1
Betting 1,000 meat from inventory
Bet 1/2/1: for 1,000 Meat -> bet #81835507
Waiting for MMG event...
02/01/13 09:12:04 AM - Penguinator took your 1,000 Meat bet, and you won, earning you 1,998 Meat.
Bet 1/2/1 (#81835507) taken by Penguinator: 998 / 998 / -16
Betting 2,000 meat from inventory
Bet 1/2/2: for 2,000 Meat -> bet #81835509
Waiting for MMG event...
02/01/13 09:12:12 AM - Penguinator took your 2,000 Meat bet, and you lost. Better luck next time.
Bet 1/2/2 (#81835509) taken by Penguinator: -2,000 / -3,000 / -2,016
Betting 1,000 meat from inventory
Bet 1/3/1: for 1,000 Meat -> bet #81835512
Waiting for MMG event...
 

Razorsoup

Member
Playing with this script, I'm getting some errors. Initially it would hang with the message "Waiting for MMG event...". I was able to determine that the check for (mmg_my_bets().count() == 0) was never returning true so the script wouldn't actually abort. So I changed that section to be:
Code:
int bet_id = mmg_wait_event(1000);
if (bet_id == 0) {
	if (wait_count == 0) {
		print("Waiting for MMG event...");
	}
	wait_count = wait_count + 1;
	if (wait_count == wait_limit) {
		mmg_visit();
		wait_count = 1;
		if (mmg_my_bets().count() == 0) {
			print("Possible server problem: " + count(chains) + " chains pending but KoL says none and it's been " + wait_limit + " seconds without an event.");
			break;
		}
		print(to_string(mmg_my_bets().count()) + " bets pending...");
	}
	continue;
} else if (bet_id == -1) {
	print("Error: no bets found but " + count(chains) + " chains still pending");
	break;
}

This uses "mmg_visit()" to force mafia to refresh the status of the MMG. I also added a line to print out how many bets KoL reports as pending. This all works fine and the script will abort now when something goes wrong. The problem is that something seems to go wrong often. Every time I run this script, I eventually get the error, "Possible server problem: 5 chains pending but KoL says none and it's been 30 seconds without an event."

I think mafia is not getting the messages when a bet is accepted. So my question is, is mafia not correctly receiving the messages or is KoL not sending them?
 

paolobagnas

New member
Betting 20,000 meat from storage
You don't have enough meat.
Bet 1/1/1: for 20,000 Meat -> FAILED
Betting 20,000 meat from storage
You don't have enough meat.
Bet 2/1/1: for 20,000 Meat -> FAILED
Chain 1 failed on iteration #1 placing bet for 20,000
Chain 2 failed on iteration #1 placing bet for 20,000
Done running 2 chains of 500000 bets.
Net winnings = 0. Net change to closet = 0

1 have 2m meat in storage. Why does this happen?


edit: figured it out. sorry lol

edit2: I don't know the reason behind the system stopping the script a few seconds when I want it to make 500,000 chains of betting. It didn't happen before but it is now. I tried reinstalling the script and the kolmafia file but nothing happens.
 
Last edited:

Veracity

Developer
Staff member
I have not looked at the MMG in many years and have no interest in supporting this script ever again. Sorry.

But, if it is still "useful" to you, I am happy for you! I think.
 
Top