View topic - AI Factory



All times are UTC + 1 hour


Post new topic Reply to topic  [ 47 posts ]  Go to page 1, 2, 3  Next
Author Message
 Post subject: AI Factory
PostPosted: 09 Apr 2012, 06:47 

Joined: 09 Oct 2009, 07:08
Previously, my Java AI project had an AI Factory that would return instances of AI's. However, with the new interface, I can no longer find any Factory to extend. Is there a Factory somewhere and I'm just missing it, or is there something different to do now?

Currently, when I have multiple bots running my AI, only the last bot actually works. The others just sit there. I'm thinking this is a side affect of the above thing.

By the way, once someone tells me how to fix this, I'll be happy to update the Wiki page for the Java AI to use the new interface.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 09 Apr 2012, 09:41 
Spring Developer
User avatar

Joined: 22 Sep 2007, 08:51
it is a known bug:
http://springrts.com/mantis/view.php?id=2840

i once tried ot fix it but failed :/
i can't say when i will have time and mood again...
sadly, it does not look too good for the near future.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 10 Apr 2012, 01:47 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
Come on hoijui, Ill give you 1000 cookies if you do.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 10 Mar 2013, 22:08 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
Is there any progress on this bug?


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 11 Mar 2013, 19:15 
Spring Developer
User avatar

Joined: 22 Sep 2007, 08:51
i have local changes that are working towards fixing this, but there is still a long way to go. i last worked on it 3 months ago (for about a day), and .. maybe 3 days, one year ago.
there are lots of small ugly problems, mostly fighting with CMake, maven, OSGi, ...
i don't remember what the current issues are i was stuck in.
so yeah...
not looking so good right now.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 13 Mar 2013, 05:05 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
Ow man.

I tried to fire up my AI a while ago, it mostly worked, but because it leans towards team based play I kind stopped there because it didn't work with more than 1 AI.

So is it to a point that it cannot even be rolled back to when it was working?


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 13 Mar 2013, 09:59 
Spring Developer
User avatar

Joined: 22 Sep 2007, 08:51
yes


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 13 Mar 2013, 10:16 
Moderator

Joined: 05 Aug 2009, 19:42
was it ever working? i recall having this issue back in 2010~


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 13 Mar 2013, 10:22 
Spring Developer
User avatar

Joined: 22 Sep 2007, 08:51
it was, before pureint (AI interface purification).
before pureint though, many things that are commonly used in AIs, were unusably slow. this got faster due to many small changes and the move from JNA to JNI.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 14 Mar 2013, 01:24 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
What sort of bribery are you open to in order to have another crack at this problem?


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 14 Mar 2013, 02:01 

Joined: 09 Oct 2009, 07:08
A few days ago, my mind wandered back to Spring and I thought to myself "I wish I could write an AI in .NET". I'd settle for being able to write a functioning Java AI right now, that you can have more than one instance of.

When I test my AI, it's much easier to put a bunch on the map and watch what it does rather than just having one running at a time.

I realize that the interface has changed breaking how AI's used to work. Either let's fix the AI side of things, or get the interface modified so that it supports proper AI's again.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 14 Mar 2013, 14:59 
Spring Developer
User avatar

Joined: 22 Sep 2007, 08:51
it's as if you people wouldn't listen to me at all..
IT IS 40 VIRGINS!

what i would need is...
a bit more time would be nice, and someone that is really good in setting up an OSGi environment.
what i need is, to startup the OSGi env. from within the Java AI Interface. it could be started from the native or from the Java part, but it would have to be simple and compact to install, and i need at least scr (including annotations) support.
it seems to be an unusual way to use OSGi. it is usually assumed that you install an OSGi env. and then run your app inside there. so for example you would use Karaf for that. Karaf is nice, but we cant ask Java AI users to install Karaf. i also don't want to put something handpicked together, as that is a maintenance nightmare. i don't know how it would be best. should the interface install something on first run, by downloading from the net? should it be done through maven? if so.. how to get maven there? and... AWW!!
i can run OSGi, if the jars are around, or if maven is installed (for neither of these options i have a nice way to ensure it in spring's case), but then i would still need lots of extra services (at least scr, scr-annotations, bundle downloading services, and dependencies of these things). and then it would also be a problem because i would not be allowed to bundle anything like this in linux packages at least, and i agree that it is not nice that a lot of stuff gets auto-downloaded when installing/running a game engine.
... i get depressed and annoyed when just thinking about this stuff already.
40 virgins seems not like a too high price.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 15 Mar 2013, 08:46 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
Why is it so hard now when it used to be working (years ago)? Do we need all that OSGi stuff?


Last edited by Petah on 17 Apr 2013, 09:26, edited 1 time in total.

Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 15 Mar 2013, 14:20 

Joined: 09 Oct 2009, 07:08
Slow AI's > not working AI's

My views on this are that pureint was supposed to improve AI's. And maybe it has, but at the same time it's also made them unusable. So we need to modify Spring to make it easier to integrate AI's, or we need to modify the interface our AI's are using. Whichever is easier and will work better (the easy things usually work best).

However, I have no idea what all the OSGi and other stuff is that you posted about. I shouldn't need to know, and neither should other AI developers. That sounds like I'm just saying "go fix it" to you. But really I'm saying maybe we should take a step back and figure out a way to implement it if it's going to be more complicated than it should be.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 15 Mar 2013, 16:21 
Spring Developer
User avatar

Joined: 22 Sep 2007, 08:51
it is of course possible to do it without OSGi, but it is not less work, and it is not simpler work. it is just different.
OSGi is a standard.. once we would have OSGi, the rest would be easy.. it would simplify everything else, and make it more robust with future changes, and .. bla bla.
i first tried to fix it without OSGi. it was even more frustrating, and i failed.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 18 Mar 2013, 01:41 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
Is there anything I can do to help (keeping in mind my c++ knowledge is limited)??


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 17 Apr 2013, 09:26 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
Any updates? Please?? :(


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 17 Apr 2013, 10:20 
Moderator

Joined: 05 Aug 2009, 19:42
DIY seems the most likely outcome.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 18 Apr 2013, 04:34 
User avatar

Joined: 28 Jul 2008, 05:51
Location: Australia
I've never understood why Java developers make everything so complicated. What's wrong with exporting a basic set of proceedural functions or simple classes in the interface and letting AI writers apply their own abstractions (Factories, Getters, Services, Gateways, etc) on top of that? Coming from a Python/Lua background I simply cannot comprehend why anything other than "here is an exported variable/function with a namespace prefix" should be forced on the user of a library.

Also I think the Java intefaces need to be moved into the "Test AI" category and/or git submodule and not built by default. Under Gentoo the JavaOO and/or NullJavaAI have been responsible for 90% of build failures on my system over the last 5 years which is why I now have the -java use flag set in the package.use file for spring.

Also most of us don't want a .Net interface. Spring is cross-platform, please keep it that way.


Top
 Offline Profile  
 
 Post subject: Re: AI Factory
PostPosted: 18 Apr 2013, 05:08 
User avatar

Joined: 13 Jan 2008, 19:40
Location: New Zealand
SpliFF wrote:
What's wrong with exporting a basic set of proceedural functions or simple classes in the interface and letting AI writers apply their own abstractions (Factories, Getters, Services, Gateways, etc) on top of that?


That was the way it used to be, and I was fine with that. I don't know why it was changed.


Top
 Offline Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 47 posts ]  Go to page 1, 2, 3  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


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

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Site layout created by Roflcopter et al.