1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

[mod] simple reminders

Discussion in 'Civ4 - Mod Components' started by eotinb, Nov 29, 2005.

  1. eotinb

    eotinb Ancient and Hermetic

    Joined:
    Sep 14, 2005
    Messages:
    409
    Location:
    Buffalo
    reminder v1.0
    by eotinb

    this mod is part of the eotinb mod suite

    A simple mod to give yourself reminders

    INSTRUCTIONS:

    Unzip file to My Documents\My Games\Sid Meier's Civilization 4\CustomAssets\python\ (or equivalent)
    !!!DO NOT OVERWRITE FILES IN GAME DIRECTORY!!! (i.e. C:\Program Files\Firaxis Games\Sid Meier's Civilization 4\Assets\Python)
    The three following files will be added:
    CvEventManager.py
    CvUtil.py
    reminder.py

    In order to facilitate combining with other mods that also change CvEventManager.py and/or CvUtil.py (including my other mods), the additions have been noted in these files. Feel free to cut and paste to combine.

    FEATURES:

    Alt+R: Creates a popup window in which you set the number of turns until the reminder goes off and the text of the reminder. When that turn comes around, your reminder will appear as a message on the screen and in the event log (but only for a few turns). Also an alarm noise will play to get your attention. You can have as many reminders pending as you like. As of now there is no way to eliminate a reminder (other than passing the turn it is set to go off) or any way to view the current reminders. If I get ambitious, I may include these features in a future version. Or if somebody else wants to do that, feel free and I will gladly include your changes in my mod.

    SCREENSHOTS:


     

    Attached Files:

  2. eotinb

    eotinb Ancient and Hermetic

    Joined:
    Sep 14, 2005
    Messages:
    409
    Location:
    Buffalo
    Just wanted to give a couple of ideas as to how this could be useful:
    1. "Right. When Orleans hits size 2 in 3 turns I want to make sure the new citizen works the mined hill and then switch it to a worker." ... 4 turns later ... "Crap!"
    2. Set yourself an alarm at the beginning of your SG turnset to tell you when your 10 (or however many) turns are up
     
  3. BeefontheBone

    BeefontheBone Windbag of the sea

    Joined:
    Nov 7, 2005
    Messages:
    2,018
    Another neat idea. Handy for switching to worker or settler in the early game - I tend to think "might as well let the city grow in 2 turns before switching" and then forget all about it.
     
  4. homegrown

    homegrown Missionary of Sorenism

    Joined:
    Jan 5, 2002
    Messages:
    203
    Location:
    Houston TX
    I have written a Save Reminder script I've been using to remind me to save every 20 turns (with a picture of my dog as the graphic) :woohoo:. This will be an incredible addition to that. Thanks.
     
  5. Stilgar08

    Stilgar08 Emperor

    Joined:
    Nov 6, 2002
    Messages:
    1,449
    Location:
    Zeven, Germany (Lower Saxony ;)
    Very good! Found your thread via your sig in the GOTM's - Maybe you should link it in the Utility-programs-forum?

    Thanks!!! :)
     
  6. Roland Johansen

    Roland Johansen Deity

    Joined:
    Apr 29, 2003
    Messages:
    4,292
    Location:
    the Netherlands
    Thank you for this mod. I'm at the moment using it to remind me when cities grow (and some other things). I read that you were planning to create a utility/mod that adds ingame log entries when cities grow and other events occur. Are you still planning to create such a utility? I would be very interested. Especially when clicking on the log entry centers the map on the city that has just grown (that happens with the other ingame log entries).

    One request concerning this reminder mod:
    It uses the shortcut ALT-R to activate. But ALT-R is also used to build roads and railroads to a certain location and to rebase air units. We now can not use these shortcuts in combination with your mod. Could you choose a shortcut that doesn't conflict with other shortcuts that already exist in the game?

    Again, thank you for this very useful mod.:goodjob:
     
  7. eotinb

    eotinb Ancient and Hermetic

    Joined:
    Sep 14, 2005
    Messages:
    409
    Location:
    Buffalo
    Roland, sorry about overwriting the existing Alt+R shortcut. I will change it to another key -- do you have any suggestions?

    As for the notifications mod, I still plan to do it, but it's not a priority right now. I did release the code that notifies when cities grow along with instructions for how to make it work, over here.
     
  8. Roland Johansen

    Roland Johansen Deity

    Joined:
    Apr 29, 2003
    Messages:
    4,292
    Location:
    the Netherlands
    Absolutely no reason to apologize, it's your mod, you decide how it works. But now you're asking, I would suggest SHIFT-R. When looking in my manual, I don't see it listed as a shortcut and the shortcut still uses the R of reminder.

    Good to hear that you're still planning to do it. Such a mod could help civvers play the game a lot (depending on what notifications are added). I already think that the ingame notifications were a good step of Firaxis.
    Thank you for the code; I added it and it actually worked (I expected to make a mistake or something like that). Is there an editor that makes editing python files easier? I was afraid that adding stuff would mess with the format of the file and corrupt the file. I must admit that I don't know anything about python (yet).
     
  9. RobO

    RobO King

    Joined:
    Jan 3, 2001
    Messages:
    836
    Location:
    Slangerup, Denmark
    Where is the Alt+R shortcut assigned? It's bugging me and I'd like to change it.
     
  10. Hamato

    Hamato Chieftain

    Joined:
    Dec 13, 2005
    Messages:
    12
    I'm new to mods so maybe I'm doing something wrong but I didn't get it to work. I unzipped the files to the correct folder and loaded my savegame. But Alt+R didn't do anything. Can somebody tell me what's wrong?
     
  11. RobO

    RobO King

    Joined:
    Jan 3, 2001
    Messages:
    836
    Location:
    Slangerup, Denmark
    I found the Alt+R shourtcut. It's in CvEventManager.py

    Look for this line:
    if (theKey == int(InputTypes.KB_R) and self.bAlt):
    and change bAlt to bShift
     
  12. RobO

    RobO King

    Joined:
    Jan 3, 2001
    Messages:
    836
    Location:
    Slangerup, Denmark
    Hamato, if you have more than one mod then chances are high that they don't easily mix, that is that they update the same file so that you need to manually cut and paste to get all of them to work.

    Check out Alerum's unaltered game play mod, he did all the dirty work for you and has a lot of good stuff, including this reminder mod.
     
  13. Hamato

    Hamato Chieftain

    Joined:
    Dec 13, 2005
    Messages:
    12
    Thanks but this is the only mod I use and I want to use. But could it have something to do with the fact I'm using the german version of the game and winXP (maybe folder names are english defaults in the mod files)?
     
  14. RobO

    RobO King

    Joined:
    Jan 3, 2001
    Messages:
    836
    Location:
    Slangerup, Denmark
    Sorry, I can't help you there. Perhaps someone else who has a German version can. Or perhaps you're placing the files in the wrong folder, though the readme is quite explicit on that point.
     
  15. Spocko

    Spocko Warlord

    Joined:
    Dec 18, 2005
    Messages:
    168
    Location:
    Dover, New Hampshire
    I noticed that while it is possible to "stack" more than one reminder messages, each time they are displayed, I get an error - something about index out of range. Still, the reminders display anyway :)

    SO, I will try to see how I can tweak this mod to allow multiple reminders without complaining about an index out of range.

    Great mod!
    Spocko
     
  16. jray

    jray King

    Joined:
    Jan 31, 2006
    Messages:
    925
    Location:
    North Carolina (USA)
    I happened upon an amusing glitch last night... I set a reminder "switch to theocracy" (for the next turn) in a game, then got wiped out a few dozen turns later, then started a new game. When I got to about the same year in the new game, I saw the "switch to theocracy" reminder! I know I hadn't accidentally set another one like it, since I didn't even have Theology. I hadn't used any reminders at all in the new game, actually. Anyway, I just thought I'd mention it in case anyone else has seen it before too.

    Awesome mod, especially for remembering to change civics and control forest chops!
     
  17. Spocko

    Spocko Warlord

    Joined:
    Dec 18, 2005
    Messages:
    168
    Location:
    Dover, New Hampshire
    ... However, when I comment out

    # del self.reminders

    in def onBeginPlayerTurn, in my eventManager, the reminders work fine - I can queue up more than one message and they display at the correct turn.

    The commented line generates an "index out of range error".

    What is a better way to delete the just-displayed reminder?

    THanks!!
    Spocko
     
  18. jray

    jray King

    Joined:
    Jan 31, 2006
    Messages:
    925
    Location:
    North Carolina (USA)
  19. jkp1187

    jkp1187 Unindicted Co-Conspirator

    Joined:
    Aug 29, 2004
    Messages:
    2,496
    Location:
    Pittsburgh, Pennsylvania
    Just curious -- is this mod ok for use with BtS? I know it's part of the BUG and can be disabled via the BUG's option screen, but I didn't want to install the entire BUG mod, just to get this feature.

    Thanks.
     
  20. Wessel V1

    Wessel V1 Emperor

    Joined:
    Sep 10, 2007
    Messages:
    1,417
    Location:
    Nijmegen
    For RFC this will be very very very useful thanks:)
     

Share This Page