[0.12.26] LuaUnitGroup::state returns undocumented value

This subforum contains all the issues which we already resolved.
User avatar
prg
Filter Inserter
Filter Inserter
Posts: 947
Joined: Mon Jan 19, 2015 12:39 am
Contact:

[0.12.26] LuaUnitGroup::state returns undocumented value

Post by prg »

LuaUnitGroup::state is supposed to return a member of defines.groupstate, which contains gathering = 0, moving = 1, attacking = 2. But I've seen this being 4 on occasion which seems to mean something like "can't reach position".

(Also Concepts.html#Command talks about defines.command.goto, this should be go_to_location)
Automatic Belt (and pipe) Planner—Automate yet another aspect of constructing your factory!
kovarex
Factorio Staff
Factorio Staff
Posts: 8258
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: [0.12.26] LuaUnitGroup::state returns undocumented value

Post by kovarex »

Thanks for the report, I updated the values for 0.12.27 to this:

Code: Select all

groupstate =
{
  gathering = 0,
  moving = 1,
  attacking_distraction = 2,
  attacking_target = 3,
  finished = 4
}
Edit: It shows go_to_location http://lua-api.factorio.com/0.12.26/def ... #inventory
User avatar
prg
Filter Inserter
Filter Inserter
Posts: 947
Joined: Mon Jan 19, 2015 12:39 am
Contact:

Re: [0.12.26] LuaUnitGroup::state returns undocumented value

Post by prg »

http://lua-api.factorio.com/0.12.26/Con ... ml#Command -> defines.command.goto

There it is.
Automatic Belt (and pipe) Planner—Automate yet another aspect of constructing your factory!
Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: [0.12.26] LuaUnitGroup::state returns undocumented value

Post by Oxyd »

prg wrote:http://lua-api.factorio.com/0.12.26/Con ... ml#Command -> defines.command.goto

There it is.
I see. That will be fixed in 0.12.27 as well.
Post Reply

Return to “Resolved Problems and Bugs”