Need help finishing a mod

The Carp

Chieftain
Joined
May 6, 2003
Messages
42
Location
Paris
So I made a mod that increase the starting distance between civs and city state.

Here's what I have so far

Spoiler morepsace.modinfo :

Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- edited with Notepad++ by RedPawn -->
<Mod id="f9458daf-9378-4470-8fd9-bc782f2d1a4e">
    <Properties>
        <Name>LOC_REDPAWN_MORE_SPACE_NAME</Name>
        <Stability>Alpha</Stability>
        <Teaser>LOC_REDPAWN_MORE_SPACE_TEASER</Teaser>
        <Description>LOC_REDPAWN_MORE_SPACE_DESCRIPTION</Description>
        <Authors>LOC_REDPAWN_MORE_SPACE_AUTHORS</Authors>
        <SpecialThanks>LOC_REDPAWN_MORE_SPACE_SPECIAL_THANKS</SpecialThanks>
    </Properties>
    <Files>
        <File>morespace.xml</File>
    </Files>
 
    <Settings>
        <Custom id="morespaceSetting">
            <Items>
                <Component>morespaceComponent</Component>
            </Items>
        </Custom>
    </Settings>
   
    <Components>
        <UpdateDatabase id="morespaceComponent">
            <Properties>
                <Name>LOC_REDPAWN_MORE_SPACE_COMPONENT_NAME</Name>
            </Properties>
            <Items>
                <File>morespace.xml</File>
            </Items>
        </UpdateDatabase>
    </Components>
   
    <LocalizedText>
        <Text id="LOC_REDPAWN_MORE_SPACE_COMPONENT_NAME">
            <en_US>RedPawn's More Space</en_US>
        </Text>
        <Text id="LOC_REDPAWN_MORE_SPACE_AUTHORS">
            <en_US>RedPawn</en_US>
        </Text>
        <Text id="LOC_REDPAWN_MORE_SPACE_SPECIAL_THANKS">
            <en_US>Special thanks go out to Reddit user /u/malvekair</en_US>
        </Text>
        <Text id="LOC_REDPAWN_MORE_SPACE_DESCRIPTION">
            <en_US>Increased starting distance between Civilizations and City States</en_US>
        </Text>
        <Text id="LOC_REDPAWN_MORE_SPACE_TEASER">
            <en_US>More Space</en_US>
        </Text>
        <Text id="LOC_REDPAWN_MORE_SPACE_NAME">
            <en_US>RedPawn's More Space</en_US>
        </Text>
    </LocalizedText>   
</Mod>

Spoiler morespace.xml :

Code:
<?xml version="1.0" encoding="utf-8"?>
<!-- edited by RedPawn -->
<!-- -->
<!-- This mod only changes the starting distance between Civilizations and City States.  -->
<!-- -->
<GameInfo>
    <GlobalParameters>
       
        <Replace Name="START_DISTANCE_MAJOR_CIVILIZATION" Value="15" />
       
        <Replace Name="START_DISTANCE_MINOR_CIVILIZATION" Value="10" />

    </GlobalParameters>
</GameInfo>


The mod seems to be loading fine and the new values are correctly loaded in the sqlite database but it doesn't seem to have changed anything with the actual starting distances.
I even did a test with 20 for both values but I still had some City States and Civs spawning closer than that.

My guess is that I need to add some lua scripting to make use of the new values but I'm not sure what function I'd need to overextend.

Any help would be greatly appreciated
 
Well it seems like they are the same except yours is also pushing back the barbarians.

So based on what you wrote in the description it looks like mine was "working" after all.
It's just that it's not really working on standard sized map.

Thanks for the help
 
I made a version that scales by map size, sort of. Technically I cheated and used the default number of minor civs since that worked out to be almost exactly the number I wanted.

You have to be careful, I didn't see any error checking to prevent cases of not enough room for starting positions so it's easy to break.

I'm at work right now so I don't have the code with me but I plan to upload my mod this weekend. It has this change in it as well as a "fix" for land reaching the poles and some other map generation tweeks.
 
The Carp - Yours isn't working or mine isn't on the Standard map?

Thought I tested on standard map, but then again, I have huge spacing, so I may only have tested on the huge+ maps.

Yea, I'm not a fan of barbarians being all up in my face from start of game.


Seven05 - I'd be curious to see that code... I'd much rather have a dynamic spread even if it is 'cheating'. :D
 
Sorry, I meant that I thought mine wasn't working since in my tests (on standard size) Civs and City States were showing closer than the limit I had set.
But according to what you wrote it seems like that's normal since they would still be placed closer if the terrain wasn't allowing them to be placed farther.
 
Back
Top Bottom