williamleonard / obblm

Automatically exported from code.google.com/p/obblm
1 stars 0 forks source link

Help with custom script #298

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Because of the rules of the league I am in,I run a custom script to 
generate extra SPP.

Nicholas helped me with a custom SQL query and a script to run it, but I 
have found an issue with it. I am by no means skilled in SQL, so I cant 
really figure out why it this issue occurs.

The thing is, that in my league, a player is awarded half a SPP for each 
match they have played (and this is all we use extra SPP for). But several 
of the coaches have now seen the following.

A player who is MNG, and therefore not able to play a match, is still 
rewarded the extra half SPP. Only players who can play the match should be 
awarded this half SPP.

Can any of you SQL and OBBLM wizards out there help me modify the attached 
script to fix this?

Original issue reported on code.google.com by syko...@gmail.com on 25 Nov 2009 at 4:50

Attachments:

GoogleCodeExporter commented 9 years ago
I can't view it right now, but I would think that using the built in OBBLM 
libraries
would be the best solution.  Also instead, you could probably use the new 
trigger
system in OBBLM to award these SPPs after a match is created, you'd also have 
to do
something when deleted or reset.  Of course these triggers are in version .8 
which
hasn't been released yet.  It shouldn't be that long though.

Original comment by funnyfin...@hotmail.com on 25 Nov 2009 at 6:01

GoogleCodeExporter commented 9 years ago
Sune, the 0.8 version has features that allow you to do this easily, it's just 
not
ready yet.
I'd suggest you wait a little while for 0.8 - making manual changes when needed 
until
0.8 is ready.

Original comment by Nimda...@gmail.com on 25 Nov 2009 at 11:46

GoogleCodeExporter commented 9 years ago
It sounds great with 0.8. However, right now I have several players in my 
league who
gain skills ahead of time, because they earn SPP while being marked as MNG.

But if the query needed is not just a quickfix, I will wait for the 0.8 release 
:)

Original comment by syko...@gmail.com on 26 Nov 2009 at 8:15

GoogleCodeExporter commented 9 years ago
Try this.

Original comment by Nimda...@gmail.com on 26 Nov 2009 at 9:11

Attachments:

GoogleCodeExporter commented 9 years ago
Just tried it. It seems the player is registered as having played the match,
eventhough they were marked as MNG. I'm guessing that it is because of this, the
extra SPP script calculates the "wrong" value. The script does its job, but the 
data
on the player is wrong.

Bottom line is, that the new script does not do what I want it to :-/

Original comment by syko...@gmail.com on 27 Nov 2009 at 11:46

GoogleCodeExporter commented 9 years ago
I really need more info. Is the dspp field unchange after running this? It 
should not
count the MNG-matches now.

Original comment by Nimda...@gmail.com on 27 Nov 2009 at 12:38

GoogleCodeExporter commented 9 years ago

Original comment by Nimda...@gmail.com on 20 Dec 2009 at 8:00