Results 1 to 16 of 16

Thread: Was Able to Partly Move a Settlement

  1. #1

    Default Was Able to Partly Move a Settlement

    Hello,

    So I decided to play with the regions.

    As you can see from the image I was able to move the settlement base, as for moving the other pieces, the coordinates have been moved in one location but I am guessing there is another location, then I assume the roads will cause trouble and I will have to find a way to fix those.

    Take a look at the screenshot.
    http://www.twcenter.net/forums/showthread.php?t=260572

    Game Scripter @ Reverie World Studios

  2. #2

    Default Re: Was Able to Partly Move a Settlement

    It seems that different files may represent different parts of the settlement. Keep at it harshman_chris, if you find a way to move the whole settlement let us know (it would be helpful if there was a list of the files and what they do).
    Morning Sun (adds Korea and China to the Shogun 2 map)
    http://www.twcenter.net/forums/forum...28-Morning-Sun

    Expanded Japan mod (97 new regions and 101 new factions)
    http://www.twcenter.net/forums/showt...ew-factions%29

    How to split a region in TWS2
    http://www.twcenter.net/forums/showt...split-a-region

    Eras Total Conquest 2.3 (12 campaigns from 970-1547)

  3. #3

    Default Re: Was Able to Partly Move a Settlement

    Alright, I have spent the last day going over all the files, and I cannot find any more position values, this leads me to believe that there are undiscovered values that we cannot see in the various esf files.

    It appears that the settlement base is controled by coordinates alone, but the slots, which include the ones inside cities have additional values that control were they are placed.

    But I cannot find any value that could even resemble these yet, I am still looking further, but whether I can find them is yet unknown.
    http://www.twcenter.net/forums/showthread.php?t=260572

    Game Scripter @ Reverie World Studios

  4. #4

    Default Re: Was Able to Partly Move a Settlement

    If you read the tutorial on adding slots to cities, you'll find everything you need to know on how to do this, including moving the road.

  5. #5
    alpaca's Avatar Harbinger of saliva
    Join Date
    Sep 2005
    Location
    Germany
    Posts
    4,811

    Default Re: Was Able to Partly Move a Settlement

    Actually, does moving the roads work? I think they are saved in the rigidmodels folder as splines so you'd have to crack the format and edit those.

    The biggest problems would be changing borders and adjusting pathfinding though.

    No thing is everything. Every thing is nothing.

  6. #6

    Default Re: Was Able to Partly Move a Settlement

    Quote Originally Posted by alpaca View Post
    Actually, does moving the roads work? I think they are saved in the rigidmodels folder as splines so you'd have to crack the format and edit those.

    The biggest problems would be changing borders and adjusting pathfinding though.
    I duno if it moves the roads yet, I am not moving any borders, but the biggest issue with moving them is that the selection is still in the old location, have not figured that out yet.

    Plus I am going to try roads, then we will see about what happens
    http://www.twcenter.net/forums/showthread.php?t=260572

    Game Scripter @ Reverie World Studios

  7. #7
    Alex1987's Avatar Tiro
    Join Date
    Apr 2009
    Location
    Russia, Krasnodar region
    Posts
    247

    Default Re: Was Able to Partly Move a Settlement

    harshman_chris,
    great work! May you write any tutorial about moving settlements? It will be very usefull!

  8. #8

    Default Re: Was Able to Partly Move a Settlement

    I took it a step further but needs more to be done.





  9. #9

    Default Re: Was Able to Partly Move a Settlement

    So, how about the tutorial?

  10. #10

    Default Re: Was Able to Partly Move a Settlement

    Very impressive. Things might finally be moving forward This is very good news. If you can give me some basic steps to do this I can start trying to figure more out. I just haven't gotten into modding with Empire for some reason... But this has intrigued me.

  11. #11

    Default Re: Was Able to Partly Move a Settlement

    There is a last serious problem to be solved: you have to click on the old position to access the removed items (the city to access town and the town to access city). Other than that it works... fine.




  12. #12

    Default Re: Was Able to Partly Move a Settlement

    You changed the settlement coordinates in regions.esf? Because those are the only coordinates I can find.....

  13. #13

    Default Re: Was Able to Partly Move a Settlement

    Quote Originally Posted by A1_Unit View Post
    You changed the settlement coordinates in regions.esf? Because those are the only coordinates I can find.....
    There are coordinates in startpos. If I remember correctly, they're the two last Ints in this screenshot. Check out the tutorial on adding city slots. It tells you where everything is.


    Last edited by erasmus777; October 16, 2009 at 06:53 PM.

  14. #14

    Default Re: Was Able to Partly Move a Settlement

    That's not what I meant ( I know about the startpos.esf coordinates, I was only talking about regions.esf). Did you edit the regions.esf coordinates and did that make the selection zone move?

  15. #15

    Default Re: Was Able to Partly Move a Settlement

    Quote Originally Posted by A1_Unit View Post
    That's not what I meant ( I know about the startpos.esf coordinates, I was only talking about regions.esf). Did you edit the regions.esf coordinates and did that make the selection zone move?
    Yes, but in startpos there are more places you have to change the grids. Here are all changes needed to be done:

    startpos.esf:

    1. In REGION/REGION_SLOT_MANAGER. Here you have to replace the grids in both slots you exchange locations. Also you have to replace the grids in SETTLEMENT/SIEGEABLE_GARRISON_RESIDENCE using these of the new city location. Last you have to recalculate new grids for ROAD and FORTIFICATION slots. I'll upload a spreed sheet for that. Note down the building slot Id of the town for later use.
    2. In CAI_WORLD_REGIONS/CAI_REGIONS record of the region that settlements belongs to. CAI_WORLD_REGIONS you'll find also CAI_SETTLEMENT Id.
    3. Go in CAI_WORLD_SETTLEMENTS/CAI_SITUATED and enter the new grids.
    4. Using CAI_SETTLEMENT Id spot the CAI_WORLD_BUILDING_SLOT of the town (or any facility) you used to exchange locations with the city. It should be a record with number after this of the SETTLEMENT. If, for example CAI_SETT. Id is 1710, the one of the town should one of the next (1711, or 1712, etc.). To find which one is it check CAI_WORLD_BUILDING_SLOT/CAI_BUILDING_SLOT the building slot Id of the town. There in 3rd line there is CAI_WORLD_REGION_SLOT number.
    5. Now you can proceed in CAI_WORLD_REGION_SLOT and make the last change in startpos for the new location of the town in CAI_SITUATED.

    In regions.esf:

    1. The slot_descriptions of both facilities (city and town)
    2. In settlement_and_slots enter the new grid of the city.
    3. Recalculate the grids for roads and fortification slots (use my spreadsheet).

    There are more changes to be done in other files (poi.esf, pathfinder.esf) and in startpos. These changes are not necessary for now and don't solve the problem of clicking the old location in order to access the new one. Also these entries are in endless lists and take many hours (or days) to be spotted.

    EDIT: Spreadsheet has been uploaded as an attachment.
    EDIT: The spreadsheet is usefull only for minor cities. For major you can use erasmus777's which can been found it in my tuto "How to convert a minor city to a major one"
    Last edited by husserlTW; October 18, 2009 at 06:17 PM.




  16. #16

    Default Re: Was Able to Partly Move a Settlement

    Do you think city selection could have something to do with the UI?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •