GUI program for editing AI scripts |
Submitted by CP1985 on Thu, 2007-12-27 02:14.
SE:V MODs
Is anyone working on a program that will change/edit AI script files? The AI scripts are too complicated to try and edit for me. It would be nice to have a program that loads a mod, analyzes the data files and writes AI script files for them.
As of now I cant do what I want with my mod. Adding new vehicle sizes and changing the life support/crew quarters requirements. I want to change it so its based on tech level of life support/crew quarters but I dont have a clue how to do so. It would be nice if this program had the option of changing things like this.




Re: GUI program for editing AI scripts
Analyzing the data files and writing scripts for them is a hard enough task for a human, let alone a computer program... I guess there are really two routes one could go here (or use both!):
* Write an "adaptive" AI layer on top of the existing functions which is capable of analyzing a limited variety of situations. For instance, most if not all of the existing SE5 AI's have pre-scripted lists of techs they will research, in order, no matter the situation. These AI's will break if you add or remove techs. However, if you develop a module which is capable of analyzing the tech tree and determining "hey, if I research these techs, I get a new weapon", then that AI module could be used in *any mod* and perform reasonably well. I'm not sure if such scripting tools exist, but it seems like something trivial for Aaron to add if it's not there already - basically all it would require is a Get_Results_Of_Research_Into_Tech(long techID) function which returns a list of components, facilities, tech areas, etc. provided by research into a specific tech area given an empire's current state! And actually, there *is* a datafile-parsing function, so you could read the mod's datafiles directly if there's no way to get the tech results any other way, though I don't think there is a formula-evaulating function... ask Aaron and he might add one!
* Write a plugin or language mapping for some text editor or IDE (or even a custom editor) which would provide syntax highlighting and possibly even code completion hints for the SE5 scripting code format. As a matter of fact, I started on something like that for Netbeans, but I could never get it to work right... anyone here know a lot about regular expressions and abstract syntax trees?
~~~
The power of the ancients is now yours to command. You are truly the Master... of the obvious