I can't seem to find any reference about adding players through lua while in game, so how about adding that?
Personally, I'd use it for my mission/scenario editor, but I can imagine it being useful when someone disconnects, f.e to transfer control temporary to an AI, and then give it back to the player when he reconnects.
I'd be fine if we could at least add AIs and new teams.
Also, while I'm at it, is there a way to modify alliances/teams in game?
Add/Remove Players/Bots in-game
Moderator: Moderators
-
- Posts: 834
- Joined: 19 May 2009, 21:10
Re: Add/Remove Players/Bots in-game
ZK does transfer units from afk/disconnected players to active ones and back when they are back.
You could setup an AI team for each alliance without any units from the beginning and transfer the units there. But I think it's better to transfer the units to another human player than AI.
You could setup an AI team for each alliance without any units from the beginning and transfer the units there. But I think it's better to transfer the units to another human player than AI.
Afaik adding/modifying is not possible.gajop wrote:Also, while I'm at it, is there a way to modify alliances/teams in game?
- CarRepairer
- Cursed Zero-K Developer
- Posts: 3359
- Joined: 07 Nov 2007, 21:48
Re: Add/Remove Players/Bots in-game
Unless you count temporary alliances using the /ceasefire command.
-
- Moderator
- Posts: 2464
- Joined: 12 Oct 2007, 09:24
Re: Add/Remove Players/Bots in-game
LuaAI is just a gadget so it can control anything. It could take control of a dropped player easily.
Re: Add/Remove Players/Bots in-game
trough the autohost interface you can already add players:
https://github.com/spring/spring/commit ... 6f4e2f7c74
do you know:
/aikill
/ailist
/aireload
/aicontrol
?
and when luasockets gets intergrated, you could make a hack-around :-O
i know this was a bit off-topic, as it was requested to add a new player trough lua. (but as the functionality in general seems to be already there, it should't be so hard to add the lua-callin)
https://github.com/spring/spring/commit ... 6f4e2f7c74
do you know:
/aikill
/ailist
/aireload
/aicontrol
?
and when luasockets gets intergrated, you could make a hack-around :-O
i know this was a bit off-topic, as it was requested to add a new player trough lua. (but as the functionality in general seems to be already there, it should't be so hard to add the lua-callin)
Re: Add/Remove Players/Bots in-game
nah, it's great info
Good to know it exists even if it's not callable through lua. Also I didn't know about those commands either. Is there any place where they are documented? It seems like I'm missing a lot of useful stuff hidden there.
Good to know it exists even if it's not callable through lua. Also I didn't know about those commands either. Is there any place where they are documented? It seems like I'm missing a lot of useful stuff hidden there.