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

Revised Roman Empire

Discussion in 'Rhye's and Fall Modmods' started by Bonci, Jun 27, 2010.

  1. Bonci

    Bonci King

    Joined:
    Oct 22, 2005
    Messages:
    738
    Location:
    Tridentum - Italia
    Main goal of the scenario
    This scenario tries to model a realistic and historically correct rise and fall of the roman empire giving to the artificial intelligence and the player the tools to achieve what the romans did in real life :p

    This is going to be developed with the PyScenario of the mighty Baldyr :goodjob:

    Current status
    I'm in the early part of the developement of this scenario, so any help would be apreciated :p

    At the moment the AI has lots of predetermined flips and unit spawns so the randomic caracteristic of a normal game is partially removed. (I've tried to not use the flips, but AI is too stupid and keeps disbanding the units that i give to it)
    For the player I'm thinking to only give the units spawns and the predetermined declarations of war but i haven't written nothing for now about that.

    Problems
    - Some civs are going to become almost impossible to play (Greece,Carthage,Egypt, Babylon) but it could be a very interesting opportunity to try to change history :)
    - In this period i have very very little time to spend on civ (damned exams) so i can't promise nothing about the updates.

    Future plans
    After the main work on the roman empire itself is done i'm planning to write some events for every civ that was involved in the history of the empire.

    Download Alpha version here
    http://www.megaupload.com/?d=LVFR60ZG
    this is a very early version and only the AI has received unit spawns and city flips...please try it and let me know if there are bugs ;)

    to install the scenario just unpack the files in the "Rhye's and Fall of Civilization\Assets\Python" folder
    WARNING:this archive contains a modified version of consts.py so be sure that you backup your original file before overwriting it

    Spoiler :


    PS: Sorry for my very bad english :(
     
  2. Baldyr

    Baldyr "Hit It"

    Joined:
    Dec 5, 2009
    Messages:
    5,530
    Location:
    Sweden
    What events would the unit spawns for the human player represent? :confused: And you mean that other Civs will declare on the Romans according to a script? (And not that the human player will be forced into declaring.)
    There is actually a way to prevent select AI Roman events from happening if some of the neighboring Civs are human controlled. With all the Trigger bindings and whatnot in the last PyScenario update. (You label a Trigger something like "Human Greece" and have it fire if the human player is Greek. Then you condition the Roman event with not the "Human Greece" event not been fired. You could prevent any Trigger you like from being fired this way.)

    Speaking of PyScenario, I think I actually finished all the work I've been planing to include in the beta version today. :goodjob: I'm currently working on the documentation and checking everything up, so expect to have all the stuff mentioned in the PyScenario thread at your disposal very soon! :D After that I'm mostly gonna fix bugs, make improvements and add requested methods. (I'm not gonna grow the API just for the sake of expanding it.) Mostly I look forward to testing it out myself for real. :D

    Thank you for helping out with testing!

    Well, its actually not bad at all and clearly you try your best... (As do I... :p)
     
  3. LuKo

    LuKo The Royal Guard

    Joined:
    Aug 28, 2006
    Messages:
    1,501
    Location:
    Poland
    I think you could try to just lower cost of legions. So when Celtic pressure is gone Rome can quickly expand and fight with superGreece and superCarthage.
     
  4. Bonci

    Bonci King

    Joined:
    Oct 22, 2005
    Messages:
    738
    Location:
    Tridentum - Italia
    Don't know for shure yet but i was thinking something like "Caesar left Rome with his army in direction of Gaul" and you get some legions and a great general...but i'm aware that at that point of the game the player could have already conquered it so i don't really know...maybe I should spawn a legion in rome let's say every 10 turns to help the player?
    this could be an option

    I'll try this out :)

    Thank you for having created such a powerful (and simple to use) tool! :D
    now i'm verifing some possible bugs (could be that I'm the problem :p) as soon as i find something i'll post in the bugs thread
     
  5. -Perceval-

    -Perceval- Prince

    Joined:
    Sep 10, 2008
    Messages:
    355
    Could you do this for the mongols and the ottomans too?:crazyeye:
     
  6. Baldyr

    Baldyr "Hit It"

    Joined:
    Dec 5, 2009
    Messages:
    5,530
    Location:
    Sweden
    Or why don't you? :D
     
  7. Baldyr

    Baldyr "Hit It"

    Joined:
    Dec 5, 2009
    Messages:
    5,530
    Location:
    Sweden
    Ok, I see.

    Don't forget that you can spawn units with any level or any amount of XP - or with any promotions you want. (In the next update there will be automatic promotions according to unit level.) So you could probably spawn lesser units by making the few stronger. :goodjob:

    What about spawning levies (free units in wartime) and auxiliaries (free units according to conquered territories). So if a war event is triggered, there could be a free unit every Roman city (Spearman or Archer?). And if Rome has conquered a Celtic city there could be periodic free Gallic Swordman joining up.

    This way the player could concentrate on building the crack troops, the Praetorians. :king:

    Another approach could be to make the rivals weaker instead of making Rome stronger. There could be regional "civil wars" wiping out units, Civs that get fragmented or individual cities that brake lose. These hot spots would be easy pickings for the human Rome. :king:

    I'm glad you're able to make sense of it! :goodjob:

    My mission tonight will be to figure out how I could add support for custom Conditions and Actions in PyScenario - because then I could just make whatever you need in your particular scenario. These methods would then be in a file called Custom.py and only used by your scenario. So you would distribute both the Scenario.py and the Custom.py file together - perhaps with a altered 3000 BC WBS?

    I'll also check how exactly Rhye managed to use the same Civ slot for two different Civs (Celtia and Byzantium). If this can be done in mid game I'll try to create a custom Action for you that turns any remaining Celtic cities into independents and spawns Byzantium as a minor Civ. But I can't promise that this can be done with Python alone, so it may not happen... :p

    edit: Oh, it turned out to be very basic. :rolleyes: Rhye has substituted the Celtic Civ from the 3000 BC WBS file with the Byzantine in the AD 600 scenario. So I guess you can't have both in the same game then. But you could have the Celts be represented by Natives or Barbarians and use Byzantium in your mod-scenario instead...

    Oh, finally! :goodjob:
     
  8. LuKo

    LuKo The Royal Guard

    Joined:
    Aug 28, 2006
    Messages:
    1,501
    Location:
    Poland
    Maybe if Rome has more Legions than every other units combined then in every non-capital city archer/spearman spans until it's even?

    I don't think so. The main problem with "Roman Scenario" in vanilla RFC is weakness of Greece and Carthage (and Celtia).

    I think we need strong, important Celtic civ taking care of Rome and legions for a few hundred years to allow Carthage and Greece to expand (with the help of scripts). I think representing Byzantium with Greece is not that bad after all.
     
  9. Bonci

    Bonci King

    Joined:
    Oct 22, 2005
    Messages:
    738
    Location:
    Tridentum - Italia
    So for the free unit spawns i decided to use a sort of "reward for the quest" system like the random quests that appear sometimes in a regular bts game
    (don't pay much attention to the texts i wrote something just to remember what the event is about :p)

    the senate wants you to conquer taras


    when you conquer it you receive some troops and coins


    but pyrrhus isn't very pleased by your actions :sad:


    what do you think? could it work?
     
  10. Baldyr

    Baldyr "Hit It"

    Joined:
    Dec 5, 2009
    Messages:
    5,530
    Location:
    Sweden
    Why not? I think you should try it. :D
     
  11. LuKo

    LuKo The Royal Guard

    Joined:
    Aug 28, 2006
    Messages:
    1,501
    Location:
    Poland
    Some time ago I've posted the idea of something similar- Unique Historical Quest, so I have to like it :p BTW: why there is no Carthaginian city at Sicily?
     
  12. scu98rkr

    scu98rkr Prince

    Joined:
    Nov 2, 2004
    Messages:
    463
    Them screen shots look stonkingly brilliant luko
     
  13. Bonci

    Bonci King

    Joined:
    Oct 22, 2005
    Messages:
    738
    Location:
    Tridentum - Italia
    because i don't know exactly how to handle Sicily...there could very well be a greek city too, but there is no space...carthaginian sicily could be represented by cultural borders instead (not to mention that another city so near at Carthage could choke its growth...)
     
  14. Bonci

    Bonci King

    Joined:
    Oct 22, 2005
    Messages:
    738
    Location:
    Tridentum - Italia
    so...I just lost all the work I did this week because my hard disk died in combat ._.

    I'm releasing my backup copy but it has only the AI improvement part...

    oh...and the fall of the empire part doesn't work very well...the byzantine empire(greece) doesn't respawn i don't know why :( (i solved this problem before but i can't remember how)
     
  15. LuKo

    LuKo The Royal Guard

    Joined:
    Aug 28, 2006
    Messages:
    1,501
    Location:
    Poland
    Code:
    Trigger(7).year(-800).once().check(False,False).garrison((63, 42), 31,1)#Taras garrison
    not Trigger(4)?

    .check(False,False) -> .check() Not the same?
     
  16. Bonci

    Bonci King

    Joined:
    Oct 22, 2005
    Messages:
    738
    Location:
    Tridentum - Italia
    yes thank you :)
    ummm you are right but I copy-pasted the first trigger so when i realized that i already had the code full of "False" XD
     
  17. Baldyr

    Baldyr "Hit It"

    Joined:
    Dec 5, 2009
    Messages:
    5,530
    Location:
    Sweden
    Default settings can be spelled out or omitted, use what makes most sense to you. It can actually be easier to always enter every single argument, so that you don't lose track of how many there are and in what order they appear. You can even spell out the name of the argument if you like:
    Code:
    check(bHuman=None,bAlive=False)
    No way is more correct than the other, its just different ways of doing the same thing.
     
  18. LuKo

    LuKo The Royal Guard

    Joined:
    Aug 28, 2006
    Messages:
    1,501
    Location:
    Poland
    Yep, though every letter makes file "heavier" :)P) and (what is more important) distracts attention when someone compares two scenarios :p Personally I try to omit values only when I omit all of them (for the reasons you said).
    Anyway, the scenario just now seems similar to extended flip modmod (or whatever the name of mod which makes cities to flip to historical owners before player spawn). I agree that the word "scenario" means that some things are predetermined but I think it's a bit too much.
     
  19. Baldyr

    Baldyr "Hit It"

    Joined:
    Dec 5, 2009
    Messages:
    5,530
    Location:
    Sweden
    Of course the file size will increase with every additional letter, but thats not really an issue. :p Rhye's modules probably take up something like 10000 lines of code, so a few more letters won't make any real difference. All the Python is probably loaded in a second or two, anyway.

    What's more important here is how much memory each Trigger will take up in the game, and how long it will take to run it. It might sound odd, but spelling out default settings or not resorting to automatic settings, can actually make these execute faster! :eek: (But I believe checking a Trigger that doesn't fire takes like 1/1000 second. So if you make 1000 of them you'd be looking at some lag of a whopping 1 sec! :rolleyes:)

    Also I believe you are using integer values while other try to use Rhye's constants from the Consts module when they can. Its also a bit distracting, as is the way you substitute True/False with 1/0... :p But no harm in that!

    One thing that bugs me however, is the way Triggers can get very long, even if you omit values, substitute boolean values with integers and use other tricks like that. This is when I personally resort to variable assignment. An example from my Spartacus! mod-scenario:
    Spoiler :
    Code:
    Event_initiate = Trigger(con.iRome).label("initiate").once() #Trigger constructor
    Event_initiate.check(True).policy(11).year(-73) #Conditions
    Event_initiate.treaty(con.iIndependent2,False) #Actions
    Event_initiate.message(slaves).effects(con.iRed,True)
    #message
    (This is actually one single Trigger. Note that the Trigger constructor is invoked only once.)

    This isn't even covered in the documentation, but I've basically applied some programming to my script. Because its really just Python after all. :D I don't think you need to go down this path anytime soon. :crazyeye:
     
  20. LuKo

    LuKo The Royal Guard

    Joined:
    Aug 28, 2006
    Messages:
    1,501
    Location:
    Poland
    Slaves are better represented by Barbarians in my humble opinion (Rome din't go to war with minor civs because of Spartacus). BTW: Mine triggers are longer :p Though, the long messages beats everything.
    Spoiler :
    Code:
    Event_initiate=Trigger(con.iRome).label("initiate").once()Event_initiate.check(True).policy(11).year(-73)Event_initiate.treaty(con.iIndependent2,False)Event_initiate.message(slaves).effects(con.iRed,True)
    Code:
    Trigger(6).turn(126).check(None,0).owned((59,47),7).label("Hannibal_at_Rome").treaty(7,0,0,0).units(58,48,67,1).XP(None,50).promotions(43).flag("Hannibal_Barca",1).AI("UNITAI_RESERVE").units(58,48,37,4).AI("UNITAI_RESERVE").units(58,48,57,3).AI("UNITAI_RESERVE").units(58,48,67,1).AI("UNITAI_RESERVE").units(58,48,76,1).AI("UNITAI_RESERVE")
     

Share This Page