Are you, in fact, a pregnant lady who lives in the apartment next door to Superdeath's parents? - Commodore

Create an account  

 
Pitboss 18 IT and Tech Issues Thread

Looks reasonable to me. Yes, you'll get the "different assets" warning unless both the Pitboss host and you put that in place. So I'm not sure how to test it without disrupting the live game.

As for the scoreboard itself, that's really simple. In CvMainInterface.py, change the line "iBtnHeight = 22" to a smaller number. Here's what it looks like at 14.

   

I'll let Krill or whoever handle the editing and packaging and distribution of that change.
Reply

I'm still thinking about the ranking. Give me a few hours and then we can decide when we pull the trigger on these changes.
I have finally decided to put down some cash and register a website. It is www.ruffhi.com. Now I remain free to move the hosting options without having to change the name of the site.

(October 22nd, 2014, 10:52)Caledorn Wrote: And ruff is officially banned from playing in my games as a reward for ruining my big surprise by posting silly and correct theories in the PB18 tech thread.
Reply

If people think it's worth the hassle to have everybody update for these changes, I would also like to add a dll fix (just one line of code changed) which makes a player's score changes get logged immediately instead of when he logs out.
I have to run.
Reply

As much as I think I'd like these fixes, is this something that will create a problem if even one person doesn't update? We've finally got things moving, and if there's a chance we'd cause a train wreck, I would be hesitant to do so.
I'm just doing my best out here.
Reply

Hey, can people log in normally currently? I'm somehow getting stuck to "finishing".
Finished:
PBEM 45G, PB 13, PB 18, PB 38 & PB 49

Top 3 favorite turns: 
#1, #2, #3
Reply

Same thing happened to me.
Reply

Here is the code for the rank ...

Code:
def getRank(self, aiGroup):
    aiGroup.sort()
    aiGroup.reverse()
    iRank = 1
    for (iLoopValue, iLoopPlayer) in aiGroup:
        if iLoopPlayer == self.iActivePlayer:
            return iRank
        iRank += 1
    return 0

It is a bit of a mess as it doesn't really return the rank. If everyone has the same value, it returns where you are in the array (ie everyone gets a different number) instead of everyone being #1.

To start with, I want to change it to ...

Code:
def getRank(self, aiGroup):
    aiGroup.sort()
    aiGroup.reverse()

    iRequiredValue = 0
    for (iLoopValue, iLoopPlayer) in aiGroup:
        if iLoopPlayer == self.iActivePlayer:
            iRequiredValue = iLoopValue
            break #'exit for loop'
    return 0  <-- this line needs to be removed (thx for the code review Novice)

    iRank = 1
    for (iLoopValue, iLoopPlayer) in aiGroup:
        if iLoopValue == iRequiredValue:
            return iRank
        iRank += 1
    return 0

... that way everyone gets their values rank and not where they ended up in the sorted array. Only really a change when players have the same value.

Re the lurker civ, I think the right change is that their value in the aiGroup collective is set to zero. They will get the bottom rank each and every time smile.
I have finally decided to put down some cash and register a website. It is www.ruffhi.com. Now I remain free to move the hosting options without having to change the name of the site.

(October 22nd, 2014, 10:52)Caledorn Wrote: And ruff is officially banned from playing in my games as a reward for ruining my big surprise by posting silly and correct theories in the PB18 tech thread.
Reply

I just realized - this isn't a pitboss game, it's a hackathon. tongue

Ruff: Your code has everybody get a rank of 0.
Edit: That said, if you remove the first "return 0" your code looks good.

Stuck at "finishing" sounds like a potential server issue.
I have to run.
Reply

(March 23rd, 2014, 15:49)novice Wrote: Ruff: Your code has everybody get a rank of 0.
Edit: That said, if you remove the first "return 0" your code looks good.

Doh. This is why you shouldn't cut and paste code. It is also illustrates that you should have others look over your code (or even run some tests).

Here is the final file, again with the compare back to the base file. I've tested it in a SP game and it works fine (assuming the lurker civ is #16).


Attached Files
.zip   Screens.zip (Size: 828.72 KB / Downloads: 2)
I have finally decided to put down some cash and register a website. It is www.ruffhi.com. Now I remain free to move the hosting options without having to change the name of the site.

(October 22nd, 2014, 10:52)Caledorn Wrote: And ruff is officially banned from playing in my games as a reward for ruining my big surprise by posting silly and correct theories in the PB18 tech thread.
Reply

(March 23rd, 2014, 09:44)Whosit Wrote: So, what screen resolution is recommended to be able to view everything?

I seem to be able to see everything at 1920x1080 fairly easily.

I didn't know anyone ran resolutions lower than that these days.
mackoti Wrote:SO GAVAGAI WINNED ALOT BUT HE DIDNT HAD ANY PROBLEM?
Reply



Forum Jump: