You mean, we should have a "Hello, World" Test AI scheme, which is then implemted in each language (eg. C, C++, Java, C#) in a Test AI.
This scheme had to be working with absolutely every kind of mod, an if not everything can be done, it had to not crash at least, and report why it could not do what.
yes, exactly that; but, to simplify things, i suggest splitting every use case to separate demo AI.
Quote:
An example for such a scheme:
Code:
snipped
something like this would also be of help.
Quote:
it is possible to draw points, lines, paths and figures wiht the AI interface as it is now, i dont know if arrows are in fugures, or if they had to be constructed manually out of 3 lines eg.
you mean hashes for the mod and the map, to not use cached data for BA6.6 when BA6.8 is loaded eg? if i am not wrong, this is not possible through the interface at the moment, would have to be added. is this the cleanest solution? (eg, what about mod-name + version?)
yes, exactly this. getting mod name, version and stuff like this should also be exposed. use case is e.g. precomputing choke points for maps/mod+map combos - need ability to access pathfinder data or heightmap+slopemap (if there is such a thing in spring, not sure) and an ability to uniquely identify which map is that.
indeed, i plan to write an ai, but it's going to be a KP AI because TA or any other mods are too complex ^^
Well KP has already a AI (LuaAI) so you have a small competition.
I want to write a AI, too after the MonoAIInterface of course. But I do not know which mod or how many I want to target for support. And I'm not sure in which language, probably C# but I do not know
was reffereing to the merge into master. i compleetly missed the posts after that somehow :/
well, if i get the branch to compile on the buildbot, next thing is to merge into master.. i guess there will be some weeks of bug hunting after that. ... and then i am willing to go deeply into LUA-AI discussions.. well we can discuss now, but i wont code anything, the merge is just much more important to me right now.
LUA AI is something that current SendToAI (or whatever it's called) can take care of. The mod and the AI should agree on a protocol and just use it completely independently of spring.
I'm more interested in accessing modoptions/engineoptions/mapoptions/player settings and generally the stuff i requested examples for.
yes, resources are modular, from an AIs perspective. there are not getMetalXXX() methods, but rather getResourceXXX(int resourceIndex) i think it would be bad if mods and AIs would define special protocols. if you want that, you should rather write a LUA AI. I think the goal of the Skirmish AI interface has to be complete modularity. also, to some extend it has to follow a common protocol, as it all has ot pass the C barrier.
We have a proposal for defining extra resources via lua that we can use right?
I would suggest we sort out the debacle that is transformations/upgrades of individual units. I cant even ask if all mods use the same implementation to pull it off, and in some cases it looks so easy to support but nobodies talking when asked, or they respond with garbage answers like learn lua.
I would suggest we sort out the debacle that is transformations/upgrades of individual units. I cant even ask if all mods use the same implementation to pull it off, and in some cases it looks so easy to support but nobodies talking when asked, or they respond with garbage answers like learn lua.
Everything but P.U.R.E. is pretty much just using CA's Morph Gadget. It should be easy enough, with Lua-->AI, to do a query through Lua to find out whether a given command ID exists, and whether that corresponds to the known command ID for Morph.
For P.U.R.E., that approach is utterly impossible. I use a transformation method that's custom to each unit-type, and the commands aren't standardized. If anybody wants to get really serious about this topic, I have a fairly lengthy set of feature specifications I'd like to propose, that would allow for the necessary flexibility.
we should start a new topic for the LUA <-> AI stuff, or in the case of resources, we could go on here, though only the details of the implementaiton are left undecided there, and they may be better discussed when we actually will be implementing it: viewtopic.php?f=15&t=16889
Everything but P.U.R.E. is pretty much just using CA's Morph Gadget. It should be easy enough, with Lua-->AI, to do a query through Lua to find out whether a given command ID exists, and whether that corresponds to the known command ID for Morph.
For P.U.R.E., that approach is utterly impossible. I use a transformation method that's custom to each unit-type, and the commands aren't standardized. If anybody wants to get really serious about this topic, I have a fairly lengthy set of feature specifications I'd like to propose, that would allow for the necessary flexibility.
In that case you could provide a wrapper layer around you implementation conforming to an agreed interface layer or mechanism. Since morphing is quite a common feature theres no reason we cant roll it into the C API
i should be in the lobby these days for direct help. or you might write mantis reports in hte AI section, or fix it yourself :D
You may use SpringLobby for testing, as it is curently the only lobby that supperts the new AI system. other lobby defs can come to me for help with implementing it.
known issue: under Linux, you will probably have to do the following for hte Java AI interface to work (runtime):
Users browsing this forum: No registered users and 0 guests
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum