Login  Register
 



Post new topicReply to topic
 
Author Message
 PostPosted: 16 Feb, 2007 
 
User avatar

Joined: 15 Feb, 2007
Posts: 529
Location: Byron Bay, Aus
Offline
I'm Just playing around with the AI Lua Scripts.

Code:
BuildConditions = {
                { UCBC, 'HaveEqualToUnitsWithCategory', { 1, categories.COMMAND}},
                { UCBC, 'HaveLessThanUnitsWithCategory', { 1, categories.MASSFABRICATION * categories.TECH3}},
                { UCBC, 'HaveLessThanUnitsWithCategory', { 1, categories.MASSEXTRACTION * categories.TECH1}},
                { EBC, 'LessThanEconStorageRatio', { 0.1, 1.1}},
            },

yadda yadda...

now if i was to change the
Code:
'LessThanEconStorageRatio', { 0.1, 1.1}},

To this.
Code:
'LessThanEconStorageRatio', { 0.4, 1.1}},


now if im thinking this through right even when the AI has some sort of surplus of mass it will build a mass fab or a mex when it hits this ratio...
now if im wrong can some one explain what i would be doing here.

any help would be thanked

_________________
Image
Want A Signature? Im Making Them For FREE! Drop By :D


Top
 Profile  
 PostPosted: 16 Feb, 2007 
 

Joined: 15 Feb, 2007
Posts: 1609
Offline
It'll build that platoon whenever the AI is less than that ratio. So whenever the AI's mass storage is below 40%, it'll build it. Which means you'll be making this built more often.


Top
 Profile  
 PostPosted: 16 Feb, 2007 
 
User avatar

Joined: 15 Feb, 2007
Posts: 529
Location: Byron Bay, Aus
Offline
Thank you so i gather 1.1 = 100% energy storage + its producing extra.


another queston
Code:
{ EBC, 'GreaterThanEconIncome',  { 3, 10}}


1:Does this mean just {+3 mass, +10 energy}?

Code:
{ EBC, 'GreaterThanEconEfficiency', { 0.75, 0.75}},


2:Also does this mean if the AI is producing 75% + mass and Energy
for this condition to met?

So.
Code:
{ EBC, 'GreaterThanEconIncome',  { 5, 15}},
{ EBC, 'GreaterThanEconStorageRatio',  { 0.2, 0.2}},
{ EBC, 'GreaterThanEconEfficiency', { 0.75, 0.75}},


the condition is
Code:
IF {mass is >=5, Energy is >=15}
And {mass storage >=20%, Energy Storage >=20%}
And {Mass production >=75%, Energy Production >=75%}
=True
Then
BuildStructures = { 'T1 mex', 'T1 Power'}

For example
That potentionaly works right?

_________________
Image
Want A Signature? Im Making Them For FREE! Drop By :D


Top
 Profile  
 PostPosted: 16 Feb, 2007 
 

Joined: 15 Feb, 2007
Posts: 1609
Offline
You're basically correct.
The conditionals are all correct, the outcome is that it'll build the platoon specified and pass it those structures to construct.


Top
 Profile  
Display posts from previous:  Sort by  
Post new topic Reply to topic



Quick Tools

Search for:
Jump to:  

© 2002-2010 Gas Powered Games Corp. All Rights Reserved. Gas Powered Games is the exclusive trademark of Gas Powered Games Corp.
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
 
Home| Games | Company | News & Press | Support
  Terms of Use   |    Copyright Information   |    Privacy Policy