TheLopez said:So let me summarize what you are asking for:
You want to be able to stack the units in the city screen and allow them to stack using multiple rows?
That is a very interesting idea.Impaler[WrG] said:I had an idea for an improvment to your stacker mod.
Normaly their is no visual feedback as to what the maximum number of alowable specialists is. I propose a stack of the faded/translucent specialist heads equal to the cap. As the player increeses or decresses specialist counts the translucents turn opace to indicate an actual specialist. When the cap is zero (like on a new city) then no transulent heads are displayed and neither are the buttons (theirs realy no point if they cant do anything).
This I'm sorry to say is not very possible since you could have more specialists than the ones being displayed. If you want to see an example of this just go into world builder and increase the population of one of your cities to 10 and add a bunch of citizens, you'll see that in the vanilla game only 6. Of course with the specialist stacker mod you can show all of them, but I do have to consider the case when they are not, you know what I mean?Impaler[WrG] said:If your realy ambitious I would like to see thouse little + and - buttons removed and instead control specialist counts by clicking directly on the heads, clicking on a translucent head sets it and all heads to the right of it to active specialists. Click on an Opacue head and all the heads to the left become transulent. Likewise using the scroll wheel of the mouse in increment up or down when moused over the specialists would be very nice.
import CvUtil
from CvPythonExtensions import *
#<GREAT STATESMAN START>
import CvCustomEventManager
normalEventManager = CvCustomEventManager.CvCustomEventManager()
#<GREAT STATESMAN END>
# **********************************
# GJD Alerts modifications start here
# **********************************
customEventManager = CvCustomEventManager.CvCustomEventManager()
def getEventManager():
return customEventManager
# **********************************
# GJD Alerts modifications end here
# **********************************
def getEventManager():
return normalEventManager
def onEvent(argsList):
'Called when a game event happens - return 1 if the event was consumed'
return getEventManager().handleEvent(argsList)
def applyEvent(argsList):
context, playerID, netUserData, popupReturn = argsList
return getEventManager().applyEvent(argsList)
def beginEvent(context, argsList=-1):
return getEventManager().beginEvent(context, argsList)
wotan321 said:TheLopez,
I really do appreciate all the hard work you have put into all these mods, they really add a lot to the game.
But I broke this one when I tried to add in the PlotListEnhancements mod by 12Monkeys, too. Now my specialists aren't stacked, they are in a single column on the right side of the city screen. A
What have I done wrong? Any help is appreciated.
Below is the python code from the CvEventInterface.py file.
Hmmm... that's wierd since this mod has been working fine for months... It's even included in the HOF mod.Caesium said:That's weird.
When using your modcomp and trying to add a specialist to the city by clicking on a city-worked plot this specialist ist set higher on the screen than the inactive specialist.
wotan321 said:Okay, if you would please, patiently step this Non-programmer through the logic of this file. I have read a bit of the tutorials available here and at Apolyton about Python, so I have a bit of understanding.
Below is my original code from the CvEventInterface.py file.
#<GREAT STATESMAN START>
import CvCustomEventManager
This "great statesman" snippet is from the GPTricklePlus componant.... the above "import" is bringing in the code in the CvCustomerEventManager.py file.
normalEventManager = CvCustomEventManager.CvCustomEventManager()
Next, the variable normalEventManager is created and given the data from the CvCustomEventManager, and that normalEventManager can be referenced later in this file....?
#<GREAT STATESMAN END>
# **********************************
# GJD Alerts modifications start here
# **********************************
customEventManager = CvCustomEventManager.CvCustomEventManager()
So here I load the data of CvCustomerEventManager again, this time for use by the variable customEventmanager.
def getEventManager():
return customEventManager
What does the above 2 lines do? In any case, here I am referencing back to customEventManager.....
# **********************************
# GJD Alerts modifications end here
# **********************************
def getEventManager():
return normalEventManager
... and here I do the same thing again, but with a different file. So at this point, is the data from customEventManager even available for use, since the later def statements refer back to getEventmanager, and that has been overwritten. Is that the problem?
If you could shine some light on this issue for this fledgling python programmer, I surely would appreciate it. (and so would many other confused people). I guess there is no way to work with events without learning python...so that is what I will do.