Green Rollover Red Rollover Arrow Rollover Focused Userbar Register Button Rollover Red Button Rollover
Welcome Guest ( Log In / Register )

Explanation of Empire At War's AI "engine"

Avatar of Drieick

Drieick

Category: Coding
Level: Intermediate
Created: Monday February 25, 2008 - 3:03
Updated: Monday May 5, 2008 - 22:43
Views: 6349
Summary: Taken from the forums, a tutorial on EAW's AI

Rating

Staff says

5.0

Members say

-

Average

5.0/5.0

1 vote

Page 1 2 3 4 5 6
Examples that you can use
Here are some functions I wrote that you can study and use; just provide a link to this thread (or just a form of credit, but I prefer the link) if you publish any work with any of these functions in it:

<!-- Are we connected to the enemy's home planet? -->
<Is_Connected_To_Enemy_Home_Planet> Function_Is_Connected_To_Me.Evaluate * Function_Is_Home_Planet.Evaluate </Is_Connected_To_Enemy_Home_Planet>

<!-- Does this planet have a barracks? -->
<Has_Barracks> Variable_Target.HasStructure{Parameter_Type = "E_Ground_Barracks", Parameter_Type = "R_Ground_Barracks", Parameter_Only_Consider_Complete = 1.0} </Has_Barracks>

<!-- Does this planet have a light factory? -->
<Has_Light_Vehicle_Factory> Variable_Target.HasStructure{Parameter_Type = "E_Ground_Light_Vehicle_Factory", Parameter_Type = "R_Ground_Light_Vehicle_Factory", Parameter_Only_Consider_Complete = 1.0} </Has_Light_Vehicle_Factory>

<!-- Does this planet have a barracks OR a light factory? -->
<Has_Barracks_Or_Light_Factory> Function_Has_Barracks.Evaluate + Function_Has_Light_Vehicle_Factory.Evaluate </Has_Barracks_Or_Light_Factory>

<!-- Does this planet have a barracks AND a light factory? -->
<Has_Barracks_And_Light_Factory> Function_Has_Barracks.Evaluate * Function_Has_Light_Vehicle_Factory.Evaluate </Has_Barracks_And_Light_Factory>

The season finale
The only thing I hope is that you understood is what I wrote; if you have any questions, just post. smile

-------------------------------------------------------------------------------------------

That's all of it. But, I would like to make a correction: it translates to, what I have reason to believe, C/C++. The files are attached, so you may download and review them. Not sure if they're valid C++, since I just started a couple days before posting that tutorial, so feel free to make appropriate modifications. (They won't Build though; they're just a rough lay out of what I think they might look like; ever heard of XAML?)

Links / Downloads

 HitsAdded
NameSpace and TestFunction (Page 6)2608February 25, 2008 - 3:19
News article pertainting to tutorial3064February 25, 2008 - 3:07
The original thread2979February 25, 2008 - 3:06

Add comment

Please enter your message below. Max 10000 characters.