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

[SDK] Advanced Diplomacy

Discussion in 'Civ4 - Mod Components' started by Afforess, Jul 30, 2010.

  1. The_J

    The_J Say No 2 Net Validations Retired Moderator Supporter

    Joined:
    Oct 22, 2008
    Messages:
    32,002
    Location:
    DE/NL/FR
  2. isenchine

    isenchine Empress

    Joined:
    Oct 18, 2010
    Messages:
    1,774
    Location:
    Brussels, Belgium
    I like this mod component but I have a problem with one of its parts. Actually, I don´t like so much the ´Trade Contacts´ possibility and I would like to disable it, either by making it come randomly almost never or by raising the cost of it so much that nobody would be able to afford it! (I´ve tried to put the <iContactRand> in CIV4LeaderHeadInfos.xml to 0 but it does not seem to work).

    On top of it all, I have a bug (maybe I did something wrong in merging it with my mod - xml and python only): each turn, every other Civ would come with the same request all over again if I refuse it.

    Does somebody have an idea on how to fix this?

    Thanks in advance(d diplomacy).
     
  3. dacubz145

    dacubz145 Deity

    Joined:
    Jun 21, 2010
    Messages:
    3,730
    Location:
    Windy City
    When workers are building something, they cant be traded, anyway to disable this?
     
  4. Bataknese

    Bataknese Horas Bah..

    Joined:
    Jun 3, 2009
    Messages:
    51
    Location:
    Indonesia
    After a night without sleep, finally I've managed to merged this mod with RevDCM 2.90 (also with BBAI 1.01). I've tested in game and the mod works well, but a problem still persist, the interface for unit actions won't show up. :cry:
    look at the settler below.

    Spoiler :


    So, i have to press 'B' to build a city. I enter the city screen, but when I want to exit (Esc) this is happened.

    Spoiler :


    what might be the cause?? :confused:
     
  5. The_J

    The_J Say No 2 Net Validations Retired Moderator Supporter

    Joined:
    Oct 22, 2008
    Messages:
    32,002
    Location:
    DE/NL/FR
    If you haven't activated python exceptions (in your normal BtS .ini file) yet, then it's now the time to do it.
    Somewhere is something broken in the merged python, which makes the interface not work properly.
     
  6. Bataknese

    Bataknese Horas Bah..

    Joined:
    Jun 3, 2009
    Messages:
    51
    Location:
    Indonesia
    OK.. Here's the capture

    Spoiler :


    and this is the corresponding codes (red fonts):

    Code:
    # Main Interface Screen
    	if ( argsList[0] == MAIN_INTERFACE ):
    		[B][COLOR="Red"]mainInterface.redraw()[/COLOR][/B]
    	elif ( argsList[0] == WORLDBUILDER_SCREEN ):
    		worldBuilderScreen.redraw()
    	elif ( argsList[0] == WORLDBUILDER_DIPLOMACY_SCREEN ):
    		worldBuilderDiplomacyScreen.redraw()
    	elif ( argsList[0] == TECH_CHOOSER ):
    		techChooser.updateTechRecords(true)

    Code:
    #			BugUtil.debug("dirty PlotListButtons start - %s %s %s", self.bVanCurrentlyShowing, self.bPLECurrentlyShowing, self.bBUGCurrentlyShowing)
    		if ( CyInterface().isDirty(InterfaceDirtyBits.SelectionButtons_DIRTY_BIT) == True ):
    			# Selection Buttons Dirty
    			[B][COLOR="red"]self.updateSelectionButtons()[/COLOR][/B]
    			CyInterface().setDirty(InterfaceDirtyBits.SelectionButtons_DIRTY_BIT, False)
    		if ( CyInterface().isDirty(InterfaceDirtyBits.ResearchButtons_DIRTY_BIT) == True ):
    			# Research Buttons Dirty
    			self.updateResearchButtons()
    			CyInterface().setDirty(InterfaceDirtyBits.ResearchButtons_DIRTY_BIT, False)
    		if ( CyInterface().isDirty(InterfaceDirtyBits.CitizenButtons_DIRTY_BIT) == True ):
    			# Citizen Buttons Dirty

    Code:
    if (CyInterface().getInterfaceMode() == InterfaceModeTypes.INTERFACEMODE_SELECTION):
    			
    				if ( pHeadSelectedUnit.getOwner() == gc.getGame().getActivePlayer() and g_pSelectedUnit != pHeadSelectedUnit ):
    				
    					g_pSelectedUnit = pHeadSelectedUnit
    					
    					iCount = 0
    
    					[B][COLOR="red"]actions = CyInterface().getActionsToShow()[/COLOR][/B]
    					for i in actions:
    						screen.appendMultiListButton( "BottomButtonContainer", gc.getActionInfo(i).getButton(), 0, WidgetTypes.WIDGET_ACTION, i, -1, False )
    						screen.show( "BottomButtonContainer" )
     
  7. The_J

    The_J Say No 2 Net Validations Retired Moderator Supporter

    Joined:
    Oct 22, 2008
    Messages:
    32,002
    Location:
    DE/NL/FR
    :confused: okay, i know that error message, but shouldn't have to do anything with the merge, that's rather a unit problem (not matching .kfm file names).
    -> does it happen only with some units, or always, everywhere?
     
  8. stolenrays

    stolenrays Deity

    Joined:
    Aug 2, 2009
    Messages:
    2,061
    I had the same problem with merging with RevDCM and couldn't figure it out.
     
  9. Bataknese

    Bataknese Horas Bah..

    Joined:
    Jun 3, 2009
    Messages:
    51
    Location:
    Indonesia
    It happens everywhere & persistent.
    As you can see in the screen capture it always happen whenever i started a game. With python exception on, i even can't play the game anymore. :sad:

    edit:
    actually now, its not specific to this mod
    because whatever mod i've merged with RevDCM.. it's always happen
    so.. it must be compiling issues:thumbsdown:

    edit2

    solved!! misconfiguration in compiling :goodjob:
     
  10. VRGS

    VRGS Chieftain

    Joined:
    May 3, 2010
    Messages:
    31
    Location:
    Petrópolis, Rio de Janeiro
    I've been trying to do it for all this Saturday, but as I couldn't do anything at all... I ask you for a chance to have it!
    Are you using along only these two mods?? If so, could you let me have it too??
    Thank you in advance!

    This would be perfect for those who doesn't get along with Civ V and looks for an improved gameplay in Civ IV!
     
  11. Bataknese

    Bataknese Horas Bah..

    Joined:
    Jun 3, 2009
    Messages:
    51
    Location:
    Indonesia
    Yes, i merged these 2 mod with 1 other additional. But now I still have a problem with the scoreboard, it's just won't show up. Maybe i'll fix it first, then i can upload it ;)
     
  12. VRGS

    VRGS Chieftain

    Joined:
    May 3, 2010
    Messages:
    31
    Location:
    Petrópolis, Rio de Janeiro
    Thank you! I'll be waiting for the files!
    :c5goldenage:
     
  13. Cruel

    Cruel King

    Joined:
    Jun 22, 2005
    Messages:
    823
    Location:
    São Paulo, Brazil
    Great mod component!
     
  14. stolenrays

    stolenrays Deity

    Joined:
    Aug 2, 2009
    Messages:
    2,061
  15. Cybah

    Cybah Emperor

    Joined:
    Jun 22, 2007
    Messages:
    1,480
    That would be nice.
     
  16. ripple01

    ripple01 Emperor

    Joined:
    Mar 7, 2006
    Messages:
    1,250
    Location:
    New York City
    I'll eagerly await this as well. :)
     
  17. mwonch

    mwonch Chieftain

    Joined:
    Mar 9, 2006
    Messages:
    49
    Advanced Diplomacy is an awesome component. I've been using RevDCM to practice merging several beloved components, and all has gone well so far. I even got this one working...sort of. The game itself plays flawlessly with these new options, but I think it broke RevDCM's BUG - or part of it.

    You know that text roll at the top-middle that lets you know certain things that are done or can be done during the turn? Well, that's no longer working. Instead, I get that dreaded "BUG Options: Cannot locate settings folder." This also prevents me from permanently changing the BUG settings. I can do it for the game session, but the darn settings revert to default upon exit.

    Just to be sure, I recompiled the DLL WITHOUT Adv. Diplo, and Rev's BUG was working again. Merge Adv Diplo in again, it doesn't. Real head-scratcher, this.

    I've re-checked all the files involved in the merge, and everything checks out there. I'm not sure what's going on.

    See here a RAR file that contains all the adjusted/edited files for the RevDCM/Advanced Diplomacy merge: http://forums.civfanatics.com/attachment.php?attachmentid=308931&d=1323613320. Everything is there, including the compiled DLL, and ALL source/project files. If someone could take a quick look to see what the problem might be, I'd really appreciate it.

    If I can get this working, I'm going to adjust further to see if I can get Advanced Diplomacy 2 working (as promised on another thread). Really would love to get this working right, guys. Can anyone help?

    Thanks in advance!

    Mike
     
  18. mwonch

    mwonch Chieftain

    Joined:
    Mar 9, 2006
    Messages:
    49
    Never mind! I have resolved the problem. For anyone who has the same problem in the future, this is what I did:

    1. Turn ON Python exceptions

    2. Pay close attention to EVERY message. Most do not really effect game play, but one or two of them will

    In my case, it was the CVModName.py file. I had the wrong mod name. I changed it and the message scroll now works as it should (without sacrificing the mod itself).

    One line...one stupid seemingly unimportant line/file. Wow...
     
  19. Vanya

    Vanya Chieftain

    Joined:
    Oct 30, 2011
    Messages:
    37
    hi to all. and happy new year

    can someone make an mod which enable the possibility to offer a war against another ai in conjunction.

    i'll explain myself.

    now i can

    1. agree on request of the AI to start a war against another AI

    2 request to an AI to start a war against another AI (but it can "think" alone)

    i would like to have the option to offer a war in conjunction with me in order tha if it agree at the end of the diplomacy the game put both in war against the 2 AI.

    and if possible i would like to offer my war against his enemy (an AI with it is already at war) in the diplo screen in order to negotiate my aid and not to wait passively its request for free (which generally are fool)

    plz make this mod.
     
  20. Sgtslick

    Sgtslick Emperor

    Joined:
    Mar 15, 2002
    Messages:
    1,685
    Gender:
    Male
    Location:
    Melbourne
    I play ROM - AND
    I use advanced diplomacy but it has one glaring problem.

    Trading resources for tech etc.
    I have to turn off military unit trading because trading corn you can get like 15 cannons etc. Totally unrealistic.

    I also make a little rule where if I trade a resource for gold or a tech it can't be cancelled for 25 turns instead of 10 (this is on marathon).
    If I were to be able to get 1 modern tech every 10 turns off someone obviously this is ridiculous.

    My point is.
    Can I restrict trading so that you can only trade tech for tech, resources for resources (maybe some cash too), contacts for contacts, military for military, maps for maps etc..
    The AI pays waaaaay too much contacts too - so I have to turn that option off aswell.
     

Share This Page