An XS file is a reference file used in Age of Empires III (AOE3) to generate artificial intelligence (AI). It is used during compilation process when a custom XML map file is loaded. If you have played AOE3, you already know that you can not only pick any map to play, but can also create your own maps using the Random Map Script program.
How to generate AI Map in Age of Empires 3?
Open a text editing program, such as Microsoft Notepad, Notepad++, or TextEdit. This will be used to program your map.
Program all of the features of your map using the Random Map Script language.
You can refer to programming tutorials to make sure that you are programming it correctly
Save your file as “MyAOE3.xs” and move it to your “Age of Empires 3” gaming folders.
XS File Format - More Information
XS files are saved as plain text files that can be opened and edited with any text editor.