Author Topic: AI Empire v0.1.1; now with finer control  (Read 14183 times)

iceita

  • Sentient
  • **
  • Posts: 53
  • Karma: +5/-0
    • View Profile
Re: AI Empire v0.1.0; updated for 1.0.2.0
« Reply #30 on: October 19, 2010, 03:02:18 AM »
 ;) This is truly great!

ayrnieu

  • Distracted
  • ***
  • Posts: 383
  • Karma: +30/-8
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #31 on: October 19, 2010, 02:51:00 PM »
Updated to 0.1.1; you can now control much more of the AI (to the point where it should appear to do nothing at all if you turn everything off).  So that all of these new checks and other potential changes don't bother the NPC empires, a new player_ai.as is used instead of basic_ai.as

SRDominator

  • Sentient
  • **
  • Posts: 58
  • Karma: +4/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #32 on: October 24, 2010, 10:21:46 PM »
Is it possible to make the mod so that it is not enabled by default. I have already figured out how to prevent it from getting control of my Home world automatically and starting the governor automatically and have altered the mod accordingly. However, could there be an option were everything is disallowed from the beginning and you could select the things you want the AI to perform yourself. Example: I want to just at first have the AI deal with Treaties and nothing else so that is the only thing I select. Later maybe scouting, so I select that. From what I have tested thus far, it seems to be a great governor which is really what I want it to be. Not to control the entire game.

ayrnieu

  • Distracted
  • ***
  • Posts: 383
  • Karma: +30/-8
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #33 on: October 25, 2010, 12:38:10 AM »
Yes, and the place to do it is in Game Data\gui\ai_control.as , when the buttons are created.  Find AIControl.set() and add this as the last line:
Code: [Select]
set_enabled(false);

SRDominator

  • Sentient
  • **
  • Posts: 58
  • Karma: +4/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #34 on: October 25, 2010, 02:12:03 PM »
Yes, and the place to do it is in Game Data\gui\ai_control.as , when the buttons are created.  Find AIControl.set() and add this as the last line:
Code: [Select]
set_enabled(false);

Thank you very much for replying and providing the answer. Also, would it be alright to merge your mod with my own mods for public consumption?

ayrnieu

  • Distracted
  • ***
  • Posts: 383
  • Karma: +30/-8
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #35 on: October 25, 2010, 06:33:06 PM »
Yes, that's fine.

maximus84

  • Newbie
  • *
  • Posts: 40
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #36 on: November 29, 2010, 01:50:55 PM »
Will this ever get an update? Did love the auto dock/undock functions of it...

vinc3nt

  • Newbie
  • *
  • Posts: 32
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #37 on: January 28, 2011, 03:10:02 PM »
Is there a chance you could update this Mod for v1.0.5.4? It is/was my favourate mod.

Maybe AI control of your empire could be included into a patch aswel :)

Thy Reaper

  • BMS Lead Developer
  • BMS Administrator
  • Hopeless
  • *
  • Posts: 3237
  • Karma: +397/-8
    • View Profile
    • Blind Mind Studios
Re: AI Empire v0.1.1; now with finer control
« Reply #38 on: January 28, 2011, 03:55:26 PM »
We did want to do something like this eventually.

vinc3nt

  • Newbie
  • *
  • Posts: 32
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #39 on: January 28, 2011, 04:08:28 PM »
We did want to do something like this eventually.

Good to hear you considered it.

This feature would make it easier to control large Empires (if you have many systems in a game), and you could think of the AI that control the different aspects of your empire as your personal advisors.

TheDarkOne

  • Newbie
  • *
  • Posts: 7
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #40 on: January 29, 2011, 11:51:10 AM »
for which version is this compatible with?

acantoni

  • Newbie
  • *
  • Posts: 5
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #41 on: January 31, 2011, 10:05:04 AM »
Quote
We did want to do something like this eventually.

Awesome! this was an excellent mode to start understanding the game mechanics and cant wait to have it implemented in the base game.

maximus84

  • Newbie
  • *
  • Posts: 40
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #42 on: January 31, 2011, 11:25:46 PM »
One of the biggest problems I have with Star Ruler is the Dock/Undock Management...

I said it before and this time it is the same... I did come back to the game to play the new version and also the new Expanded Universe Mod. I did play some hours now and already stopped again (not because of the Mod, the EU Mod is great)... cause it is a big Pain in the Ass to manage Sector Defense and things like Carriers cause there is no "comfort" feature implemented for it... which makes it very time intensive and unfunny and just makes me stop playing.

It is like... You are the Emperor of a Huge Star Empire and have to give manual Dock/undock orders for every Carrier refitting its fighters, Carrier Fighter unload for attack (or Sector Defense) and after that you have to manually dock the fighters again and some other things... also involving Fighter Stations or the Ship Storage Bays of Planets.

I know that the Devs have something planned... I was told that since 1.0.2.2. I know they want to wait till they give the AI a full overhaul... but this can be a Loooong time till it is finished (my opinion). A much better way would be to take the small script part out of the Empire AI that docks your fighters everywhere where Ship Storage is available if they are idle, and undocks them when enemies enter the System. This could also be set to off/on via a button, like in this Empire AI Mod... it was so grand back when this mod did work... i miss it really. I am not a very good coder and have not the time to learn it at the moment... if I had the chance I would code it in myself.

This is not a perfect solution but it makes managing Fighters much much easier and it would be not THAT much of work for this big effect. It would also help with performance in big games, or in general, games where players build lots of smaller ships, cause they don't "idle" around in Space and use commands like "Fetch fuel" for example.

Foraven

  • Delusional
  • ****
  • Posts: 1591
  • Karma: +102/-6
  • Fear the gauss weapons!
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #43 on: January 31, 2011, 11:48:28 PM »
Hum... Maybe i can use the code i made for my AI to be used as a tool... Like a tool that call all fighters within range to dock or something like that. I never tried to make tools though, might be more complicated...
Maker of FRB mod.

Journier

  • Rather Die Standing, Than Live Kneeling
  • Star Ruler Beta Tester
  • Sentient
  • *
  • Posts: 132
  • Karma: +5/-2
  • Not a moderator.
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #44 on: February 01, 2011, 02:02:00 AM »
the ability to autocolonize all nearby systems i have to say would be fantastical.

I hate having to go to each system in larger galaxies and hit auto colonize
I got a killing desire, To spam mah bomber.

maximus84

  • Newbie
  • *
  • Posts: 40
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #45 on: February 01, 2011, 02:15:03 AM »
I think the use of tools gets also too complicated when having a really big empire... I am speaking here of Games with 500 Systems (I usually play Games like this).

Just the AI Routine that automatically sends an order to idling fighters in a system so they have to dock somewhere, where capacity is empty (Stations/Carriers/Planets). And if there are enemies in sector, let them all undock automatically (and then the Star Ruler Stock AI jumps in and lets the Fighters attack Enemies in the sector)... plain and simple like the AI Empire did handle it.

It did not need anything clicking around a lot or something like that... it was something you had running in the background and you could concentrate on the stuff that really matters and not clicking buttons for "undock/dock" a lot.

This makes Fighters/Bombers more funny to play around with... at the moment I can not think of anybody using them a lot, cause they are a pain in the ass to handle... well or somebody lets them idle around in Space in the tenthousands and gets a performance hit ^^

Superking

  • Distracted
  • ***
  • Posts: 332
  • Karma: +27/-7
  • Ohhhh Jobi
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #46 on: February 01, 2011, 03:00:00 AM »
looks great, is this compatible with online multiplayer against the unmodded game?
I Make the Bread

Foraven

  • Delusional
  • ****
  • Posts: 1591
  • Karma: +102/-6
  • Fear the gauss weapons!
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #47 on: February 01, 2011, 09:00:33 AM »
Just the AI Routine that automatically sends an order to idling fighters in a system so they have to dock somewhere, where capacity is empty (Stations/Carriers/Planets). And if there are enemies in sector, let them all undock automatically (and then the Star Ruler Stock AI jumps in and lets the Fighters attack Enemies in the sector)... plain and simple like the AI Empire did handle it.

I guess it's the next features i should work on for my mod. I got a lot of AI routines done, but even i find it tedious to play my own mod when i have to do all that chore like docking fighters manually (or undocking them from planets). So i will add a bunch of tools based on the AI code i made...
Maker of FRB mod.

echo66

  • Distracted
  • ***
  • Posts: 309
  • Karma: +10/-10
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #48 on: February 01, 2011, 10:31:19 AM »
the ability to autocolonize all nearby systems i have to say would be fantastical.

I hate having to go to each system in larger galaxies and hit auto colonize

or we can have a colonization planning window like in MOO3 or Distant Worlds. It has already been done and it works. Just use the concept.  :)

krageon

  • Newbie
  • *
  • Posts: 5
  • Karma: +1/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #49 on: March 15, 2011, 09:10:12 AM »
I'm having a stab at updating this - is it OK if I upload the new version here so someone with a fresh pair of eyes can look at it and tell me if something is going horribly wrong? I'm attempting to add in all the new AI bits and keep the old bits (or merge them in if they're obsolete enough), with a diff program and a lot of time, so things are probably getting horribly mangled and it may come out very broken.
However, this project is such that I'm willing to invest the time in updating (and subsequently fixing >.<) it; it's simply extremely nice :)

I've also gone through the files and I've removed the old bits that were included but not (I hope) strictly necessary (notably, the Script Data folder as I figured nothing was changed - I don't have access to an old version though, so I can't be sure).
It's currently picking personalities, but not actually using all of them.

tl;dr: Updating this, can I upload it for all to see?

Sid0035

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #50 on: March 16, 2011, 07:45:06 PM »
i would love to see this project revived i never got to try it out but it's what i been looking for as i have troble manigeing every thing in star ruler lol....

Thy Reaper

  • BMS Lead Developer
  • BMS Administrator
  • Hopeless
  • *
  • Posts: 3237
  • Karma: +397/-8
    • View Profile
    • Blind Mind Studios
Re: AI Empire v0.1.1; now with finer control
« Reply #51 on: March 16, 2011, 07:52:02 PM »
I sent a message to Ayrnieu, I don't know if he'll reply any time soon. I don't think he'd mind you releasing a modification, krageon, as long as you credit him.

krageon

  • Newbie
  • *
  • Posts: 5
  • Karma: +1/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #52 on: March 17, 2011, 04:58:17 AM »
That's what I was thinking as well, but I always feel better if I've asked beforehand. I'm having a bit of a pause with the GUI bits so far though, and I'm beginning to think writing this from scratch using the new files would be a better (and less bug-prone) idea than essentially going over every game file with a diff program.

If I ever get through the GUI bits, I might actually do that.

Edit: I especially like the idea of a very non-intrusive way of adding the code (something like an include statement?), so that updating for a new version won't be such a pain. That  won't work for the AI itself, though (or at least I don't see how)
« Last Edit: March 17, 2011, 08:29:26 AM by krageon »

Thy Reaper

  • BMS Lead Developer
  • BMS Administrator
  • Hopeless
  • *
  • Posts: 3237
  • Karma: +397/-8
    • View Profile
    • Blind Mind Studios
Re: AI Empire v0.1.1; now with finer control
« Reply #53 on: March 17, 2011, 02:50:59 PM »
What do you mean for the non-intrusive inclusion?

You can import functions by declaration from modules, which is seen in many of the GUI code files. That allows the module to be edited separately, as long as it maintains the functions that are imported.

krageon

  • Newbie
  • *
  • Posts: 5
  • Karma: +1/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #54 on: March 18, 2011, 08:44:46 AM »
That's exactly what I meant: Keeping the largest part of everything outside of anything else so updating things is not such a humongous pain.

More on that after I finish mountains of uni work >.<

DMZ

  • Newbie
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #55 on: April 16, 2011, 03:22:47 PM »
Hou do i Install this mod and use it?

GGLucas

  • Dr. Evil
  • BMS Staff
  • Delusional
  • *
  • Posts: 1877
  • Karma: +300/-6
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #56 on: April 16, 2011, 03:25:52 PM »
This mod has not been updated for the latest version of star ruler, so you will not be able to use it, sorry.

Orophin

  • Newbie
  • *
  • Posts: 8
  • Karma: +0/-0
  • I am a rock. I am an island.
    • View Profile
    • STEAM
Re: AI Empire v0.1.1; now with finer control
« Reply #57 on: May 04, 2011, 07:29:58 PM »
Can someone update this for the new star ruler versions?
It's a great mod, useful for when I just want to get back and spectate or need some help and want my PC to be my advisor / take over.

Please? Pretty please?
Maybe make it an official feature, even?
"He was an avalanche from an unexpected quarter. He was a thunderbolt from a clear sky."

scarface2cz

  • Newbie
  • *
  • Posts: 8
  • Karma: +1/-0
    • View Profile
Re: AI Empire v0.1.1; now with finer control
« Reply #58 on: August 21, 2014, 07:26:04 PM »
Looks like i would have to update it my self. But i dont know a thing about modding star ruler and even more, AI wich will suplement player. any ideas where to look, what to learn?

seronis

  • Distracted
  • ***
  • Posts: 338
  • Karma: +25/-0
    • View Profile
    • Steam Profile Link
Re: AI Empire v0.1.1; now with finer control
« Reply #59 on: September 25, 2014, 07:09:31 PM »
Jyins Ministry mod does similar things and is compatible with current star ruler version. 

Alternately, for a 'place to start' just download this mod and read the code.  Look at the files it edits.  Look at the original star ruler files with the same name.  Look at the differences between the two.  A tool like  WinMerge makes this comparison trivial to see at a glance. I suggest using it.
Any code/mods I post on this site should be considered Public Domain. Borrow it, steal it, shred it into little pieces to your hearts content. I dont require credit but I appreciate bug fixes and suggestions.