1. We have added the ability to collapse/expand forum categories and widgets on forum home.
    Dismiss Notice
  2. Photobucket has changed its policy concerning hotlinking images and now requires an account with a $399.00 annual fee to allow hotlink. More information is available at: this link.
    Dismiss Notice
  3. All Civ avatars are brought back and available for selection in the Avatar Gallery! There are 945 avatars total.
    Dismiss Notice
  4. To make the site more secure, we have installed SSL certificates and enabled HTTPS for both the main site and forums.
    Dismiss Notice
  5. Civ6 is released! Order now! (Amazon US | Amazon UK | Amazon CA | Amazon DE | Amazon FR)
    Dismiss Notice
  6. Dismiss Notice
  7. Forum account upgrades are available for ad-free browsing.
    Dismiss Notice

Worlds Unlimited (formerly 'Large World Fits All')

Discussion in 'Civ5 - Map Scripts' started by skweetis, Nov 9, 2010.

  1. skweetis

    skweetis Chieftain

    Joined:
    Mar 14, 2008
    Messages:
    58
    Location:
    Canada
    Cheers Ceph! ;)

    and while we're here...

    BETA 4 is up.
    • Revamped and reorganised script from ground up. More control = better map results!
    • Custom Map Size Randomizing: Anywhere from 68x38 to 128x72 @ a 16:9 proportion.
    • Map Size option only used to get number of players! (affects this map only)
    • User scalable Land Area by City Count per Major Civ!
    • Tweaked generator values in an attempt to produce 'natural' looking worlds.
    • Plenty of override options for personal control!
     
  2. skweetis

    skweetis Chieftain

    Joined:
    Mar 14, 2008
    Messages:
    58
    Location:
    Canada
    *** NOT CURRENTLY AVAILABLE THROUGH THE IN-GAME MOD BROWSER. *** Having troubles with uploading it there... I'll check again later.
     
  3. skweetis

    skweetis Chieftain

    Joined:
    Mar 14, 2008
    Messages:
    58
    Location:
    Canada
    Well, for whatever reason, Beta 4 is listed as "Denied" for the In-Game Mod Browser. I changed a few things like removing the link to this thread, and special characters, incremented to version 5 (because you can't override or delete whatever you upload) but even Beta 5 won't upload... it says Failed for Duplicate Record, even though there is no version 5 up there. Tried changing the GUID...no dice....

    Guess it's only available from here now. Shame, Cause I took 3 down, and it won't let me put it back up....

    Ah well...
     
  4. skweetis

    skweetis Chieftain

    Joined:
    Mar 14, 2008
    Messages:
    58
    Location:
    Canada
    And just in case anyone wants to use the land scale by players method with their own script, here it is as a function to paste in your script, and call to get your water percent value.

    Code:
    ----------------------------------------------------------------------------------------------------------------------------------|
    -- THIS NEEDS TO GO IN GetMapScriptInfo().  Change GetCustomOption(<index>) to suit your needs.
    -- For GetWaterPercent() Custom method: Land Scaling by Number of Cities per Players and City-States
    -- Use in your own script, just please remember to credit ColBashar and I.  Thanks!
    ----------------------------------------------------------------------------------------------------------------------------------|	
    		{-- Override Land Scale
    				Name = "Land Scale Target:",					-- overrideLandScale = Map.GetCustomOption(6) -- based on target 25 tiles per city
    				Values = {										-- Val	PlotsPerCiv
    						"3 Cities/Civilization",				-- 1	75
    						"4 Cities/Civilization",				-- 2	100
    						"5 Cities/Civilization",				-- 3	125 <-Default
    						"6 Cities/Civilization",				-- 4	150
    						"7 Cities/Civilization",				-- 5	175
    						"TXT_KEY_MAP_OPTION_RANDOM"				-- 6	??? 
    					},
    					DefaultValue = 3,
    					SortPriority = 1
    			},
    ----------------------------------------------------------------------------------------------------------------------------------|
    
    
    
    
    
    
    
    
    ----------------------------------------------------------------------------------------------------------------------------------|
    -- GetWaterPercent() Custom method: Land Scaling by Number of Cities per Players and City-States
    -- Code based on Tyson Guttwein's (ColBashar) variation of my Land Scale by Player Count concept. 
    -- Use in your own script, just please remember to credit ColBashar and I.  Thanks!
    ----------------------------------------------------------------------------------------------------------------------------------|	
    function GetWaterPercent()
    	print("S>-----------------------------------------------------------------------------------|");
    	print("S>-----Get Water Percentage: START!");
    	print("S>--------------------------------------------------------------------5.0");
    
    --Declare and initialise variables and constants	
    	local X, Y = Map.GetGridSize();
    	local major_civ_count	= 0;
    	local minor_civ_count	= 0;
    	local tiles_per_city	= 19; -- Constant: This is based on calculation of Firaxis default... I may be off... TODO: Make this user selectable????
    	local tiles_per_state	= 35; -- Constant
    	local extra_land		= 3;
    	local water_percent		= 0; 
    	print("S>-----Land Tiles per Target City/Civ:", tiles_per_city);
    	print("S>-----Land Tiles City State:", tiles_per_state);
    
    --Collect custom options
    	local land_scale = Map.GetCustomOption(6);  -- YOU WILL NEED THIS CUSTOM OPTION SETUP
    	local sea_level = Map.GetCustomOption(4);	-- sea_level core option
    	print("S>-----Land Scaling override:", land_scale);
    	print("S>-----Sea Level override:", sea_level);
    
    --Do randomising and perform other evaluations.
    --Cities per Civilization override selection
    	if land_scale == 6 then -- user chose Random
    		land_scale	= 3 + Map.Rand(5, "S>-----Rolling Land Scale Option:");
    		print("S>-----Rolled Cities per Civ:", land_scale);
    	else 
    		land_scale = (land_scale + 2); -- need to bump it up by two, as option values represent 3 to 7 Cities per Civilization		
    		print("S>-----User Cities per Civ:", land_scale);
    	end
    	
    	tiles_per_city = math.ceil(tiles_per_city * land_scale); -- tiles per city * option value
    
    --Sea Level override selection
    	if sea_level == 4 then
    		sea_level	= 1 + Map.Rand(3, "S>-----Random Sea Level");
    	end
    
    --This is for WorldBuilder compatability -- 
    --Simulate random Civ values coming in from Map Size...
    	if worldSize == nil then	-- if map size is nil, then we are in WB
    		major_civ_count, minor_civ_count = 2, 4; 
    
    		local sim_map_size_roll	= 1 + Map.Rand(6, "S>-----Roll Map Size Sim");	
    
    		major_civ_count = major_civ_count * sim_map_size_roll;
    		minor_civ_count = minor_civ_count * sim_map_size_roll;
    
    	end
    	
    	
    	-- DEBUG 
    	-- major_civ_count, minor_civ_count = 2, 4;  -- override random for testing in WB
    	-- DEBUG
    	print("S>-----Map Grid Size:", X, "x", Y);
    	print("S>-----Total Number of Map Plots:", X * Y);
    	print("S>-----Civs and States:", major_civ_count, minor_civ_count);
    	print("S>-----Major Civ Land Plots: ", major_civ_count * tiles_per_city);
    	print("S>-----Minor Civ Land Plots: ", minor_civ_count * tiles_per_state);
    
    --Set the number of land tiles by tiles_per_city by major_civ_count and minor_civ_count
    	local land_total = math.abs((major_civ_count * tiles_per_city) + (minor_civ_count * tiles_per_state));
    	print("S>-----Pure Total Land Plots:", land_total);
    
    --Adjust extra_land according to selected Sea Level
    	if sea_level == 2 then					-- Normal: 4-6%
    		extra_land = 4 + Map.Rand(3, "S>-----Random Normal Extra Land %"); 
    		print("S>-----Land increased by: ", extra_land, "%");
    	elseif sea_level == 1 then				-- Low: 7-9%
    		extra_land = 7 + Map.Rand(3, "S>-----Random More Extra Land %");
    		print("S>-----Land increased by: ", extra_land, "%");
    	else									-- High: 1-3%
    		extra_land = 1 + Map.Rand(3, "S>-----Random Less Extra Land %");
    		print("S>-----Land increased by: ", extra_land, "%");
    	end
    
    --Increase land total by extra land percentage
    	extra_land = math.abs((extra_land / 100) + 1.00)
    	land_total = math.ceil(land_total * extra_land);
    	print("S>-----Adjusted Total Land Area: ", land_total);
    
    	local total_map_plots = (X * Y);
    --Collect water percentage for map size.
    	water_percent = math.abs((total_map_plots - land_total) / total_map_plots * 100);
    	water_percent = math.floor(water_percent + 0.5)
    	water_percent = math.clamp(water_percent, 5, 95);
    	print("S>-----Ocean Percentage for Player Count: ", water_percent);
    
    	return water_percent;
    end
    ----------------------------------------------------------------------------------------------------------------------------------|
     If you use it, please remember to credit ColBashar and I.  Thanks!
    
     
  5. skweetis

    skweetis Chieftain

    Joined:
    Mar 14, 2008
    Messages:
    58
    Location:
    Canada
    So much to do, so little time. Lots of play testing and study have produced the final result. Unfortunately, my real-world schedule is getting busier these days, which means I will have less time to work on all the things I had hoped to.

    In play testing, I found that a lot of my map creation options (the rediculous mountain counts, etc.) spoiled some of the playability. The more I examined, tested and tweaked, the closer I got to Firaxis' values. I guess that's why they get the big bucks.

    I have played a few games and am really pleased with the gameplay and aesthetic. I have included a number of Advanced Setup options for map creation, defaulted to my personal taste, so that users can customise their world as they see fit.

    Now with the new patch, Random Map Size is working again, which brings the map back to my original intent! Just finishing up the documentation part of things, a few minor tweaks, and I will release the final stable build as 'Your World' in the next few days, so keep an eye open for it.

    So please Let this thread rest, I'll resurrect it when I finish my map collection and utilities, and release Worlds Unlimited as a map pack.

    Thanks!
     
  6. Buddhakeks

    Buddhakeks Chieftain

    Joined:
    Jan 20, 2011
    Messages:
    5
    Is there a way to use that in Multiplayer?

    and how do i install it?
     
  7. skweetis

    skweetis Chieftain

    Joined:
    Mar 14, 2008
    Messages:
    58
    Location:
    Canada
    There is actually. However, I need to remove the existing copies and ask that people delete whatever versions of this they have. While on hiatus, I have been doing some extensive study and research to get better understanding. It turns out I found that the Hieght of the map must be an even number, or the AI and other Game Logic gets screwie if the Height is an odd number. The map sizes I have, and random methods and whatnot can produce odd numbers...

    I'm currently working on updating and improving these, but am waiting for a more stable and working version of Civ 5 and the Mod tools before continuing, pretty frustrated with the state of things, hard to bug test your own work when the core you are building on is already buggy.

    Rest assured I will be back, I'm using this time wisely to focus more on design and learning.

    Cheers.
     
  8. ColBashar

    ColBashar Chieftain

    Joined:
    Nov 3, 2010
    Messages:
    32
    I don't mean to state the obvious but...

    math.floor(mapHeight * .5 + .25) * 2

    I -really- hope that hasn't been holding you up, Skweetis. <s> I wouldn't hold my breath that Firaxis is going to accommodate odd-numbered height dimensions in their maps any time soon. If I were to guess, chances are that it's not so much a bug as a programming convenience for the engine.

    For good measure, Rhineland script is designed to set map dimensions as multiples of four. It used to be eight but I lowered it when I saw the stock scripts were so.
     
  9. Jabberwockxeno

    Jabberwockxeno Chieftain

    Joined:
    Jul 10, 2012
    Messages:
    487
    Can we get some screenshots?
     

Share This Page