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

More Luxuries

Discussion in 'Civ5 - Mod Components' started by Barathor, Aug 7, 2013.

  1. lockstep

    lockstep Prince

    Joined:
    Jan 15, 2004
    Messages:
    391
    Location:
    Vienna, Austria
    Too many plantations? ;-) I hope that the +1 Culture from Plantations will survive in a modified form.
     
  2. janboruta

    janboruta Artistriarch

    Joined:
    Feb 23, 2011
    Messages:
    2,140
    Location:
    Tarnów, Poland
    New features sound great, can't wait! What about adding some bonus resources as well, like Rice, Timber or Corn? (mods that add them are obviously incompatible with yours :( )
     
  3. AbsintheRed

    AbsintheRed Deity

    Joined:
    Jul 27, 2009
    Messages:
    8,263
    Location:
    Szeged, Hungary
    That would be great! Rice, Maize/Corn, Pigs, Prime Timber, Clam, Lead, maybe some of Bison, Potatoes, Barley, Flax, Sulphur.
    Also Honey as a new luxury resource, while I would move Crab and Marble to bonus resources. Probably Copper and Tin too.
    And if you are really into it, you can also add Perfumes and Glassware as city-state resource. Those don't really change anything after all, but I would love some diversity there too.
     
  4. janboruta

    janboruta Artistriarch

    Joined:
    Feb 23, 2011
    Messages:
    2,140
    Location:
    Tarnów, Poland
    Very nice list of additions, even though too large for the game ;) As for city-state luxuries, it would be great to integrate More Luxuries mod with Sukritact's More Mercantile mod, which has a very good variety of resources, like Artifacts, Paintings, Furniture. I guess he would have nothing against it if you asked him, I believe his resources already appear in some overhaul mods.
     
  5. AbsintheRed

    AbsintheRed Deity

    Joined:
    Jul 27, 2009
    Messages:
    8,263
    Location:
    Szeged, Hungary
    Yeah, but maybe there is room for a couple more ;)

    I don't really like Manuscripts, Paintings, Furniture and Artifacts in that mod. Neither of those suits city-states well IMO.
    Glassware and Perfumes would be perfect there though. Maybe Corals as well, after seeing Barathor's fantastic icon :)
     
  6. lockstep

    lockstep Prince

    Joined:
    Jan 15, 2004
    Messages:
    391
    Location:
    Vienna, Austria
    "A designer knows he has achieved perfection not when there is nothing left to add, but when there is nothing left to take away." ;)
     
  7. Galgus

    Galgus Emperor

    Joined:
    Aug 22, 2012
    Messages:
    1,695
    It might be excessive, but would Wonders tied to any if the luxuries make sense?

    I'm not sure it would count fully as a wonder, but it would be a nice was to see the Amber Room.
     
  8. Gilgamesch

    Gilgamesch Ancient Alien

    Joined:
    Dec 15, 2010
    Messages:
    2,228
    Location:
    good old germany
    Wow amazing looking icons dude:salute:.

    May i ask you if we could use some of your icons for the CCTP mod?
    Would be perfect addition.
     
  9. Barathor

    Barathor Emperor

    Joined:
    May 7, 2011
    Messages:
    1,202
    Thanks, Gil, and of course, go right ahead.
     
  10. Over_9000

    Over_9000 Chieftain

    Joined:
    Jan 18, 2011
    Messages:
    13
    Location:
    Tundra
    AWESOME work! I think modification and optimization AssignStartingPlots.lua is a HELL. So you are my hero now lol.
    Also it seems a good idea for me to merge this mod with Resource mods for GnK and BNW (FramedArchitect did a good job adding suitable buildings and even units). FramedArchitect made bonus recources that are converting into luxuries by special buildings and it's a gooood idea.
    And smth else. FramedArchitect added Timber, but I think that TimberMod by Hulfgar is more logical.
    Just thinking. I will try to bring this ideas to life and ask permission to use your wonderful AssignStartingPlots. :crazyeye:
    But I am not a coder at all. Pechal'ka.
    Spoiler :
    Am I right thinking that after your 'increasing of the hard-cap number of total resources the game utilizes to 75' there is no more need in changes of this number? Sorry for my English :blush:
     
  11. Barathor

    Barathor Emperor

    Joined:
    May 7, 2011
    Messages:
    1,202
    Thanks! :D

    Yes, please feel free to use it! That's why I took all the time commenting and adding notes to the file, to make it easier for modders to find what they need, want to remove, or if they have any suggestions or ideas for it. Just do a case-sensitive search for "MOD" and it'll jump to each modification, along with the note.

    You probably don't have to increase the cap. But, it's always better to verify it, because it was a devious little error for me to track down when I initially discovered it by adding a 6th new luxury.

    The default game uses a cap of 45. The default game alone has 40 resource types, so there's only room for 5 new ones.

    With my increase of it to 75, and using the new luxuries here, you'll have room for a total of 27 new resources. ;)
     
  12. AbsintheRed

    AbsintheRed Deity

    Joined:
    Jul 27, 2009
    Messages:
    8,263
    Location:
    Szeged, Hungary
    So you don't plan to add anything else?
    Not even for city-states?
     
  13. Barathor

    Barathor Emperor

    Joined:
    May 7, 2011
    Messages:
    1,202
    I personally have no plans to and don't believe city-states need any more either -- okay, well, maybe 1 or 2 more mercantile city-state luxuries would be nice. :)

    I won't be adding any just for the sake of having more -- I don't really believe in doing that. Which is the same reason I don't add any bonus-type resources; there really isn't a great need for them. Their role is to simply to supplement the existing terrain and normalize things, and I believe it's all pretty much covered. But, again, that's just me.

    For the map script I've been developing and will pick up on again soon, it requires exactly 8 more luxury types in order to function at a specific world size. Originally, it was less, but I was persuaded by others and started to rework some numbers and 8 more luxuries actually turned out to work very nicely, so I dished out some more.

    If I ever have the time, I could certainly create some more icons or "try" to make new graphics for others to use. Though, so far I've only been successful with replacing plantation resource graphics, the other ones are a bit beyond my understanding. :sad:
     
  14. Over_9000

    Over_9000 Chieftain

    Joined:
    Jan 18, 2011
    Messages:
    13
    Location:
    Tundra
    Yeees, I did it that way (with Notepad++ it was too easy btw). And your comments are really helpful. Thank you again and thank for your help :3
     
  15. lockstep

    lockstep Prince

    Joined:
    Jan 15, 2004
    Messages:
    391
    Location:
    Vienna, Austria
    Any time frame for the update? Also, will you eventually release an "Optimized Luxuries" version (fixes, support for 12 unique regional luxuries), or should I start to delve into your modified AssignStartingPlots.lua?
     
  16. Barathor

    Barathor Emperor

    Joined:
    May 7, 2011
    Messages:
    1,202
    Yeah, I could probably update it today as I'm sitting down to do some gaming and then gonna play around with a bit of modding too. (The wife is away until tomorrow afternoon! :banana:) I'll put it at the top of my list. :D

    As for the Optimized Luxuries mod, I've already finished most of it. I just need to tweak GetWorldLuxuryTargetNumbers and determine some new values so it corrects the section that places random luxuries and doesn't always set it equal to the lux_minimum value. Especially, with only 4 types being placed for Huge maps, if only 5 of the first, 4, 3, and then 3 of the last type are placed on the whole map -- no good! (adding, of course, any additional types placed at roughly 25% of the city-state total and added as a 2nd type at start locations.)
     
  17. Barathor

    Barathor Emperor

    Joined:
    May 7, 2011
    Messages:
    1,202
    Updated More Luxuries with random luxury totals which match the existing game. With the new method I added to determine the different totals, I added a new part which will adjust the random luxury total according to world size.

    Spoiler :


    I also found some more things to fix while working on this update, and got caught up in it a bit. :crazyeye: But, I decided to go back to a backup and just change the totals for now and release it while I continue to work on the other things.
    • 1) One inefficiency I've found has to do with some luxuries and regional placement. I noticed this because I was paying careful attention to the totals on revealed maps I was generating for my other pantheons mod. Luxuries like Dyes, Spices, and Silk (and some others) often don't meet the regional luxury target total. Also, when this happens, the game ignores it and moves on.

      I believe this is due to a few reasons:

      a) The obvious one is if the luxury isn't flexible enough and is very selective. For example, Silk's primary is flat, non-tundra forests and its secondary is flat jungle, that's it. Foliage can be limited already, but if hills pop up underneath as well, it lessens the total tiles available in the region even more.

      The solution to this is to add more flexibility to luxuries and skew realism a bit. This is already seen with some of the luxuries and I've supported this too with some tweaks to the existing ones and handling the new luxuries this way (like Cocoa being found in non-tundra forests as well). So, it looks like I have some more tweaks to make.

      Also, another solution which could help would be allowing some plantation resources on hill tiles which meet their requirements (terrain/foliage). I tested it and the graphics work fine and adjust to the height levels. I don't believe it's unrealistic either, as I'm sure there are ones which exist on hillier terrain and regions (like tea plantations, for example), especially if they don't require machinery to roll along and harvest them. Citrus already does this, and the new Cocoa. Also, we're already allowed to farm fresh water hills, and conversely, mined resources are found on flat lands.

      And yet another option would be to create a function similar to the FixSugarJungles one which, for example, searches for a luxury type that was initially placed on a bare tile and then converts it to a forest or jungle to meet its needs in the end. Another could be to search for a luxury that is normally found on flat terrain, but was placed on some hills to improve its chances for placement, and then convert the hill tile to a flat one. In the end, it all works out nicely to the player, and they're unaware of the "cheats" during map creation.

      b) If a luxury only has a few plot list indices, and not four, and especially if they're selective ones, the game will have trouble placing all of the luxury that it needs to since the primary and secondary placement only use a ratio of 0.3 (so for every 10 eligible tiles, it will place 3, rounded up).

      A solution to this is to maybe increase the initial ratios of the primary and secondary placements, perhaps up to 0.5. But, I'll have to test it to make sure it doesn't overdo it and place too many on one type of tile, before going to the next index(es).

      Another solution is to add a whole new fallback method after the initial four placements if the target hasn't been met. The new four placements will use a ratio of 1 so it'll be allowed to place an additional luxury even if it finds only 1 eligible tile of the type. I think I like this method more, since you can keep the existing ratios in the initial placement methods, and just clean things up with this one if needed. (I already have this implemented in the version I'm working on.)

      c) Radius values from the impact site. Currently, they're fairly random from a value of 0 to 3. If you think about it though, 3 is really big (equals the area of workable tiles by a city)! It can easily block out a big chunk of potentially eligible tiles, especially in forest/jungle areas which tend to cluster together.

      A solution to this is to limit the maximum radius of 3 to either 1 or 2. I personally prefer 1, and is what I'm testing right now. The regional plot list is initially shuffled anyway, so that already helps spread things out randomly. Plus, a radius of 1 makes things much more flexible. I'm also considering raising the minimum radius of 0 to 1 as well, since I don't like clustering and like things sprinkled about more.

      Now, this may have one repercussion involving "random" luxury placements later on, as there will be more "holes" around the impact sites of the regional luxuries. Though, I thought of a solution to this which can also enhance the way random luxuries are placed: creating a separate impact table for the random luxuries. So, when regional luxuries are placed, they also emit larger ripples which affect the random luxuries, but have no affect on other regional luxuries which need to be placed and will be ignored. (I also may have more plans for the random luxuries involving impacts and ripples so that each type can reliably be placed throughout the whole map, and not cluster at all -- each regional type should cluster in an area... random types should be spread out!)​
    • 2) Another inefficiency has to do with regional "water" luxuries. I was horrified when I came across one of the AI regions and they only received ONE copy of their regional luxury. It was Pearls, but could've happened to any of the water types. That's a pretty severe handicap to start with.

      I believe this one was due to:

      a) The initial check made for water luxuries when assigning roles to luxuries and checking for regional luxury qualifications. In this, when a water luxury is chosen as a possible candidate for a regional luxury, it has additional checks made. It can't be in a region type that the devs decided to block each one from (Whales/Jungle, Pearls/Tundra, Crab/Desert), the civ within the region needs a coastal start, and lastly (this one is probably the problem) the region needs to have at least 12 coastal water tiles.

      Yeah, only 12. If you look back up top, you can see that a regional luxury can potentially have a radius of 3 from the impact site. That can easily block out all the tiles in a region that barely meets the minimum requirements with one placement! Even if the coast is a thin, single-tile band along the land, a luxury placed with a radius of 3 could easily block off 7 out of the 12+ tiles. In addition to this, a decent amount of those coastal tiles are going to be off limits anyway. This is because the start is going to be coastal, therefore, any tiles which fall within the cities workable radius will also be off limits too, as these areas are handled differently with regards to bonus and luxury placements on the map, and are controlled more tightly.

      A solution to this is, again, to limit the maximum radius to 1. Also, I believe the 12 coastal tile requirement should be increased by 150% to 30. This will make things a little stricter for the water luxuries if they want to become regional. (I personally believe they work better as randoms anyway -- I almost restricted them all only city-state/random in another mod, but decided not to. Instead, I may just guarantee that at least one water luxury is chosen for city-states to use.)
    • 3) This one I already explained in another post above: how the random luxury placement method is somewhat broken and basically places only the minimum number of each random luxury type, since the world luxury target numbers are way off. So, on Standard with 5 random luxuries, for each type it'll place 4, 3, 3, 3, 3 during random luxury placement. On Huge with 8 random luxuries, i'll place 5, 4, 3, 3, 3, 3, 3, 3 during random luxury placement.

      I'm working on fixing this so it at least functions the way it was supposed to. I may even simplify it a bit, since a lot of the methods don't seem really necessary and are a bit overboard.

      Though, while messing with this, I came across yet another error! Within the printouts, where it shows each luxury total and the total world luxury count -- the total world one is way off! On Standard, with standard settings, it'll display an average number around 130. Really, though, this average number is only around 100.

      I tracked this down and I found the culprit. It has to do with the function PlaceSpecificNumberOfResources, which increments the variable totalLuxPlacedSoFar within it. The problem is, the file uses this function at times for non-luxury resources, instead of using ProcessResourceList! :crazyeye:

      Luckily, totalLuxPlacedSoFar is only utilized by the random luxury placement methods AND all luxuries are usually placed before any bonus or strategic types. Though, one example is if you use the Strategic Balance option. With that, it'll place strategics earlier and it'll increment totalLuxPlacedSoFar. So, once I fix the random luxury placement methods, I'll have to address this or else it'll break it again when the option is used!

      So far, the other functions I've found which cause the problem are: AddModernMinorStrategicsToCityStates, PlaceSexyBonusAtCivStarts, and PlaceOilInTheSea.

      For accurate printouts during testing, I came up with a simple solution. I created a new variable called realtotalLuxPlacedSoFar. At the end of all luxury placements, I simply set realtotalLuxPlacedSoFar equal to totalLuxPlacedSoFar before it gets corrupted with non-luxury additions.
     
  18. bouncymischa

    bouncymischa Synthetic Genie

    Joined:
    Nov 28, 2012
    Messages:
    1,537
    Location:
    In a bottle
    Just figured I'd drop a note to say I noticed this mod last week and was eager to try it out! Finally got the chance on the weekend -- while my own civ was a homemade one with a desert start, and thus ended up with incense and some rather abundant silver deposits, Brazil ended up north of me with some extensive ebony reserves, while a couple of the nearby city states have Tobacco. I've also seen Chocolate in a couple of spots.

    Haven't gotten to any of the other continents yet to see what they might have, but it was definitely fun and cool to see. Luxuries are one of my favorite things about Civ, helping to give each civilization a somewhat unique identity (on top of all their other unique traits, and a quality that varies from game to game), so it's cool to have more to play with!

    Now I just have to add in that mod for more luxuries for mercantile city-states... I used to have one of the older ones, and it was always fun to check what each city-state ended up with. :3
     
  19. Eduardo Dacal

    Eduardo Dacal Chieftain

    Joined:
    Dec 2, 2009
    Messages:
    73
    Location:
    Rio de Janeiro - Brasil
    Some questions/sugestions/wishes:

    - What do you think about ebony being supplied by lumbermills intead of plantations

    - I tried to use this mod in the World Builder from the tools of the steam but it didn't work. Does it work?, I mean, can I place these resources the place I wish?

    - This mod is really cool, but what do yyou think of making some more luxury resources for CS?
     
  20. Eduardo Dacal

    Eduardo Dacal Chieftain

    Joined:
    Dec 2, 2009
    Messages:
    73
    Location:
    Rio de Janeiro - Brasil
    Some questions/sugestions/wishes:

    - What do you think about ebony being supplied by lumbermills intead of plantations

    - I tried to use this mod in the World Builder from the tools of the steam but it didn't work. Does it work?, I mean, can I place these resources the place I wish?

    - This mod is really cool, but what do yyou think of making some more luxury resources for CS?
     

Share This Page