Results 1 to 14 of 14

Thread: hidden resources

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default hidden resources

    Hey guys,
    I've been working on a mod in which each faction can only recruit units in their "home" provinces. I've created hidden resources like 'english' or 'french' and put them in all the provinces, but I've run into a problem. There are certain units which overlap, and I can't seem to find a way to make it so that you can recruit a unit of, for example, mounted seargents with either hidden resource english, or hidden resource french. Is there a way to do this? If not, could I create separate units of mounted seargents in the export_descr_unit file for each faction? Let me know what you think. Thanks.

  2. #2

    Default Re: hidden resources

    Okay, so it was working for a little while. I just went through the EDB file and created separate units for each faction that shared a unit. ex. I made mounted sergeants unit that required faction HRE and hidden_resource german. But now it's just crashing all the time. Anybody have any ideas?

  3. #3
    Lonck's Avatar Centenarius
    Join Date
    Jun 2006
    Location
    mah couch
    Posts
    851

    Default Re: hidden resources

    Post your log.txt there may be something helpful there. And I don't think I understand your problem. You can copy/paste a unit and just change the type name. That unit will be the same as the one you copied it from. Dunno if I'm helping with that last statement.

  4. #4

    Default Re: hidden resources

    crackerjack1348
    You may want to have super-regions, eg Europe, hence mailed knights can be recruited in Europe as they can be recruited by France, England, HRE etc., where as a Lancers could only be recruited in France.

    To err is human, but to really foul things up you need a computer.
    Paul Ehrlich

  5. #5

    Default Re: hidden resources

    recruit_pool "Peasants" 1 0.1 3 0 requires factions { england, } and hidden_resource aor_england or hidden_resource aor_wales or hidden_resource aor_ireland or hidden_resource aor_scotland or hidden_resource aor_france or hidden_resource aor_flanders or hidden_resource aor_germany or hidden_resource aor_switzerland or hidden_resource aor_scandinavia or hidden_resource aor_iberia or hidden_resource aor_n_italy

  6. #6
    Gigantus's Avatar I am not special - I am a limited edition.
    Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    52,682
    Blog Entries
    35

    Default Re: hidden resources

    Quote Originally Posted by Lord_Phan View Post
    recruit_pool "Peasants" 1 0.1 3 0 requires factions { england, } and hidden_resource aor_england or hidden_resource aor_wales or hidden_resource aor_ireland or hidden_resource aor_scotland or hidden_resource aor_france or hidden_resource aor_flanders or hidden_resource aor_germany or hidden_resource aor_switzerland or hidden_resource aor_scandinavia or hidden_resource aor_iberia or hidden_resource aor_n_italy
    That looks like the PDER way of doing it.










  7. #7

    Default Re: hidden resources

    Well I made my mod for Stainless Steel 5.1 and I was looking at some of the other mods for SS and I found one called "the AI survival script". Basically it spawns armies for the AI factions when they're getting their butts kicked and they're losing settlements. So that combined with my mod is making pretty much all of the larger AI factions stay alive. I'm at turn 100 in a test campaign, and so far only Portugal is dead. It's really turning out awesome.

    Since the AI can't just start pumping soldiers out of a settlement it just captured, it's giving the defenders a chance to counterattack and regain their territories. Some territories which aren't represented by factions, ie the Neatherlands, I didn't assign a culture to so that nobody could gain a really strong foothold there and that has proved to be pretty cool. I'm playing as France so its been a 3 way battle between me England and the HRE for control of the low countries. At first I was the dominant power there, but I had trouble holding on and England kicked me out. Now the HRE is moving in and England is losing ground.

    I think all of this is really awesome, because it makes conquering a faction really hard. Which I think is historically accurate. Medieval France never conquered all of Germany, there's no way it could have. Feudalism doesn't allow for that kind of projection of power.
    Last edited by crackerjack1348; April 12, 2008 at 11:54 PM.

  8. #8

    Default Re: hidden resources

    AHHHHHHH!!!! It was going so well, now it's crashing! I'll see if I can find something in the error log and post it if I can't figure it out.
    Last edited by crackerjack1348; April 13, 2008 at 01:13 AM.

  9. #9

    Default Re: hidden resources

    I've been trying to figure out the error log thing, but I don't really know how it works. If I figure out how to get the log.txt file, while it show me which line the program crashes on? I figured out what was making it crash the first time and I've gotten quite far, but I've run into another crash.

    Also, where did you get that text Lord Phan? If that works it might save me a little time.

    Just kidding, I found the error file. It makes things a lot easier. Thanks guys
    Last edited by crackerjack1348; April 11, 2008 at 10:56 AM.

  10. #10

    Default Re: hidden resources

    The whole reason I'm doing this by the way, in case anybody was wondering, is because I get really annoyed when a random AI faction conquers half the map, or is pushed out of it's home. In one game Scotland only had two provinces in Scandinavia, and Denmark only had the two dutch provinces... which I found retarded.
    So I'm editing the files so that factions can only recruit units in their home provinces. Hopefully the logistics involved in moving armies all over the place as well as the lowered production capacity will slow the AI down so that they'll stay basically where they started.

  11. #11

    Default Re: hidden resources

    Keep me posted on how this comes. I like the sound of it. Maybe you could also add something where after a faction owns a regions for so many turns/years only then is it able to recuirt any units there....kinda like a reconstruction period while the region slowly converts to the new ruling faction

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

    Default Re: hidden resources

    Just a reminder: Disjunction ("or") has a higher priority in M2TW than conjunction ("and"), so you need to rephrase some statements in order to arrive at expressions where you only have "or" in the innermost brackets

    So if you want: (england and resource england) or (france and resource france) you need to use boolean algebra to transform it, taking care that the or has higher priority, and write:
    requires factions { england, } or factions { france, } and factions { france, } or hidden_resource england and factions { england, } or hidden_resource france and factions {france, } or hidden_resource england

    Doing it like that probably made sense for CA because they didn't want brackets so left-to-right interpretation would be a problem I believe. They should have used prefix-notation in my opinion

    No thing is everything. Every thing is nothing.

  13. #13

    Default Re: hidden resources

    Javolenus,

    I forgot to check the log file and I just reloaded my game and kept playing it and it didn't crash. So I don't know what happened, but its working fine now. I can give you the files if you want them, but all I did was edit the EDB file and the descr_regions file, both of which are SS 5.1. I would also recommend Turbo's AI survival script, it really works well with my recruitment mod. Let me know if you want the files, or if you're playing a different mod or vanilla or something I can tell you how to change your files manually.

    Also, your idea of editing the victory conditions sounds awesome. Please let me know how you did that. I think between the two of us we could make a mod that's half-way realistic!
    Last edited by crackerjack1348; April 13, 2008 at 06:46 PM.

Posting Permissions

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