Home Crush your enemies... and create an EMPIRE!!! Space Empires V -- BUY NOW!!!

User login

  • Create new account
  • Request new password

Navigation

  • news
    • archive
    • blogs
    • books
    • forums
    • recent posts
    • groups
  • image galleries
  • projects & downloads
  • search
  • create content
  • news aggregator

Search

Who's online

There are currently 1 user and 282 guests online.

Online users

  • Captain Kwok

Languages

  • English English
  • French French

Browse archives

« November 2008  
Mo Tu We Th Fr Sa Su
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
Home » news » forums » Support & Feedback » Scenarios & Mods » SE:V MODs

MAKING THE AI BETTER

Submitted by Grelvis on Mon, 2006-12-18 00:48. SE:V MODs

I've noticed that when the AI designs ships, it doesn't take notice of component levels of life support or crew quarters. After a bit playing around with different files, I came up with these changes to the "Get_Number_Of_Components_To_Add" section of the "Script_AI_DesignCreation.txt". After making these changes the AI designs ships with more Weapons and Armor.

Modifaction The above file needs to be copied and pasted over the existing code in the file.

Now i'm working on making a more aggressive AI. I'm trying to make a race that will attack you in force.. Got my work cut out for me..

‹ Ring World Mod IRTM v 0.54c is out! ›
» login or register to post comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

AI Defending it System

Submitted by Grelvis on Tue, 2006-12-19 08:18.

Just got my AI to start attacking ships in it teritory.. Still got a bit of fine turning to do on it as it only does it when a ship is in sensor range. So now i need to get the AI to have at least one ship on patrol around the system to find any ships and also sit to full non aggression treaties, as at the momement it attacks cause your there.. but hey its a good start...
coding in THIS file replaces the current code of the same section in the Script_AI_Orders_Ships file.

» login or register to post comments
cordas's picture

Is this a generic AI update,

Submitted by cordas on Tue, 2006-12-19 09:16.

Is this a generic AI update, or is it specific to any particular race?

Also get the AI to research sensors as an early game priority so it can cover more gorund easily. You could also get the AI to seed spy satalites around warp gates to make it so it can see any ship coming in and out (it should be possible to make a little function to allow it to seed sats to cover the entire system).

» login or register to post comments
Captain Kwok's picture
Mod Designer

Freeing up attack ships

Submitted by Captain Kwok on Tue, 2006-12-19 10:29.

Slightly decrease the number of attack ships the AI will add to fleets will free up a free lone ships that could be used for this purpose.

-----

Space Empires Depot | SE:V Balance Mod

» login or register to post comments

Both Are Generic

Submitted by Grelvis on Wed, 2006-12-20 05:54.

Both Changes are Generic changes i've made, however the attack change still has some work to make it fully playable (eg. Even if you have a Non Aggression treaty including Colony System, the computer still attacks). I think i'll add the sensor upgrades as one of the primary research areas.

I found that I have the percent of ships sent to fleet at 60 percent so it has several lone ships around, and if your ship is within sensor range of several of them, they attack you at the once. (eg. the one combat)..

» login or register to post comments
Captain Kwok's picture
Mod Designer

Inspiration...

Submitted by Captain Kwok on Wed, 2006-12-20 06:24.

Your LS/CQ script gave me inspiration to change this for the Balance Mod, where I was able to condense it some more...

Snippet:
...
"Life Support":
set tech_id := Sys_Get_Tech_ID("Vehicle Systems")
set tech_level := Sys_Trunc(Sys_Get_Empire_Research_Tech_Level(sys_long_Player_ID, tech_id) * 0.4)
set num_to_add := Sys_Trunc(lst_AI_Vehicle_Sizes_Num_Life_Support.Get(index) / (100 + (tech_level * 25)) + 0.99)
return num_to_add
...

I grab the level of required tech, then because the mod only has LS/CQ components at levels 1-3-5 (and not at every tech level) I needed to throw in a multiplication factor after. In global settings I changed the lst_AI_Vehicle_Sizes_Num_Life_Support variable to carry the number of crew required (rather than number of LS/CQ to add) and then did a calculation to figure out the number to add.

» login or register to post comments

Glad to be of Inspiration...

Submitted by Grelvis on Thu, 2006-12-21 06:47.

Glad to be of Inspiration...

» login or register to post comments
cordas's picture

Sounds great!! Any chance

Submitted by cordas on Thu, 2006-12-21 07:12.

Sounds great!!

Any chance of getting Aaron to put this into the next patch for all the stock races?

» login or register to post comments

Hey Captain, How does the

Submitted by Grelvis on Tue, 2006-12-26 00:08.

Hey Captain, How does the "Sys_Trunc()" fuction work, eg. does it convert a fraction of 3.3 to a whole number of 3 or 4.
As this would drastically reduce the coding i've used.

» login or register to post comments
Captain Kwok's picture
Mod Designer

Sys_Trunc

Submitted by Captain Kwok on Wed, 2006-12-27 06:51.

Sys_Trunc() just cuts off the decimal, so 3.97 becomes 3 and so on.

-----

Space Empires Depot | SE:V Balance Mod

» login or register to post comments

Thanks Captain, I have

Submitted by Grelvis on Wed, 2006-12-27 07:28.

Thanks Captain, I have re-written the coding for the ship design file so its alot smaller. clearing all the if-then-else statements...

» login or register to post comments

Script_AI_Orders_Ships

Submitted by Grelvis on Wed, 2007-01-03 07:32.

Just Made some more changes to the Attack Ship orders coding. Available HERE. Now working on coding for dealing with Planets and Bases. My Plan is the create a new global variable to list locations that are heavily defended for one ship, and then order the fleet to converge on that location.

» login or register to post comments
Captain Kwok's picture
Mod Designer

Calculate distance to target too

Submitted by Captain Kwok on Wed, 2007-01-03 08:33.

I like the script - but what about adding a provision to calculate the distance (Sys_Get_Hex_Distance_Between_Sectors) to the object so only the closest ships are given orders to attack? Right now it looks like each free attack ship might be given the same attack order on the first object that is found.

-----

Space Empires Depot | SE:V Balance Mod

» login or register to post comments
Captain Kwok's picture
Mod Designer

Oops...

Submitted by Captain Kwok on Wed, 2007-01-03 09:09.

Oops. Neglected to pick up that the ship's orders would be only issued for enemy ships in the same system, since it's just a scan of objects in the same system as the ship and not empire wide. Sticking out tongue

Although I suppose the distance clause might work ok for attack ships in an adjacent system - like a situation where the AI has a colony but no attack ships in the system where there is a valid target.

-----

Space Empires Depot | SE:V Balance Mod

» login or register to post comments

In regards to PLanets, i

Submitted by Grelvis on Thu, 2007-01-04 07:52.

In regards to PLanets, i will come back and write code on how a ship deals with a planet, its just a mater of putting in code similar to "if (sobj_type = SPACE_OBJECT_TYPE_SHIP) then" but using SPACE_OBJECT_TYPE_PLANET. But mainly i want it to take note of the planet, attack its outer defenses, and then a troop carrier come in and drop troops on the planet..

As with ships in nearby systems, i would like to get it so, if a ship has no enemies in it current system, it would then move an adjacent system to attack, and it thats out of range, it would at least move to the warp point to prevent any incursion.

I haven't very hard for it yet, but do you know if it is possible to recode how a ship acts in battle. Its not very KLingon like to run away once the weapons are either out of ammo or are damaged. I want them to instead to try and ram the attacker.

And i have never bothered to research cloak before in my owns games, as i prefer to let my enemies see me coming to kill them, but in tactical combat, is a ship able to cloak and decloak during the combat???

» login or register to post comments

In Regards to Warp Point

Submitted by Grelvis on Thu, 2007-01-04 07:59.

Also i want to get the AI the lay mines on Warp Points to systems that have enemy colonies. I think mines shouldn't show up on basic sensors, or require a higher level.

» login or register to post comments
Captain Kwok's picture
Mod Designer

AI stuffs

Submitted by Captain Kwok on Thu, 2007-01-04 09:30.

Strategies determine how a ship will behave in combat. You can make new strategies and reference them in the AI's main scripts. Right now it seems the strategies for design types are hard-coded, but it's probably fairly easy to assign a default strategy in the design creation script.

It seems that sometimes with SPACE_OBJECT_TYPE_PLANET ability that uncolonized planets get picked as attack targets. I'll have to double check the scripts I made with this provision though and the debug log to see what is happening exactly when I get home tonight.

Unfortunately the abilities on mine hulls that are supposed to make them invisible to basic sensors are not working properly. Anyhow I believe even the stock AI will launch mines above it's planets and at warp points (if they have mine layers available). The Balance Mod AIs do it though.

-----

Space Empires Depot | SE:V Balance Mod

» login or register to post comments

Mine Mod GRRR

Submitted by evilginger on Thu, 2007-01-04 09:39.

The ballence Mod should be called the Mine mod as the AI loves its blasted mines so much. The last game I played every planet I took required two fleets first suicide mine sweepers as you had to clear 150+ mines then the battle fleet excorting troop ships

» login or register to post comments

Uncolonized Planets

Submitted by Grelvis on Fri, 2007-01-05 07:51.

Since a planet is a Space Object, using Sys_Get_Space_Object_Owner would identify if it was colonised or not, as it returns a value of 0 if no one owns it.

» login or register to post comments
Rilbur's picture

Mines

Submitted by Rilbur on Sun, 2007-01-07 00:11.

evilginger wrote:
The ballence Mod should be called the Mine mod as the AI loves its blasted mines so much. The last game I played every planet I took required two fleets first suicide mine sweepers as you had to clear 150+ mines then the battle fleet excorting troop ships

If the enemy is using that many mines, proper minesweepers may be required... "polish mine sweeping" only goes so far.
_______________________
There are 10 types of people in the world:

Those that understand binary, and those that don't.

» login or register to post comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Now on STEAM

Now on STEAM!Space Empires V via STEAMSpace Empires IV via STEAMSTEAM online by Valve Corporation

Popular content

Today's:

  • Research By Percentage SUCKS
  • Star Trek Trailers.....
  • Space Dock suggestion
  • Balance Mod v1.15 Available!
  • drone combat?!

All time:

  • Space Empires V and VI: Expansions and the Future: Tell the Company What's on Your Wish List
  • Space Empires V
  • Gritty Galaxy Fleet Clash
  • Damn Dirty Bugs/Annoyances
  • Space Empires V: General Thoughts, Observations, and Suggestions

Last viewed:

  • Warp Point 'parking'
  • Warp Points
  • Planet Creator Bug
  • Frequent Crashes
  • Help! Something has assploded.
(c) Strategy First, Inc. All rights reserved.