[mod] Log changes

Is the current version v1.1? Also is this compatible with patch 1.09, or a better way to ask would be are there changes in the 1.09 versions of the python files this mod is based on? That might be a hole in the whole modding process, for mods which require manipulation of the existing game files.

A minor bug, because of the way "research begun" events are posted, if you set a list of techs to research, all of the techs in the chain show as beginning research.
Turn 78 (925 BC)
Research begun: Mathematics
Research begun: Drama
Research begun: Music
Kyoto begins: Settler
 
Dave, this is based off of the events that are generated by the game. I've noticed that if you select one tech to research then select another one, they'll both show up. In your instance, it might be good to show them all so that the next in line knows that multiple techs are selected.

And yes v1.1 is the latest revision. If anyone wants to colorized version let me know and I'll send it to them. eot (understandably) wants to keep his code his code. That way if someone has a problem with it then he doesn't have to weed through my code to figure out what's wrong.
 
Same thing happens if you are indecisive about builds and set a build then change it, then change it back, then change it to something else; each change initiates a log entry for "Starts build". Can be annoying.
 
Tubby Rower said:
If anyone wants to colorized version let me know and I'll send it to them. eot (understandably) wants to keep his code his code. That way if someone has a problem with it then he doesn't have to weed through my code to figure out what's wrong.

I'd like to get a copy, or at least see how you coded it; still learning the ins and outs of the files.
 
Here is the only file that I changed for the color. I think that there might be something wrong with the custom log entry but I'll look at that today. Basically all I did is
- copy the "message = blah blah blah" line and paste it right below it.
- rename the pasted variable to "logmessage"
- added the appropriate vbCode tags
- renumbered the changes to their appropriate numbers (there was some spots called autolog change XX/XX) I think that there are ~ 30 additions in there.
- changed all of the lines like "self.log.write(1, message)" to "self.log.write(1, logmessage)"

That's it. the reason for the additional variable is that some of them were reported on the screen and the vbCode tags were showing up. So I just made a copy that had them for the log
 

Attachments

@DaveShack: I haven't gotten around to cleaning up v1.1, which is why I haven't updated the first post. I haven't checked the 1.09 patch Python files, but I've been running v1.1 of my mod with the patch installed and haven't seen any problems. As to the annoyances you and Civgeek mentioned, those are due to the way the events work in the game, and I don't see an easy workaround -- I'm still going for the low-hanging fruit, so any fixes to those problems are in the future.
 
@eotinb,

I gotta throw up my hands. autolog will not run at all. Not sure what's happening. Read through the thread and made sure the directory existed but ALT+E or CTRL+T gets nothing.

Any ideas?
 
eotinb said:
As to the annoyances you and Civgeek mentioned, those are due to the way the events work in the game, and I don't see an easy workaround -- I'm still going for the low-hanging fruit, so any fixes to those problems are in the future.

Not really a problem; just requires some post-game edting and clean-up of the log file (which I do anyway to expand on my own in-game comments).
 
Bede, which version are you using? 1.0 is on the first post of this thread, but I also posted a rough version of 1.1 a page or so back. If you are using 1.1, do you get the popup window on game load or game start asking for the fiile name you want to use? I'm guessing not. For either version, is it creating a file in the directory you specified? If Alt+E isn't doing anything, I'm guessing it's not loading at all. Check that the path directory does not end with a backslash ("C:\Bede" is OK but "C:\Bede\" gives some people problems).

If the files are in the right place and there isn't a problem with the path variable, I'm not sure what else could be giving you trouble. If error logging is not turned on (in My Documents\My Games\Sid Meier's Civilization 4\CivilizationIV.ini -- LoggingEnabled = 1) turn it on and see what kind of error messages you get. If it says something along the lines of "Failed to load CvEventManager.py" that usually means there was a path problem. If it says something else, let me know and I'll see if I can decipher it.

Sorry this is giving you so much trouble. I hope you find it worth the effort (assuming you ever get it working).
 
@eotinb, I am sure it will be worth the trouble. I will start the debugger and see what messages I get.

i have tried renaming the path with C:\ and C:\\ to no effect.

And I get the same lack of response with either 1.0 or 1.1 and as far as I can tell nothing in the setup instructions changed.

But now that i know where to find the debugger that will help.

Thanks
 
@Bede: Are you naming the autolog file at the start of the game? I've found on my computer whenever I name the file other than the default none of the Ctr-E, Alt-E, Ctr-Tab, nor even the Escape key works.

As long as I leave it with the default name it works just fine.

Unfortunately I haven't been able to try the suggestion given me about not adding numerical digits in the name so am unsure if that was causing the problem.
 
Don't even get an option to name the file at the start. And the only line I changed in the autolog.py file was the directory path using cut and paste from the adress bar and adding \\ as needed.
 
That's just odd Bede. And what you report does not match with my experience Methos. I had no problem creating and adding to LK108.txt for my most recent turns there.
 
Bede, that's really strange that it isn't working. I'll take a crack at some diagnostic questions, sorry that some of them seem pretty obvious but you'd be surprised how many obvious questions turn into forehead slaps on the other end. :D

Here's my "path" line from the autolog.py file. Just an offhand question to start with, you don't have any non-printable characters in the directory you want to use, and you've already created the directory, right?

Code:
path = "C:\Documents and Settings\david\My Documents\My Games\Sid Meier's Civilization 4\Saves\succession"

Do you have the 3 files installed in the customassets folder off the my documents path? Any non-printable or other strange characters in this path on your system? On my system it is here:

Code:
C:\Documents and Settings\david\My Documents\My Games\Sid Meier's Civilization 4\CustomAssets

Also did you make any modifications to the CivilizationIV.ini file? I have no idea what might break it but it's a possibility. Also it will work best if AutoSaveInterval = 1 is specified, but I expect pretty much everyone will have updated that as soon as they found out about it.

[edit]
BTW my path does not have any double backslashes, just singles.
Also I had Python installed on my system before Civ4. If the others who have it working had Python and you don't that would be an interesting little tidbit.
[/edit]
 
@Dave, the only modification I made to the .ini file was to set FullScreen mode to "ask" as I found that worked best for handling screenshots and such. If autolog works I won't have to do that as I can then make an entry followed by the screenshot number. So I will change it back and see what happens.

Thanks for the review as it always helps me to see someone else wrtie it all down in a logical fashion.

Edit: And now it works!!! Interesting to say the least. This has metamorphosed from a trial to a triumph.
 
Bede said:
Edit: And now it works!!! Interesting to say the least. This has metamorphosed from a trial to a triumph.
:dance: looks like your a computer nerd after all Bede ;)
 
Messing around with the mod and have a few questions/observations.

In the autolog.py file there is several statements that begin with EVENT_LOG_....=0 or 1. Typically 0 equals false and 1 equals true, yet this doesn’t seem to follow along with the way my turnlog came out. So my question is what does the 0 and 1 mean?

Edit: Looking further into the file makes me wonder if the 0, 1, and possibly 2 are actually indications of how the log is shown.

Moved the mod into CustomAssets and renamed the original files to their original names. Checked everything in CivIV and it works great. In fact the mod works better now than it did before. Prior to this I was unable to use anything other than the default autolog.txt file. Now I can individually name them. Surely moving it to the CustomAssets folder wasn’t what was causing the problem? Oh well, its working now.
 
Back
Top Bottom