Bridging the divide

Bridging the divide

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Bridging the divide

Post by AF »

Currently the AI itnerface is beign redesigned btu theres a problem.

None of us can redesign how to interface with lua because we do not understand how the existing interface works at all.

Poking about on the AI side is useless if there's nothing on the lua end to talk to to show we managed to say hello/goodbye

So it would be of immense help if there was a lua gadget that demonstrated receiving messages from AIs and sending them back. This should give a better idea of how to proceed on the AI end.
Kloot
Spring Developer
Posts: 1867
Joined: 08 Oct 2006, 16:58

Re: Bridging the divide

Post by Kloot »

None of us
A version of KAIK I've been working on for IW has had it implemented for
quite a while, AI2Lua is not the dark incomprehensible secret you keep
making it out to be (no demo gadget, the code is really simple enough
to figure out on your own).
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Re: Bridging the divide

Post by AF »

As I said no demo exists and my knowledge of lua is limited at best. I have written a gadget but most of what I learnt is either forgotten or obsolete.

Suffice to say your knowledge is clouding your perception of the lack of knowledge in the rest of us.

I wonder why no mention of the Imperial winter AI gadget has been made here? Is this not counter-productive?
Gnomre
Imperial Winter Developer
Posts: 1754
Joined: 06 Feb 2005, 13:42

Re: Bridging the divide

Post by Gnomre »

Because there's like three lines to it. It's only a callin which, in this case, returns a list of units which can capture the flag points so the AI can know what to park around flags until they are captured, without hardcoding that information.

Kloot did the real work, he just made me add the callin to the script. The callin is AICallIn, btw. As I understand it, the AI still wouldn't be able to handle other things like upgrades but that stuff isn't entirely necessary to play our game.

On a related note, I've been meaning to ask for a copy of KAIK with IW support, Kloot. Could you PM a link?
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Re: Bridging the divide

Post by AF »

How would I use AICallin? A basic level of lua knowledge is being assumed here that I do not have. Please don't harang me for asking for help =/

If it were so simple then someone should have said something and shown how in a quickpost rather than let the other AI developers scratch their heads in confusion. Its more a case of AI developers with no experience in the lua end of things not having a clue where to start looking, that an AI developer figured it out and kept it from the rest is adding insult to injury, and despite that this solution is apparently a 3 liner is even more worrying.
imbaczek
Posts: 3629
Joined: 22 Aug 2006, 16:19

Re: Bridging the divide

Post by imbaczek »

You put it in the mod someplace interesting and give it stuff that your AI needs. Then, in the AI, you receive the exact same stuff and do what you want.

This needs cooperation between mod devs and AI devs, obviously.
Post Reply

Return to “Lua Scripts”