Redwall: Warlords

Discussion => Turbo Discussion => Topic started by: Gen. Volkov on May 10, 2014, 08:44:24 PM

Title: Why isn't the emp unmaxing?
Post by: Gen. Volkov on May 10, 2014, 08:44:24 PM
No one has hit him since I did yesterday, but he's still maxed.
Title: Re: Why isn't the emp unmaxing?
Post by: Shadow on May 11, 2014, 08:57:53 AM
im moving to a new apartment this weekend so I am mostly without internet, but if windy can't get to this before me I'll investigate on tuesday when the internet is back
Title: Re: Why isn't the emp unmaxing?
Post by: windhound on May 12, 2014, 12:48:04 PM
Will try to poke the emp this evening
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on May 12, 2014, 02:51:13 PM
The emp now has 4 attacks available, but hasn't been hit since Friday, as far as I can tell.
Title: Re: Why isn't the emp unmaxing?
Post by: windhound on May 12, 2014, 07:15:15 PM
Interesting.

The code that runs that is pretty simple, turns.php shaves off 2 attacks each hour
dbquery("UPDATE $playerdb SET attacks=(attacks-2) WHERE attacks>0;");
dbquery("UPDATE $playerdb SET attacks=0 WHERE attacks > $theme[attack_limit] OR attacks < 0;");


Buut its not working?
turns.php is running, just made sure, but I don't know if its actually subtracting from attacks like its supposed to (showing 19 when I checked).  Server time used to be on the scores page but its not anymore :/ so I don't know for sure what time the server thinks it is.

Reset the emp's attacks to 0 for now, let me know if it screws up again.
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on May 12, 2014, 09:05:33 PM
Alright, thanks wondy!
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on May 13, 2014, 12:48:49 PM
Ok, I ran this morning and maxed the emp. It's been about 6 hours, and he's still maxed.
Title: Re: Why isn't the emp unmaxing?
Post by: Shadow on May 13, 2014, 01:28:03 PM
is the same thing happening to anyone else? what about the land farm?
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on May 19, 2014, 02:13:59 PM
I think I may be the most active person on Turbo right now, which is why only I am noticing, but the emp is still maxed today, and no one has hit him since yesterday. He only had 20 open attacks when I hit him yesterday.
Title: Re: Why isn't the emp unmaxing?
Post by: Shadow on May 20, 2014, 01:39:33 PM
blarg

never happened before the 28th - I wonder if there is a piece of autoreset code hanging around messings things up.
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on May 20, 2014, 02:37:10 PM
Could be, he was at 8 attacks last time I checked, hadn't been hit since Sunday.
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on July 20, 2014, 07:37:29 AM
Now the land farm is not unmaxing. He has been maxed since Friday, and there have been 4 attacks on him since then.
Title: Re: Why isn't the emp unmaxing?
Post by: The Lady Shael on July 20, 2014, 09:39:07 AM
I'll take a look.

[edit] I'm not sure if there's a bug... I did some testing (and it's possible I missed something) but it looks like the attacks are going down by 2 every day as intended.
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on July 20, 2014, 02:21:02 PM
Well, he unmaxed now, but he wasn't unmaxing the rest of the weekend.
Title: Re: Why isn't the emp unmaxing?
Post by: The Lady Shael on July 20, 2014, 02:30:48 PM
He must have been, if there were 4 attacks on him since Friday, and Friday was two days ago.

How come attack opportunity was removed? Seems like that could avoid this situation.
Title: Re: Why isn't the emp unmaxing?
Post by: Shadow on July 20, 2014, 03:52:49 PM
It was removed just for 3.0 as a way to balance leader vs Indy. We could try adding it back in since leaders are no longer directly productive.
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on July 21, 2014, 02:31:35 AM
Shael, those 4 attacks were the only 4 attacks people could make on him. Which means he wasn't unmaxing like he should have.
Title: Re: Why isn't the emp unmaxing?
Post by: The Lady Shael on July 21, 2014, 05:55:17 AM
I'm still not getting something then. What do you mean by "unmaxing like he should have"? According to the code, he "should be" unmaxing by two attacks per day.

[edit] Okay, took another look at the code. My mistake, it does look like it's supposed to be every hour instead of every day (been a while since I've looked at this code). It looks like it's unmaxing faster now, but I'll keep an eye on it.
Title: Re: Why isn't the emp unmaxing?
Post by: Gen. Volkov on July 21, 2014, 07:27:48 AM
Ok, thanks Shael. Yeah, it should be 2 attacks every hour.